Initial contribution of the Adaptation Documentation. default tip
authorGraeme Price <GRAEME.PRICE@NOKIA.COM>
Fri, 15 Oct 2010 14:32:18 +0100
changeset 15 307f4279f433
parent 14 578be2adaf3e
Initial contribution of the Adaptation Documentation.
Adaptation/GUID-003D2C5B-09DC-5BD1-AF45-A0FCB56F567B.dita
Adaptation/GUID-009D71C6-481F-5EF1-B230-EB64F67047C8.dita
Adaptation/GUID-01072199-382F-4691-AC0D-D1226EE5CF2F.dita
Adaptation/GUID-01F1F488-8E95-56B0-818E-6096CAE4C50C.dita
Adaptation/GUID-024EE22F-4B86-48EF-A55E-C9C1C7E9BADB.dita
Adaptation/GUID-02B40662-B5F3-59BD-832B-9A28FE3B51C7.dita
Adaptation/GUID-0346036B-A470-4C18-B276-3A3485F6A069.dita
Adaptation/GUID-04FF36CE-DEFA-45DC-BAAF-77F3BB649AFF-master.png
Adaptation/GUID-04FF36CE-DEFA-45DC-BAAF-77F3BB649AFF_d0e499_href.png
Adaptation/GUID-052F58B7-117B-5EDD-A3D5-CB0DE6A4E239.dita
Adaptation/GUID-0563266C-8B5A-5664-9AC6-A5504AB5056F.dita
Adaptation/GUID-058BAEDF-5E04-5BB4-928F-0E0528FD9465.dita
Adaptation/GUID-058FAE44-DF72-53E2-BE62-EDC840A7C87F-master.png
Adaptation/GUID-058FAE44-DF72-53E2-BE62-EDC840A7C87F_d0e25110_href.png
Adaptation/GUID-05DAF5EF-6F2E-562D-9DB1-0985AD4A1E48.dita
Adaptation/GUID-07E0DEC0-A749-4B14-9E73-3AF8ACD28BC6.dita
Adaptation/GUID-0804E71D-8B20-49A2-9F7C-F2D6795681D0.dita
Adaptation/GUID-08867AEC-5866-5583-9AAB-068CB51F5C18.dita
Adaptation/GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita
Adaptation/GUID-092D336A-155A-4F18-AAF7-92E08473700E.dita
Adaptation/GUID-092F414B-2279-4ADB-970F-75DAB8A80BD7.dita
Adaptation/GUID-09EE01E2-BF5E-5302-BA25-46C440ADECF5-master.png
Adaptation/GUID-09EE01E2-BF5E-5302-BA25-46C440ADECF5_d0e11034_href.png
Adaptation/GUID-0A6C8DB8-ED41-4243-BA96-CA691CF9CD19.dita
Adaptation/GUID-0A9C35DA-DF54-5885-AFE0-F4D5B3E49941.dita
Adaptation/GUID-0AB3D313-79FF-4716-AFD4-FF3AA3C2E936.dita
Adaptation/GUID-0AFF5666-6BF9-5022-ADBC-5EFFA743B288.dita
Adaptation/GUID-0C3A4156-E5CF-55F9-91A0-A7961FDEE030.dita
Adaptation/GUID-0C435514-EEC6-5660-BB5F-535790349632.dita
Adaptation/GUID-0C80F447-B82E-5586-9B02-4BC0D365FFD6.dita
Adaptation/GUID-0C8318B1-71D7-5384-97EB-85CBBC3E6B84.dita
Adaptation/GUID-0C84FD76-87B2-4AD1-B23A-2C5C8668BC4C.dita
Adaptation/GUID-0C8C41EC-A8ED-5916-B944-DDDF20FADAF4.dita
Adaptation/GUID-0D2F811C-81C3-526F-8EA4-98E50261BF4B.dita
Adaptation/GUID-0DB79535-E4E6-50BD-852D-B2F177202C9C-master.png
Adaptation/GUID-0DB79535-E4E6-50BD-852D-B2F177202C9C_d0e13227_href.png
Adaptation/GUID-0DC908A1-6CF6-50B5-978F-AF6C8CE04F44.dita
Adaptation/GUID-0E93319A-439E-49D8-BF38-C809FEE4BB74.dita
Adaptation/GUID-0F17BCDF-CF50-40D1-9048-793DC4442B50.dita
Adaptation/GUID-0FE0B646-A62F-55A8-A6E6-587D0909CE19-master.png
Adaptation/GUID-0FE0B646-A62F-55A8-A6E6-587D0909CE19_d0e74784_href.png
Adaptation/GUID-10C986FD-BD56-4F8E-87EC-7B890EFCDAC7.dita
Adaptation/GUID-10D79C75-6AB9-4717-87EF-057F19CB8283.dita
Adaptation/GUID-10F3E16A-8CCE-420A-9D1C-F9891B3D75FE.dita
Adaptation/GUID-10FD1B94-EC0C-458F-839F-B60A8E47BAD6.dita
Adaptation/GUID-10FE825A-4383-4A10-A507-58577BB230FB-master.png
Adaptation/GUID-10FE825A-4383-4A10-A507-58577BB230FB_d0e89974_href.png
Adaptation/GUID-110DB7EF-5E85-5BC4-9BBB-9A37B2D0C3A6.dita
Adaptation/GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F.dita
Adaptation/GUID-113B3755-1797-5D1B-8E07-8A18F5FE1504.dita
Adaptation/GUID-124AC7EE-E227-5358-A755-628FFE257250.dita
Adaptation/GUID-12A4418A-9BC6-4BEB-993D-B55E61240A15.dita
Adaptation/GUID-12CD8E91-4102-5253-A7DE-E5436028764F-master.png
Adaptation/GUID-12CD8E91-4102-5253-A7DE-E5436028764F_d0e18431_href.png
Adaptation/GUID-12EFB295-C527-5F96-81F1-6021D335D865.dita
Adaptation/GUID-132349A6-9A5F-4866-A54D-F01B6F58ABDD.dita
Adaptation/GUID-13664BB9-7D05-594E-95D4-49C0D31D3734-master.png
Adaptation/GUID-13664BB9-7D05-594E-95D4-49C0D31D3734_d0e18989_href.png
Adaptation/GUID-1391CDCC-9A09-54FB-BA7D-BC7A91DB2351.dita
Adaptation/GUID-142C21E1-2629-5215-9FBD-B507436E17DB.dita
Adaptation/GUID-1499E635-B6E3-51A0-AE38-ADF99FF86CD6.dita
Adaptation/GUID-14B65BE7-A166-48B6-B43D-DFF267F87F9E-master.png
Adaptation/GUID-14B65BE7-A166-48B6-B43D-DFF267F87F9E_d0e433_href.png
Adaptation/GUID-159BDA2E-123C-52DF-9F8B-E058379EBFB8.dita
Adaptation/GUID-15FDDEED-89F1-5BE5-97AD-8DFD3640369A.dita
Adaptation/GUID-16423056-C435-5C4D-BE3D-4A15F95F7F68.dita
Adaptation/GUID-178E140F-BB15-5A82-99A6-D1BC0E11E018.dita
Adaptation/GUID-180973A1-5C0A-5A85-82CC-E6B739A7F207.dita
Adaptation/GUID-18DD4FE5-6641-5A0E-A00E-DC0C00639CE4.dita
Adaptation/GUID-197A1071-CDAA-5A87-9981-A52FB32C084E.dita
Adaptation/GUID-1A72F75A-1930-5C32-93B7-20F4934BCFAA.dita
Adaptation/GUID-1A92047A-3C1D-5B4C-949B-98D770F5F530-master.png
Adaptation/GUID-1A92047A-3C1D-5B4C-949B-98D770F5F530_d0e32642_href.png
Adaptation/GUID-1AFAD1C4-340B-4119-94A8-F50E9D8DA8E6.dita
Adaptation/GUID-1BB379B6-C0B5-5099-90A0-1BA39DC2C7DD-master.png
Adaptation/GUID-1BB379B6-C0B5-5099-90A0-1BA39DC2C7DD_d0e25918_href.png
Adaptation/GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC.dita
Adaptation/GUID-1E43E258-A926-5D24-B0A5-8756491C687F.dita
Adaptation/GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita
Adaptation/GUID-209514AE-9457-4ED2-AFE0-FDC059CE2B30.dita
Adaptation/GUID-20F8DA2A-9157-54C5-97D0-4CCA50AB0631.dita
Adaptation/GUID-2281F91F-67BD-5B85-A47F-30A5E683BBF6.dita
Adaptation/GUID-22CCA5B5-D4AB-4ABC-94C6-CD85EC470238.dita
Adaptation/GUID-2344B900-5EC5-4467-BEAD-AB55C88CE63E.dita
Adaptation/GUID-2380FDDE-5489-5B1C-87BB-1FD882E385D2.dita
Adaptation/GUID-240EE926-BAFC-4A53-A8F8-D559BA7BB672.dita
Adaptation/GUID-2490DA46-A57B-4DFD-AA9C-2004D58486E3.dita
Adaptation/GUID-2559E3F7-314B-5DCC-A7FE-A08162A89721.dita
Adaptation/GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita
Adaptation/GUID-2607CCFA-3D24-4716-A447-74304F861C44.dita
Adaptation/GUID-2622DE31-AA12-5FAD-86FB-B13259EFC6D9-master.png
Adaptation/GUID-2622DE31-AA12-5FAD-86FB-B13259EFC6D9_d0e9239_href.png
Adaptation/GUID-2648B61C-6EBD-4668-AACD-EA4B2C435BB2.dita
Adaptation/GUID-26621CA5-B686-53FB-AF3E-96CDD38C8520.dita
Adaptation/GUID-26714A57-B6B4-5E81-B512-FB520718482B.dita
Adaptation/GUID-2700AAC8-A034-5E7D-B0E0-26B49E68BB18.dita
Adaptation/GUID-28844FE0-AE0F-531C-826E-CDA8400A0581.dita
Adaptation/GUID-28F3F720-A2E0-59C9-8BB4-B6124CFC6C89-master.png
Adaptation/GUID-28F3F720-A2E0-59C9-8BB4-B6124CFC6C89_d0e11050_href.png
Adaptation/GUID-29B84A67-9DB7-5F4C-A4D1-A3BDC69015A8.dita
Adaptation/GUID-2ADB873A-1580-476A-9642-AB47D13D4A98.dita
Adaptation/GUID-2AE438CC-F2E4-5FCB-971F-CFFAE5EF81E4-master.png
Adaptation/GUID-2AE438CC-F2E4-5FCB-971F-CFFAE5EF81E4_d0e93636_href.png
Adaptation/GUID-2B7D04D9-98DE-5284-836D-01DB4FA8949D.dita
Adaptation/GUID-2BDDB4F8-3175-411B-A206-FAE27DEBF678.dita
Adaptation/GUID-2C1B74C4-C80D-5EF9-B822-2DA2FCF9B006.dita
Adaptation/GUID-2C312536-2410-42D7-B976-F7CF99492DEA-master.png
Adaptation/GUID-2C312536-2410-42D7-B976-F7CF99492DEA_d0e344_href.png
Adaptation/GUID-2C6B7D51-C201-453D-ABBA-C9EC6B3DBDB2.dita
Adaptation/GUID-2C915A03-AD8C-5924-87BB-953AE323E0FA.dita
Adaptation/GUID-2D8B8FF1-7A35-5E98-BDDB-2B0BD8DE6215.dita
Adaptation/GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8.dita
Adaptation/GUID-2D98DB88-BA48-5EF8-A5F9-0CB8688B0B63-master.png
Adaptation/GUID-2D98DB88-BA48-5EF8-A5F9-0CB8688B0B63_d0e32099_href.png
Adaptation/GUID-2E402D4E-53A9-5BA6-9FBD-B2713DBC7858.dita
Adaptation/GUID-2E42E7EA-FED8-522C-8A5F-F65D799476C9.dita
Adaptation/GUID-2E4F8732-F253-5E0D-9A37-9476541E6004.dita
Adaptation/GUID-2E54DA7D-1094-41C6-AFB0-9999471991F8.dita
Adaptation/GUID-2EC16C9C-7241-46B2-B569-B89751933C57.dita
Adaptation/GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9.dita
Adaptation/GUID-3046453A-AB3A-5491-87A0-00F3514D4768.dita
Adaptation/GUID-306A0B41-94CD-534A-B3BA-FAECB858E9A9.dita
Adaptation/GUID-30978E00-D244-44CD-8F4E-9676DF172A52.dita
Adaptation/GUID-3102F778-DD2F-4C87-A0DF-7FA44C9709D8.dita
Adaptation/GUID-315DD62B-8669-471F-BDDC-BC4D700AEA60.dita
Adaptation/GUID-31CE66F2-B36C-56ED-A399-BA9EFA179DED-master.png
Adaptation/GUID-31CE66F2-B36C-56ED-A399-BA9EFA179DED_d0e75538_href.png
Adaptation/GUID-31FFA810-129A-4E35-A47F-C6D3C1C71D5E.dita
Adaptation/GUID-32B82E5C-FD53-48E6-9ABC-88F82ACF71BC.dita
Adaptation/GUID-3335663A-BC11-556E-B5A6-F83622AE34C3.dita
Adaptation/GUID-33A7D8D4-84D6-56EA-8EAB-2A3A3ACABF77.dita
Adaptation/GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita
Adaptation/GUID-3574BE12-9DA9-573D-8545-3B073005A139.dita
Adaptation/GUID-360DEB3A-3E38-413A-9941-6C758BA01ADE.dita
Adaptation/GUID-365283F1-54B4-519A-81EC-9B5018896DDE-master.png
Adaptation/GUID-365283F1-54B4-519A-81EC-9B5018896DDE_d0e35432_href.png
Adaptation/GUID-36CD752C-45FE-5BFE-A695-11DF085F301F.dita
Adaptation/GUID-3722B946-07CF-4AEA-B228-E50642D6B5BE.dita
Adaptation/GUID-372D2B88-2035-44A5-82CF-57FF131DDEBE.dita
Adaptation/GUID-3773A78D-F491-52EB-AA1D-201636497F28.dita
Adaptation/GUID-37B8243E-027A-49D0-A896-27946DAC9052.dita
Adaptation/GUID-388004AF-6F99-4BBB-A8E0-D75DC5B6790C.dita
Adaptation/GUID-38FD682F-656B-48F7-A553-50BC4F1FB4BB.dita
Adaptation/GUID-3A1BCF46-FFBB-4E4F-A73A-6E68254B23FF.dita
Adaptation/GUID-3A30DA16-ECA8-5639-A9DC-6BE2AD55420B.dita
Adaptation/GUID-3A625B23-354E-5CB4-98CF-FF53AD724FA0.dita
Adaptation/GUID-3A785F02-F4AA-432C-9331-8827029BB384.dita
Adaptation/GUID-3AFE0D8B-FB9B-5355-A63B-FB71DD13E7D0-master.png
Adaptation/GUID-3AFE0D8B-FB9B-5355-A63B-FB71DD13E7D0_d0e73917_href.png
Adaptation/GUID-3B6544CD-FA6E-5AB2-AA63-61186F52167D.dita
Adaptation/GUID-3C34724F-B476-5329-B0B1-6D5A34294979.dita
Adaptation/GUID-3CB74FE6-272E-4176-BC51-E36103CADB09-master.png
Adaptation/GUID-3CB74FE6-272E-4176-BC51-E36103CADB09_d0e94075_href.png
Adaptation/GUID-3E85C075-436F-5D2E-B1F7-0C9EC6D382E3.dita
Adaptation/GUID-3F0053A7-6EE2-5B59-81C2-27EC3CC7820A-master.png
Adaptation/GUID-3F0053A7-6EE2-5B59-81C2-27EC3CC7820A_d0e9276_href.png
Adaptation/GUID-3F47E907-975A-5739-9B03-042CB90D675D.dita
Adaptation/GUID-3FE9C184-1880-51E1-B045-3C2EA4BE204A-master.png
Adaptation/GUID-3FE9C184-1880-51E1-B045-3C2EA4BE204A_d0e78117_href.png
Adaptation/GUID-40880992-B177-4584-84B4-6F6CF096E423-master.png
Adaptation/GUID-40880992-B177-4584-84B4-6F6CF096E423_d0e96877_href.png
Adaptation/GUID-40F2BC43-5022-5F4E-B445-56FEF43FEB8B.dita
Adaptation/GUID-423537D5-2C8A-5C26-8D7B-60446E95F681.dita
Adaptation/GUID-42F8FA5A-BBE4-50DE-917E-D05755019FEC.dita
Adaptation/GUID-431A08D4-46DD-5A9D-B2A4-3D58C9B1E9E7-master.png
Adaptation/GUID-431A08D4-46DD-5A9D-B2A4-3D58C9B1E9E7_d0e18839_href.png
Adaptation/GUID-4353940E-C77B-4080-86AD-7DBE52B0A27B.dita
Adaptation/GUID-43782364-0865-43D0-BC89-D63BA9912FB6.dita
Adaptation/GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita
Adaptation/GUID-44540C74-CD73-5D8E-A9E0-F90F46B4E7B1.dita
Adaptation/GUID-450BF1D4-85D7-45D4-8893-57DA8F1640E9.dita
Adaptation/GUID-455ED16F-D288-42C9-AA7A-AE5822F7A5BC.dita
Adaptation/GUID-4592D493-A47C-5622-8C03-F24FABB4381C-master.png
Adaptation/GUID-4592D493-A47C-5622-8C03-F24FABB4381C_d0e19271_href.png
Adaptation/GUID-463915EE-25DB-4ABD-AA80-1C10CD242072.dita
Adaptation/GUID-465D1450-B1EF-568B-B518-34ACE8C1697C-master.png
Adaptation/GUID-465D1450-B1EF-568B-B518-34ACE8C1697C_d0e9201_href.png
Adaptation/GUID-4804B6E0-9199-5F3E-984A-4B00B3984E45.dita
Adaptation/GUID-4862EA2E-6BFE-5E11-B527-7EBA94BB0EA2.dita
Adaptation/GUID-49379616-C235-598D-AE43-668998AD072B.dita
Adaptation/GUID-4993AF8E-28C3-54BA-8D27-D86E05D39CFD.dita
Adaptation/GUID-4A2E212E-BC1B-5965-9A62-6309CC7CAAAB-master.png
Adaptation/GUID-4A2E212E-BC1B-5965-9A62-6309CC7CAAAB_d0e61647_href.png
Adaptation/GUID-4A2E212E-BC1B-5965-9A62-6309CC7CAAAB_d0e65116_href.png
Adaptation/GUID-4A910E9F-E881-51D7-A84A-CBC6AC343FD1.dita
Adaptation/GUID-4AEF7595-17C0-513E-9568-B212E6194388.dita
Adaptation/GUID-4AFDA3FF-38D1-5EFE-B18A-E3EAAA52EB75.dita
Adaptation/GUID-4C4515EA-A5DD-56B4-94B0-EE48D66013F7.dita
Adaptation/GUID-4C5DB74E-41A5-53CB-A053-CBBEADD31AFF.dita
Adaptation/GUID-4C8E40EE-8CC9-4737-A28E-A18E89356718.dita
Adaptation/GUID-4CB3C746-606F-4533-8BBB-4A1254A74772-master.png
Adaptation/GUID-4CB3C746-606F-4533-8BBB-4A1254A74772_d0e94716_href.png
Adaptation/GUID-4DAC39E0-2EC2-40F7-9AEF-4FDA09F1A151.dita
Adaptation/GUID-4E3C086B-25BE-4DAC-9E21-CFC4F8B792A5.dita
Adaptation/GUID-4E6520E8-4BF1-55D1-B643-81B8D2816D1D-master.png
Adaptation/GUID-4E6520E8-4BF1-55D1-B643-81B8D2816D1D_d0e5246_href.png
Adaptation/GUID-4FDD1F7B-1A4E-5389-A0A4-22727CD42B5B-master.png
Adaptation/GUID-4FDD1F7B-1A4E-5389-A0A4-22727CD42B5B_d0e9110_href.png
Adaptation/GUID-50217E69-F4A9-4B9F-8608-419783046A1E.dita
Adaptation/GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita
Adaptation/GUID-51C5DC6C-0CEE-5F44-8578-AEFBEF90FA4D.dita
Adaptation/GUID-52583CC7-483E-54B5-8094-F0F61BD46B7F.dita
Adaptation/GUID-52702561-DA37-5381-BA0D-76D9A41B2760.dita
Adaptation/GUID-529757E6-ABF2-5C5C-A995-7DED6D298F52.dita
Adaptation/GUID-52B8098A-7695-5EA6-B58F-D730A445C583-master.png
Adaptation/GUID-52B8098A-7695-5EA6-B58F-D730A445C583_d0e77443_href.png
Adaptation/GUID-535C66C9-8B45-4DF3-8404-8ED03ABB4799-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-11-1.dita
Adaptation/GUID-535C66C9-8B45-4DF3-8404-8ED03ABB4799-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1.dita
Adaptation/GUID-535E5C2A-DCFD-4BCB-B26B-11E88BDB8A8A.dita
Adaptation/GUID-53649311-4465-48B5-8D07-A65515950040.dita
Adaptation/GUID-5392507E-45FF-4B20-B257-E58E23685295-master.png
Adaptation/GUID-5392507E-45FF-4B20-B257-E58E23685295_d0e410_href.png
Adaptation/GUID-53944506-5CA2-52BA-8D5A-9EE72092612B.dita
Adaptation/GUID-54042C84-6216-5930-9CBF-BAF635CECD4D.dita
Adaptation/GUID-552530EB-1287-542D-AED3-125387B485C1.dita
Adaptation/GUID-5686E787-537F-5B32-B719-34EF5B7F0D37-master.png
Adaptation/GUID-5686E787-537F-5B32-B719-34EF5B7F0D37_d0e18814_href.png
Adaptation/GUID-57989FF8-5E8F-4C8A-9D38-169AFCA4C078.dita
Adaptation/GUID-583F70B4-5C8C-54FA-A869-E6F073DE1FD6.dita
Adaptation/GUID-58AA7257-0951-42AB-9B6E-AAF63343FEFA-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-5-1.dita
Adaptation/GUID-58AA7257-0951-42AB-9B6E-AAF63343FEFA-GENID-1-2-1-9-1-6-1-8-1-7-1-4-1.dita
Adaptation/GUID-592B6D20-4ABA-5C79-9734-D18E2CE4A86C.dita
Adaptation/GUID-59322A4F-B9CB-5997-B843-C4A80F8D42F1.dita
Adaptation/GUID-59FF3BFE-21E2-554D-99EC-1A1D34AAEB7C-master.png
Adaptation/GUID-59FF3BFE-21E2-554D-99EC-1A1D34AAEB7C_d0e35295_href.png
Adaptation/GUID-5B24741C-7CE0-58E8-98C9-1D1CACCD476F.dita
Adaptation/GUID-5BD2D468-838A-49BC-BA92-F41102D37CBC.dita
Adaptation/GUID-5C17A2E7-DE18-5CFB-A5D5-421D427CD5DD.dita
Adaptation/GUID-5C223AD5-4676-58B4-B3A5-066F6B69AA4D.dita
Adaptation/GUID-5CCF303A-B7D5-570D-9BE8-29DFBE184995.dita
Adaptation/GUID-5CF162CA-4395-58AC-A318-2BF178276A57-master.png
Adaptation/GUID-5CF162CA-4395-58AC-A318-2BF178276A57_d0e69352_href.png
Adaptation/GUID-5E24CFFD-1F87-4B77-B7A0-59A419ADBC90.dita
Adaptation/GUID-5E358AB4-03A7-5859-ABF2-A8B64B74AF56.dita
Adaptation/GUID-5EB03086-A87D-5588-8927-7A7F8DB38366.dita
Adaptation/GUID-5F35ED29-18A0-4764-B84D-B43BF23BF44F.dita
Adaptation/GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita
Adaptation/GUID-5FB6BEFD-579B-4139-B54D-9CDCF2198A14.dita
Adaptation/GUID-5FDAF564-6BE1-544A-B5C0-E0D6E25D82E7-master.png
Adaptation/GUID-5FDAF564-6BE1-544A-B5C0-E0D6E25D82E7_d0e15107_href.png
Adaptation/GUID-6060F138-CEB6-482A-B0E9-BBBE261568B0.dita
Adaptation/GUID-60949ACD-AAA9-540E-85AE-BB173382D548-master.png
Adaptation/GUID-60949ACD-AAA9-540E-85AE-BB173382D548_d0e13468_href.png
Adaptation/GUID-610E0C09-F014-4DA2-8411-D7A0CDAF5BBB-master.png
Adaptation/GUID-610E0C09-F014-4DA2-8411-D7A0CDAF5BBB_d0e90471_href.png
Adaptation/GUID-6114133F-E738-4DF1-8308-B09C02B9CEEA.dita
Adaptation/GUID-616C3426-A8C4-5653-912D-7150944E5836.dita
Adaptation/GUID-622D6337-E60A-5252-8B2B-BA8232927453-master.png
Adaptation/GUID-622D6337-E60A-5252-8B2B-BA8232927453_d0e29152_href.png
Adaptation/GUID-627FC480-AF4F-4B23-8671-6E0A0DABA0EF.dita
Adaptation/GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita
Adaptation/GUID-6381BC82-3060-5023-8221-79B18CCB2CDB.dita
Adaptation/GUID-63CDD34D-936A-459C-B40B-495696204722.dita
Adaptation/GUID-647ADEDA-AB5A-548F-93C3-D099EAE6A030-master.png
Adaptation/GUID-647ADEDA-AB5A-548F-93C3-D099EAE6A030_d0e17089_href.png
Adaptation/GUID-654A788A-526A-4C3F-838C-05B09F0D5445.dita
Adaptation/GUID-6597A895-37D5-51D1-86B3-E74F6E845899-master.png
Adaptation/GUID-6597A895-37D5-51D1-86B3-E74F6E845899_d0e23392_href.png
Adaptation/GUID-65CDCA83-C726-5173-8E46-B8981D1D7B02.dita
Adaptation/GUID-65F012C2-19BA-474E-8E94-D0E89DADF7B8.dita
Adaptation/GUID-660A8E4C-F930-415C-8CCC-CB1DCCAA2442.dita
Adaptation/GUID-669C77A3-89BA-5321-ABB1-4356A5FE478C.dita
Adaptation/GUID-66E5F769-1156-54CA-94BC-8912159A1240.dita
Adaptation/GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita
Adaptation/GUID-670B0580-B81B-4211-A4C0-23A2D8EDF96C.dita
Adaptation/GUID-6752A77F-B1D1-49BE-A672-5DDE3B7976BF.dita
Adaptation/GUID-6786C7D8-34B9-496C-890E-03DE018D2DE1.dita
Adaptation/GUID-67CFF27B-55AF-42AC-95AF-E71A7C54039E.dita
Adaptation/GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita
Adaptation/GUID-68446E8E-129C-444A-836A-EF8F56BFE0BC.dita
Adaptation/GUID-6873E764-4132-46C8-8444-6301CF4D2033.dita
Adaptation/GUID-687997B5-BDFD-49D1-947B-4AB21C3AF58C.dita
Adaptation/GUID-690F943E-7459-4FBA-B33C-258969D7759A-master.png
Adaptation/GUID-690F943E-7459-4FBA-B33C-258969D7759A_d0e93193_href.png
Adaptation/GUID-6A4FE3A3-2E5D-51BB-8272-5995586291E9.dita
Adaptation/GUID-6AC01B10-92C1-4E56-813B-6853DFCF3386-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-4-1.dita
Adaptation/GUID-6AC01B10-92C1-4E56-813B-6853DFCF3386-GENID-1-2-1-9-1-6-1-8-1-7-1-5-1.dita
Adaptation/GUID-6B2221F2-A598-4677-A2D3-40FF27C7373F.dita
Adaptation/GUID-6B9041F7-79A6-5CCA-9B4D-B8EF377FD378.dita
Adaptation/GUID-6C27AAD6-EB88-53AF-8E04-921A957042CF.dita
Adaptation/GUID-6C74A8B4-50B6-486C-A75F-A50636F4C566.dita
Adaptation/GUID-6CCF249B-DEDD-4E0B-A081-0FCD9FCCBB5A.dita
Adaptation/GUID-6CE68645-D8C5-52E1-88B3-76AEFB80DE51.dita
Adaptation/GUID-6D75968E-53CF-5436-8390-54CA12BCFDE9.dita
Adaptation/GUID-6DE69F29-45B0-5E62-AA13-DA4041B1BC46.dita
Adaptation/GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita
Adaptation/GUID-6E208C69-AC2C-4A7A-8203-2C4C3F2E54F5.dita
Adaptation/GUID-6E89E787-749D-5AC5-957D-967B4B9ACD74.dita
Adaptation/GUID-6EB38F10-849D-5763-96A0-A0A108982D67-master.png
Adaptation/GUID-6EB38F10-849D-5763-96A0-A0A108982D67_d0e63496_href.png
Adaptation/GUID-6EF762B8-DE93-51C0-8A5D-89FC5289B7D0.dita
Adaptation/GUID-6F82A35E-9F11-591D-AA5C-8F60734A2827.dita
Adaptation/GUID-70041B11-4C03-42C6-9EC2-307E5FF0F626.dita
Adaptation/GUID-71271D1C-C385-5687-8A90-46E8B590BB1E-master.png
Adaptation/GUID-71271D1C-C385-5687-8A90-46E8B590BB1E_d0e1517_href.png
Adaptation/GUID-73B853D5-13E6-54E7-AA8B-C41EEDB5EA7F.dita
Adaptation/GUID-73D9E2F2-5965-479E-97DB-C3773DA0D90C.dita
Adaptation/GUID-73F220EA-F41F-56A5-BAEB-4A37174CFD1F.dita
Adaptation/GUID-746BD53F-F637-4BC9-91AC-E53BA182B823-master.png
Adaptation/GUID-746BD53F-F637-4BC9-91AC-E53BA182B823_d0e87730_href.png
Adaptation/GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita
Adaptation/GUID-772C2721-DD84-54A6-ACE0-ECACC6432B95.dita
Adaptation/GUID-775901A4-0262-4E14-9E9C-C4E37DFCCF2E.dita
Adaptation/GUID-782E8D92-0431-50F5-95A0-5B231EBDF391-master.png
Adaptation/GUID-782E8D92-0431-50F5-95A0-5B231EBDF391_d0e25767_href.png
Adaptation/GUID-788ECC4B-36B9-493C-A86E-E6C8007074B1.dita
Adaptation/GUID-78963104-C2B0-4E19-99E5-FEAEB7EA307A.dita
Adaptation/GUID-795B8649-B6C3-5540-B52A-9B460F35A5B5.dita
Adaptation/GUID-79620372-BADC-4826-A3AC-7FDBCFF98DA9.dita
Adaptation/GUID-796CB42C-29AC-5ECC-AC6E-35FC6B8CC84E.dita
Adaptation/GUID-79B2CF91-FB95-5E7C-81CC-235A6A660D88.dita
Adaptation/GUID-7A50630B-2B44-5D27-AA18-3BEEE1453020.dita
Adaptation/GUID-7AB0C7E2-8B7C-5CC3-BAA5-15AA59F31181.dita
Adaptation/GUID-7AB51180-7A1A-40C7-B28F-EA46314A6E5B-GENID-1-2-1-9-1-5-1-4-1.dita
Adaptation/GUID-7AB51180-7A1A-40C7-B28F-EA46314A6E5B-GENID-1-2-1-9-1-6-1-9-1-5-1.dita
Adaptation/GUID-7B0BA327-54A0-4908-B8E3-0C82112EB957-master.png
Adaptation/GUID-7B0BA327-54A0-4908-B8E3-0C82112EB957_d0e93167_href.png
Adaptation/GUID-7B9D4E46-6AF9-5B77-9BE3-8B1DFAC588BD.dita
Adaptation/GUID-7BB36477-0FE2-51D5-B4C0-86F7265C1B94.dita
Adaptation/GUID-7BCC0EFA-0DD5-4879-BECF-C32D04BC8A39.dita
Adaptation/GUID-7BCDDA55-1460-5411-AFCF-C4640BEB9DE4.dita
Adaptation/GUID-7C064328-8368-4259-9CE1-B8DFE2DF4AAC.dita
Adaptation/GUID-7C533836-0D27-5519-BC1D-7153AC8BE4C0.dita
Adaptation/GUID-7D535B68-CA7F-4796-80FB-AE7A27642A88.dita
Adaptation/GUID-7DDF052C-2520-428D-932D-BDB476344575.dita
Adaptation/GUID-7E357DA2-67AD-403A-B4E1-7CB83E75136F.dita
Adaptation/GUID-7E3BBB18-3113-4312-AD91-897DE87C58BF.dita
Adaptation/GUID-7ECDCF7B-3B2A-561F-9136-04BC4DAE46E4.dita
Adaptation/GUID-80698E62-E310-59CA-A524-5CF44C437BE4.dita
Adaptation/GUID-80E0DB93-A96A-54A8-A201-E11935418BE7.dita
Adaptation/GUID-812DEBEB-84D0-5BD4-A5BB-5AF6B8384CCF.dita
Adaptation/GUID-817E0561-6165-5BB1-97F9-AD53CFCDAA56.dita
Adaptation/GUID-81C69779-27AE-55E0-ACCF-E4F3E6657427.dita
Adaptation/GUID-81DD805C-90B5-5227-B62B-F2413855BD9A.dita
Adaptation/GUID-834781AF-D202-5752-B81A-A51D12A4D1EC.dita
Adaptation/GUID-84D56A30-1E97-40AE-BFB0-E33495E95AAC.dita
Adaptation/GUID-85332468-292D-589B-891B-0E7ACBADC7BA-master.png
Adaptation/GUID-85332468-292D-589B-891B-0E7ACBADC7BA_d0e11000_href.png
Adaptation/GUID-8552E66E-73D6-51DA-8F53-DDF437186CD6.dita
Adaptation/GUID-857F981E-711B-5CA8-AB37-5C700A6140FA.dita
Adaptation/GUID-85C18DAF-DB76-51C6-B38D-A802E314F4D1.dita
Adaptation/GUID-86082C0C-B0EE-5E7C-85B4-4A509066012F.dita
Adaptation/GUID-862CA4C4-C6E8-4D60-8DD0-F3590C92E15D.dita
Adaptation/GUID-86737CAB-2A4A-4424-8856-67E0804BCD60.dita
Adaptation/GUID-86C21C9B-9F08-579F-84E9-CBE46F756373-master.png
Adaptation/GUID-86C21C9B-9F08-579F-84E9-CBE46F756373_d0e10964_href.png
Adaptation/GUID-877EEB52-40C8-4880-87A0-9736A625F85F.dita
Adaptation/GUID-8798F896-E0CB-4B9B-8F88-3C8B58574213.dita
Adaptation/GUID-892931C3-E560-54AA-A9CB-2820BF025E52.dita
Adaptation/GUID-898704CF-26A1-50F5-BEFE-1E29D85064AA.dita
Adaptation/GUID-89BCF9A5-ABBD-5523-BA76-FDB00B806A30.dita
Adaptation/GUID-8A1B6104-4B13-5200-AF3D-64B3929707BB-master.png
Adaptation/GUID-8A1B6104-4B13-5200-AF3D-64B3929707BB_d0e14531_href.png
Adaptation/GUID-8A5EC98B-E9AD-5496-9909-7C3B35610785.dita
Adaptation/GUID-8A78D678-D1C8-4A4E-9BF1-81C7019815C3-master.png
Adaptation/GUID-8A78D678-D1C8-4A4E-9BF1-81C7019815C3_d0e94711_href.png
Adaptation/GUID-8B7E2A72-B793-5E70-87F0-92AA0A482F23.dita
Adaptation/GUID-8B8CAEED-A89D-53B3-A311-51CF45B334B1.dita
Adaptation/GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita
Adaptation/GUID-8C22AF20-EE0E-5AD2-BEFD-FED5A7DBB09B.dita
Adaptation/GUID-8C9F26BC-2579-545C-9A86-9C45E06679F0-master.png
Adaptation/GUID-8C9F26BC-2579-545C-9A86-9C45E06679F0_d0e32265_href.png
Adaptation/GUID-8D237BD6-9759-4180-B190-F1624594017F.dita
Adaptation/GUID-8D7ED882-C61E-4B4F-8483-A323C60BFC57.dita
Adaptation/GUID-8D9A9283-6E55-4AC8-89CE-DD2B55D05067.dita
Adaptation/GUID-8DC12024-7599-52E8-BCF1-D9D765EC7B9B.dita
Adaptation/GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita
Adaptation/GUID-8F78705E-CD82-5039-A7CB-7C963F7FBA83-master.png
Adaptation/GUID-8F78705E-CD82-5039-A7CB-7C963F7FBA83_d0e69457_href.png
Adaptation/GUID-8FA1B2B0-5842-4D5D-BD61-C2D79B56ADC6.dita
Adaptation/GUID-904C9C5A-5FDB-5978-88CF-E30D6C0DBB61-master.png
Adaptation/GUID-904C9C5A-5FDB-5978-88CF-E30D6C0DBB61_d0e8869_href.png
Adaptation/GUID-90B5FDD9-7D59-5035-BF53-2B177655DCD6.dita
Adaptation/GUID-9173EEBA-CC84-51D9-9C8D-A75F7F494D62-master.png
Adaptation/GUID-9173EEBA-CC84-51D9-9C8D-A75F7F494D62_d0e9004_href.png
Adaptation/GUID-91958EA5-9444-5895-B4B8-F2C670B81CD7-master.png
Adaptation/GUID-91958EA5-9444-5895-B4B8-F2C670B81CD7_d0e11017_href.png
Adaptation/GUID-919E48BE-6AA1-54CC-8B70-3A4B3A9C6CF1.dita
Adaptation/GUID-921AF7A3-C711-5979-877B-4B6D977888E8-master.png
Adaptation/GUID-921AF7A3-C711-5979-877B-4B6D977888E8_d0e5006_href.png
Adaptation/GUID-922E4771-C1FD-5C88-9C11-57499684DB97.dita
Adaptation/GUID-93DA75DE-096F-5E40-A47E-5A1A94C3145A.dita
Adaptation/GUID-9573F7B9-76E9-5DCB-A498-C0DE59606911.dita
Adaptation/GUID-9595FD6F-1EDE-51A8-B00D-029CFDFE0F38.dita
Adaptation/GUID-9597DB22-D932-5A58-9C3C-4E5FCA244253.dita
Adaptation/GUID-95A33491-17AC-4F12-948E-A1352ADDA483.dita
Adaptation/GUID-95BD3650-08CB-407D-969E-DFDB39B2FEFC.dita
Adaptation/GUID-95CE7187-66B2-581A-A5B8-6359AD431E87.dita
Adaptation/GUID-970EC5A9-8ED3-53C5-93A3-2EC1A7B6F25F-master.png
Adaptation/GUID-970EC5A9-8ED3-53C5-93A3-2EC1A7B6F25F_d0e13980_href.png
Adaptation/GUID-97F97D7B-D5A3-5471-A359-77B805ED198C.dita
Adaptation/GUID-98210124-0B65-4679-BB3A-E94B9999365C.dita
Adaptation/GUID-984C2A0D-36BE-5A99-9D65-3F8791C669FF.dita
Adaptation/GUID-99637158-DE86-4BB4-98D4-3A3E64AB768F-master.png
Adaptation/GUID-99637158-DE86-4BB4-98D4-3A3E64AB768F_d0e87314_href.png
Adaptation/GUID-9986DCC6-EE73-59FB-BDAC-9B09DC64FBCE.dita
Adaptation/GUID-99C4FCCC-9E8B-51CC-85F8-F03BE18DF19E-master.png
Adaptation/GUID-99C4FCCC-9E8B-51CC-85F8-F03BE18DF19E_d0e82580_href.png
Adaptation/GUID-99F7E70F-2733-57B2-94F5-A0C0FF9219FE-master.png
Adaptation/GUID-99F7E70F-2733-57B2-94F5-A0C0FF9219FE_d0e10765_href.png
Adaptation/GUID-99FC067C-0AED-5373-AF63-8DB7FF5C1F7E.dita
Adaptation/GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita
Adaptation/GUID-9B52E0C3-9EBB-44C6-A1BF-2F95711FFBA4.dita
Adaptation/GUID-9B66387C-B6CF-41D9-BEFC-F79E30C70F52.dita
Adaptation/GUID-9BBDFF77-5E2C-4E13-BEB3-716CC80B3375.dita
Adaptation/GUID-9C05C157-D58E-4C43-87E4-82B4F310AEA9.dita
Adaptation/GUID-9CC514E9-85C2-5F4B-9F3B-F9FA1F4CB20A-master.png
Adaptation/GUID-9CC514E9-85C2-5F4B-9F3B-F9FA1F4CB20A_d0e14358_href.png
Adaptation/GUID-9CF985F1-C100-5999-9410-58B7865A1E18.dita
Adaptation/GUID-9D26E38F-5C7B-5330-A54B-8F97D0F204D0-GENID-1-2-1-8-1-1-7-1-1-5-1.dita
Adaptation/GUID-9D26E38F-5C7B-5330-A54B-8F97D0F204D0-GENID-1-2-1-9-1-8-1-19-1.dita
Adaptation/GUID-9D4B8CDF-60D7-5952-AAAF-94A3C1E8908F.dita
Adaptation/GUID-9D8C62FB-1E42-5B69-8ECC-2B68AD7C71A5-master.png
Adaptation/GUID-9D8C62FB-1E42-5B69-8ECC-2B68AD7C71A5_d0e25863_href.png
Adaptation/GUID-A04F46F8-1BA9-5A77-B455-59C67DD4AA36.dita
Adaptation/GUID-A25FFD79-0797-43EC-8975-8C23E7E539C4.dita
Adaptation/GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita
Adaptation/GUID-A328F9E3-7D91-594A-A589-E8CE5FA9227A-master.png
Adaptation/GUID-A328F9E3-7D91-594A-A589-E8CE5FA9227A_d0e69077_href.png
Adaptation/GUID-A3A3405C-C89C-5079-85CE-8CB069C8E0C0.dita
Adaptation/GUID-A4179FF3-4541-44B8-A8F3-52C1318159B3.dita
Adaptation/GUID-A4C19890-2380-5498-A5F8-3B6D95CEFEF4.dita
Adaptation/GUID-A4CCF2B6-26B7-5E8C-B738-9EE9E68A0B35.dita
Adaptation/GUID-A51C3E48-3ED0-519B-A128-C5175D7E175B-master.png
Adaptation/GUID-A51C3E48-3ED0-519B-A128-C5175D7E175B_d0e19782_href.png
Adaptation/GUID-A568F9D3-58E3-58D6-8A6E-4EC6BEC41A4D-master.png
Adaptation/GUID-A568F9D3-58E3-58D6-8A6E-4EC6BEC41A4D_d0e29723_href.png
Adaptation/GUID-A6845EB0-4B4D-49C8-85A5-A933A2C351CF-master.png
Adaptation/GUID-A6845EB0-4B4D-49C8-85A5-A933A2C351CF_d0e89230_href.png
Adaptation/GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930.dita
Adaptation/GUID-A70A01D2-467E-5BA8-A01D-6182558F3F52.dita
Adaptation/GUID-A74BC61D-85E6-5DB5-93F4-DFE4F0B93EF2.dita
Adaptation/GUID-A74F0245-1A37-41C8-B0E9-63AF858EE4B6.dita
Adaptation/GUID-A789E0D6-74B2-517D-B73A-F9B11794F175.dita
Adaptation/GUID-A7ECF51F-F96A-5251-A71F-2F269C8C0664.dita
Adaptation/GUID-A819DE06-7B00-4643-9D3E-EFE14132981C-master.png
Adaptation/GUID-A819DE06-7B00-4643-9D3E-EFE14132981C_d0e99133_href.png
Adaptation/GUID-A819DE06-7B00-4643-9D3E-EFE14132981C_d0e99345_href.png
Adaptation/GUID-A87D9280-B61A-49BA-A9AF-178DB9BAECBC.dita
Adaptation/GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1.dita
Adaptation/GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1.dita
Adaptation/GUID-AA53650C-664C-53F0-8BE9-445677FC1FE2-master.png
Adaptation/GUID-AA53650C-664C-53F0-8BE9-445677FC1FE2_d0e19130_href.png
Adaptation/GUID-AABC7605-9EE9-41E4-BFDF-77A589A9887B.dita
Adaptation/GUID-AB5370D9-9F0B-4583-A825-11CBF7C6365C.dita
Adaptation/GUID-AB9175EB-1B61-5341-B6B9-5613A7862D74.dita
Adaptation/GUID-ABE7BC1A-C51B-5ADD-8568-87A81423B648-master.png
Adaptation/GUID-ABE7BC1A-C51B-5ADD-8568-87A81423B648_d0e77808_href.png
Adaptation/GUID-AC2E5824-4E69-4964-968F-839EB5D2EF4F.dita
Adaptation/GUID-AC560324-798C-5D0A-B23D-2419A7688A5B.dita
Adaptation/GUID-AC7830F9-C3FB-5117-B851-1D106AE400D4-master.png
Adaptation/GUID-AC7830F9-C3FB-5117-B851-1D106AE400D4_d0e10568_href.png
Adaptation/GUID-ACA48BEE-FE73-5C47-B022-E50728CEDBEE.dita
Adaptation/GUID-ACB79CEF-CA4D-5C96-AFCD-6AD7C7C26C53.dita
Adaptation/GUID-ACC010D4-B419-4CDD-8091-C85579575D46-master.png
Adaptation/GUID-ACC010D4-B419-4CDD-8091-C85579575D46_d0e94724_href.png
Adaptation/GUID-AD195629-81CE-5E57-A59E-C67AACF7A2C2.dita
Adaptation/GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51.dita
Adaptation/GUID-ADB848FD-317A-521C-9684-BBCF20358207.dita
Adaptation/GUID-ADC42B89-B061-50C3-B532-6065A0C418C3.dita
Adaptation/GUID-AE486C82-8854-463F-8CB9-B7353D6B2804.dita
Adaptation/GUID-AE53C15E-0C0F-5726-BBA4-E7DCDA7F48B4-master.png
Adaptation/GUID-AE53C15E-0C0F-5726-BBA4-E7DCDA7F48B4_d0e9145_href.png
Adaptation/GUID-AEDBF425-6077-4C84-A698-508291671F2B-master.png
Adaptation/GUID-AEDBF425-6077-4C84-A698-508291671F2B_d0e27993_href.png
Adaptation/GUID-AF245763-EB25-49BC-90DC-0BD5F2D22AA5.dita
Adaptation/GUID-AF2E227B-C5BD-5F05-98D4-7D15530161C8.dita
Adaptation/GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07.dita
Adaptation/GUID-AFA1604D-FF0C-56BE-A71E-AF3C662F8943.dita
Adaptation/GUID-B0FA9741-CB42-560F-A13E-78FAA57F7871-master.png
Adaptation/GUID-B0FA9741-CB42-560F-A13E-78FAA57F7871_d0e93088_href.png
Adaptation/GUID-B0FA9741-CB42-560F-A13E-78FAA57F7871_d0e93496_href.png
Adaptation/GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671.dita
Adaptation/GUID-B2F86F54-EF50-56DB-ADF7-15325AC9324D.dita
Adaptation/GUID-B30D6027-EB0F-578F-9B2F-AFC2DFD27E39-master.png
Adaptation/GUID-B30D6027-EB0F-578F-9B2F-AFC2DFD27E39_d0e19057_href.png
Adaptation/GUID-B345CDED-92DC-50ED-BC87-AC3C903E5E10.dita
Adaptation/GUID-B35A70D2-1BC8-51DE-95BF-F315DB394582.dita
Adaptation/GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita
Adaptation/GUID-B4C05C46-F2C9-57FA-AD85-EFE6479C2FF1.dita
Adaptation/GUID-B5657E8C-770C-4322-88B2-057AAEF62E95.ditamap
Adaptation/GUID-B5657E8C-770C-4322-88B2-057AAEF62E95.ditaoriginal
Adaptation/GUID-B6A21D4A-86D3-45A9-95AE-A0206D15944B.dita
Adaptation/GUID-B6F0C909-6E58-584E-9270-8066337FCE0F.dita
Adaptation/GUID-B7C56FF9-FE1B-58C3-BBD4-7479F0BEE555.dita
Adaptation/GUID-B7E7E6D6-7824-505C-BA0B-B7861897E78F-master.png
Adaptation/GUID-B7E7E6D6-7824-505C-BA0B-B7861897E78F_d0e13349_href.png
Adaptation/GUID-B8B36A53-CB13-41C1-9CCC-CA5AABE13BF6.dita
Adaptation/GUID-B94FFCA4-1EB3-46A7-9FF9-54C55D67FFE8.dita
Adaptation/GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita
Adaptation/GUID-B97BAC2E-04E3-4979-BACE-9C46BADE912E.dita
Adaptation/GUID-B9B35999-0937-51C5-BB77-91A6C039CE2F.dita
Adaptation/GUID-BA0AC9AA-A8E1-5650-9512-DEC06D77668F.dita
Adaptation/GUID-BA3B42A2-141C-49D9-B513-1571C246C19B.dita
Adaptation/GUID-BA4E634D-5B03-4848-8D42-743914D0955E.dita
Adaptation/GUID-BB507973-77A4-4DC1-91C0-65E3CA2CF790.dita
Adaptation/GUID-BBEA9F6B-2F0C-584E-BF12-256E27605499.dita
Adaptation/GUID-BC0936D7-7064-447D-83EF-68C65CF3D1B0.dita
Adaptation/GUID-BD0D62CD-A067-4A87-8779-CC245E2C4CEA.dita
Adaptation/GUID-BDB847A2-557A-5902-AA6D-C1AE10D8E493.dita
Adaptation/GUID-BDF1F32B-796B-4D3D-9C91-43FF8E9DDAF9.dita
Adaptation/GUID-BDFAE7E7-18B2-4B5D-8349-CC6C607B717A.dita
Adaptation/GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF.dita
Adaptation/GUID-BE73CFE6-D48D-5B92-AF49-E2D967ADF0EC.dita
Adaptation/GUID-BF04B68E-7F77-5D99-A0F6-2842758EFD4D.dita
Adaptation/GUID-BF157EE2-B680-554A-AE32-69C652B61FA6-master.png
Adaptation/GUID-BF157EE2-B680-554A-AE32-69C652B61FA6_d0e29926_href.png
Adaptation/GUID-BF86E9F9-531A-51A1-90B4-23B51604F5B4.dita
Adaptation/GUID-BFE1422D-3B4A-5B25-A757-B5B68D6390F8.dita
Adaptation/GUID-C059F39F-BC53-5C92-B05E-863B8CF22859.dita
Adaptation/GUID-C06CFF3E-23E9-5E0B-99A1-51B8ED95465F.dita
Adaptation/GUID-C0DC5D95-2EB5-45D9-A859-78329A4B3EF1.dita
Adaptation/GUID-C2114C7B-705C-4527-836A-C6E72227111A.dita
Adaptation/GUID-C22974D8-CFB9-4A83-BE58-CCC97EA8DF13.dita
Adaptation/GUID-C244D421-8BD0-4212-A5C5-47A8B1E0C1E2.dita
Adaptation/GUID-C24A5B52-0B40-53B2-BF85-6ECC35BDCBA5.dita
Adaptation/GUID-C34DFF54-87C5-47F6-B0AE-3B066DC7F5A0.dita
Adaptation/GUID-C38DA704-8868-479B-AF81-375E0A2F5BCC.dita
Adaptation/GUID-C3C89BD7-A56D-4597-8804-01A25BC71581.dita
Adaptation/GUID-C3CE35FF-240E-5385-9088-38EF926ABB7B-master.png
Adaptation/GUID-C3CE35FF-240E-5385-9088-38EF926ABB7B_d0e29836_href.png
Adaptation/GUID-C57086D7-7672-4A52-8634-D28B37AC6290.dita
Adaptation/GUID-C649DB97-F138-4C90-B177-16590F2E3F19-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-3-1.dita
Adaptation/GUID-C649DB97-F138-4C90-B177-16590F2E3F19-GENID-1-2-1-9-1-6-1-8-1-7-1-3-1.dita
Adaptation/GUID-C661B40F-1439-587F-9E8E-DB2DFC79C040.dita
Adaptation/GUID-C661BFA4-6C39-476A-8DE0-08E18AA0F548.dita
Adaptation/GUID-C6647E84-7237-44FC-BD5D-2476EC161D02.dita
Adaptation/GUID-C6825C8F-8020-58CF-A09E-34558B1542DE.dita
Adaptation/GUID-C6ABE2CA-901E-55F1-9837-7018A1612BCF.dita
Adaptation/GUID-C74770A5-ADD4-4AB1-946F-77105E2B8C10-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-6-1.dita
Adaptation/GUID-C74770A5-ADD4-4AB1-946F-77105E2B8C10-GENID-1-2-1-9-1-6-1-8-1-7-1-6-1.dita
Adaptation/GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita
Adaptation/GUID-C8450E58-A603-5CF8-993E-053C990DDA19-master.png
Adaptation/GUID-C8450E58-A603-5CF8-993E-053C990DDA19_d0e9181_href.png
Adaptation/GUID-C8DF0CB0-92F4-5F9E-A8F1-7DE50954C4F1.dita
Adaptation/GUID-C92CC81A-35A1-5860-AA08-C8C08B39804C.dita
Adaptation/GUID-C9644081-004E-5DA0-8133-A32EEA91EF5E.dita
Adaptation/GUID-C98DF912-A903-4FDB-B27A-CC8E75E3E40F.dita
Adaptation/GUID-C9923DF3-8425-4EB4-8066-FB5A92A85F5B.dita
Adaptation/GUID-CA788AFE-D425-4B72-B8A2-34D38A8C341B.dita
Adaptation/GUID-CAEDFD1D-ECA1-5A6F-9861-63B7BE24E9E4.dita
Adaptation/GUID-CB0FC4F4-6DAB-4ADD-B044-0E8B9365B4D5.dita
Adaptation/GUID-CB3A8650-751C-4DAA-9408-7AEB3C7FD41A.dita
Adaptation/GUID-CC04A14B-A839-5613-820D-F1E65EB2DF7F.dita
Adaptation/GUID-CDB2DD00-482D-5AEA-AF89-064C8F904DD9.dita
Adaptation/GUID-CDDD8189-D532-5179-92F6-74264C2E3D81-master.png
Adaptation/GUID-CDDD8189-D532-5179-92F6-74264C2E3D81_d0e35308_href.png
Adaptation/GUID-CE9EA167-0594-5E61-9640-6B2B63A92EA7.dita
Adaptation/GUID-CEA3343B-138E-4D6B-8E5F-A255C5C73376.dita
Adaptation/GUID-CEDA0EFF-A1D4-53FE-9BF2-DB9AA857BCF5-master.png
Adaptation/GUID-CEDA0EFF-A1D4-53FE-9BF2-DB9AA857BCF5_d0e3163_href.png
Adaptation/GUID-CF252B09-335E-5831-94A6-0B16B64C5030-master.png
Adaptation/GUID-CF252B09-335E-5831-94A6-0B16B64C5030_d0e10851_href.png
Adaptation/GUID-CF710BE5-531D-4287-9002-39E7DE27FACA.dita
Adaptation/GUID-CFE0A4EB-845C-43B6-A732-AA155AFD99D6.dita
Adaptation/GUID-D003030D-8506-4210-9194-7A3819205D68.dita
Adaptation/GUID-D048E187-6B1C-5A80-9CD0-89CD10688C6F.dita
Adaptation/GUID-D089C2E9-1BE4-4B37-B8A8-21E5B2425E6C.dita
Adaptation/GUID-D0F5D40A-28D2-4A2E-9B40-180537E60F56.dita
Adaptation/GUID-D1C5BB01-6780-41D6-B47B-43D4C983B0B6.dita
Adaptation/GUID-D1F7D21F-BA9D-482C-9B58-7C53A680145A.dita
Adaptation/GUID-D207C135-EF02-4D1A-A48C-4AB8C6703496.dita
Adaptation/GUID-D2163920-D448-5BFC-B655-B654FD657A94.dita
Adaptation/GUID-D291C9E9-5207-4B23-B287-C240464087B9.dita
Adaptation/GUID-D2D41326-BA88-5A02-805B-5EAEC29ADB5D-master.png
Adaptation/GUID-D2D41326-BA88-5A02-805B-5EAEC29ADB5D_d0e19383_href.png
Adaptation/GUID-D34DB4A1-1B17-5FAF-A48B-E06D247B0A83.dita
Adaptation/GUID-D43AB2F5-32AE-540C-80D8-DE8B2072F1E6-master.png
Adaptation/GUID-D43AB2F5-32AE-540C-80D8-DE8B2072F1E6_d0e10612_href.png
Adaptation/GUID-D477EB1F-89CF-5836-BAA2-6D731D50D99F.dita
Adaptation/GUID-D5030CC5-1FC1-40F3-9D68-4A454B25C58B-master.png
Adaptation/GUID-D5030CC5-1FC1-40F3-9D68-4A454B25C58B_d0e103563_href.png
Adaptation/GUID-D520CBC3-FCAC-5A53-AE1A-E5254ABBC6A2.dita
Adaptation/GUID-D5ED62EB-744D-42EB-B8CF-D5623BDA5B38.dita
Adaptation/GUID-D5EE0A17-2246-4CB3-9CE5-538F1E01F8D4.dita
Adaptation/GUID-D683DBD8-15AA-5F2F-826C-B56CCE1DC06E.dita
Adaptation/GUID-D6861A7A-1845-52AF-BB09-4B97E6B8AA13-master.png
Adaptation/GUID-D6861A7A-1845-52AF-BB09-4B97E6B8AA13_d0e10260_href.png
Adaptation/GUID-D729BD58-D4FE-5D46-ACD4-F78B37BA833A.dita
Adaptation/GUID-D7D7615F-B67D-44D0-82DF-24853159A114.dita
Adaptation/GUID-D8911BE6-100D-588A-8E5C-A429A72AFCDA-master.png
Adaptation/GUID-D8911BE6-100D-588A-8E5C-A429A72AFCDA_d0e19356_href.png
Adaptation/GUID-D8A3C18B-A107-5557-B882-CD6CDD0F0F1D-master.png
Adaptation/GUID-D8A3C18B-A107-5557-B882-CD6CDD0F0F1D_d0e76208_href.png
Adaptation/GUID-DA382265-232F-40F4-92ED-C90E6DE3D709.dita
Adaptation/GUID-DA62FD4F-2E74-5B2F-B703-4A40DF5F01CA.dita
Adaptation/GUID-DA7751A1-4EC5-5FBA-A42B-E254133A1D82-master.png
Adaptation/GUID-DA7751A1-4EC5-5FBA-A42B-E254133A1D82_d0e76254_href.png
Adaptation/GUID-DB0EDBC2-8204-59F3-9029-EBBCE04A9E3C-master.png
Adaptation/GUID-DB0EDBC2-8204-59F3-9029-EBBCE04A9E3C_d0e9220_href.png
Adaptation/GUID-DB441DFF-0075-5122-A2EB-A6EF76375D71.dita
Adaptation/GUID-DB55C1A0-2901-4661-B6B1-3B61BF6FF4FA.dita
Adaptation/GUID-DBEAD516-5DD4-5E33-B6DA-657C1AE60C4B.dita
Adaptation/GUID-DC2CF276-95E2-5810-9B8D-EB8B72E04FEC.dita
Adaptation/GUID-DC8D3736-EDCF-54CB-A614-2AAC4664F1CA.dita
Adaptation/GUID-DCBBDFA7-1E6C-5B00-A13E-A25794668E12-master.png
Adaptation/GUID-DCBBDFA7-1E6C-5B00-A13E-A25794668E12_d0e13252_href.png
Adaptation/GUID-DCDD68C7-8EBE-4E91-A983-076460B2C2F3.dita
Adaptation/GUID-DD0DA06D-4180-54F1-8807-A7BF31D6A1F1-master.png
Adaptation/GUID-DD0DA06D-4180-54F1-8807-A7BF31D6A1F1_d0e70450_href.png
Adaptation/GUID-DD568637-CD37-5E4C-AD78-4AA5AFE1E9D8.dita
Adaptation/GUID-DD9DBB55-330E-4F43-A156-621979B675BC.dita
Adaptation/GUID-DDD883A2-6784-4851-8E36-227EC564452A-master.png
Adaptation/GUID-DDD883A2-6784-4851-8E36-227EC564452A_d0e90311_href.png
Adaptation/GUID-DE7BD5C8-9966-5D5E-B81F-D57EA9FBA451-master.png
Adaptation/GUID-DE7BD5C8-9966-5D5E-B81F-D57EA9FBA451_d0e9161_href.png
Adaptation/GUID-DF2F0439-AE1A-599C-91B9-6EF2177C3C7E.dita
Adaptation/GUID-DF3045C7-4BDA-53AF-85E4-A8AAD99F40F7-master.png
Adaptation/GUID-DF3045C7-4BDA-53AF-85E4-A8AAD99F40F7_d0e18806_href.png
Adaptation/GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita
Adaptation/GUID-DFADEB44-4D57-564F-ABDF-A3CCD38ACABC-master.png
Adaptation/GUID-DFADEB44-4D57-564F-ABDF-A3CCD38ACABC_d0e15086_href.png
Adaptation/GUID-DFDB6864-0F63-41EC-B549-791B750F3EB3.dita
Adaptation/GUID-E081474F-6B17-5D2E-833B-E8177778577A.dita
Adaptation/GUID-E0A0C542-2922-407D-88E9-2DC5D159E1F6.dita
Adaptation/GUID-E0DCBDCF-C056-53E5-A375-778327F848E4.dita
Adaptation/GUID-E1277A18-7201-4856-8712-067022F92123.dita
Adaptation/GUID-E1FEEDCE-0CD5-559C-9AE0-8090A613C166.dita
Adaptation/GUID-E21C4AF8-852A-5BBD-A92A-5473D1DFFBB1.dita
Adaptation/GUID-E21E7992-607A-5A49-B022-189ECA9E76D1.dita
Adaptation/GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita
Adaptation/GUID-E3C70135-EC0C-504C-B428-53A5750B520B.dita
Adaptation/GUID-E3C7CB78-8A68-4FFA-BD00-04D27E67C1F3.dita
Adaptation/GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita
Adaptation/GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita
Adaptation/GUID-E539FF7D-C221-4961-8227-9E94FBAA624C.dita
Adaptation/GUID-E5459A54-14BC-55C1-B911-63415E4C61A6.dita
Adaptation/GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita
Adaptation/GUID-E55B594F-CC84-5984-9307-9819F6EBEB7F-master.png
Adaptation/GUID-E55B594F-CC84-5984-9307-9819F6EBEB7F_d0e29647_href.png
Adaptation/GUID-E6F9A60A-0112-4C9B-A880-7E2908A74DAA.dita
Adaptation/GUID-E7C55048-5B7A-5BF2-B7F4-4D731659B88C.dita
Adaptation/GUID-E7E67A52-0725-446B-A49C-CF571C4A0C64.dita
Adaptation/GUID-E7F91A65-235D-589C-9A8C-0B207D19A24B.dita
Adaptation/GUID-E90DBF35-0A05-4751-904D-4F06987FFF48.dita
Adaptation/GUID-E96E4542-7017-4069-BD9C-97467A99F211.dita
Adaptation/GUID-E9999276-6861-4ECA-B542-1B6C3471BFC9.dita
Adaptation/GUID-EA0C5715-7CE8-5415-A915-D5701E3C957A-master.png
Adaptation/GUID-EA0C5715-7CE8-5415-A915-D5701E3C957A_d0e10709_href.png
Adaptation/GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita
Adaptation/GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3.dita
Adaptation/GUID-EB76FAF8-CD4B-5CB6-9F23-C852ED91866F.dita
Adaptation/GUID-EBF025DB-1552-5E99-8C07-09932DB60552.dita
Adaptation/GUID-EBF4F1F1-F76B-455B-B8EE-B7965CF0717E.dita
Adaptation/GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D.dita
Adaptation/GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1.dita
Adaptation/GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-9-1-8-1-16-1.dita
Adaptation/GUID-EDC1C30B-4078-4434-95AC-2E37AF809A51.dita
Adaptation/GUID-EE2F64B2-A2E3-524F-8E04-68BE9AA9EA36-master.png
Adaptation/GUID-EE2F64B2-A2E3-524F-8E04-68BE9AA9EA36_d0e29378_href.png
Adaptation/GUID-EE50283A-543C-446F-A5D1-E64043F988ED.dita
Adaptation/GUID-EE7086B4-A60A-55B2-85DC-28F07F9E227E-master.png
Adaptation/GUID-EE7086B4-A60A-55B2-85DC-28F07F9E227E_d0e55772_href.png
Adaptation/GUID-EF73C56D-AEB1-558B-BAD1-D076BA6EA889.dita
Adaptation/GUID-EFEACBE5-B9E1-5315-88CA-DA3B7C1BFCE0-master.png
Adaptation/GUID-EFEACBE5-B9E1-5315-88CA-DA3B7C1BFCE0_d0e29694_href.png
Adaptation/GUID-F09740DA-015B-449D-A124-0BEABBDDCB52.dita
Adaptation/GUID-F123D574-44DE-528A-806C-DB64229BCEA2.dita
Adaptation/GUID-F12437C5-BD96-5B43-AD76-614CFAB104D2-master.png
Adaptation/GUID-F12437C5-BD96-5B43-AD76-614CFAB104D2_d0e69275_href.png
Adaptation/GUID-F127644A-6072-52CA-9B17-E9DDEA784BE0-master.png
Adaptation/GUID-F127644A-6072-52CA-9B17-E9DDEA784BE0_d0e8997_href.png
Adaptation/GUID-F20D5802-7B83-5B78-8753-A88E74E28398.dita
Adaptation/GUID-F367F6C9-66F7-4061-81A7-0C845D8F39C4.dita
Adaptation/GUID-F3B93325-E30E-456A-B281-5451B7C47AAE.dita
Adaptation/GUID-F461CBB3-F8D1-5961-AD51-5741143A1CB1.dita
Adaptation/GUID-F4B2D20B-8F1D-4A4B-8ECB-65BE8E9824DD.dita
Adaptation/GUID-F4E04E00-D9C6-5E8F-9EC6-F90BC951D4D0-master.png
Adaptation/GUID-F4E04E00-D9C6-5E8F-9EC6-F90BC951D4D0_d0e63912_href.png
Adaptation/GUID-F50E1C81-E80F-5692-996B-3AC2BE995425-master.png
Adaptation/GUID-F50E1C81-E80F-5692-996B-3AC2BE995425_d0e39862_href.png
Adaptation/GUID-F5430A12-D89D-4936-B846-E917B434F755.dita
Adaptation/GUID-F54BB3B5-D069-4524-A215-6F2CCA372666.dita
Adaptation/GUID-F55A0CB4-0AB6-4DE3-9DFA-FBCB7131BB3A-master.png
Adaptation/GUID-F55A0CB4-0AB6-4DE3-9DFA-FBCB7131BB3A_d0e98263_href.png
Adaptation/GUID-F5DC77CD-4730-4FD8-A483-F5D22F34887E.dita
Adaptation/GUID-F60E5156-38B0-4781-8088-180E6716FC63.dita
Adaptation/GUID-F67AFC0F-5245-48DE-8901-79461FB6EADE-master.png
Adaptation/GUID-F67AFC0F-5245-48DE-8901-79461FB6EADE_d0e93180_href.png
Adaptation/GUID-F67AFC0F-5245-48DE-8901-79461FB6EADE_d0e94068_href.png
Adaptation/GUID-F67FA7B5-F6D1-5C5C-8E10-A8E317A778E4.dita
Adaptation/GUID-F6E83530-3F8E-5930-8C6C-4D58B675E67A.dita
Adaptation/GUID-F7249C66-B62F-45DF-B733-BC6D5FCDA003.dita
Adaptation/GUID-F75F975B-A490-4EB5-96CD-B2F8DFC63C7C.dita
Adaptation/GUID-F7ABA3C6-60DD-4AE1-916B-BE2BCF6285CE-master.png
Adaptation/GUID-F7ABA3C6-60DD-4AE1-916B-BE2BCF6285CE_d0e89266_href.png
Adaptation/GUID-F7ABA3C6-60DD-4AE1-916B-BE2BCF6285CE_d0e91217_href.png
Adaptation/GUID-F84E18B8-5883-5A3A-A9DB-EC25BB86149F.dita
Adaptation/GUID-F8A32666-5003-5B14-A700-C6E6388D2D38-master.png
Adaptation/GUID-F8A32666-5003-5B14-A700-C6E6388D2D38_d0e63938_href.png
Adaptation/GUID-F8B8C030-B5E1-5EB3-A672-83BF35555801.dita
Adaptation/GUID-F8BD699A-E926-5434-9F35-3DC6DC9FFBB6.dita
Adaptation/GUID-F8E8CCB1-E239-5285-BA99-48E2168C9E31.dita
Adaptation/GUID-F9051D21-3E4C-4645-BD04-06606E849AEF.dita
Adaptation/GUID-F9558573-7C79-57C5-809A-9257BF84758A.dita
Adaptation/GUID-FA026EBD-7867-4A2C-9FA4-EC70A5243526.dita
Adaptation/GUID-FB063C1A-EF9F-4292-827F-A3DBC7C7F13A.dita
Adaptation/GUID-FB69F45C-2256-5F2D-8D2C-98C93B865962-master.png
Adaptation/GUID-FB69F45C-2256-5F2D-8D2C-98C93B865962_d0e14972_href.png
Adaptation/GUID-FBE6E61F-5A2E-5A7A-BC59-51F072EBED7D.dita
Adaptation/GUID-FCCF9634-0610-5199-A37A-CF2EC9B73261.dita
Adaptation/GUID-FD8634B8-E522-4AC4-8129-ED807A7754A2-GENID-1-2-1-9-1-5-1-6-1.dita
Adaptation/GUID-FD8634B8-E522-4AC4-8129-ED807A7754A2-GENID-1-2-1-9-1-6-1-9-1-8-1.dita
Adaptation/GUID-FDAED7A7-3D93-5B57-9879-DF8BDBE8A9BD.dita
Adaptation/GUID-FE36E7DE-7C2C-415B-BB2F-22D9E2BE49A6.dita
Adaptation/GUID-FE77CDFC-B66B-485B-A94D-F646894FD330.dita
Adaptation/GUID-FF2ABA1D-1F71-5A9C-AFD5-A0CED39BFD86-master.png
Adaptation/GUID-FF2ABA1D-1F71-5A9C-AFD5-A0CED39BFD86_d0e39571_href.png
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-003D2C5B-09DC-5BD1-AF45-A0FCB56F567B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,172 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-003D2C5B-09DC-5BD1-AF45-A0FCB56F567B" xml:lang="en"><title>ROMBUILD</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>ROMBUILD is the Symbian platform binary XIP (execute-in-place)
+ROM builder. It is normally invoked through <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">BUILDROM</xref>,
+the Symbian platform ROM configuration tool that acts as a front-end
+to ROMBUILD. </p>
+<section id="GUID-CFAB320B-5F0D-4E76-AD96-FE6EE8D3BE43"> </section>
+<section id="GUID-06C4A9F7-E8D4-5A53-97BA-F3C2973B661A"><title>ROMBUILD
+command syntax</title><p>If the OBY files are encoded in UTF-8 with
+non-ASCII character support, use the following the ROMBUILD command
+syntax:</p><codeblock id="GUID-379818BF-A17B-5CAF-A311-3EE4142EE51D-GENID-1-2-1-8-1-1-6-1-1-5-1-2-3-3" xml:space="preserve">ROMBUILD [options] [–oby-charset=utf-8 &lt;obyfile&gt;] [-datadrive=&lt;fat.oby&gt;]</codeblock><p>If the OBY files are encoded in local character set with non-ASCII
+characters support, use the following the ROMBUILD command syntax:</p><codeblock id="GUID-B3A01582-9631-57C6-A654-D5539DF1AE54-GENID-1-2-1-8-1-1-6-1-1-5-1-2-3-5" xml:space="preserve">ROMBUILD [options] &lt;obeyfile&gt; [-datadrive=&lt;fat.oby&gt;]</codeblock> <p>The following command line <codeph>options</codeph> are supported: </p> <table id="GUID-321B472A-D58B-5348-A701-EA7E33E3A0B5">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>–argfile=&lt;parameter file&gt;</codeph>  </p> </entry>
+<entry><p>Accepts a parameter file, which contains a list of command-line
+parameters specific to the ROM tools, as input. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> -? </codeph>  </p> </entry>
+<entry><p>Displays more detailed help for the command. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-coff-header</codeph>  </p> </entry>
+<entry><p>Uses a PE-COFF header instead of a Symbian platform header. PE-COFF is a Portable Executable–Common Object File
+Format and is a Microsoft extension to the COFF standard. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> -compress</codeph>  </p> </entry>
+<entry><p>Compresses executable files where possible using the inflate
+(Deflate, Huffman+LZ77) algorithm unless the <codeph>-compressionmethod</codeph> keyword is used to override the default (see below). </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-compressionmethod [none | inflate | bytepair]</codeph>  </p> </entry>
+<entry><p>Specifies the compression algorithm to use. Can be used
+either with the <codeph>-compress</codeph> keyword or alone. </p> <p><table id="GUID-34E5FD4C-7B82-5342-85C3-C84A706C8C17-GENID-1-2-1-8-1-1-6-1-1-5-1-2-3-7-1-3-5-2-2-1">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>none </codeph>  </p> </entry>
+<entry><p>No compression is used. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>inflate </codeph>  </p> </entry>
+<entry><p>Compresses executable files using the default (Deflate,
+Huffman+LZ77) algorithm. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>bytepair </codeph>  </p> </entry>
+<entry><p>Compresses executable files using the bytepair algorithm.
+Bytepair compression allows faster decompression than the default
+Deflate, Huffman+LZ77 algorithm and supports demand paging by performing
+compression and decompression of code in independent 4 KB pages. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>coreimage=&lt;core ROM image file&gt;</codeph>  </p> </entry>
+<entry><p>Uses the specified core image file as the basis for creating
+the ROM image extension. </p> <p>If the given core ROM image file
+is invalid or does not exist, an error message is displayed. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-d&lt;bitmask&gt; </codeph>  </p> </entry>
+<entry><p>Sets the trace bitmask; this only applies to debug builds. </p> <p>The simplest way of specifying this is to use a string of hexadecimal
+characters starting with 0x (for example, 0x01234567). However, any
+string that can be interpreted and translated into a valid TUint value
+may be used. See the standard C function <codeph>strtoul()</codeph>. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-lowmem</codeph>  </p> </entry>
+<entry><p>Reduces the physical memory consumption during image generation. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-loglevel&lt;level&gt;</codeph>  </p> </entry>
+<entry><p>Level of information to log file. The following valid log
+levels are available: </p> <p><table id="GUID-6D12A1F6-70D6-5CAC-891F-CC0E98D21E70">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>0</codeph>  </p> </entry>
+<entry><p>Default level of information to log file. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>1</codeph>  </p> </entry>
+<entry><p>Logs the host or the ROM filenames, the file size, and the
+hidden attribute in addition to the <codeph>loglevel 0</codeph> information. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> 2</codeph>  </p> </entry>
+<entry><p>Logs the E32 file header attributes such as UIDs, data size,
+heap size, stack size, VID, SID, and priority in addition to the <codeph>loglevel 1</codeph> information. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-no-header </codeph>  </p> </entry>
+<entry><p>Suppresses the image loader header. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-no-sorted-romfs </codeph>  </p> </entry>
+<entry><p>Does not add sorted entry arrays (6.1 compatible). It is
+a table of offsets for the subdirectories and files which are not
+in the sorted order. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-r&lt;fileName&gt;</codeph>  </p> </entry>
+<entry><p>Compares the generated ROM image with the ROM image whose
+file name is specified. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-s[log|screen|both] </codeph>  </p> </entry>
+<entry><p>Displays a summary of the size to the specified destination,
+that is, to the log, to the screen or to both the log and the screen. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-v </codeph>  </p> </entry>
+<entry><p>Verbose mode. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-wstdpath</codeph>  </p> </entry>
+<entry><p>Displays a warning if a file is placed in a non-standard
+directory when <codeph>PlatSecEnforceSysBin</codeph> is set to <codeph>OFF</codeph>.  </p><p> For example, the following instruction in
+OBY file leads to a warning when <codeph>-wstdpath</codeph> is used
+and <codeph>PlatSecEnforceSysBin</codeph> is <codeph>OFF</codeph>:</p><p><codeph>File=ABI_DIR/BUILD_DIR/hello.exe myfolder/bin/hello.exe</codeph></p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-j&lt;NUM_OF_WORKING_THREADS&gt;</codeph></p> </entry>
+<entry><p>Specifies the number of working threads that can run concurrently
+to create a ROM image. The <codeph>&lt;NUM_OF_WORKING_THREADS&gt;</codeph> must be an integer in the range 1-128. </p> <p>If the <codeph>-j</codeph> option is not specified or an invalid value is specified, ROMBUILD
+uses the following ways to determine the number of working threads: </p> <ul>
+<li id="GUID-7B81919D-9F6A-5945-A311-EFDE7B0985F5"><p>If the <codeph>NUMBER_OF_PROCESSORS</codeph> environment variable is set correctly,
+ROMBUILD uses the number of processors as the number of working threads. </p> </li>
+<li id="GUID-6C697962-2AE9-5AEC-950F-304ABE720501"><p>If the <codeph>NUMBER_OF_PROCESSORS</codeph> environment variable is not set or
+is invalid, the default value <codeph>8</codeph> is used as the number
+of working threads. </p> </li>
+</ul> </entry>
+</row>
+<row>
+<entry><p><codeph>-gendep</codeph></p></entry>
+<entry><p>Generates a dependencies file describing internal dependencies
+among executables or dlls in a ROM image.</p><p><b>Note</b>: You can
+only generate dependence information in the paged section of a ROM
+image.</p></entry>
+</row>
+<row>
+<entry><p><codeph>-symbols</codeph></p></entry>
+<entry><p>Generates symbols for each data or executable specified
+in the OBY file. </p><p><b>Note</b>: The symbols file is not generated
+by default.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p> <codeph>&lt;obeyfile&gt;</codeph> is a standard text file
+containing statements that are used to control the operation of the
+tool. </p> <p>See the <xref href="GUID-9CF985F1-C100-5999-9410-58B7865A1E18.dita">OBEY files</xref> reference for the full syntax. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-009D71C6-481F-5EF1-B230-EB64F67047C8.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,47 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-009D71C6-481F-5EF1-B230-EB64F67047C8" xml:lang="en"><title>Calibration</title><shortdesc>Calibration of the Digitizer Driver is required to convert between
+digitiser ADC values and screen coordinates. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Calibration is done through a user-side calibration application. </p>
+<p>The platform specific layer performs the following calculation to convert
+between ADC values and co-ordinates: </p>
+<fig id="GUID-932E1DED-C393-5C26-A08F-E270CF5DC90B">
+<image href="GUID-D6861A7A-1845-52AF-BB09-4B97E6B8AA13_d0e10260_href.png" placement="inline"/>
+</fig>
+<p>Where the <b>R</b> matrix determines the scaling and rotation, and the <b>T</b> vector
+determines the translation. </p>
+<p>This conversion is implemented by the platform specific layer's implementation
+of <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita#GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9/GUID-A51F6890-2D47-3FCC-A51B-19479658E49F"><apiname>DDigitiser::DigitiserToScreen()</apiname></xref> and <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita#GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9/GUID-F85119E0-83DC-3C54-BDFC-4F156ADFE538"><apiname>DDigitiser::ScreenToDigitiser()</apiname></xref>.
+Default implementations are provided by the template port. Note, however,
+that in these implementations, the calculation is slightly more complex because
+screen coordinate values are left shifted 16 bits. This allows the operations
+to use integer divisions without loosing precision. </p>
+<p>All that you need to do is to provide an initial set of values for <b>R</b> and <b>T</b>.
+An example of how to set them up is included in the template port. </p>
+<p>The principle is that the application draws cross hairs on the screen,
+and then invites the user to touch these points. The digitiser ADC value is
+used to calculate the digitiser to screen pixel value transformation. </p>
+<p>Any calibration code will interface with the <xref href="GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8.dita#GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8/GUID-4DA41221-40B9-5BC7-B2C6-7C6EB4522508">User-Side
+Hardware Abstraction</xref> component using four <xref href="GUID-8B3280A2-318F-380C-B2A4-894C3C675868.dita"><apiname>UserHal</apiname></xref> functions. </p>
+<p>On a cold restart, the calibration application goes through the following
+steps: </p>
+<ul>
+<li id="GUID-DDEF3346-09D3-56B1-A9EE-CC520620611B"><p>Gets the calibration
+points by using <xref href="GUID-8B3280A2-318F-380C-B2A4-894C3C675868.dita#GUID-8B3280A2-318F-380C-B2A4-894C3C675868/GUID-57FFFEEF-200A-3F62-937F-181760F756A9"><apiname>UserHal::CalibrationPoints()</apiname></xref>  </p> </li>
+<li id="GUID-F93D82ED-924D-5268-807F-8F52F18A1A9E"><p>Sets calibration points
+by using: <xref href="GUID-8B3280A2-318F-380C-B2A4-894C3C675868.dita#GUID-8B3280A2-318F-380C-B2A4-894C3C675868/GUID-D494A58D-BBFA-3D3B-A979-A7CB4045EF23"><apiname>UserHal::SetXYInputCalibration()</apiname></xref>  </p> </li>
+<li id="GUID-C368C9AA-BE3C-5B95-AEDA-703B91059AFB"><p>Saves calibration data
+by using: <xref href="GUID-8B3280A2-318F-380C-B2A4-894C3C675868.dita#GUID-8B3280A2-318F-380C-B2A4-894C3C675868/GUID-B93BD9B9-9F33-337D-A110-993B717F1D50"><apiname>UserHal::SaveXYInputCalibration()</apiname></xref>  </p> </li>
+</ul>
+<p>On a warm restart, the calibration application just restores calibration
+data using <xref href="GUID-8B3280A2-318F-380C-B2A4-894C3C675868.dita#GUID-8B3280A2-318F-380C-B2A4-894C3C675868/GUID-63CC94BD-CD0C-3B2C-8714-1A976FE7D0DD"><apiname>UserHal::RestoreXYInputCalibration()</apiname></xref>. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-01072199-382F-4691-AC0D-D1226EE5CF2F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-01072199-382F-4691-AC0D-D1226EE5CF2F" xml:lang="en"><title>Time Client Interface Quick Start</title><shortdesc>Explains how to use the interface between the Time platform
+service and its clients.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-91FBBDBE-A015-4B6A-A1DB-74D87A6DB816"><title>Introduction</title><p>The Time client interface is used when communicating with the
+Real Time Clock (RTC). This client interface can be used to check
+that the RTC is working correctly, maintain its request queue and
+to set/reset the wake-up alarm.</p> </section>
+<section id="GUID-C072C87B-323F-4678-BD81-7D34F2E9E6DF"><title>Time
+client interface limitations</title><p>None</p></section>
+<section id="GUID-E306BFAB-60CC-46D5-8176-A2FEDF55C89B"><title>Adaptation
+dependencies</title><p>None</p></section>
+<section id="GUID-4ADBBA99-D1D6-4E1A-9C5A-81E882011A61"><title>Time
+client interface classes</title><p>The following classes provide the
+RTC interface:</p><table id="GUID-D01391B7-9427-45F3-A873-5FE9BDEDCCA4">
+<tgroup cols="2"><colspec colname="col1" colwidth="0.46*"/><colspec colname="col2" colwidth="1.54*"/>
+<tbody>
+<row>
+<entry><p><b>Name</b></p></entry>
+<entry><p><b>Description</b></p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita"><apiname>MRtcAdaptation</apiname></xref></p></entry>
+<entry><p>Provides the interface between the Real Time Clock (RTC)
+and the upper layers of the OS.</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9.dita"><apiname>ASIC</apiname></xref></p></entry>
+<entry><p>Provides an interface to the Application Specific Integrated
+Circuit (ASIC) that is being used.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p>The functionality provided by this class, can be split
+into the following groups:</p><ul>
+<li><p>Diagnostics</p></li>
+<li><p>Management of the wake-up alarm</p></li>
+<li><p>Request management</p></li>
+<li><p>Set and read the RTC</p></li>
+</ul></section>
+<section id="GUID-7A7E1108-5D58-4500-AB6C-BFC8CA65EE0E"><title>Diagnostics</title><p>These methods are used to test that the RTC is working correctly.
+The methods that are included in this group are:</p><ul>
+<li><xref href="GUID-8D237BD6-9759-4180-B190-F1624594017F.dita#GUID-8D237BD6-9759-4180-B190-F1624594017F/GUID-98F7B0DE-CBA6-430C-972D-02F9AB444E1B">MRtcAdaptation::ValidateRtc()</xref></li>
+<li><xref href="GUID-8D237BD6-9759-4180-B190-F1624594017F.dita#GUID-8D237BD6-9759-4180-B190-F1624594017F/GUID-3D0DD0AB-4F3F-4411-B5E8-9199AB71F1A6">ASIC::SetSystemTimeCalibration()</xref></li>
+</ul></section>
+<section id="GUID-CB062F05-0410-4B8D-930F-2DD55BAFC829"><title>Management
+of the wake-up alarm</title><p>This group of methods, relate to the
+setting and releasing of the wake-up alarm. The methods that are included
+in this group are:<ul>
+<li><p><xref href="GUID-8D237BD6-9759-4180-B190-F1624594017F.dita#GUID-8D237BD6-9759-4180-B190-F1624594017F/GUID-813CB223-3385-4293-9D1C-8C712B031E8F">MRtcAdaptation::SetWakeUpAlarm()</xref></p></li>
+<li><p><xref href="GUID-8D237BD6-9759-4180-B190-F1624594017F.dita#GUID-8D237BD6-9759-4180-B190-F1624594017F/GUID-DE156EC7-759F-4BFC-BCAA-FE0E84CC83D9">MRtcAdaptation::UnsetWakeUpAlarm()</xref></p></li>
+</ul></p></section>
+<section id="GUID-DDED587F-ADBF-4C3D-A263-8A1D333EE85C"><title>Request
+management</title><p>Calls to the RTC are placed in a request queue,
+waiting for the RTC to process them. Calls to the other two groups
+of functionality add requests to the queue for the RTC, the methods
+in this group remove them.  The methods that are included in this
+group are:</p><ul>
+<li><p><xref href="GUID-8D237BD6-9759-4180-B190-F1624594017F.dita#GUID-8D237BD6-9759-4180-B190-F1624594017F/GUID-1111CFEA-D85C-4107-BB14-618C6A5A0B3F">MRtcAdaptation::Cancel()</xref></p></li>
+<li><p><xref href="GUID-8D237BD6-9759-4180-B190-F1624594017F.dita#GUID-8D237BD6-9759-4180-B190-F1624594017F/GUID-2EE46E01-006D-431E-B6C0-CAEBDDE5D53A">MRtcAdaptation::Release()</xref></p></li>
+</ul></section>
+<section id="GUID-69B30672-ABD6-421A-967A-3669C8477505"><title>Set
+and read the RTC</title><p>These functions are used to set and read
+the RTC. Both functions measure time as the number of seconds since
+the start of the year 2000.</p><ul>
+<li><xref href="GUID-8D237BD6-9759-4180-B190-F1624594017F.dita#GUID-8D237BD6-9759-4180-B190-F1624594017F/GUID-C69C0225-1779-4FFC-B071-D18B71C18A74">ASIC::SystemTimeInSecondsFrom2000()</xref></li>
+<li><xref href="GUID-8D237BD6-9759-4180-B190-F1624594017F.dita#GUID-8D237BD6-9759-4180-B190-F1624594017F/GUID-1BFBAEE5-AE48-4624-BD34-3D6B936C8C3B">ASIC::SetSystemTimeInSecondsFrom2000()</xref></li>
+</ul></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-01F1F488-8E95-56B0-818E-6096CAE4C50C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-01F1F488-8E95-56B0-818E-6096CAE4C50C" xml:lang="en"><title>Architecture</title><shortdesc>This topic describes the architecture of the Base Starter program, <filepath>e32strt.exe</filepath>.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Base Starter is started by the File Server, <filepath>EFILE.EXE</filepath>,
+near the end of the boot process. </p>
+<p> <filepath> EFILE.EXE</filepath> initialises generic file services. <filepath>e32strt.exe</filepath> performs
+handset specific initialisation. The Base Starter completes the initialisation
+of the file server, and then creates the system starter process. The system
+starter process is the next process in the chain of processes responsible
+for starting all the major Symbian platform services. The following
+diagram shows the relative position of the Base Starter in the start-up sequence. </p>
+<fig id="GUID-C184517B-0E86-5E22-BCD6-F4DFD7AEA731">
+<title>           Base Starter architecture         </title>
+<image href="GUID-CEDA0EFF-A1D4-53FE-9BF2-DB9AA857BCF5_d0e3163_href.png" placement="inline"/>
+</fig>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-024EE22F-4B86-48EF-A55E-C9C1C7E9BADB.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-024EE22F-4B86-48EF-A55E-C9C1C7E9BADB" xml:lang="en"><title>SDIO Client Interface</title><shortdesc>Describes SDIO APIs and their use in a device driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-02B40662-B5F3-59BD-832B-9A28FE3B51C7.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-02B40662-B5F3-59BD-832B-9A28FE3B51C7" xml:lang="en"><title>Debug</title><shortdesc>This topic describes how to use debug messages in the USB
+client controller.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>As the USB PDD runs in kernel mode, debug <codeph>printf</codeph> are implemented using the <codeph>KTRACE</codeph> macro.
+This macro takes two arguments: </p>
+<ul>
+<li id="GUID-E3A1AA52-12D9-58EE-A459-46FAA7F5001C"><p>The debug message
+type </p> </li>
+<li id="GUID-2D7B1C30-563C-5346-8DBC-943839008874"><p>A kernel object
+that takes a message string as a constructor. </p> </li>
+</ul>
+<p>Two debug message types are used: </p>
+<ul>
+<li id="GUID-962DAE50-32C5-53AB-A203-E08CA57252D5"><p> <codeph>KPANIC</codeph> for error messages </p> </li>
+<li id="GUID-6F6409F4-37B1-5713-A763-61B477545706"><p> <codeph>KUSBPSL</codeph> for PSL information messages </p> </li>
+</ul>
+<p>The following code samples illustrate their use: </p>
+<codeblock id="GUID-A130740F-20FA-5825-9BDB-9CE234971757" xml:space="preserve">_KTRACE_OPT(KPANIC, Kern::Printf("Error: USB Controller not present"));</codeblock>
+<codeblock id="GUID-6A8812CE-791C-5C62-AC67-29FF5098D9E4" xml:space="preserve">_KTRACE_OPT(KUSBPSL, Kern::Printf("Received new Ep0 Setup packet"));</codeblock>
+<note>Do not use the <codeph>KUSB</codeph> flag. This flag is used
+within the PDD PIL and the USB LDD only.</note>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0346036B-A470-4C18-B276-3A3485F6A069.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-0346036B-A470-4C18-B276-3A3485F6A069" xml:lang="en"><title>Design
+Options</title><shortdesc>These documents describe high-level implementation choices for
+a device driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> </p>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-04FF36CE-DEFA-45DC-BAAF-77F3BB649AFF-master.png has changed
Binary file Adaptation/GUID-04FF36CE-DEFA-45DC-BAAF-77F3BB649AFF_d0e499_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-052F58B7-117B-5EDD-A3D5-CB0DE6A4E239.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,80 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-052F58B7-117B-5EDD-A3D5-CB0DE6A4E239" xml:lang="en"><title>IIC SHAI Implementation Layer: Generic Considerations</title><shortdesc>This document explains how to implement the SHAI implementation
+layer for IIC.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-C3EE341A-BEAB-4E0C-A91E-7A1A285BCE96"><title>Purpose</title> <p>This document covers information which is generic to master and
+slave channel implementation </p> <p><b>Intended Audience</b> </p> <p>Base porting engineers. </p> <p><b>Introduction</b> </p> <p>IIC
+buses (a term used in this document to represent serial inter-chip
+buses that IIC can operate on) are a class of bus used to transmit
+non time-critical data between components of a hardware system. </p> </section>
+<section id="GUID-38B543E8-06DB-417F-8B8E-84F6B43DF8BF"><title>Generic
+architecture</title> <p>Different IIC buses have a large amount of
+functionality in common, but some functionality is specific to individual
+implementations. For this reason, the IIC software has an architecture
+consisting of two layers, the Platform Independent Layer (PIL) and
+the SHAI implementation layer. The Platform Independent Layer is a
+set of classes which encapsulate generic functionality and have been
+implemented for you. The SHAI implementation layer is an interface
+which you must implement yourself to encapsulate the functionality
+specific to the platform you are working on. </p> <p>You implement
+the SHAI implementation layer by subclassing the classes of the Platform
+Independent Layer and writing functions that provide an abstraction
+of your hardware. To access the hardware you are strongly recommended
+to use existing Symbian APIs such as e.g. <codeph>AsspRegister</codeph> to access hardware registers, or <codeph>GPIO</codeph> to access
+GPIO pins). </p> <p>An IIC channel operates in one of two modes, master
+and slave, and there are separate master and slave APIs to be implemented.
+In master mode, a channel and a client communicating with that channel
+execute in two separate threads. In slave mode there is only one thread
+for both channel and client. </p> <p>The SHAI implementation and platform
+independent APIs assume an interrupt-driven approach to implementation.
+An event on hardware triggers an interrupt, which then signals this
+event to the channel thread (where client is master) or client thread
+(where client is slave). This means that implementation involves writing
+interrupt service routines (ISRs) and a DFC queue to hold the callbacks
+which respond to them. For both master and slave operation, the callbacks
+are queued for execution on the client thread - so the client thread
+must not be blocked, otherwise the callbacks will never run.</p><p>Clients of a master channel request transactions for execution in
+either a synchronous or asynchronous manner. This results in the transaction
+being entered in the channel’s request queue.  </p><p>If synchronous
+execution is requested, the client thread is blocked until the transaction
+completes (either an ISR or polling mechanism in the SHAI implementation
+layer recognizes the transaction has completed, and it calls the PIL
+method <codeph>CompleteRequest()</codeph>, which will unblock the
+client thread.  </p><p>If asynchronous execution is requested, the
+client thread is not blocked, and may continue to perform other tasks.
+In the meanwhile, the channel thread will retrieve the next transaction
+from the request queue and pass it to the SHAI implementation layer
+for processing. When the transaction completes, the SHAI implementation
+layer calls the PIL method <codeph>CompleteRequest()</codeph> and
+this adds the client’s callback to the client’s DFC queue.  </p><p>A client of a slave channel provides receive and transmit buffers
+to be used and specifies the types of event (trigger) that it wishes
+to be notified of. When ANY event occurs, the SHAI implementation
+layer should call the PIL method <codeph>NotifyClient()</codeph>;
+this determines whether the reported triggers qualify for notifying
+the client – if so, the client callback is added to the client’s DFC
+queue for execution. Note that the same mechanism is used to notify
+the client of completion of asynchronous capture of the channel, and
+of bus errors.</p> <p>You should refer to the template port at <filepath>\os\kernelhwsrv\bsptemplate\asspandvariant\template_assp\iic</filepath> for more information. </p> </section>
+</conbody><related-links>
+<link href="GUID-0C8318B1-71D7-5384-97EB-85CBBC3E6B84.dita"><linktext>IIC
+SHAI Implementation Layer: Master Channel</linktext></link>
+<link href="GUID-C9644081-004E-5DA0-8133-A32EEA91EF5E.dita"><linktext>IIC
+SHAI Implementation Layer: Slave Channel</linktext></link>
+<link href="GUID-9986DCC6-EE73-59FB-BDAC-9B09DC64FBCE.dita"><linktext>Client
+of Master Channel Tutorial</linktext></link>
+<link href="GUID-F461CBB3-F8D1-5961-AD51-5741143A1CB1.dita"><linktext>Client
+of Slave Channel Tutorial</linktext></link>
+<link href="GUID-B2F86F54-EF50-56DB-ADF7-15325AC9324D.dita"><linktext>IIC
+Concepts</linktext></link>
+<link href="GUID-3A30DA16-ECA8-5639-A9DC-6BE2AD55420B.dita"><linktext>I2C
+Technology Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0563266C-8B5A-5664-9AC6-A5504AB5056F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-0563266C-8B5A-5664-9AC6-A5504AB5056F" xml:lang="en"><title>Porting Tutorial</title><shortdesc>Describes the steps to implement a port of the Digitizer Driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/><related-links>
+<link href="GUID-6C27AAD6-EB88-53AF-8E04-921A957042CF.dita"><linktext>Concepts</linktext>
+</link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-058BAEDF-5E04-5BB4-928F-0E0528FD9465.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-058BAEDF-5E04-5BB4-928F-0E0528FD9465" xml:lang="en"><title>MultiMediaCard
+Technology</title><shortdesc>MultiMediaCard (MMC) is a low cost data storage and communication
+media, and is defined by the <i>MultiMediaCard System Specification</i></shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> The MMC specification is published by the <xref href="http://www.mmca.org" scope="external">MultiMediaCard Association</xref>. </p>
+<p>Communication is based on a 7-pin serial bus designed to operate in a low
+voltage range (2.0 - 3.6V). The MultiMediaCard specification defines a communication
+protocol referred to as MMC mode (0-20MHz). In addition, for compatibility
+with existing controllers, MultiMediaCards may offer an alternative communication
+protocol which is based on the SPI standard (0-5MHz). </p>
+<section id="GUID-69DA6510-AF66-566A-9B19-5554B4743D0B"><title> Omissions</title> <p>The
+following features of the MultiMediaCard System Specification are not provided
+in the Symbian platform MultiMediaCard controller: </p> <ul>
+<li id="GUID-75439A4B-28C8-58A6-81A8-92BF08F490A1"><p>Stream read and write
+operations are not supported. </p> </li>
+<li id="GUID-85C665FB-152C-5A94-A245-E99D44F384C2"><p>SPI bus mode is not
+supported. </p> </li>
+<li id="GUID-26F8D809-57EF-5CCB-99A5-BFDCA59A5F76"><p>The MultiMediaCard System
+Specification includes a feature where a MultiMediaCard can be put into a
+disconnected state. This can be performed on a card which is currently in
+the programming state, i.e. writing data to the disk. To place that card into
+the disconnected state involves placing another card into the transfer state,
+which means giving the other card the current data transfer focus. A disconnected
+card will not terminate the programming operation and, if re-selected, moves
+back to the programming state. The Symbian platform MultiMediaCard controller
+does not support this mode of operation even if the underlying hardware interface
+does. </p> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-058FAE44-DF72-53E2-BE62-EDC840A7C87F-master.png has changed
Binary file Adaptation/GUID-058FAE44-DF72-53E2-BE62-EDC840A7C87F_d0e25110_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-05DAF5EF-6F2E-562D-9DB1-0985AD4A1E48.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-05DAF5EF-6F2E-562D-9DB1-0985AD4A1E48" xml:lang="en"><title>Port Implementation
+Tutorial</title><shortdesc>Describes the steps to implement a port of the User-Side Hardware
+Abstraction component. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/><related-links>
+<link href="GUID-B7C56FF9-FE1B-58C3-BBD4-7479F0BEE555.dita"><linktext>Concepts</linktext>
+</link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-07E0DEC0-A749-4B14-9E73-3AF8ACD28BC6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-07E0DEC0-A749-4B14-9E73-3AF8ACD28BC6" xml:lang="en"><title>Register Access Implementation</title><shortdesc>Provides information about implementing the Register Access
+platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0804E71D-8B20-49A2-9F7C-F2D6795681D0.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,56 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-0804E71D-8B20-49A2-9F7C-F2D6795681D0" xml:lang="en"><title>DMA Quick Start</title><shortdesc>DMA is used to ease the burden on the main CPU, by performing
+some of the data transfers. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There are two types of user that are interested in DMA: those that
+want to use it to transfer data, and those that need to implement
+it for their hardware.</p>
+<section id="GUID-0C4E7346-F73E-4348-8C1D-0CE6211BE222"><title>Users</title><ul>
+<li><p>Device driver developers use DMA to reduce the burden on the
+main CPU. They open a channel and then use that channel to queue one
+or more DMA requests.</p></li>
+<li><p>Hardware implementers, usually device creators, implement the
+DMA Platform Specific Layer (PSL) so that it will work with the particular
+DMA controller on a device.</p></li>
+</ul><p>Some devices will have more than one DMA controller, which
+means the DMA channel manager may require the hardware implementer
+to provide a means of identifying whether a particular DMA channel
+is of the correct type and on the appropriate controller.</p></section>
+<section id="GUID-AC961C9D-DD23-41D0-89AC-C89C5A2A6B6F"><fig id="GUID-01E7521A-ECD4-45F8-B104-659054A457AF">
+<title>DMA Class Diagram</title>
+<image href="GUID-F7ABA3C6-60DD-4AE1-916B-BE2BCF6285CE_d0e89266_href.png" placement="inline"/>
+</fig><p>The diagram represents different classes related to the DMA.
+The classes in green provide the Client Interface which allows the
+users to request data transfer, the classes in blue implement the
+platform specific layer and the classes in white are the abstract
+classes.</p></section>
+<section id="GUID-05B51EC6-F4CC-4C1C-AF91-1977FEE68FF6"><title>Device
+driver developers</title><p>The device driver writers including the
+developers of physical device drivers and kernel extension writers
+use the client interface of the DMA platform service. </p><ul>
+<li><p>DMA technology is described the <xref href="GUID-4E3C086B-25BE-4DAC-9E21-CFC4F8B792A5.dita">DMA Technology Guide</xref></p></li>
+<li><p>The concepts of device driver are described in the <xref href="GUID-EE50283A-543C-446F-A5D1-E64043F988ED.dita">DMA Device Driver
+Guide</xref></p></li>
+<li><p>The Client Interface is explained in the <xref href="GUID-D5ED62EB-744D-42EB-B8CF-D5623BDA5B38.dita">DMA Client Interface
+Guide</xref></p></li>
+</ul></section>
+<section id="GUID-556FBE81-A39C-429F-8AF5-CDE5C0E076CA"><title>Hardware
+implementers</title><p>If you are a device creator or are adapting
+the DMA Framework for your DMA controller, you must implement the
+Platform Specific Layer.</p><ul>
+<li><p>The hardware interface is explained in the <xref href="GUID-6873E764-4132-46C8-8444-6301CF4D2033.dita">DMA Hardware Interface</xref></p></li>
+<li><p>The hardware specific functions are implemented in the platform
+specific layer and the implementation is explained in the <xref href="GUID-95A33491-17AC-4F12-948E-A1352ADDA483.dita">DMA Implementation
+Guide</xref></p></li>
+<li><p>Testing the implementation is described in the <xref href="GUID-C2114C7B-705C-4527-836A-C6E72227111A.dita">DMA Testing Guide</xref></p></li>
+</ul></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-08867AEC-5866-5583-9AAB-068CB51F5C18.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-08867AEC-5866-5583-9AAB-068CB51F5C18" xml:lang="en"><title>Platform-Specific
+Source Code</title><shortdesc>The platform-specific layer of the bootstrap must implement
+a set of standard functions and definitions that are used by the generic
+layer.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,459 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C" xml:lang="en"><title>The
+Debug Monitor Command Syntax</title><shortdesc>The debug monitor is entered when the kernel crashes, if a system
+process panics, or an unhandled processor exception occurs.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Under normal circumstances this ought not to happen, but when the kernel
+faults, the device enters the kernel debug monitor. </p>
+<p>There may be circumstances where you need to force a kernel crash, for
+example, if the system is locking up. Running the test program <filepath>crash.exe</filepath> forces
+a crash. This program takes a parameter that defines the number of seconds
+that must elapse before the kernel crash is forced. </p>
+<p>For example, when the system locks up under certain conditions, run "crash
+60", and then recreate the conditions that lead to the lockup. After 60 seconds,
+the kernel crash is forced and the debug monitor is entered. </p>
+<p>Notes: </p>
+<ul>
+<li id="GUID-E85767DA-5B42-5F9A-9B5D-4E0ED819FB4B"><p>the EKA2 debug monitor
+is very similar to the EKA1 version, although the details displayed may be
+different. </p> </li>
+<li id="GUID-9E27270F-21AE-582F-9520-8871B09159E6"><p>you will occasionally
+find references to the <i>crash debugger</i>; this is the same as the debug
+monitor. </p> </li>
+</ul>
+<section id="GUID-F7E31A93-BAE2-4D83-8AF6-66B9183EE5F0"><title>Getting the
+debug monitor going</title> <p>When the kernel faults, the device enters the
+debug monitor. </p> <p>To make use of the debug monitor, do the following: </p> <ul>
+<li id="GUID-289A65AF-17C1-5C71-8D7F-E9A687355318"><p>Plug the mains adaptor
+into the DC jack. </p> </li>
+<li id="GUID-19DF62B2-BFF4-592D-820D-5BF74814FF8A"><p>Connect the target device
+COM port to your PC, and set the PC serial port to 115200 baud, 8 bits, no
+parity, 1 stop bit, XON/XOFF flow control. </p> </li>
+<li id="GUID-8A852DA8-ADCD-5E17-963F-4304EF91538C"><p>Press the ON key on
+the target device. </p> </li>
+<li id="GUID-12889F87-DBD1-514D-A1D6-26D119CE0872"><p>Start a terminal program
+on the PC (e.g. HyperTerminal.) </p> </li>
+<li id="GUID-FBAEC406-3187-5AC9-850D-5B31521D0B5F"><p>Press <userinput>RETURN</userinput> on
+the PC. The target device should reply with the prompt: </p> <codeblock id="GUID-1F5189A4-560F-55ED-AC97-1651D1563E7C" xml:space="preserve">Password:</codeblock> </li>
+<li id="GUID-CE10F0C1-308E-5E67-93BF-4EFA81AADF59"><p>Enter the password "replacement"
+(all lower case, but without the quotes) on the PC. The target device should
+now reply: </p> <codeblock id="GUID-6A58CD1A-DA4E-50BF-A6CB-54B681BF5B35" xml:space="preserve">*** DEBUG MONITOR ***</codeblock> </li>
+</ul> <p>You can now enter debug monitor commands. </p> </section>
+<section id="GUID-A52544F3-7F66-4354-A29A-B05181A95F07"><title>Crash debugger
+commands</title> <p>Commands consist of a single letter describing the operation
+to be performed, followed by any arguments. Not all commands take arguments.
+Commands are case sensitive; the majority are lower case. Commands should
+be entered at the command prompt, on the PC. The set of supported commands
+is as follows: </p> <ul>
+<li id="GUID-DB12F01A-5AC0-5ABB-AB4E-A2F59969F5AD"><p> <userinput>f</userinput> - <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-D5F2E0AF-EF03-5150-813B-DF989F12C47B">displays
+kernel fault information</xref>  </p> </li>
+<li id="GUID-946567F9-0B82-5056-84D3-9E25480DB3B1"><p> <userinput>m</userinput> - <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-2A0D5950-F1A5-5EE1-87A3-840B1EAD6AAD">does
+a memory dump</xref>  </p> </li>
+<li id="GUID-3F2349E5-AE6C-550E-A743-D3B6AF34685F"><p> <userinput>z</userinput> - <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-FDF734D6-9E05-573F-BF40-8DB4C7E0BAC5">does
+a memory dump, but skips over unmapped memory space</xref>  </p> </li>
+<li id="GUID-B11F3889-ABB2-5458-8648-CC08E268E7A2"><p> <userinput>i</userinput> - <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-D0175D78-6F84-5F4F-BA90-2C591B473C69">displays
+information on the current thread and the current process</xref>  </p> </li>
+<li id="GUID-B558D40B-F34E-5D13-9170-B22B04EFED51"><p> <userinput>o</userinput> - <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-3494E61C-7097-544C-AE7D-73750337744A">displays
+brief DObject information</xref>  </p> </li>
+<li id="GUID-B687B7A2-3177-5C14-9191-F9E5DB0F1799"><p> <userinput>O</userinput> - <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-1DED2B2F-E780-50A0-8325-5DA22BC7D3E0">displays
+full DObject information</xref>  </p> </li>
+<li id="GUID-E6DE23AE-6599-5F97-BC90-14277409FF61"><p> <userinput>p</userinput> - <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-AE1A903F-6351-523C-AD88-AD6CA4527C39">display
+short information about code segments</xref>  </p> </li>
+<li id="GUID-CEA42CE2-DBF9-514E-BAA2-6A580AA65DC0"><p> <userinput>P</userinput> - <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-9450C209-3F28-581D-87B0-CEA96B94DB62">display
+full information about code segments</xref>  </p> </li>
+<li id="GUID-DBCA7F2B-F4A9-5A1D-9C14-01A03C912E20"><p> <userinput>c</userinput> - <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-FB2E24A6-9744-5169-BA90-DDF84DF1D3E5">displays
+contents of object container; (nb lower case)</xref>  </p> </li>
+<li id="GUID-4777B729-FFFA-5882-A60B-1D1E981A0390"><p> <userinput>C</userinput> - <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-55EF66A9-684F-50DA-8E2B-FA00B3D4FB6C">displays
+contents of object container; (nb upper case)</xref>  </p> </li>
+<li id="GUID-4DFB16FF-91D2-52FD-B2A9-C0D6AEBE682E"><p> <userinput>r</userinput> - <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-0CDF0190-A445-526B-AC1F-D9D58095B18B">dumps
+register contents</xref>  </p> </li>
+<li id="GUID-D0E5A7FB-9722-5686-82CF-8BC4ECE7CE86"><p> <userinput>S</userinput> - <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-5693700E-6401-56B1-9817-AE0C3A81B42D">dumps
+thread stack contents</xref>  </p> </li>
+<li id="GUID-B218BE95-7A94-58A1-911A-4CA79F3CE9B5"><p> <userinput>x</userinput> - <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-8F9BAB99-8B88-5120-A95E-A22404110BAE">leaves
+the debugger, does a cold restart of the same ROM image; (nb lower case)</xref>  </p> </li>
+<li id="GUID-D2089650-2B94-51EB-A0E7-4E15E266DC67"><p> <userinput>X</userinput> - <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-4E12A080-AC83-5872-A66D-4C14A65C5CFA">leaves
+the debugger, and returns to the bootloader to wait for a new ROM image to
+be downloaded; (nb upper case)</xref>  </p> </li>
+<li id="GUID-AE255B3D-C61A-58ED-AFB0-6E003BBE37F6"><p> <userinput>h</userinput> - <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-190C956D-4F57-593B-B3B1-958B6CAE1267">help</xref>. </p> </li>
+</ul> </section>
+<section id="GUID-D5F2E0AF-EF03-5150-813B-DF989F12C47B"><title>f - display
+kernel fault information</title> <p>This command displays information about
+the the kernel fault that caused the debugger to be entered. The information
+has the following format. </p> <codeblock id="GUID-608A834D-00FA-56E6-AC8A-EA8C762F4315" xml:space="preserve">Fault Category: Exception  Fault Reason: 10000000
+ExcId 00000001 CodeAddr ffe0016c DataAddr 80000001 Extra 00000013
+Exc 1 Cpsr=68000010 FAR=80000001 FSR=00000013
+ R0=00000000  R1=00000000  R2=30000000  R3=80000001
+ R4=00000001  R5=00403d68  R6=00002000  R7=00000000
+ R8=00000000  R9=00000000 R10=00000000 R11=00403fa0
+R12=00403d34 R13=00403d48 R14=500d41e8 R15=ffe0016c
+R13Svc=81716000 R14Svc=500480b8 SpsrSvc=20000010</codeblock> <p>Notes: </p> <ul>
+<li id="GUID-7FC165D2-735D-50D7-86D0-5513C8D3770A"><p>R15 is the program counter </p> </li>
+<li id="GUID-9D653C6D-C085-5EF1-938E-28081214661E"><p>R14 is the link register, </p> </li>
+<li id="GUID-5596B888-26D6-57AB-9760-EBEDA927E693"><p>R13 is the stack pointer </p> </li>
+</ul> </section>
+<section id="GUID-2A0D5950-F1A5-5EE1-87A3-840B1EAD6AAD"><title>m - do a memory
+dump</title> <p>This command dumps memory in both hexadecimal and ASCII format.
+Use one of the following command formats: </p> <codeblock id="GUID-157ED0E9-4012-5514-B17F-D2CC01A84C31" xml:space="preserve">m start end</codeblock> <codeblock id="GUID-ED0AE1B8-8AF7-5D31-872B-42878C3C11B1" xml:space="preserve">m start+length</codeblock> <p> <codeph>start</codeph> specifies
+the start address in hexadecimal, and <codeph>end</codeph> specifies the end
+address in hexadecimal. If the second parameter starts with a + character,
+then the following hexadecimal characters are interpreted as a length. </p> <p>Address
+parameters are always virtual addresses (the MMU is still on). </p> <p>The
+resulting format is similar to the EKA1 format. </p> <p>For example: </p> <p><userinput>.m
+81c01c60+30</userinput> </p> <codeblock id="GUID-06B94331-E70F-5058-8EE1-BD4310102C11" xml:space="preserve">81C01C60: 00 00 00 00 15 00 00 10 E0 6A 13 50 01 00 00 80 .........j.P....
+81C01C70: 30 3B C0 81 34 D9 03 50 00 00 FF FF E8 1C C0 81 0;..4..P........
+81C01C80: 34 D9 03 50 30 3B C0 81 FC 4A 13 50 E8 1C C0 81 4..P0;...J.P.....
+</codeblock> <p>If an illegal memory access occurs, the debugger traps the
+exception and displays an error message. </p> </section>
+<section id="GUID-FDF734D6-9E05-573F-BF40-8DB4C7E0BAC5"><title>z - do a memory
+dump, skipping over unmapped memory</title> <p>This command dumps memory in
+both hexadecimal and ASCII format, but excludes any unmapped memory space.
+If an illegal memory access occurs, it does not stop, but skips to the next
+page instead. This is useful to inspect the content of discontiguous chunks. </p> <p>The
+syntax and the display format is the same as for the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-2A0D5950-F1A5-5EE1-87A3-840B1EAD6AAD">m</xref> command. </p> </section>
+<section id="GUID-D0175D78-6F84-5F4F-BA90-2C591B473C69"><title>i - display
+information for the current process and thread</title> <p>This command displays
+information for the current process and thread. </p> <codeblock id="GUID-6EFED69E-3792-5F19-ACE5-A63F922F35DA" xml:space="preserve">SCHEDULER @80000d98: CurrentThread 8070dd28
+RescheduleNeeded=00 DfcPending=00 KernCSLocked=00000001
+DFCS: next 80000ea8 prev 80000ea8
+ProcessHandler=5004b040, AddressSpace=8070d7c8
+SYSLOCK: HoldingThread 8070dd28 iWaiting 00000000
+Extras 0: 8070d7c8 1: 8070d7c8 2: 8070d7c8 3: 00000000
+Extras 4: 00000000 5: 00000000 6: 00000000 7: 00000000
+Extras 8: 00000000 9: 00000000 A: 00000000 B: 00000000
+Extras C: 00000000 D: 00000000 E: 00000000 F: 00000000
+</codeblock> <p>The format for the thread is: </p> <codeblock id="GUID-53C336CC-CA91-542A-8BB3-858DF9F32745" xml:space="preserve">TheCurrentThread=8070da6c
+THREAD at 8070da6c VPTR=50052b50 AccessCount=3 Owner=8070d7c8
+Full name crash::Main
+Thread MState READY
+Default priority 28 WaitLink Priority 28
+ExitInfo 3,0,
+Flags 80000004, Handles 8070a79c
+Superviso81715000 size 1000
+User stack base 00402000 size 2000
+Id=19, Heap=00600000, Created heap=00600000, Frame=00000000
+Trap handler=00000000, ActiveScheduler=00000000, Exception
+handler=00000000
+TempObj=00000000 TempAlloc=00000000
+NThread @ 8070dd28 Pri 28 NState READY
+Next=8070dd28 Prev=8070dd28 Att=03 ExcInUserMode=10
+HeldFM=80000eb8 WaitFM=00000000 AddrSp=8070d7c8
+Time=0 Timeslice=20 ReqCount=0
+SuspendCount=0 CsCount=0 CsFunction=00000000
+SavedSP=81715d6c
+CAR 00000001
+DACR 30315507
+R13_USR 00000000 R14_USR 81715dc4 SPSR_SVC 81715e10
+ R4 30303031  R5 30303030  R6 81715dc4  R7 81715e14
+ R8 81715dac  R9 81715da0 R10 50055c88 R11 50055c3c
+ PC 81715dc0</codeblock> <p>The format for the process is: </p> <codeblock id="GUID-1D3E3B5D-9E9C-5D2D-A720-004B2783087E" xml:space="preserve">TheCurrentProcess=8070d7c8
+PROCESS at 8070d7c8 VPTR=50052bc4 AccessCount=5 Owner=00000000
+Full name crash
+ExitInfo 3,0,
+Flags 00040000, Handles 80709c98, Attributes 60010000
+DataBssChunk 8070a514, CodeChunk 8070a9a8
+DllDataChunk 00000000, Process Lock 8070d90c
+NumChunks=2
+0: Chunk 8070a514, run 00400000, access count 1
+1: Chunk 8070a704, run 00600000, access count 1
+Domain -1, DACR 55555507
+TheCurrentAddressSpace=8070d7c8
+TheCurrentVMProcess=8070d7c8
+PROCESS at 8070d7c8 VPTR=50052bc4 AccessCount=5 Owner=00000000
+Full name crash
+ExitInfo 3,0,
+Flags 00040000, Handles 80709c98, Attributes 60010000
+DataBssChunk 8070a514, CodeChunk 8070a9a8
+DllDataChunk 00000000, Process Lock 8070d90c
+NumChunks=2
+0: Chunk 8070a514, run 00400000, access count 1
+1: Chunk 8070a704, run 00600000, access count 1
+Domain -1, DACR 55555507
+TheCurrentDataSectionProcess=8070d7c8
+TheCompleteDataSectionProcess=8070d7c8
+PROCESS at 8070d7c8 VPTR=50052bc4 AccessCount=5 Owner=00000000
+Full name crash
+ExitInfo 3,0,
+Flags 00040000, Handles 80709c98, Attributes 60010000
+DataBssChunk 8070a514, CodeChunk 8070a9a8
+DllDataChunk 00000000, Process Lock 8070d90c
+NumChunks=2
+0: Chunk 8070a514, run 00400000, access count 1
+1: Chunk 8070a704, run 00600000, access count 1
+Domain -1, DACR 55555507
+</codeblock> </section>
+<section id="GUID-3494E61C-7097-544C-AE7D-73750337744A"><title>o - display
+brief DObject information</title> <p>This command in <i>lower case</i> displays
+basic information about the <xref href="GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497.dita"><apiname>DObject</apiname></xref>. The command has the
+following syntax: </p> <codeblock id="GUID-9F24821C-78C8-5CD0-8FF7-60F4A485C898" xml:space="preserve">o address</codeblock> <p>where <codeph>address</codeph> specifies
+the address of the <xref href="GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497.dita"><apiname>DObject</apiname></xref>. </p> <p>For example: </p> <p><userinput>o
+6403c170</userinput> </p> <codeblock id="GUID-4BB938B5-EB18-54E7-93AF-C06B79FEAB6F" xml:space="preserve">THREAD at 6403c170 VPTR=f8046c18 AccessCount=3 Owner=6403bb4c
+Full name crash::Main
+</codeblock> </section>
+<section id="GUID-1DED2B2F-E780-50A0-8325-5DA22BC7D3E0"><title>O - display
+full DObject information</title> <p>This command in <i>upper case</i> displays
+full information about the <xref href="GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497.dita"><apiname>DObject</apiname></xref>. The exact format displayed
+depends on the exact type of the <xref href="GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497.dita"><apiname>DObject</apiname></xref> being referenced,
+for example, whether it is a thread, process, or a chunk. The command has
+the following syntax: </p> <codeblock id="GUID-C817409C-04A2-54BA-ABB6-185950CF4462" xml:space="preserve">O address</codeblock> <p>where <codeph>address</codeph> specifies
+the address of the <xref href="GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497.dita"><apiname>DObject</apiname></xref>. </p> </section>
+<section id="GUID-AE1A903F-6351-523C-AD88-AD6CA4527C39"><title>p - display
+short information about code segments</title> <p>This command in <i>lower
+case</i> displays basic information about one or more code segments, as encapsulated
+by <codeph>DCodeSeg</codeph> objects. The command has the following syntax: </p> <codeblock id="GUID-EA2F3910-8E6B-58AA-B2DF-BED7E002C786" xml:space="preserve">p address | all</codeblock> <p>where: </p> <ul>
+<li id="GUID-AE4B3337-4438-5DC8-B84E-D5CABF708E5E"><p> <codeph>address</codeph> is
+the address of a specific code segment </p> </li>
+<li id="GUID-878886DD-9F7F-5B42-963F-37F7D5058F11"><p> <codeph>all</codeph> refers
+to all code segments. </p> </li>
+</ul> <p>For example: </p> <p><userinput>p 64053b70</userinput> </p> <codeblock id="GUID-9B44910A-3FB8-5283-AD41-29E5192A6393" xml:space="preserve">.p 64053b70
+CodeSeg at 64053b70:
+ FileName: Z:\sys\bin\crash.exe
+ RunAddress: f83e3498</codeblock> </section>
+<section id="GUID-9450C209-3F28-581D-87B0-CEA96B94DB62"><title>P - display
+full information about code segments</title> <p>This command in <i>upper case</i> displays
+the full information about one or more code segments, as encapsulated by <codeph>DCodeSeg</codeph> objects.
+The command has the following syntax: </p> <codeblock id="GUID-FBFC0802-A4CA-5050-8DC7-893144A24330" xml:space="preserve">P address | all</codeblock> <p>where: </p> <ul>
+<li id="GUID-DE005DAD-FBDB-5A07-8E6A-6D95A64E6BD5"><p> <codeph>address</codeph> is
+the address of a specific code segment </p> </li>
+<li id="GUID-339213D1-55B3-546B-B8CC-32785469CCC0"><p> <codeph>all</codeph> refers
+to all code segments. </p> </li>
+</ul> <p>For example: </p> <p><userinput>P 64053b70</userinput> </p> <codeblock id="GUID-B6B41D55-0093-5118-B5EB-C956AE8980EA" xml:space="preserve">.p 64053b70
+CodeSeg at 64053b70:
+ FileName: Z:\sys\bin\crash.exe
+ RunAddress: f83e3498
+
+ iLink:     Prev 64052f48 (64052f40) Next 640000e0 (640000d8)
+ iTempLink: Prev dfdfdfdf (dfdfdfcf) Next 00000000 (00000000)
+ iGbgLink:  Prev 00000000 (00000000) Next 00000000 (00000000)
+ iAccessCount: 1
+ iEntryPtVeneer: f83e3498
+ iFileEntryPoint: f83e3498
+ iExtOffset: 10
+ iUids: 1000007a 00000000 00000000
+ iDeps: 00000000 ( )
+ iDepCount: 0
+ iNextDep: 0
+ iMark: 31
+ iAttr: a
+ iExeCodeSeg: 64053b70
+ iAttachProcess: 00000000
+ iModuleVersion: a0000
+ iS:
+   SecureId: 00000000, VendorId: 70000001
+   Caps: 000fffff 00000000
+ iSize: 370
+
+ iXIP: 1
+ iInfo: f83e3420 (TRomImageHeader*)
+  iUid1: 1000007a, iUid2: 00000000, iUid3: 00000000
+  iUidChecksum: 045ac39e
+  iEntryPoint:  f83e3498
+  iCodeAddress: f83e3498, iCodeSize: 00000370
+  iDataAddress: 00000000, iDataSize: 00000000
+  iTextSize:    00000370, iBssSize:  00000000
+  iHeapSizeMin: 00001000, iHeapSizeMax: 00100000, iStackSize: 00002000
+  iDllRefTable: 00000000
+  iExportDirCount: 0, iExportDir: f83e33fc
+  iS:
+    SecureId: 00000000, VendorId: 70000001
+    Caps: 000fffff 00000000
+  iToolsVersion: Major 02 Minor 01 Build 0225
+  iFlags: 0000002a
+  iPriority: 352
+  iDataBssLinearBase: 00400000
+  iNextExtension: 00000000
+  iHardwareVariant: 01000000
+  iTotalDataSize: 00000000
+  iModuleVersion: 000a0000
+  iExceptionDescriptor: f83e34f4
+
+ iCodeAllocBase: 80000000
+ iDataAllocBase: 80000000
+ iKernelData: 00000000</codeblock> </section>
+<section id="GUID-FB2E24A6-9744-5169-BA90-DDF84DF1D3E5"><title>c - display
+contents of object container</title> <p>This command in <i>lower case</i> displays
+the contents of one of the kernel's object containers, a <codeph>DObjectCon</codeph> type.
+Note that information is dumped very quickly without page breaks, which is
+useful in situations where the kernel is likely to become very unstable very
+shortly after crashing. There is an upper case version of this command, <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-55EF66A9-684F-50DA-8E2B-FA00B3D4FB6C">C</xref>,
+which generates output with a pause between pages. </p> <p>The command has
+the following syntax: </p> <codeblock id="GUID-71EF50B9-1612-57CA-840D-F142CF5EE88E" xml:space="preserve">c type</codeblock> <p>where <codeph>type</codeph> is
+a single hexadecimal digit between 0 and D inclusive that specifies which
+kernel container is to be dumped. The mapping between the hexadecimal digit
+and the kernel container is: </p> <table id="GUID-B1F908E6-0492-507E-BDAC-D010A1C4E231">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>0</p> </entry>
+<entry><p>Threads </p> </entry>
+</row>
+<row>
+<entry><p>1</p> </entry>
+<entry><p>Processes </p> </entry>
+</row>
+<row>
+<entry><p>2</p> </entry>
+<entry><p>Chunks </p> </entry>
+</row>
+<row>
+<entry><p>3</p> </entry>
+<entry><p>Libraries </p> </entry>
+</row>
+<row>
+<entry><p>4</p> </entry>
+<entry><p>Semaphores </p> </entry>
+</row>
+<row>
+<entry><p>5</p> </entry>
+<entry><p>Mutexes </p> </entry>
+</row>
+<row>
+<entry><p>6</p> </entry>
+<entry><p>Timers </p> </entry>
+</row>
+<row>
+<entry><p>7</p> </entry>
+<entry><p>Servers </p> </entry>
+</row>
+<row>
+<entry><p>8</p> </entry>
+<entry><p>Sessions </p> </entry>
+</row>
+<row>
+<entry><p>9</p> </entry>
+<entry><p>LogicalDevices </p> </entry>
+</row>
+<row>
+<entry><p>A</p> </entry>
+<entry><p>PhysicalDevices </p> </entry>
+</row>
+<row>
+<entry><p>B</p> </entry>
+<entry><p>Channels </p> </entry>
+</row>
+<row>
+<entry><p>C</p> </entry>
+<entry><p>ChangeNotifiers </p> </entry>
+</row>
+<row>
+<entry><p>D</p> </entry>
+<entry><p>Undertakers </p> </entry>
+</row>
+<row>
+<entry><p>E</p> </entry>
+<entry><p>Message queues </p> </entry>
+</row>
+<row>
+<entry><p>F</p> </entry>
+<entry><p>Property references </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>For example: </p> <p><userinput>c A</userinput> </p> <codeblock id="GUID-9153AF8D-8F14-5E1E-B6A5-F24502DF704D" xml:space="preserve">Container 10 at 640275c4 contains 3 PHYSICAL DEVICES:
+PHYSICAL DEVICE at 64032dac VPTR=f805d9fc AccessCount=2 Owner=00000000
+Full name Media.IRam
+PHYSICAL DEVICE at 640339e8 VPTR=f8067e44 AccessCount=2 Owner=00000000
+Full name Media.Flash
+PHYSICAL DEVICE at 64033a64 VPTR=f806b9f8 AccessCount=2 Owner=00000000
+Full name Media.Ata
+</codeblock> <p><userinput>c 0</userinput> </p> <codeblock id="GUID-D0EAECD6-B683-591A-964F-C8C893A074F0" xml:space="preserve">Container 0 at 807022b8 contains 12 THREADS:
+THREAD at 807011c0 VPTR=50052b04 AccessCount=1 Owner=8070107c
+Full name EKern::Null
+Thread MState READY
+Default priority 0 WaitLink Priority 0
+ExitInfo 3,0,
+Flags 0000000c, Handles 80701520
+Supervisor stack base 80700000 size 1000
+User stack base 00000000 size 0
+Id=0, Heap=00000000, Created heap=00000000, Frame=00000000
+Trap handler=00000000, ActiveScheduler=00000000, Exception
+handler=00000000
+TempObj=00000000 TempAlloc=00000000
+NThread @ 8070147c Pri 0 NState READY
+Next=8070147c Prev=8070147c Att=00 ExcInUserMode=00
+HeldFM=00000000 WaitFM=00000000 AddrSp=8070107c
+Time=-1 Timeslice=-1 ReqCount=0
+SuspendCount=0 CsCount=0 CsFunction=00000000
+SavedSP=80700f50
+CAR 00000001
+DACR 55555547
+R13_USR 00403ed4 R14_USR 500c88b4 SPSR_SVC 200000d3
+ R4 00000009  R5 5004b7ec  R6 50000000  R7 dc911000
+ R8 00000000  R9 807103c0 R10 50002140 R11 80700fb4
+ PC 500481b4
+</codeblock> <p>The information displayed for each object is the same as that
+shown after using the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-1DED2B2F-E780-50A0-8325-5DA22BC7D3E0">q</xref> command.
+After displaying the information for each object, the debugger pauses until
+you press a key. </p> <p>Notes </p> <ul>
+<li id="GUID-63AF0857-4C02-5F39-8CB2-E57E11727F92"><p>the <codeph>DObjectCon</codeph> class
+is internal to Symbian platform. </p> </li>
+<li id="GUID-827905CF-C25F-56D6-B40B-416C3DA1C5CB"><p>the type value passed
+as an argument to the command is one of the enum values of the <codeph>TObjectType</codeph> enum;
+this enum is internal to Symbian platform. </p> </li>
+</ul> </section>
+<section id="GUID-55EF66A9-684F-50DA-8E2B-FA00B3D4FB6C"><title>C - display
+contents of object container</title> <p>This command in <i>upper case</i> is
+exactly the same as the lower case <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-FB2E24A6-9744-5169-BA90-DDF84DF1D3E5">c</xref> command
+except that the display of output pauses between pages. If you need to dump
+output as fast as possible without pauses, use the lower case version. </p> </section>
+<section id="GUID-0CDF0190-A445-526B-AC1F-D9D58095B18B"><title>r - dump register
+contents</title> <p>This command dumps the full ARM register set. </p> <p>On
+ARM this dumps the full set of user mode registers and all the alternate registers
+for other modes. </p> <p>For example: </p> <p><userinput>r</userinput> </p> <codeblock id="GUID-4569C1FE-78B0-518F-A2A0-642CECD9E1F3" xml:space="preserve">MODE_USR:
+ R0=6571de54  R1=0000002a  R2=00000002  R3=ffffffff
+ R4=0000002a  R5=f8170414  R6=6571df14  R7=6403cba8
+ R8=00000001  R9=6403c41c R10=640002f8 R11=6571de70
+R12=00000020 R13=00404e00 R14=f80818c0 R15=f800bfa8
+CPSR=60000013
+MODE_FIQ:
+ R8=00000000  R9=ffffffff R10=ffffffff R11=00000000
+R12=00000000 R13=64000d0c R14=c080079c SPSR=e00000dc
+MODE_IRQ:
+R13=6400110c R14=00000013 SPSR=20000013
+MODE_SVC:
+R13=6571de54 R14=f80328bc SPSR=60000010
+MODE_ABT:
+R13=6400090c R14=ffff0010 SPSR=400000d7
+MODE_UND:
+R13=6400090c R14=95221110 SPSR=f000009d
+</codeblock> </section>
+<section id="GUID-5693700E-6401-56B1-9817-AE0C3A81B42D"><title>S - Dumps thread
+stack contents</title> <p>This command, in upper case, dumps both the user
+and supervisor stacks used by each thread in the system. Some threads do not
+have a user thread, in which case this is indicated. Each set of stacks is
+displayed in turn, in the following format: </p> <codeblock id="GUID-F8622389-3BD3-5CC9-A6BC-4358BCE8F5F8" xml:space="preserve">THREAD at c8052fa0 VPTR=80082304 AccessCount=6 Owner=c8044608
+Full name efile.exe::LoaderThread
+User stack base at 00410000, size == 1000
+Stack pointer == 00413e30
+Stack mapped at 00410000
+00413e30: 10 01 70 01 99 93 1b 80 18 01 70 01 d0 56 1b 80 ..p.......p..V..
+00413e40: 00 00 00 00 00 00 00 00 84 00 70 01 84 00 70 01 ..........p...p.
+00413e50: 04 00 00 00 23 91 1b 80 38 01 70 01 10 01 70 01 ....#...8.p...p.
+00413e60: 80 3e 41 00 01 00 00 00 10 01 70 01 00 00 00 00 .&gt;A.......p.....
+00413e70: 84 00 70 01 cd 91 1b 80 30 02 70 01 00 00 00 00 ..p.....0.p.....
+
+Supervisor stack base at c9127000, size == 1000
+Stack pointer == c9127fbc
+c9127fb0: b0 d1 0a c8 0c 00 00 00 13 00 00 00 00 07 00 00 ................
+c9127fc0: 00 00 f0 00 45 55 55 55 30 3e 41 00 89 ff 1b 80 ....EUUU0&gt;A.....
+c9127fd0: 10 00 00 20 10 01 70 01 80 3e 41 00 98 c7 23 80 ... ..p..&gt;A...#.
+c9127fe0: 58 3e 41 00 04 00 00 00 40 00 00 00 98 4b 04 c8 X&gt;A.....@....K..
+c9127ff0: 60 04 00 c8 98 01 02 80 00 00 00 00 10 5a 1b 80 `............Z..</codeblock> <p><note> With
+a multiple memory model, this command is the only way to reliably dump a stack. </note></p> </section>
+<section id="GUID-8F9BAB99-8B88-5120-A95E-A22404110BAE"><title>x - leave debugger,
+cold restart of ROM image</title> <p>This command, in lower case, leaves the
+debugger and does a cold restart of the current ROM image. </p> </section>
+<section id="GUID-4E12A080-AC83-5872-A66D-4C14A65C5CFA"><title>X - leave debugger,
+return to bootloader</title> <p>This command, in upper case, leaves the debugger,
+and returns to the bootloader to wait for a new ROM image to be downloaded. </p> </section>
+<section id="GUID-190C956D-4F57-593B-B3B1-958B6CAE1267"><title>h - Help</title> <p>Displays
+a short summery of the crash debugger commands. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-092D336A-155A-4F18-AAF7-92E08473700E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-092D336A-155A-4F18-AAF7-92E08473700E" xml:lang="en"><title>DMA Overview</title><shortdesc>Direct Memory Access (DMA) uses a controller to copy data
+between memory locations, or between memory and peripherals with minimal
+involvement from the CPU.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-04298BEC-F064-40C4-9A8C-DFB15953C85B"><title>Purpose</title><p>Direct Memory Access (DMA) channels allow you to copy data between
+memory locations, or between memory and peripherals, while minimizing
+the use of  the CPU. The transfer operation is performed in hardware
+by the DMA controller. The purpose of the DMA platform service is
+to provide a common interface between hardware and device drivers
+which use DMA.</p><p>The framework is divided into a platform-independent
+layer and a platform-specific layer, with the DMA platform service
+being the interface between the two. The framework presents an API
+for use by device drivers and other client applications which transfer
+data by DMA. The PSL must be implemented by hardware developers to
+provide the same functionality on multiple platforms.</p></section>
+<section id="GUID-140D36E7-EFC1-4206-A563-417AAB6BCC1C"><title>Architecture</title><p><fig id="GUID-0EF82751-1A74-4A39-BA92-E7E8F441E7F7">
+<title>DMA Framework</title>
+<image href="GUID-A6845EB0-4B4D-49C8-85A5-A933A2C351CF_d0e89230_href.png" placement="inline"/>
+</fig></p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-092F414B-2279-4ADB-970F-75DAB8A80BD7.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,68 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE task
+  PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
+<task id="GUID-092F414B-2279-4ADB-970F-75DAB8A80BD7" xml:lang="en"><title>SDIO Testing Guide</title><shortdesc>How to run unit tests of the SDIO platform-specific layer.</shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody>
+<prereq id="GUID-A029444C-0BF1-4D78-88EF-48AFBC35606B">       <p>Before
+running this test, you must do the following:<ul>
+<li><p>Port the SDIO Controller for your platform (see <xref href="GUID-9BBDFF77-5E2C-4E13-BEB3-716CC80B3375.dita">SDIO Implementation
+Guide</xref>)</p></li>
+<li><p>Build the test ROM.</p></li>
+<li><p>Boot the device with the test ROM.</p></li>
+</ul></p>     </prereq>
+<context id="GUID-88D222F5-0078-42E9-B1AF-67C32056EDBE"> <p>After
+you have ported the SDIO Controller on your platform, you can test
+it using the provided unit test application, SDIOTest. </p><p>The
+test application runs in a text shell and is made of two parts:<ul>
+<li><p>The test program, <filepath>sdiotest.exe</filepath> tests the
+Controller in isolation, at the interface level.</p></li>
+<li><p>The test driver,  <filepath>d_sdioif.ldd</filepath> uses the SDIO API, which is a kernel-side interface.</p> </li>
+</ul></p><p>The source code of the test application is in <filepath>/e32utils/sdio/source/</filepath>.</p><p>You must build <filepath>d_sdioif.ldd</filepath> for the appropriate platform and <filepath>sdiotest.exe</filepath> for the appropriate CPU architecture.</p><p>To include the two test components in a ROM, specify the <filepath>sdiotests.iby</filepath> file in your command line when building
+the image, such as in the following example:<codeblock xml:space="preserve">rom.bat -v h4hrp -i armv5 --symbol –t sdiotests.iby -m USE_SDIO_SD_MMC</codeblock></p><p>The SDIOTest utility is not an automated test: it performs
+various unitary operations which can be used to validate the behavior
+of the SDIO Controller. First, you request an operation by pressing
+the corresponding key on the command line. Then, you compare the resulting
+display with the data expected from the card. </p><p>The following
+steps provide an example of how to test your port.</p>     </context>
+<steps id="GUID-4DD07DEC-6017-4237-BE46-1D69E5FBD744-GENID-1-2-1-10-1-5-1-9-1-1-8-1-7-1-3-3">
+<step id="GUID-A295D44C-B646-4C27-842F-E11828BD2C6B"><cmd>Run the
+SDIOTest application.</cmd>
+</step>
+<step id="GUID-9A69E5AD-E938-4092-A8C2-CB65C37C8962-GENID-1-2-1-10-1-5-1-9-1-1-8-1-7-1-3-3-2"><cmd>Power up
+the stack by pressing the <userinput>P</userinput> key.</cmd>
+<stepresult><p>The stack must report that no card is present.</p></stepresult>
+</step>
+<step id="GUID-7F13CFE3-7B78-42EF-8BEA-682435B5F228"><cmd>Insert a
+card and power it up.</cmd>
+<stepresult><p>The stack must report that a card is present. </p></stepresult>
+</step>
+<step id="GUID-5FB0E930-1590-44FF-8C44-4DD842065C5E"><cmd>Read the
+card information by pressing the <userinput>I</userinput> key.</cmd>
+<stepresult><p>The data returned by the stack must match the data
+sheet you have for the card.</p></stepresult>
+</step>
+<step id="GUID-6798C237-7567-4BC8-9D69-358871167864"><cmd>Read the
+common control registers by pressing the <userinput>R</userinput> key.</cmd>
+<stepresult><p>The values must match the expected card data.</p></stepresult>
+</step>
+<step id="GUID-39001CA5-47E5-4340-B70C-13C4AD2A0266"><cmd>Read the
+common configuration by pressing the <userinput>C</userinput> key.</cmd>
+<stepresult><p>The values must match the expected card data.</p></stepresult>
+</step>
+<step id="GUID-CF489FD9-D291-4FFB-9FC7-F1EB5C80416F"><cmd>Read information
+about the I/O function by pressing the <userinput>F</userinput> key.</cmd>
+<stepresult><p>The data returned by the stack must match the I/O specifications
+of the card.</p></stepresult>
+</step>
+<step id="GUID-EB45AEEA-6EEA-4B9E-B0C4-A2BF66252812"><cmd>Quit the
+test by pressing the <userinput>Q</userinput> key.</cmd>
+</step>
+</steps>
+</taskbody></task>
\ No newline at end of file
Binary file Adaptation/GUID-09EE01E2-BF5E-5302-BA25-46C440ADECF5-master.png has changed
Binary file Adaptation/GUID-09EE01E2-BF5E-5302-BA25-46C440ADECF5_d0e11034_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0A6C8DB8-ED41-4243-BA96-CA691CF9CD19.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-0A6C8DB8-ED41-4243-BA96-CA691CF9CD19" xml:lang="en"><title>Data
+Buffers</title><shortdesc>This document describes how device drivers allocate and access
+memory buffers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-21C5B685-F546-45B5-A829-00B2DBCBF8E4">      
+      <p>Most device drivers need to use memory buffers for I/O operations.
+Drivers typically own memory buffers, allocate them, and access them through
+pointers. The thread should be in a critical section when it allocates or
+de-allocates memory. </p> <codeblock id="GUID-B222000C-8344-5239-9546-4E831A3C0A6E" xml:space="preserve">// Tx and Rx Buffers
+TUInt8* iTxBuffer;    
+TUInt8* iRxBuffer;</codeblock> <codeblock id="GUID-A921D206-7243-5F0A-ADA3-0330D93A137F" xml:space="preserve">// Logical Channel second stage constructor
+TInt DExDriverLogicalChannel::DoCreate(TInt /*aUnit*/, const TDesC8* 
+/*anInfo*/, const TVersion&amp; aVer)
+    {
+    ...
+    // Initialize the Tx Buffer
+    iTxBuffer = (TUInt8*) Kern::Alloc(KTxBufferSize);
+    if (!iTxBuffer)
+        return KErrNoMemory;
+    ...
+    }</codeblock> <p>Memory buffers must be freed when they are not required.
+If this is not done, a memory leak occurs. </p> <codeblock id="GUID-688A360C-1B7A-5F3A-BB83-98EB8A4658F3" xml:space="preserve">// Free Tx Buffer
+Kern::Free(iTxBuffer)</codeblock>     </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0A9C35DA-DF54-5885-AFE0-F4D5B3E49941.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept xml:lang="en" id="GUID-0A9C35DA-DF54-5885-AFE0-F4D5B3E49941"><title>Allocate Resources for Endpoints</title><shortdesc>This tutorial shows how to set up the required endpoint resources. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody><p> <b>Note</b>: This is an optional step when creating a class driver. </p> <section id="GUID-0FD43479-5CDC-5CF0-99F4-9A9B5DB82CDE"><title>Introduction</title> <p>Class drivers can allocate resources to endpoints. This allows the PDD PSL to manage DMA resources more efficiently and to enable and disable endpoint resources on particular interface settings. </p> <p> <b>Note</b>: The functions <codeph>AllocateEndpointResource()</codeph>, <codeph>QueryEndpointResourceUse()</codeph> and <codeph>DeAllocateEndpointResource()</codeph> always refer to the endpoints of the currently active alternate interface setting. Since after interface creation, and before configuration through the host, alternate setting 0 (default) is active, resources for endpoints on other settings of that interface can only be accessed after a successful <codeph>SetInterface()</codeph> request from the host that selects the respective alternate setting. See <xref href="GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita#GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834/GUID-9D773343-8597-5A85-9511-32E176D06E8F">Set the interface</xref>. </p> </section> <section><title>PDD Support for endpoint resource allocation</title> <p>The USB Client PDD PSL must explicitly support the allocation of endpoint resources. The PDD will indicate if this is the case by setting the <codeph>iFeatureWord1</codeph> member in the <xref href="GUID-638DE142-E894-3EC9-9406-CAF67DB822A1.dita"><apiname>TUsbDeviceCapsV01</apiname></xref> structure to the constant <xref href="GUID-B9F2B6CB-E2D7-3794-B0E2-0F60DC24B8F0.dita"><apiname>KUsbDevCapsFeatureWord1_EndpointResourceAllocV2</apiname></xref>. </p> <codeblock id="GUID-2DF5FC9B-A742-5D2C-8AFE-F94F95908514" xml:space="preserve">TUsbDeviceCaps caps;
+... 
+caps().iFeatureWord1 | KUsbDevCapsFeatureWord1_EndpointResourceAllocV2;</codeblock> <p>This structure is passed to the LDD as part of <xref href="GUID-8133647A-13D8-38A5-B458-13AA58470F0B.dita"><apiname>TUsbcInterfaceInfo</apiname></xref> at interface (and thus logical endpoint) creation time in the call to <codeph>SetInterface()</codeph>. See <xref href="GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita#GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834/GUID-8B403342-D4CC-5DB7-AD4E-402DFD75FA62">Define the interface data</xref>. </p> <p>The successful outcome of the <codeph>SetInterface()</codeph> call does not depend on the availability of requested resources as the driver does not try to allocate requested endpoint resources at this point. The Physical Device Driver (PDD) PIL passes the resource request information to the PSL only at endpoint configuration time (after a <codeph>SetInterface()</codeph> request has been received from the host). </p> <p>Check that the driver supports endpoint resource allocation for DMA and double buffering with by <xref href="GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita#GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834/GUID-E816E6FE-BD6A-5FF6-B450-CA5304BC0175">Getting the Device capabilities</xref> for <codeph>iFeatureWord1</codeph>. </p> </section> <section><title>Allocate endpoint resources</title> <p>Allocate resources for endpoints with <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-094CA4FC-E221-373F-BEB6-0D9382A8B0BC"><apiname>RDevUsbcScClient::AllocateEndpointResource()</apiname></xref>. Pass the function the endpoint number and a member of <xref href="GUID-98F7AB41-2C6F-38F9-951B-36659EE394F5.dita"><apiname>TUsbcEndpointResource</apiname></xref> to indicate the type of resource. The parameter that takes the resource type is not a bitmap and <codeph>TEndpointResource</codeph> values should not be combined in the same call to the function. </p> <p>If more than one resource is to be specified then multiple calls to the function have to be made, each one selecting a single resource. </p> <codeblock id="GUID-D04EE4DA-5E9A-5F55-88AF-51694D2BBCE6" xml:space="preserve">gPort.AllocateEndpointResource(aEndpoint, EUsbcEndpointResourceDoubleBuffering);</codeblock> <p> <codeph>KErrNone</codeph> is returned if the resource has been successfully allocated, in which case it will be used from when the current bus transfer has been completed. <codeph>KErrNotSupported</codeph> will be returned if the endpoint does not support the resource requested and <codeph>KErrInUse</codeph> will be returned if the resource is already consumed and cannot be allocated. </p> </section> <section><title>Query </title> <p>There is no direct and immediate feedback as to whether the resources were successfully allocated. The user can find out about the outcome by calling <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-AF83C7D3-A914-3B5E-A505-50BD2D74A2BA"><apiname>RDevUsbcScClient::QueryEndpointResourceUse()</apiname></xref> after a configuration or interface alternate setting change notification. </p> <p> <codeph>QueryEndpointResourceUse()</codeph> returns <codeph>ETrue</codeph> if the specified resource is in use at the endpoint and <codeph>EFalse</codeph> if not. </p> <codeblock id="GUID-9D3E1AA9-73DF-5099-8877-B56224F68C09" xml:space="preserve">TBool res = gPort.QueryEndpointResourceUse(aEndpoint, EUsbcEndpointResourceDoubleBuffering);</codeblock> <p>A resource may be deallocated by the PDD if: </p> <ul><li id="GUID-7B6A5139-2FF9-5CF3-A9F6-6125E5883F83"><p>the host selects a different configuration (including zero) than the current one by sending a SET_CONFIGURATION request, </p> </li> <li id="GUID-3C5232C1-9E27-5752-B75C-4169150B3C4F"><p>the host selects a different alternate interface setting than the current one by sending a SET_INTERFACE request, </p> </li> <li id="GUID-2A853D94-7955-519C-82A0-DB544A6C3E9E"><p>the user calls <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-37D64B03-5907-31F8-96C6-CD4E2313147D"><apiname>RDevUsbcScClient::ReleaseInterface()</apiname></xref> or <xref href="GUID-BE73CFE6-D48D-5B92-AF49-E2D967ADF0EC.dita">Unloads the USB Client LDD</xref>. </p> </li> </ul> </section> <section><title>Deallocate</title> <p> <xref href="GUID-9348DBF1-AAD2-3D56-819E-09EE51BE5820.dita"><apiname>DeAllocateEndpointResource()</apiname></xref> de-allocates the use of <codeph>aResource</codeph> from some endpoint or ends a specified endpoint behaviour. <codeph>aResource</codeph> is typically some rationed hardware resource or possibly specifies a type of endpoint behaviour. <codeph>aResource</codeph> is not a bitmap and <codeph>TEndpointResource</codeph> values should not be combined. <codeph>KErrNone</codeph> is returned if the resource has been successfully de-allocated, in which case it will be removed from when the current bus transfer has been completed. <codeph>KErrNotSupported</codeph> will be returned if the endpoint does not support the resource requested. </p> </section> <section><p>After you have allocated resources for the endpoints you should force a <xref href="GUID-9597DB22-D932-5A58-9C3C-4E5FCA244253.dita">Re-Enumeration</xref>. </p> </section> </conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0AB3D313-79FF-4716-AFD4-FF3AA3C2E936.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-0AB3D313-79FF-4716-AFD4-FF3AA3C2E936" xml:lang="en"><title>Trace-Based
+Debugging</title><shortdesc>This document describes how to generate traces with the Kernel
+Trace and BTrace APIs.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-58E18DB3-8E47-4625-9F66-FEAEA3315587">       <title>Kernel
+debug messages</title><p><b>KTRACE</b> </p> <p>During development,
+drivers can display information for debugging purposes. The basic API to use
+for this is <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-CAAD1252-CBEF-318B-B61D-D12D4E80C5CF"><apiname>Kern::Printf()</apiname></xref>. </p> <p>You can make the display
+of debugging messages conditional on whether certain flags have been set in
+the ROM. To do this, use the print command with the <xref href="GUID-9C275309-15B4-34D0-AD05-44C6C501FC08.dita"><apiname>__KTRACE_OPT()</apiname></xref> macro.
+For example: </p> <codeblock id="GUID-BB56427E-762B-5B77-B3DA-369751A262D8" xml:space="preserve">_KTRACE_OPT(KDEVICE,Kern::Printf("++DExDriverLogicalChannel::DoCreate"));</codeblock> <p>This macro's first argument is a mask that must be enabled for the message
+to be displayed. The <codeph>kerneltrace</codeph> keyword, defined in <filepath>header.iby</filepath>,
+sets which masks are enabled for a debug ROM image. </p> <p>The following
+are some of the mask definitions that can be found in <filepath>nk_trace.h</filepath>: </p> <ul>
+<li id="GUID-3F091877-D335-5F73-A752-6D80E272D6E7"><p> <codeph>KHARDWARE</codeph>  </p> </li>
+<li id="GUID-CF060894-A381-5253-BA21-344DD6334E16"><p> <codeph>KEXTENSION</codeph>  </p> </li>
+<li id="GUID-BD44067A-0FCA-5C40-9F96-2996FAE96B4D"><p> <codeph>KDMA</codeph>  </p> </li>
+<li id="GUID-20E085C0-ECD6-5119-AC33-449D6F2EDA6C"><p> <codeph>KBOOT</codeph>  </p> </li>
+<li id="GUID-8221B2F2-6773-53DE-9784-EA609BA57900"><p> <codeph>KSCRATCH</codeph>  </p> </li>
+<li id="GUID-E395983C-A76B-5EC3-AA07-258074A0AE71"><p> <codeph>KPANIC</codeph>  </p> </li>
+<li id="GUID-AFCF4A79-C5E0-531C-97CE-A55F9BCE4E8C"><p> <codeph>KPBUS1</codeph>  </p> </li>
+<li id="GUID-A908027F-B8BC-54CC-B784-5FE45BA20E4F"><p> <codeph>KPBUS2</codeph>  </p> </li>
+</ul>     </section>
+<section id="GUID-B404E745-2D37-4D63-88D9-1ABAA474B58A"><title>BTrace service</title> <p>BTrace
+is a Kernel service that is designed to generate and capture trace information
+with minimal impact on a running system. It is useful for generating trace
+information in the Kernel and in drivers, for which fast tracing is required
+and general serial debug is not possible. </p> <p>BTrace defines API and macros
+to use in programs to create trace information in <filepath>e32btrace.h</filepath>.
+The generated trace messages can be retrieved from the driver or Kernel during
+execution. To do this, BTrace must be built into the ROM image; it is included
+by default in a text shell ROM. The <codeph>BTrace</codeph> command should
+then be executed from the text shell with the appropriate options. For example,
+the following commands sets various filter and buffer size options, runs a
+program called <filepath>t_expio</filepath> that generates some trace data,
+and finally writes the trace data into a file <filepath>d:\expiolog.txt</filepath>. </p> <codeblock id="GUID-F631555E-2736-5D57-9543-8566A22590B8" xml:space="preserve">BTRACE -f1,2,3 -m3 -b1024
+t_expio.exe
+BTRACE d:\expiolog.txt</codeblock> <p>The basic macros used for generating
+traces are: </p> <ul>
+<li id="GUID-C4CED603-6EAB-5CC3-8C8F-F72962F14F6D"><p> <codeph> BTrace0 (aCategory,aSubCategory)</codeph>  </p> </li>
+<li id="GUID-099F0EA6-60A2-50F7-B855-CC0DE97B70C2"><p> <codeph> BTrace4 (aCategory,aSubCategory,a1)</codeph>  </p> </li>
+<li id="GUID-1D643E7D-2C8B-51A1-B702-CA6BB644F61B"><p> <codeph> BTrace8 (aCategory,aSubCategory,a1,a2)</codeph>  </p> </li>
+<li id="GUID-B895DBA3-D4A2-59F7-952B-7E6E1856E1A4"><p> <codeph> BTrace12(aCategory,aSubCategory,a1,a2,a3)</codeph>  </p> </li>
+</ul> <p>The macros set category and sub-category values with their first
+two arguments. The category indicates the type of information being recorded,
+which is specified using a value from the enumeration <xref href="GUID-5BF17780-AD31-30CF-AFD9-915CBDA74441.dita#GUID-5BF17780-AD31-30CF-AFD9-915CBDA74441/GUID-E26B390F-390C-372B-B60F-9F788119A98B"><apiname>BTrace::TCategory</apiname></xref>.
+The sub-category is an enumeration specific to each category. The other arguments, <codeph>a1</codeph> -<codeph>a3</codeph>,
+set the trace data, of lengths 0, 4, 8 or 12 bytes, to record. </p> <p>For
+longer traces that include a context ID, program counter values, and different
+filters, more macros are provided. Performance logging macros are also available
+which in turn use BTrace to <xref href="GUID-9D26E38F-5C7B-5330-A54B-8F97D0F204D0-GENID-1-2-1-8-1-1-7-1-1-5-1.dita">log
+performance</xref> related data. For example: </p> <codeblock id="GUID-20F3E42A-B6F6-55B6-B0B5-D466518AC6DC" xml:space="preserve">TKName nameBuf;
+Name(nameBuf);
+
+// Output a fast-trace record of the specified category which also 
+// includes a Context ID 
+BTraceContextN(BTrace::EChunks,BTrace::EChunkCreated,this,iMaxSize,
+    nameBuf.Ptr(),nameBuf.Size());</codeblock></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0AFF5666-6BF9-5022-ADBC-5EFFA743B288.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-0AFF5666-6BF9-5022-ADBC-5EFFA743B288" xml:lang="en"><title>ROM
+Paging Guide</title><shortdesc>Describes demand paging when applied to ROM demand paging. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-D67AB531-76C8-50AE-BBA2-48FC7F47DCDD"><title>Introduction</title> <p>Demand
+paging using ROM demand paging is used when the files to be paged are in the
+core ROM image and not using another file system such as ROFS. </p> </section>
+<section id="GUID-338FBBC7-2B90-4483-B055-2AEA23DAB479"><title>Background information</title><p> The following are useful
+background information for Demand Paging using ROM demand paging:</p><ul>
+<li><p>Demand Paging</p></li>
+<li><p>ROM paging</p></li>
+</ul> </section>
+<section id="GUID-143C5BFF-AC9A-4A83-B20A-79E0A8E9B36E"><title>ROM Demand Paging features</title><p>Demand paging (using
+ROM demand paging) provides the following features compared to <xref href="GUID-CE9EA167-0594-5E61-9640-6B2B63A92EA7.dita">code
+paging</xref> and <xref href="GUID-2B7D04D9-98DE-5284-836D-01DB4FA8949D.dita">writable
+data paging</xref> : </p><ul>
+<li><p>Lower RAM overhead</p></li>
+<li><p>Lower performance overhead.</p></li>
+</ul> </section>
+<section id="GUID-5391A3D1-A6CE-4C1A-8D42-B74A7E77E709"><title>ROM Demand Paging limitations</title><p>The following are
+known limitations for Demand Paging (using ROM demand  paging) compared to
+the other types of code paging: </p><ul>
+<li><p>If the executable has static dependencies, then it is best to place
+ these dependencies in ROFS. This is a limitation of ROFS and not ROM demand
+paging.</p></li>
+<li><p>This paging system can only be used with files that are stored using
+ the ROM filing system. This is because ROM images using the ROM filing system
+ are designed to be executed in place. </p></li>
+</ul> </section>
+</conbody><related-links>
+<link href="GUID-D6C2202C-778C-558A-97AA-649CD6DB5E87.dita"><linktext>ROFS File
+System</linktext></link>
+<link href="GUID-5A71755A-E67F-5007-8C55-5B8FA65B3C04.dita"><linktext>ROM File
+System</linktext></link>
+<link href="GUID-D666F9A0-8BFE-5067-BC76-C3AD73587195.dita"><linktext>Composite
+File System</linktext></link>
+<link href="GUID-903A9956-87E2-5191-87A3-6D40797EB820.dita"><linktext>Configuring
+and building a ROM</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0C3A4156-E5CF-55F9-91A0-A7961FDEE030.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-0C3A4156-E5CF-55F9-91A0-A7961FDEE030" xml:lang="en"><title>LCD Extension Architecture</title><shortdesc>This topic describes the architecture of the LCD Extension. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The LCD Extension (or video driver) is implemented as a standard
+kernel extension and is loaded by the kernel at boot time. </p>
+<p>The public interface to the LCD Extension is accessed through the
+User-Side Hardware Abstraction (HAL) interfaces <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-573C49D6-7763-37AE-B2B2-4C8FB1327E21"><apiname>HAL::Get()</apiname></xref> and <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-9454F1B2-D525-3D6D-A872-C6457CACD4FC"><apiname>HAL::Set()</apiname></xref>. The LCD Extension registers itself
+with the kernel as the handler for the <xref href="GUID-7F299BFC-D8A5-3A5A-B8DA-39BF42C99DC6.dita"><apiname>EHalGroupDisplay</apiname></xref> function group and implements the functions. </p>
+<p>From Symbian^3 there is a new graphics architecture called <xref href="GUID-D93978BE-11A3-5CE3-B110-1DEAA5AD566C.dita">ScreenPlay</xref>. When ScreenPlay is in use, the <xref href="GUID-4C166A49-31F7-5315-B797-F97DB52600BC.dita">Display Channel Driver</xref> can provide a logical device driver proxy between the Composition
+Implementation and the LCD Extension. However, the use of the Display
+Channel Driver is optional and implementers may decide not to use
+it. </p>
+<p>When ScreenPlay is not in use, the Graphics <xref href="GUID-9E7D563E-9FFB-5FA9-8944-9CBAC281FDD2.dita">Screen Driver component</xref> is a client of the LCD Extension. The Screen Driver is platform-specific
+and must be ported by the device creator. </p>
+<p>The Text Window Server also implements a version of the Screen
+Driver for a simple console user interface. </p>
+</conbody><related-links>
+<link href="GUID-D93978BE-11A3-5CE3-B110-1DEAA5AD566C.dita"><linktext>The
+ScreenPlay Graphics                 Architecture</linktext></link>
+<link href="GUID-F64E6551-670E-5E12-8103-DE504D3EC94F.dita"><linktext>The
+Non-ScreenPlay                 Graphics Architecture</linktext></link>
+<link href="GUID-4C166A49-31F7-5315-B797-F97DB52600BC.dita"><linktext>Display
+Channel Driver</linktext></link>
+<link href="GUID-9E7D563E-9FFB-5FA9-8944-9CBAC281FDD2.dita"><linktext>Screen
+Driver                 Component</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0C435514-EEC6-5660-BB5F-535790349632.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,127 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-0C435514-EEC6-5660-BB5F-535790349632" xml:lang="en"><title>Power Management</title><shortdesc>The kernel provides a framework for managing power within
+the system, and the management of the transition between power states. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The kernel-side framework manages the transition between power
+states on the device. A base port can implement a kernel extension
+to interface to the power management hardware that is provided on
+the phone. The framework also provides an interface for device drivers
+to use the power </p>
+<p>The user-side interface to the framework is provided by the Power
+class in the User Library. This allows applications can be notified
+about, and can react to, changes in power state, and indeed can initiate
+changes to power state. The <xref href="GUID-E09E4418-4DC3-56A3-BFBE-486C9C8D25C9.dita">Domain Manager</xref> component provides a way to manage the power needs and dependencies
+of applications. </p>
+<p>In Symbian platform, an initial port of the system does not require
+the existence of a power model. In this sense it is optional, and
+its absence will result in default behaviour provided by Symbian platform.
+However, this is not likely to result in optimal power usage, so the
+development of a power model based on the framework provided by Symbian
+platform will be required for commercial devices. </p>
+<p>The interfaces for power management on the kernel-side are shown
+in the following diagram: </p>
+<fig id="GUID-4020768D-7FDF-58EC-82A7-F98E259046D0">
+<image href="GUID-782E8D92-0431-50F5-95A0-5B231EBDF391_d0e25767_href.png" placement="inline"/>
+</fig>
+<ul>
+<li id="GUID-4E59C261-2025-5402-9EE1-EBC50BCD409F"><p>The power manager
+manages the transition between power states. </p> </li>
+<li id="GUID-B3CD4688-45D0-5F46-A968-2DDD76ABB9B7"><p>The power controller
+is a kernel extension that manages the device-specific power management
+hardware such as an on-chip power management controller, oscillators
+etc. The power controller kernel extension is provided in the base
+port. </p> </li>
+<li id="GUID-07CBC9E9-7A2E-5BB5-95F6-1ECF36B502ED"><p>Power handlers
+are device drivers that interface to the power manager. </p> </li>
+</ul>
+<p>The following sections describes these concepts in more detail. </p>
+<section id="GUID-330F07B2-BBDF-5675-B7D5-FF6B25DD03F4"><title>Power
+manager</title> <p>The power manager manages the transition between
+power states. It co-ordinates the change in the power state of peripherals
+and the CPU (hardware), and provides the necessary interactions with
+the device (peripheral) drivers and the power controller (software).
+It also manages interactions with the user-side model. </p> <p>The
+power manager is an instance of the <codeph>DPowerManager</codeph> class, an object that is private to Symbian platform. This object
+is created when the system is initialised, but is not installed as
+the power manager until the <xref href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita#GUID-0C435514-EEC6-5660-BB5F-535790349632/GUID-07F53484-4727-5338-9320-DF6A0BB440E4">power controller</xref> has been created and registered. Until the <codeph>DPowerManager</codeph> object is installed as the system's power
+manager, Symbian platform manages power using built-in default behaviour. </p> <p>The user-side uses the <xref href="GUID-15D25C07-CFD2-32CE-AD22-E17D512D8E87.dita"><apiname>Power</apiname></xref> class, a set
+of static functions, as an interface to the power manager. This allows
+the user side to request a transition to the <i>Standby</i> or <i>Off </i> state, and to request notification of wake-up events, i.e.
+events that will cause a transition back to the <i>Active</i> state. </p> <p>The power manager object is the anchor point for the power controller
+object and the power handler objects. </p> </section>
+<section id="GUID-07F53484-4727-5338-9320-DF6A0BB440E4"><title>Power
+controller</title> <p>The power controller manages the device-specific
+power management hardware such as an on-chip power management controller,
+oscillators etc. </p> <p>The power controller is an instance of a <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita"><apiname>DPowerController</apiname></xref> class. This is an abstract class that
+requires an implementation . A concrete implementation supports power
+management hardware that is Variant specific. Typically, the Variant
+creates a power controller object when the Variant is initialised,
+and then registers it with the power manager through a call to <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-F66D72D0-AA27-3BAF-8915-C6E8CC4E7CCF"><apiname>DPowerController::Register()</apiname></xref>. Registration puts a pointer
+to the <codeph>DPowerController</codeph> object into the Symbian platform
+internal <codeph>DPowerManager</codeph> object. </p> <p>The power
+controller is responsible for tracking wake-up events, notifying the
+power manager of such events through a call to <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-3524A807-F4A9-3DE4-918A-0C03BE0D1AEF"><apiname>DPowerController::WakeUpEvent()</apiname></xref>. </p> <fig id="GUID-7BBCE70B-381C-5E65-83CF-498B2C6D15DA">
+<image href="GUID-9D8C62FB-1E42-5B69-8ECC-2B68AD7C71A5_d0e25863_href.png" placement="inline"/>
+</fig> </section>
+<section id="GUID-DC5F1ECD-CCA3-59FF-A2F1-A3DBD76CD458"><title>Power
+handlers</title> <p>Device drivers interface to the power manager
+through the <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita"><apiname>DPowerHandler</apiname></xref> class. This is an abstract
+class that requires a concrete implementation by device (peripheral)
+drivers. </p> <p>How a <codeph>DPowerHandler</codeph> object fits
+into a driver's own object model is a matter of individual device
+driver design. However, after construction of this object, the driver
+is expected to register it with the power manager by calling <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-E8353DF6-B21B-383F-99AB-94B6B5139E47"><apiname>DPowerHandler::Add()</apiname></xref>, after which it will receive notification
+of changes to the power state. </p> <p>The power manager calls <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-578DB5FB-731D-36B2-A459-AAC7F250D726"><apiname>DPowerHandler::PowerDown()</apiname></xref> when it requests a power state
+transition to either the <i>Off</i> or the <i>Standby</i> state. The
+power manager calls <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-DDC564B4-BD12-30E9-B04A-DBA6CFAF8743"><apiname>DPowerHandler::PowerUp()</apiname></xref> when
+it requests a power state transition to the <i>Active</i> state. The
+driver must respond to a power transition notification after it has
+dealt with it by calling <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-BF62042B-FB7B-3D5B-8379-490FBA284A7A"><apiname>DPowerHandler::PowerUpDone()</apiname></xref> or <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-EBE8CFF8-50BD-3AC3-A4C8-47094DA5674D"><apiname>DPowerHandler::PowerDownDone()</apiname></xref> as appropriate. </p> <fig id="GUID-5A5E8846-DE8A-50FC-9D0E-8D8E88291835">
+<image href="GUID-1BB379B6-C0B5-5099-90A0-1BA39DC2C7DD_d0e25918_href.png" placement="inline"/>
+</fig> </section>
+<section id="GUID-8062EF29-9CE3-5414-9DE2-E494F48F0CFB"><title>Shared
+power sources</title> <note><p>See the <xref href="GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9.dita">Power Resource Manager</xref> documentation for more information. </p></note> <p>The set of power sources on a device, how they are connected to peripherals,
+and their power states are totally dependent on the specific device.
+This means that Symbian platform cannot provide a comprehensive API
+for handling such sources. </p> <p>However, Symbian platform does
+provide an interface, <xref href="GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A.dita"><apiname>MPowerInput</apiname></xref>, through which
+drivers register their use of a power source and their release of
+that power source. Symbian platform makes the following recommendations: </p> <ul>
+<li id="GUID-D1B32CB8-E3EF-532C-9771-D5B9CFE3C5DD"><p>Each (shared)
+power source is represented by a separate object. </p> </li>
+<li id="GUID-AA47D3A2-8F3A-5D7D-AB41-8658FF5C9260"><p>The class, or
+class hierarchy, that represents the power source should implement
+the <codeph>MPowerInput</codeph> interface so that device (peripheral)
+drivers can register their use or their release of that power source. </p> </li>
+<li id="GUID-017BC38F-1207-52B8-8B35-D38F66849FC6"><p>Define a custom
+interface with the power controller. It is likely that the Variant
+will be responsible for providing the implementation for the power
+inputs, and for providing this custom interface. </p> </li>
+</ul> <p>Drivers that need power from a specific power source call <xref href="GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A.dita#GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A/GUID-2BCA5312-43D9-3763-9636-3B2EB046D2C1"><apiname>MPowerInput::Use()</apiname></xref> on the object that represents that power
+source. To release dependence on that power source, the driver calls <xref href="GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A.dita#GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A/GUID-606ECD77-A5F7-3408-9B63-C68C0A7B73C6"><apiname>MPowerInput::Release()</apiname></xref>. </p> <p>To represent a shared power
+source, a suggested implementation of <codeph>MPowerInput</codeph> might be to associate a counting value with the power source object.
+A call to <codeph>Use()</codeph> would increment the counter, while
+a call to <codeph>Release()</codeph> would decrement it. On construction
+of the object, the initial value might be 0, indicating that no peripherals
+require power from this source. A value of 1 or higher would indicate
+that one or more peripherals require power from this source. The implementation
+would, therefore, cause this power source to be kept on while at least
+one peripheral needs it; the power source would only be switched off
+when no peripherals need power from it. </p> </section>
+</conbody><related-links>
+<link href="GUID-E09E4418-4DC3-56A3-BFBE-486C9C8D25C9.dita"><linktext>Domain
+Manager</linktext></link>
+<link href="GUID-3773A78D-F491-52EB-AA1D-201636497F28.dita"><linktext>Power
+Management Tutorials</linktext></link>
+<link href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita"><linktext>Power
+Resource Manager (PRM)</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0C80F447-B82E-5586-9B02-4BC0D365FFD6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept xml:lang="en" id="GUID-0C80F447-B82E-5586-9B02-4BC0D365FFD6"><title>Write Data to USB using Shared Chunks</title><shortdesc>This tutorial describes how to write shared chunk data to a USB connection. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody><p> </p> <section><title>Write data</title> <p>To write data from the device to the host (<codeph>In</codeph>), read some data (e.g. from a media card on the device) to a shared chunk and make a write request to the driver. Use <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita"><apiname>RDevUsbcScClient::WriteData()</apiname></xref> to send data placed inside a shared chunk to the USB hardware. </p> <codeblock id="GUID-CBF0FC3A-4C22-50FD-A87E-F0F9C0EBAC6A" xml:space="preserve">TUsbcScChunkHeader chunkHeader(gChunk);
+TUsbcScHdrEndpointRecord* epInfo;
+TRequestStatus status;
+
+TUsbcScBufferRecord* buff = chunkHeader.GetBuffer(0, 1, epInfo);
+TInt inBuffNum = epInfo-&gt;iBufferNo;
+TUint bufferOffset = buff-&gt;Offset();
+TUint length = buff-&gt;Size();
+
+gPort.WriteData(inBuffNum, bufferOffset, length, 1, status);</codeblock> <p>The function <codeph>WriteData()</codeph> does not take an endpoint as a parameter. To send data to a particular endpoint the data must be put in the correct buffer. Find the buffer number in the chunk header with the endpoint number and the current alternate setting. See <xref href="GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita#GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834/GUID-9D773343-8597-5A85-9511-32E176D06E8F">Setting the interface</xref> to see how alternate settings are created. </p> <p>When sending buffers using this function, if a second buffer is ready to send before the first has finished transmitting then the second buffer can be sent to the LDD. The LDD will start sending the data in the second buffer when the first has finished. This reduces the delay between finishing one and transmitting the next. To do this the <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita"><apiname>TRequestStatus</apiname></xref> objects must be kept track of as only one of these can be used with each request. </p> <p> <b>Note</b>: an offset is provided that allows a buffer to be split into parts. This allows you to fill one half while sending the other. </p> <p>When the request has completed, if there is no more data to be sent then close the channel and unload the driver. </p> </section> <section><p>When you have finished reading and writing <xref href="GUID-BE73CFE6-D48D-5B92-AF49-E2D967ADF0EC.dita">Close and Unload the Driver</xref>. </p> </section> </conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0C8318B1-71D7-5384-97EB-85CBBC3E6B84.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,187 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-0C8318B1-71D7-5384-97EB-85CBBC3E6B84" xml:lang="en"><title>IIC SHAI Implementation Layer: Master Channel</title><shortdesc>This document explains how to implement the a master channel
+in the SHAI implementation layer of IIC. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-38D02829-2B52-4E2E-ABD0-D88D5F1B5FBC"><title>Purpose</title> <p>This document explains how to implement a master channel on the
+SHAI implementation layer of IIC. </p> <p><b>Intended Audience</b> </p> <p>Base porting engineers. </p> <p><b>Introduction</b> </p> <p>IIC buses (a term used in this document to represent serial inter-chip
+buses that IIC can operate on) are a class of bus used to transmit
+non time-critical data between components of a hardware system. </p> </section>
+<section id="GUID-69ED3F3A-8D85-4940-B9C7-691081EC5E93"><title>Implementing
+a master channel</title> <p>You should read and understand the template
+port at<filepath> \os\kernelhwsrv\bsptemplate\asspandvariant\template_assp\iic\iic_master</filepath> as this will provide most of the information you need to implement
+the master channel.</p><p>To implement the SHAI implementation layer
+of an IIC channel as master you must write a class extending <xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita"><apiname>DIicBusChannelMaster</apiname></xref>. You must implement certain pure virtual
+functions of the parent class in the subclass. Those functions and
+any other functions which you write in the subclass are called the
+SHAI implementation layer. The functions inherited from the parent
+class are called the Platform Independent Layer (PIL). </p> <p>The
+four functions you must implement are: </p> <ul>
+<li id="GUID-B49F1DAB-AB30-5C95-BFAF-93D8DC779371"><p> <xref href="GUID-11C2715E-409F-3F24-AE8F-89CF5A893B80.dita"><apiname>DoCreate()</apiname></xref>  </p> </li>
+<li id="GUID-A402D653-D8D5-5031-A647-ED02B95B4857"><p> <xref href="GUID-9D910016-5611-30DD-A139-EE46705A4912.dita"><apiname>DoRequest()</apiname></xref>  </p> </li>
+<li id="GUID-AF3B74BE-9193-51CD-B7E4-E721F2CCDC98"><p> <xref href="GUID-AD480427-A00E-3BB3-AD62-1B91A86B37A2.dita"><apiname>HandleSlaveTimeout()</apiname></xref>  </p> </li>
+<li id="GUID-242CB2B6-0DB0-53A0-B951-1FACA037DEE0"><p> <xref href="GUID-A5E66E7E-E03B-3249-A5E5-F0E5DFC3B3EB.dita"><apiname>CheckHdr()</apiname></xref>  </p> </li>
+</ul> <p>You must also provide the following functionality: </p> <ul>
+<li id="GUID-7C3DDA6A-1976-518C-90D8-27BD1D2B9C23"><p>validation of
+input, </p> </li>
+<li id="GUID-6E61EE3F-D8A1-58B4-A129-61A42E710150"><p>interrupt service
+routines, and </p> </li>
+<li id="GUID-8018060E-C5D6-5C9C-BA63-05B9DAE47823"><p>reporting on
+transmission status using the callback function <xref href="GUID-853C87F1-0E44-3B1E-A97E-6461F1188B3A.dita"><apiname>CompleteRequest()</apiname></xref> with the relevant error code. </p> </li>
+</ul> <p>Your implementation of the SHAI implementation layer will
+need to call functions of the PIL. You are restricted to using a certain
+subset of these. </p> <p><b>Implementing DoCreate()</b> </p> <p> <xref href="GUID-11C2715E-409F-3F24-AE8F-89CF5A893B80.dita"><apiname>DoCreate()</apiname></xref> is the second phase constructor of your class.
+Implement it to perform functionality including: </p> <ul>
+<li id="GUID-47401DEC-3072-541A-BE75-034E1ABFE40A"><p>call the PIL
+function <xref href="GUID-741A0FD7-5A5A-31B0-BB5F-763B5795009C.dita"><apiname>Init()</apiname></xref>, </p> </li>
+<li id="GUID-C41E4C4B-10CE-5393-9326-83110FEBB244"><p>create the DFC
+queue for the driver and assign it to the driver by calling <xref href="GUID-391B9E13-9A66-3DD4-872F-439C46022448.dita"><apiname>SetDfcQueue()</apiname></xref>, </p> </li>
+<li id="GUID-D2E8E3FB-EF15-5257-BDD8-BA72D80EA129"><p>initialize the
+hardware, setting up interrupts, and </p> </li>
+<li id="GUID-851D395C-330B-5492-AD1A-A54A484ED63D"><p>initialize the
+other data structures representing the channel. </p> </li>
+</ul> <p><b>Implementing DoRequest()</b> </p> <p> <xref href="GUID-9D910016-5611-30DD-A139-EE46705A4912.dita"><apiname>DoRequest()</apiname></xref> is the gateway function to the SHAI implementation layer. It configures
+the interface using the supplied configuration and processes transactions.
+It takes one argument <xref href="GUID-2803075B-3B59-3DF1-BB22-A6DF4DB6AA58.dita"><apiname>aTransaction</apiname></xref>, a pointer to
+a <xref href="GUID-1A326AA6-7C9F-3E61-9B55-34FCE771EB96.dita"><apiname>TIicBusTransaction</apiname></xref> object created by the client:
+you use the protected data functions of the PIL (listed below) to
+extract the data needed to perform the associated transfers. Implement <xref href="GUID-9D910016-5611-30DD-A139-EE46705A4912.dita"><apiname>DoRequest()</apiname></xref> with functionality including the following: </p> <ul>
+<li id="GUID-A7E758C2-89C0-5CCE-A5D2-1F7019CDF890"><p>Extract the
+transaction parameters, that is the transaction header and transfers
+(<xref href="GUID-73FDF24F-0B9D-3A97-B9BB-E021257E77F1.dita"><apiname>TIicBusTransfer</apiname></xref>), </p> </li>
+<li id="GUID-EF3B0B5A-E03B-58FF-8E8B-90EB6C7F5CFF"><p>configure the
+interface with the configuration supplied in the transaction header, </p> </li>
+<li id="GUID-A38796B7-A3F3-50D0-86DC-CCB4D3C69658"><p>set up the hardware
+to start the first transfer, that is </p> <ul>
+<li id="GUID-94CAE80B-2221-5664-85FB-B06666851DDB"><p>extract the
+first transfer for one direction by calling <xref href="GUID-2ADBFCF5-109F-33BA-97D1-44DA7D8604F2.dita"><apiname>GetTransHalfDuplexTransfer()</apiname></xref>, </p> </li>
+<li id="GUID-4613E372-DA10-5105-816F-1890A4314CDD"><p>and if the transfer
+is full duplex extract the first transfer for the second direction
+by calling <xref href="GUID-0C7ACFD8-279D-385D-8BF4-B870ABD185CE.dita"><apiname>GetTransFullDuplexTransferPtr()</apiname></xref>, </p> </li>
+</ul> <p>in each case filling hardware FIFO buffers, enabling interrupts
+and so on, </p> </li>
+<li id="GUID-B3CF4DEE-DAA2-5ADD-BA08-9861C457AF35"><p>call the PIL
+function <xref href="GUID-967E4167-498F-3714-8CFB-8273968C551B.dita"><apiname>StartSlaveTimeoutTimer()</apiname></xref>, </p> </li>
+<li id="GUID-48D2A463-EB97-5604-8106-9980AAE0FFE6"><p>instruct the
+hardware to start transmission, and </p> </li>
+<li id="GUID-45785C69-E8FB-5548-B8FF-3EA3EE45447F"><p>return either
+an error code or <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref>. </p> </li>
+</ul> <p>The effect of calling <codeph>DoRequest()</codeph> should
+be to start the sequence of transfers comprising the transaction.
+Typically, at the end of each transfer a hardware interrupt and associated
+DFC callback occurs. If the PIL function <codeph>StartSlaveTimeout()</codeph> was called to monitor the duration of an individual transfer, the
+PIL function <codeph>CancelTimeout()</codeph> should be called to
+cancel the timer. If the transfer was successful and a call to get
+the next transfers succeeds, the next transfer is set up. This continues
+until either all the transfers have been processed, or there is an
+error; after that, the PIL method <codeph>DIicBusChannelMaster::CompleteRequest()</codeph> is called to indicate the result.  </p> <p><b>Implementing HandleSlaveTimeout()</b> </p> <p>If the timer started by the PIL method <codeph>StartSlaveTimeoutTimer()</codeph> expires then the slave peripheral has not responded within the expected
+time, and in such case some SHAI implementation layer-specific recovery
+will be required; this is to be provided by the implementation of
+ <codeph>HandleSlaveTimeout()</codeph>. Implement it with functionality
+including: </p> <ul>
+<li id="GUID-37E4C87F-4980-5651-BD13-2AD8622A8F52"><p>stop the transmission, </p> </li>
+<li id="GUID-667655D7-76B0-5F0A-BFA5-F74B964AF982"><p>disable the
+hardware, and </p> </li>
+<li id="GUID-DCF7198C-BFB2-58EF-9014-C9BEB31F57E4"><p>call the PIL
+function <codeph>CompleteRequest()</codeph> with the <xref href="GUID-BAC2386E-8168-3CDB-9F9F-180319EF6920.dita"><apiname>KErrTimedOut</apiname></xref> error code. </p> </li>
+</ul> <p><b>Implementing CheckHdr()</b> </p> <p>Implement <xref href="GUID-B44147A7-D880-3510-A3F1-D73E9B5F8230.dita"><apiname>CheckHdr().</apiname></xref> This is the function which is called in the
+context of the client thread when the client calls <xref href="GUID-D0F8DF19-790F-3FE5-89E4-057C240AD3FE.dita"><apiname>QueueTransaction()</apiname></xref>. Implement it with the following functionality: </p> <ul>
+<li id="GUID-42548EF0-4A41-5095-8541-CDC8BF6032D4"><p>check if the
+header of the transaction is valid. </p> </li>
+</ul> <p><b>Using the Platform Independent Layer</b> </p> <p>You can
+only use certain functions of the PIL. Most are used to access private
+data of the parent class. Others provide functionality which is generic
+to IIC buses. These are: </p> <ul>
+<li id="GUID-1034BC57-BC77-5D7F-9385-3ACCC0EFF6DE"><p> <xref href="GUID-995FA70D-F28C-3AA6-BB6A-528210F3716E.dita"><apiname>DIicBusChannelMaster()</apiname></xref>, the constructor of the superclass <xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita"><apiname>DIicBusChannelMaster</apiname></xref> with arguments representing the bus type and the duplex settings. </p> </li>
+<li id="GUID-27AE6A8A-3C0E-5DC3-917B-0F23D3D6E7C2"><p> <xref href="GUID-741A0FD7-5A5A-31B0-BB5F-763B5795009C.dita"><apiname>Init()</apiname></xref>. Initializes <xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita"><apiname>DIicBusChannelMaster</apiname></xref>. </p> </li>
+<li><p>•<codeph>SetDfcQ()</codeph>. Sets the driver's DFC queue to
+be used by DFCs in the PIL. </p></li>
+<li id="GUID-B90804B6-0A44-5764-B6AD-62F0A0E0C8C5"><p> <xref href="GUID-30953225-638A-3627-8183-544E127FE72C.dita"><apiname>StartSlaveTimeOutTimer()</apiname></xref>. Starts a timer which causes the <xref href="GUID-AD480427-A00E-3BB3-AD62-1B91A86B37A2.dita"><apiname>HandleSlaveTimeout()</apiname></xref> callback to run if the transaction (or transfer, SHAI implementation
+layer decides) is not completed in the specified time. </p> </li>
+<li id="GUID-4AC4BD6D-2123-5151-B744-8785A4D4E364"><p> <xref href="GUID-03DA2EEC-8E8C-30FC-9956-E721184FE43E.dita"><apiname>CancelTimeOut();</apiname></xref>. Cancels the timeout timer which monitors the transaction time. </p> </li>
+<li id="GUID-B61C0B7E-43EF-55E6-9BA6-9791F3858D76"><p> <xref href="GUID-853C87F1-0E44-3B1E-A97E-6461F1188B3A.dita"><apiname>CompleteRequest()</apiname></xref>. Called to signal the PIL about completed transactions, transmission
+errors and timeouts. </p> </li>
+</ul> <p>The functions accessing private members of <xref href="GUID-1A326AA6-7C9F-3E61-9B55-34FCE771EB96.dita"><apiname>TIicBusTransaction</apiname></xref> are: </p> <table id="GUID-11F852E6-4180-5F2D-BC57-5F45946C9F71">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<thead>
+<row>
+<entry>Function</entry>
+<entry>Returns</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p> <codeph>GetTransactionHeader() </codeph> </p> </entry>
+<entry><p>A pointer to the configuration header. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>GetTransHalfDuplexTfrPtr()</codeph>  </p> </entry>
+<entry><p>A pointer to the head of the list of half duplex transfers. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>GetTransFullDuplexTfrPtr()</codeph>  </p> </entry>
+<entry><p>A pointer to the head of the list of full duplex transfers. </p> </entry>
+</row>
+<row>
+<entry><p><codeph>GetTransCallback()</codeph></p></entry>
+<entry><p>A pointer to the callback function</p></entry>
+</row>
+<row>
+<entry><p><codeph>GetTransFlags()</codeph></p></entry>
+<entry><p>a pointer to the transaction flags</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>The functions accessing private members of <xref href="GUID-73FDF24F-0B9D-3A97-B9BB-E021257E77F1.dita"><apiname>TIicBusTransfer</apiname></xref> are: </p> <table id="GUID-6B66FB92-634F-5B57-8AEE-7D90606BF26F">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<thead>
+<row>
+<entry>Function</entry>
+<entry>Returns</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-779C14B5-7D9D-3582-BE22-21CB668FADE6.dita"><apiname>GetTferType()</apiname></xref>  </p> </entry>
+<entry><p>The transfer type, EMasterRead or <xref href="GUID-5E76AC81-4074-337D-86E4-B3FC14062B51.dita"><apiname>EMasterWrite</apiname></xref>, defined in the enumeration <xref href="GUID-5FBF20DE-E998-3281-A85E-EF56A1FDDFA3.dita"><apiname>TReqType</apiname></xref>. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-D55D721A-4F5C-3B94-9351-971269E94493.dita"><apiname>GetTferBufGranularity()</apiname></xref>  </p> </entry>
+<entry><p>The size of the buffer item in bits, typically 8 or 16. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-8A2E8454-957C-3F24-AF23-CF375C30EB05.dita"><apiname>GetTferBuffer()</apiname></xref>  </p> </entry>
+<entry><p>A pointer to the buffer where the data is stored. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-FD0F5059-1B2B-3477-907C-9BC50D6CF6AE.dita"><apiname>GetTferNextTfer()</apiname></xref>  </p> </entry>
+<entry><p>A pointer to the next transfer in the transaction. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table><note>In addition to the above functions, there are additional
+functions for accessing transactions with preambles, extending transactions
+(multitransactions) and extended transactions with preamble. Refer
+to the header file for details on these functions.</note> </section>
+</conbody><related-links>
+<link href="GUID-052F58B7-117B-5EDD-A3D5-CB0DE6A4E239.dita"><linktext>IIC
+SHAI Implementation Layer:  Generic Considerations</linktext></link>
+<link href="GUID-C9644081-004E-5DA0-8133-A32EEA91EF5E.dita"><linktext>IIC
+SHAI implementation Layer: Slave Channel</linktext></link>
+<link href="GUID-9986DCC6-EE73-59FB-BDAC-9B09DC64FBCE.dita"><linktext>Client
+of Master Channel Tutorial</linktext></link>
+<link href="GUID-F461CBB3-F8D1-5961-AD51-5741143A1CB1.dita"><linktext>Client
+of Slave Channel Tutorial</linktext></link>
+<link href="GUID-B2F86F54-EF50-56DB-ADF7-15325AC9324D.dita"><linktext>IIC
+Concepts</linktext></link>
+<link href="GUID-3A30DA16-ECA8-5639-A9DC-6BE2AD55420B.dita"><linktext>I2C
+Technology Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0C84FD76-87B2-4AD1-B23A-2C5C8668BC4C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-0C84FD76-87B2-4AD1-B23A-2C5C8668BC4C" xml:lang="en"><title>Base Porting Guide</title><shortdesc>The Base Porting Guide provides information that will help
+you to port versions of the Symbian platform base to
+new hardware. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0C8C41EC-A8ED-5916-B944-DDDF20FADAF4.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-0C8C41EC-A8ED-5916-B944-DDDF20FADAF4" xml:lang="en"><title>Port
+Implementation Tutorial</title><shortdesc>Steps required to implement a port of the Serial Port Driver. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The actions needed in porting a Serial Port Driver are based on
+the experience of porting the template reference board port. Note
+however that the code shown here is idealized to show the basic principles;
+it is not an exact copy of the template port code. </p>
+<p>In the template reference board port, the <filepath>.mmp</filepath> for the physical device driver is <filepath>...\template_variant\datxtemplate.mmp</filepath>. This is one of the <codeph>PRJ_MMPFILES</codeph> referenced
+in the variant's <filepath>bld.inf</filepath> in the <filepath>...\template_variant\...</filepath> directory, and means that the Serial Port Driver is built as part
+of the variant. The source for the driver is contained entirely within <filepath>...\template_variant\specific\uart.cpp</filepath>. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0D2F811C-81C3-526F-8EA4-98E50261BF4B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,282 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-0D2F811C-81C3-526F-8EA4-98E50261BF4B" xml:lang="en"><title>DMA
+Framework Technology</title><shortdesc>Describes the classes that the DMA Framework provides to transfer
+data using DMA. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The following diagram shows the general relationship between the various
+classes and structs that form the DMA Framework. The individual items are
+described in more detail below. </p>
+<fig id="GUID-C6B032F0-7E05-5E29-8024-B713C42A2434">
+<image href="GUID-D43AB2F5-32AE-540C-80D8-DE8B2072F1E6_d0e10612_href.png" placement="inline"/>
+</fig>
+<section id="GUID-D9855D5F-3D4D-5A65-A1BB-B7CB94E60316"><title>The DMA Software
+Controller</title> <p>This is the <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> object. It has
+two purposes: </p> <ul>
+<li id="GUID-E4C8A5C5-192B-5E3E-A2F1-D884BF7FE641"><p>It defines the main
+interface between the platform independent and platform specific layers. </p> </li>
+<li id="GUID-98888CE1-5AA6-5D91-A5C5-E60F1200465A"><p>it is a container for
+channels, descriptors and descriptor headers </p> </li>
+</ul> </section>
+<section id="GUID-37DF82BE-5F8E-5497-90E8-C48F44C2A7F1"><title>The Channel
+Manager</title> <p>The channel manager is a <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita"><apiname>DmaChannelMgr</apiname></xref> object. </p> <p> <codeph> DmaChannelMgr</codeph> is
+a static class defined by the platform independent layer but implemented in
+the platform specific layer. The functionality is used by the platform independent
+layer. It contains: </p> <ul>
+<li id="GUID-B5626DA4-1465-5469-BE3D-36F31996C75A"><p>a function to open a
+DMA channel: <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita#GUID-176B8E0D-0422-341B-A134-7C85432E1303/GUID-934F46B3-1DF9-3870-87EE-A8E2DEF82810"><apiname>DmaChannelMgr::Open()</apiname></xref>  </p> </li>
+<li id="GUID-67C7DE2F-196E-5919-BA80-99898DF6837D"><p>a function that is called
+when a channel is closed: <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita#GUID-176B8E0D-0422-341B-A134-7C85432E1303/GUID-909D795A-7303-3A76-9C8E-3B07A97DD716"><apiname>DmaChannelMgr::Close()</apiname></xref>  </p> </li>
+<li id="GUID-F044E05A-A307-51B0-BDD5-8A29A950BE5F"><p>a function that can
+be used to extend the framework with platform specific functionality on a
+channel independent basis: <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita#GUID-176B8E0D-0422-341B-A134-7C85432E1303/GUID-C733B302-4269-3391-8ADE-617CFF198B56"><apiname>DmaChannelMgr::StaticExtension()</apiname></xref>  </p> </li>
+</ul> </section>
+<section id="GUID-34B8E965-9C5C-533E-BFE6-EB9B486A81BB"><title>Descriptors</title> <p>DMA
+controllers operating in scatter/gather mode are configured via a linked list
+of small data structures describing the data to be transferred. These data
+structures are called descriptors. (Note that the use of the term descriptor
+in the context of DMA should not be confused with the same term widely used
+in Symbian platform to refer to the family of <xref href="GUID-52D07F46-2162-380C-A775-C3BB335C42F5.dita"><apiname>TDesC</apiname></xref> derived
+classes). </p> <p>The Symbian platform DMA Framework always uses descriptor
+data structures to store transfer-configuration-information, even if the underlying
+DMA controller does not support scatter/gather mode. </p> <p>The following
+example illustrates the idea: assume that a device driver needs to transfer
+two disjoint blocks of memory, A and B, into another block C. Block A starts
+at address 1000 and is 300 bytes long. Block B starts at address 2000 and
+is 700 bytes long. The destination buffer C starts at address 5000 and is
+1000 bytes long. Assume that the DMA descriptors are allocated in a pool starting
+at address 600. The following diagram shows the scatter/gather list that the
+device driver might create: </p> <fig id="GUID-966DC875-FA9E-59E5-A1CA-842F4A82592D">
+<image href="GUID-EA0C5715-7CE8-5415-A915-D5701E3C957A_d0e10709_href.png" placement="inline"/>
+</fig> <p>If the DMA controller supports the scatter/gather arrangement, then
+the framework uses a structure that will be specific to the hardware. This
+structure is defined in the platform specific layer. </p> <p>If the DMA controller
+does not support scatter/gather, then the framework uses the generic structure <xref href="GUID-D7934AD9-38F6-325A-A734-F867D886D7C2.dita"><apiname>SDmaPseudoDes</apiname></xref> containing
+the following information: </p> <ul>
+<li id="GUID-D5EA7DC2-FC49-5FF3-95FE-6E5426D25BFF"><p>a set of generic flags
+that characterise the transfer. For example, is the source of the data memory
+or a peripheral; is the destination memory or peripheral; what addressing
+mode is to be used? </p> </li>
+<li id="GUID-4D54D3E6-0252-5F15-9966-E7F09A10020E"><p>the source and destination
+location. This is in the form of the base virtual address for a memory buffer,
+and a 32-bit value (or cookie) for peripherals. The meaning of the 32-bit
+value is interpreted by the platform specific layer. </p> </li>
+<li id="GUID-416CB113-5973-50AD-9FF3-F3AF78B47D0C"><p>The number of bytes
+to be transferred. </p> </li>
+<li id="GUID-D76CE2CE-5005-5C2F-B17D-F882D6BD7EB8"><p>A word that only has
+meaning for the platform specific layer, and passed by the client at request
+fragmentation time. </p> </li>
+</ul> </section>
+<section id="GUID-BC1C248D-170D-51AE-B2E5-61FFEC779D61"><title>Descriptor
+headers</title> <p>These are objects of type <xref href="GUID-710B3501-FF22-307D-AC88-D142E9A07CB8.dita"><apiname>SDmaDesHdr</apiname></xref>. </p> <p>A
+descriptor header allows additional information about a descriptor to be stored.
+The header is a separate object from the descriptor because it is difficult
+to embed additional data in a structure whose layout may be hardware-imposed. </p> <p>Descriptors
+and descriptor headers are stored in two parallel arrays allocated at boot-time,
+and each descriptor is always associated with the header of same index, so
+that there is always a one-to-one relationship between the header and the
+descriptor. </p> <fig id="GUID-A635E3EA-883C-5857-8690-E0AE6F43CAC4">
+<image href="GUID-99F7E70F-2733-57B2-94F5-A0C0FF9219FE_d0e10765_href.png" placement="inline"/>
+</fig> <p>In the current design, the only information in the descriptor header
+is a pointer, <codeph>SDmaDesHdr::iNext</codeph>, that is used to chain headers
+together on various lists. So, although the pool of headers is allocated as
+an array, they are almost always accessed by following the chain of pointers
+linking one header to the next. </p> <p>Descriptors are <i>always</i> accessed
+through their associated header. </p> <p>The platform independent layer never
+directly accesses hardware-specific descriptors. It just passes descriptor
+headers to the platform specific layer. However, the platform independent
+layer does directly manipulate the generic descriptors, <xref href="GUID-D7934AD9-38F6-325A-A734-F867D886D7C2.dita"><apiname>SDmaPseudoDes</apiname></xref>. </p> </section>
+<section id="GUID-F4685621-1FAA-544C-B4C0-B4DD566B856F"><title>Transfer Requests</title> <p>A
+transfer request is the way in which a device driver sets up and initiates
+a DMA transfer, and is represented by a <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita"><apiname>DDmaRequest</apiname></xref> object. </p> <p>A
+transfer request has a number of characteristics: </p> <ul>
+<li id="GUID-D5B73919-B6C8-54F9-8C1E-87467E32EAA0"><p>it is always associated
+with exactly one channel. </p> </li>
+<li id="GUID-FE3326FA-B0CF-50A2-BD4D-72F868226EFB"><p>it stores a client-provided
+callback function, which is invoked when the whole request completes, whether
+successfully or not. </p> </li>
+<li id="GUID-627B7D15-0119-5D72-A517-84832D90C3D1"><p>it can be in one of
+four states: </p> <ul>
+<li id="GUID-1D600F30-F06C-58FB-B258-8167164FE1FC"><p>not configured </p> </li>
+<li id="GUID-194A4B9A-12E6-50B6-816A-73717CD100F9"><p>idle </p> </li>
+<li id="GUID-0B7A0249-9F5D-5D5D-AB3C-4DDE8AFC58E6"><p>being transferred </p> </li>
+<li id="GUID-AF57DDF1-406D-55D4-A001-F62921165189"><p>pending; this state
+only occurs in streaming mode. </p> </li>
+</ul> </li>
+</ul> <p>Internally, a transfer request is represented as a singly linked
+list of descriptor headers. Each header in the list is associated with a descriptor
+that specifies how to transfer one fragment of the whole request. Transfer
+requests have pointers to the first and last headers in the list. </p> <p>When
+the request is idle, the header list ends with a NULL pointer. This is not
+always true when the request is queued (i.e. when the request is being transferred
+or is still pending). The following diagram shows an idle request with three
+fragments. </p> <fig id="GUID-0A5594BD-05E4-5A97-A3F7-459E3F8638A2">
+<image href="GUID-CF252B09-335E-5831-94A6-0B16B64C5030_d0e10851_href.png" placement="inline"/>
+</fig> <p>Splitting a request into fragments is useful because: </p> <ul>
+<li id="GUID-BEA0F4C5-4308-54E9-82AB-91570ACC9ADC"><p>it insulates device
+drivers from the maximum transfer size supported by the underlying DMA controller. </p> </li>
+<li id="GUID-A768A76B-DD9E-5A25-92D3-23A69299C096"><p>the source and destination
+DMA buffers may not be physically contiguous and thus require fragmenting. </p> </li>
+</ul> <p>Both of these situations can be handled by using the generic fragmentation
+algorithm <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-B14B0478-80D6-3F5E-88B6-1676411D9CF2"><apiname>DDmaRequest::Fragment()</apiname></xref>. </p> <p>Some device
+drivers may have to create custom descriptors lists. For example, the USB
+section of the PXA250 manual describes how to build custom lists where a descriptor
+containing data transfer information is followed by another one poking an
+I/O port to issue a command to the USB controller. </p> <p>To cover that case, <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita"><apiname>DDmaRequest</apiname></xref> provides
+the <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-AAB7C209-7D30-3282-B084-D80E12BB5152"><apiname>DDmaRequest::ExpandDesList()</apiname></xref> member function to allocate
+a list of headers associated with blank descriptors whose content is then
+set by device drivers. Blank descriptors thus created can be accessed in the
+following way (this example was taken and simplified from the PXA250 USB controller
+driver): </p> <codeblock id="GUID-EFA935A1-0D7E-5153-9071-2D0C58E8E920" xml:space="preserve">TDmaChannel* channel;
+TDmaChannel::SCreateInfo info;
+info.x = y;
+if (TDmaChannel::Open(info, channel) != KErrNone)
+    ... return;
+DDmaRequest* req = new DDmaRequest(*channel);
+if (!req)
+    ... return;
+const TDmac* dmac = req-&gt;iChannel.Controller();
+if (req-&gt;ExpandDesList(2) != KErrNone)
+    ... return;
+TDmaDesc* desc1 = static_cast&lt;TDmaDesc*&gt;(dmac-&gt;HdrToHwDes(*req-&gt;iFirstHdr));
+TDmaDesc* desc2 = static_cast&lt;TDmaDesc*&gt;(dmac-&gt;HdrToHwDes(*req-&gt;iFirstHdr-&gt;iNext));
+desc1-&gt;iSrcAddr  = ...;
+desc1-&gt;iDestAddr = ...;
+desc1-&gt;iDescAddr = ...;
+desc1-&gt;iCmd      = ...;
+desc2...
+...
+</codeblock> </section>
+<section id="GUID-4BF7605E-55D4-5B3A-BCD7-1F976765D738"><title>Channels</title> <p>A
+channel is a <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref> object, and there is one of these
+for each hardware DMA channel. </p> <p>A channel can be in one of 4 states: </p> <ul>
+<li id="GUID-09581FA5-D01A-502A-9841-52ABDF0BB16E"><p>closed </p> </li>
+<li id="GUID-D03F51BA-1493-5B23-B029-4FF5FCC4DE5E"><p>open and idle </p> </li>
+<li id="GUID-606FA290-FB8D-5CBE-88C2-BCD03062EE25"><p>open and transferring
+data </p> </li>
+<li id="GUID-2E845C88-292D-54B9-9F99-AAC3775768E4"><p>suspended following
+an error. </p> </li>
+</ul> <p>On opening a channel, the client device driver specifies: </p> <ul>
+<li id="GUID-6F373D39-4078-5C76-BF5E-69294297D8CE"><p>A 32-bit value (cookie)
+that is used by the platform specific layer to select which channel is to
+be opened </p> </li>
+<li id="GUID-71E4D026-4BA5-592B-BB3E-5F5354640E50"><p>The number of descriptors
+that must be reserved for this channel. </p> </li>
+<li id="GUID-4C34A82A-AF7E-5683-986B-A65EA6C8F5B2"><p>A DFC to be used by
+the framework to service DMA interrupts. </p> </li>
+</ul> <p>A channel maintains a queue of transfer requests. If the channel
+is being used for one-shot transfers, the queue will always contain an idle
+or a transferring request. In streaming mode, the queue may contain several
+requests, the first one being transferred and the remaining ones pending.
+When a request is completely transferred, it is removed from the queue. The
+first request is always the one being transferred. </p> <p>A transferring
+channel has a pointer to the header associated with the descriptor being transferred.
+The headers of all queued requests are linked together on one linked list. </p> <p>The
+following diagram shows a DMA channel with a three-fragment request being
+transferred and a two-fragment one pending. The fragment currently being transferred
+is the second one of the first request. </p> <fig id="GUID-36E11A64-4626-53F9-925C-3DC323DEA895">
+<image href="GUID-86C21C9B-9F08-579F-84E9-CBE46F756373_d0e10964_href.png" placement="inline"/>
+</fig> <p>The <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref> class contains the code and data
+that is common to all of the channel types. The code and data for the specific
+channel types: single buffer, double buffer, and scatter/gather channels,
+are implemented in the derived classes: <xref href="GUID-A8B4AD1B-770C-363E-A0DE-C78A9786CBDC.dita"><apiname>TDmaSbChannel</apiname></xref>, <xref href="GUID-FD76AF08-6250-3054-8A06-16343E385B23.dita"><apiname>TDmaDbChannel</apiname></xref>,
+and <xref href="GUID-2D4CFBB1-8D64-3CF5-B6F0-B24D16D5BAD4.dita"><apiname>TDmaSgChannel</apiname></xref> respectively. </p> <p><b>TDmaSbChannel
+State Machine</b> </p> <p>For reference purposes, the following diagram shows
+the state machine that <xref href="GUID-A8B4AD1B-770C-363E-A0DE-C78A9786CBDC.dita"><apiname>TDmaSbChannel</apiname></xref> implements to deal
+with a single buffer channel. </p> <fig id="GUID-82A8742D-CE5E-5EA2-A19E-6DCA30D9AE61">
+<image href="GUID-85332468-292D-589B-891B-0E7ACBADC7BA_d0e11000_href.png" placement="inline"/>
+</fig> <p><b>TDmaDbChannel
+State Machine</b> </p> <p>For reference purposes, the following diagram shows
+the state machine that <xref href="GUID-FD76AF08-6250-3054-8A06-16343E385B23.dita"><apiname>TDmaDbChannel</apiname></xref> implements to deal
+with a double buffer channel. </p> <fig id="GUID-1CF4D292-310C-5D75-9E3B-2DB65217FEEA">
+<image href="GUID-91958EA5-9444-5895-B4B8-F2C670B81CD7_d0e11017_href.png" placement="inline"/>
+</fig> <p><b>TDmaSgChannel
+State Machine</b> </p> <p>For reference purposes, the following diagram shows
+the state machine that <xref href="GUID-2D4CFBB1-8D64-3CF5-B6F0-B24D16D5BAD4.dita"><apiname>TDmaSgChannel</apiname></xref> implements to deal
+with a scatter/gather channel. </p> <fig id="GUID-1206C662-9856-57A1-A0C5-FDF74F2A3BD3">
+<image href="GUID-09EE01E2-BF5E-5302-BA25-46C440ADECF5_d0e11034_href.png" placement="inline"/>
+</fig> </section>
+<section id="GUID-2F8979D3-A4DC-5919-B027-F8C17739A05D"><title>Streaming and
+Scatter/Gather DMA Controllers</title> <p>When a transfer request is queued
+onto a channel that is already transferring data, the header descriptor for
+the new list of descriptors is appended to the header of the previous request
+on the queue. If the underlying DMA controller supports hardware descriptors,
+they must also be linked together. </p> <p>The following diagram shows how
+headers and descriptors for a new request are appended to the existing ones
+for a DMA controller. The dashed arrows represent the new links. </p> <fig id="GUID-7E06E92E-C8D1-53FF-AF03-5B1A3EBC1EA5">
+<image href="GUID-28F3F720-A2E0-59C9-8BB4-B6124CFC6C89_d0e11050_href.png" placement="inline"/>
+</fig> <p> <i>Note that hardware descriptors are linked together using physical
+addresses, not virtual ones.</i>  </p> <p>Linking hardware descriptors together
+is implemented in the platform specific layer. There are two issues to consider: </p> <ul>
+<li id="GUID-4236DD82-FFAD-56D3-B46F-9D2198E0349A"><p>The channel may go idle
+before the linking is complete, which means that the data for the new request
+would not be transferred. </p> </li>
+<li id="GUID-48AAA44F-1EEF-5899-9D62-587AA0EC8303"><p>If the channel is transferring
+the last descriptor in the list, then updating the “next” field in the descriptor
+will have no effect because the content of the descriptor will already have
+been loaded in the controller registers. Again the channel would go idle without
+transferring the data associated with the new request. </p> </li>
+</ul> <p>The solutions available when porting the DMA Framework are: </p> <ul>
+<li id="GUID-DC8EBCE6-E355-5D93-A265-0D591F06841C"><p>If the DMA controller
+has hardware support for appending descriptors while transferring data, then
+there is no problem. </p> </li>
+<li id="GUID-77DE96E7-9D9A-543F-8CD9-A36055F38E7A"><p>If the peripheral attached
+to the channel can withstand a short disruption in the transfer flow, then
+the channel can be suspended while the appending takes place. This should
+be done with interrupts disabled to minimise disruption. </p> </li>
+<li id="GUID-962DAD2E-2684-5F51-8F80-A1E3C86BC8F7"><p>The alternative technique
+is to append the new list with interrupts disabled and set a flag. When the
+next interrupt occurs, if the flag is set and the channel idle, then the interrupt
+service routine must restart the transfer. </p> </li>
+</ul> <p>See <xref href="GUID-0D2F811C-81C3-526F-8EA4-98E50261BF4B.dita#GUID-0D2F811C-81C3-526F-8EA4-98E50261BF4B/GUID-4BF7605E-55D4-5B3A-BCD7-1F976765D738">Channels</xref>. </p> </section>
+<section id="GUID-106BBBE0-C18B-5321-96AE-F1A65FAB4FF7"><title>Interrupt Service
+Routine (ISR) and DFC Issues</title> <p>The platform specific layer must notify
+the platform independent layer when the following events occur: </p> <ul>
+<li id="GUID-13589C1E-5146-5044-9587-092C4347D4EC"><p>when an error occurs. </p> </li>
+<li id="GUID-47C15152-8C06-5864-9292-4EF6A9A458E6"><p>when each fragment completes,
+for single-buffer and double-buffer controllers. </p> </li>
+<li id="GUID-BCDD4ECD-4396-5F2C-9A3A-B0C3B20DCC90"><p>when the last fragment
+of a request completes, for scatter/gather controllers. </p> </li>
+</ul> <p>The ISR, as implemented in the platform specific layer, must: </p> <ul>
+<li id="GUID-037B8F96-3C27-5D2F-8E70-35C66C601D63"><p>determine which channel
+the interrupt is for. If the DMA controller uses dedicated interrupt lines
+per channel, the ASSP/variant interrupt dispatcher will do this. See <xref href="GUID-3C34724F-B476-5329-B0B1-6D5A34294979.dita">Interrupt Dispatcher Tutorial</xref>. </p> </li>
+<li id="GUID-58A2D3AE-BF42-56E6-9EB1-B77DC9B2B934"><p>determine whether the
+interrupt was asserted following a successful transfer completion or a failure.
+If the DMA controller uses different interrupt lines for completion and failure,
+the ASSP/variant interrupt dispatcher will do this. </p> </li>
+<li id="GUID-F9D50FBF-171A-5D26-851E-3FDDB4AE38BB"><p>Call <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-187EBCEB-4488-3606-BB71-8813111D8AF4"><apiname>TDmac::HandleIsr()</apiname></xref> in
+the platform specific layer. This function queues the DFC associated with
+the relevant channel. It takes care of the case where several interrupts occur
+before the DFC gets a chance to run. </p> </li>
+</ul> <p>The DFC updates the state of the channel and, for single and double
+buffer DMA controllers, configures the next fragment to transfer, if any.
+When all fragments making up a request have been transferred, the DFC calls
+the client-supplied callback associated with the completed request. The callback
+is also called if an error occurs during transfer. </p> </section>
+<section id="GUID-2CB7E268-0535-5AD0-8B08-3FEDBA39016D"><title>Locking Strategy</title> <p>For
+a given device driver, <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref> and <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita"><apiname>DDmaRequest</apiname></xref> instances
+can be accessed concurrently from the device driver thread and from a DFC
+queue thread. To avoid race conditions, each <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref> instance
+has a fast mutex, the protected data member <codeph>TDmaChannel::iLock</codeph>.
+This lock is acquired when queuing a new request, cancelling requests and
+executing the DFC. </p> <p> <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref> and <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita"><apiname>DDmaRequest</apiname></xref> instances
+are not protected against concurrent access from several client threads because
+this is assumed to be an exceptional case. A device driver with such need
+would have to implement its own locking scheme around calls to <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref> and <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita"><apiname>DDmaRequest</apiname></xref> member
+functions. </p> <p>Each <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> instance includes a fast
+mutex, the private member <codeph>TDmac::iLock</codeph> to protect descriptor
+reservation and allocation, because several device drivers may try to reserve
+or allocate descriptors concurrently. </p> <p>The <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita"><apiname>DmaChannelMgr</apiname></xref> static
+class includes a fast mutex which is used to protect channel opening as several
+device drivers may compete for the same channel. This lock is also used at
+channel closing time. </p> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-0DB79535-E4E6-50BD-852D-B2F177202C9C-master.png has changed
Binary file Adaptation/GUID-0DB79535-E4E6-50BD-852D-B2F177202C9C_d0e13227_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0DC908A1-6CF6-50B5-978F-AF6C8CE04F44.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-0DC908A1-6CF6-50B5-978F-AF6C8CE04F44" xml:lang="en"><title>Automatic
+Translation of Header Files From C++</title><shortdesc>Describes how C++ header files are translated into the assembler
+language that the bootstrap requires.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Some header files that the bootstrap uses are shared with the Kernel and
+are written in C++. The header files are shared to avoid duplicate definitions
+of, for example, super page layout in the kernel and in the bootstrap. Since
+the bootstrap is written in assembler, the C++ header files must be translated
+to assembler-syntax include files. </p>
+<p>This is done automatically under the control of the generic makefile. The
+translation tool can produce include files in ARMASM, GNU AS or Turbo Assembler
+(for X86) syntax; the examples will all be in ARMASM syntax. </p>
+<p>It should be noted that the translation tool does not process <codeph>#include</codeph> directives
+or any other preprocessor directives. Only the types listed below and types
+created from those (by typedef or class/struct declaration) will be recognised. </p>
+<p>The following elements of C++ header files are translated: </p>
+<section id="GUID-44615AE9-41CB-434E-B329-53A0B8F62AB0"><title>Compile time constants, both at file and class scope</title> <p>Constants
+at file scope have the same name in the assembler include file and constants
+at class scope have the name<codeph> &lt;class name&gt;_&lt;constant name&gt;</codeph> in
+the assembler include file. Initialiser values may be expressions and may
+involve previously-defined constants or enumerators as well as <codeph>sizeof</codeph> operations
+applied to previously-defined types. </p> <p>For example: </p><codeblock id="GUID-B865A222-D7DB-51EF-B371-2FE7EB167D00" xml:space="preserve">const TInt KBufferSize = 1024;
+class X { const TInt KClassConstant = 100; };
+</codeblock><p>translates to: </p><codeblock id="GUID-5D46D2A6-EA88-5350-8CBD-2FCA6E961CEE" xml:space="preserve">KBufferSize            EQU 0x00000400
+X_KClassConstant     EQU 0x00000064
+</codeblock> </section>
+<section id="GUID-7C0EF920-D60D-4215-B7C3-CEF51D6E027A"><title>Enumerators, both at file and class scope</title> <p>For example: </p><codeblock id="GUID-F9FEE61B-D409-53F4-A032-95667300A3C7" xml:space="preserve">enum T1 {E1=0, E2=8, E3};
+class X { enum {EE1=-1, EE2, EE3}; };
+</codeblock> <p>translates to: </p><codeblock id="GUID-6C3A4922-E67E-5020-B5AE-0C30C76428E0" xml:space="preserve">E1                    EQU    0x00000000
+E2                    EQU    0x00000008
+E3                    EQU    0x00000009
+X_EE1                EQU    0xFFFFFFFF
+X_EE2                EQU    0x00000000
+X_EE3                EQU    0x00000001
+</codeblock> </section>
+<section id="GUID-3D197845-41A1-4063-AA73-74058C13F56D"><title>Offset of a class member within the class</title> <p>For example: </p><codeblock id="GUID-84324D58-A2FC-592A-BA20-1986C51A6A4A" xml:space="preserve">class X { TInt iX; TInt iY; TInt iZ[16]; };</codeblock> <p>translates
+to:</p><codeblock id="GUID-8B86F0FC-8FF1-5CE5-8832-F692DAAF6478" xml:space="preserve">X_iX                EQU    0x00000000
+X_iY                EQU    0x00000004
+X_iZ                EQU    0x00000008
+X_iZ_spc            EQU    0x00000004
+X_sz                EQU    0x00000048</codeblock> <p>The offset of a class
+member within the class is given the assembler name<codeph> &lt;class&gt;_&lt;member&gt;</codeph>.
+For an array member, this offset is the offset of the first element of the
+array within the class and <codeph>&lt;class&gt;_&lt;member&gt;_spc</codeph> is
+the size of each array element. The overall size of the class is given the
+assembler name <codeph>&lt;class&gt;_sz</codeph>. </p> <p>When computing these
+offsets and sizes the following basic types are known to the translation tool: </p><codeblock id="GUID-5F7D5BB0-E679-54F2-AA40-79CE67F6663F" xml:space="preserve">TInt8, TUint8 = 1 byte</codeblock><codeblock id="GUID-B42C7375-C025-50CD-8E0D-F51D5CD06F22" xml:space="preserve">TInt16, TUint16 = 2 bytes aligned to 2 byte boundary</codeblock><codeblock id="GUID-D3138371-2EF3-5461-A45F-7C2F5B7EA789" xml:space="preserve">TInt32, TUint32, TInt, TUint, enum, TLinAddr, TPte, TPde = 4 bytes aligned to 4 byte boundary</codeblock><codeblock id="GUID-7043D61A-451E-57AE-8912-1A18C029F31E" xml:space="preserve">TInt64, TUint64 = 8 bytes aligned to 8 byte boundary</codeblock> <p>The
+tool will produce an error if an attempt is made to use a <xref href="GUID-AAE85115-A8AA-3F6C-BA8C-69F5A23B0D90.dita"><apiname>TInt64</apiname></xref> or <xref href="GUID-5944E314-0D03-37D7-AA37-D29E6F6E18B8.dita"><apiname>TUint64</apiname></xref> which
+is not aligned on an 8 byte boundary. This is done to avoid incompatibilities
+between GCC and EABI compilers since the tool is not aware which is being
+used to compile the kernel. </p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0E93319A-439E-49D8-BF38-C809FEE4BB74.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,47 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-0E93319A-439E-49D8-BF38-C809FEE4BB74" xml:lang="en"><title>User-side
+Creation</title><shortdesc>This document describes user-side creation of asynchronous requests.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Asynchronous requests are commonly initiated by a call to <xref href="GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066.dita#GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066/GUID-FCC4A3A9-69F5-3947-8D0F-2AD12086F1E2"><apiname>RBusLogicalChannel::DoRequest()</apiname></xref>.
+The user making an asynchronous request creates a <xref href="GUID-E0B34F3E-D4C4-3232-B8B1-7DB35B454646.dita"><apiname>TRequestStatus</apiname></xref> object
+and passes it along with the request type to the <xref href="GUID-9D910016-5611-30DD-A139-EE46705A4912.dita"><apiname>DoRequest()</apiname></xref> call.
+The request status is changed to <xref href="GUID-B0778F54-C5DD-3307-A1E2-0DD339C4E4E7.dita"><apiname>KRequestPending</apiname></xref> by the
+Kernel before sending the message to the driver. The user may then either
+wait on the request using <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-50223158-D05D-33FE-A3DD-FFA9E2F464FF"><apiname>User::WaitForRequest()</apiname></xref>, or it
+may queue one or more requests and then wait. It may have an active object
+handler to receive the request complete notifications. </p>
+<codeblock id="GUID-39AC44C2-1FDF-5A6C-81F0-0BA9BB23DF91" xml:space="preserve">// Request status object for transmit. This object will be used to 
+// read the status of asynchronous requests after the notification of 
+// request completion
+//
+ TRequestStatus txStatus;
+     
+// Call the LDD interface TransmitData() API with test data descriptor 
+// and TRequestStatus object as parameters. Here TransmitData() is a
+// wrapper over a DoRequest() call.
+//
+r = ldd.TransmitData(txStatus, KTestSendData);
+test(r==KErrNone);
+            
+// Wait till the request is complete on txStatus. The user thread is 
+// blocked with this call, till it is notified about the request 
+// completion.
+//
+User::WaitForRequest(txStatus);
+     
+// txStatus holds the request completion. TRequestStatus::Int() 
+// returns the completion code. It will be KErrNone in case of 
+// successful completion.
+//
+r = txStatus.Int();
+test(r==KErrNone);</codeblock>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-0F17BCDF-CF50-40D1-9048-793DC4442B50.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-0F17BCDF-CF50-40D1-9048-793DC4442B50" xml:lang="en"><title>Introduction</title><shortdesc>This set of documents describes the device driver development process
+and provides links to example material.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> </p>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-0FE0B646-A62F-55A8-A6E6-587D0909CE19-master.png has changed
Binary file Adaptation/GUID-0FE0B646-A62F-55A8-A6E6-587D0909CE19_d0e74784_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-10C986FD-BD56-4F8E-87EC-7B890EFCDAC7.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-10C986FD-BD56-4F8E-87EC-7B890EFCDAC7" xml:lang="en"><title>DMA Chipset Configuration</title><shortdesc>Chipset configuration is performed entirely within the
+platform service implementation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The DMA controller chipset has multiple DMA channels that can be
+configured for different DMA transfers. Drivers generally initialize
+and open the required DMA channel and use this channel to do the DMA
+transfers. </p>
+<p>For some peripherals, such as the Camera and the Display controller,
+there can be dedicated DMA channels that cannot be configured for
+DMA transfers by other peripherals. </p>
+<p>To configure the channels and other features of the chipset, you
+may need to write code. This code should be executed prior to the
+DMA channels being used for the first time, or to configure dynamically-allocated
+channels.</p>
+<p>This requires chipset specific code which is beyond the scope of
+this documentation. Please refer to your chipset's datasheet and any
+accompanying documentation for details on how to perform any required
+chipset configuration.</p>
+<p><note>If you need to perform chipset configuration after the device
+driver has loaded, there is an <xref href="GUID-93A3F01A-3489-37E5-921C-5EA5228545AA.dita"><apiname>Extension()</apiname></xref> function.
+This function passes chipset specific code or instructions from the
+client to the platform service implementation. Implementation of the <xref href="GUID-93A3F01A-3489-37E5-921C-5EA5228545AA.dita"><apiname>Extension()</apiname></xref> API is platform specific and is not covered
+further in this documentation.</note></p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-10D79C75-6AB9-4717-87EF-057F19CB8283.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE task
+  PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
+<task id="GUID-10D79C75-6AB9-4717-87EF-057F19CB8283" xml:lang="en"><title>Time Implementation Guide</title><shortdesc>How to implement the Time platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody>
+<prereq id="GUID-9237420C-294D-4A65-AB19-46BD17038B5D"><p>The Time
+platform service specifies functions to get and set the current time.</p></prereq>
+<context id="GUID-547ED715-ED71-486D-B9F2-CFD9E39C4E83"><p>To implement
+the Time platform service, you implement the functions <xref href="GUID-DED2C0D0-EA27-3C02-8FF2-8CB5ADCC1170.dita"><apiname>RtcData()</apiname></xref> and <xref href="GUID-9926EDCB-DA2C-3D1C-9637-CB3147E7E97A.dita"><apiname>SetRtcData()</apiname></xref> in hardware.</p></context>
+<steps id="GUID-4DD07DEC-6017-4237-BE46-1D69E5FBD744-GENID-1-2-1-10-1-5-1-10-1-1-8-1-3-1-3-3">
+<step id="GUID-9A69E5AD-E938-4092-A8C2-CB65C37C8962-GENID-1-2-1-10-1-5-1-10-1-1-8-1-3-1-3-3-1"><cmd/>
+<info><p>The function <xref href="GUID-9926EDCB-DA2C-3D1C-9637-CB3147E7E97A.dita"><apiname>SetRtcData()</apiname></xref> sets the state
+of the real time clock to a passed in value. To implement it you write
+that value to the RTC current time register. On Symbian platform,
+the value should be the number of seconds that have elapsed since
+the beginning of 2000.</p></info>
+<stepresult><p>The platform now has a function to set the current
+time in seconds.</p></stepresult>
+</step>
+<step id="GUID-9A69E5AD-E938-4092-A8C2-CB65C37C8962-GENID-1-2-1-10-1-5-1-10-1-1-8-1-3-1-3-3-2"><cmd/>
+<info><p>The function <xref href="GUID-DED2C0D0-EA27-3C02-8FF2-8CB5ADCC1170.dita"><apiname>RtcData()</apiname></xref> returns the current
+state of the real time clock. To implement it, you read the RTC current
+time register and return that time as a <xref href="GUID-F9432D7B-41C9-3048-AC50-B5BCF8BE11D0.dita"><apiname>TUint</apiname></xref>.</p></info>
+<stepresult><p>The current state of the real time clock is a <xref href="GUID-F9432D7B-41C9-3048-AC50-B5BCF8BE11D0.dita"><apiname>TUint</apiname></xref> containing the number of seconds since the beginning
+of 2000.</p></stepresult>
+</step>
+</steps>
+<result id="GUID-A265C295-5403-4C52-9CC1-8D004F06DC4A"><p>You have
+now implemented the Time platform service in hardware.</p></result>
+</taskbody><related-links>
+<link href="GUID-8D237BD6-9759-4180-B190-F1624594017F.dita"><linktext>Time
+Client Interface Tutorial — Using the Interface</linktext></link>
+</related-links></task>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-10F3E16A-8CCE-420A-9D1C-F9891B3D75FE.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-10F3E16A-8CCE-420A-9D1C-F9891B3D75FE" xml:lang="en"><title>Concepts</title><shortdesc>Describes the technology, architecture, and behaviour of
+the power management framework.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-10FD1B94-EC0C-458F-839F-B60A8E47BAD6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,163 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-10FD1B94-EC0C-458F-839F-B60A8E47BAD6" xml:lang="en"><title>Baseport Template Configuration Guide</title><shortdesc>Describes the configuration of the Baseport Template platform
+service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The <filepath>config.inc</filepath> file provided at <filepath>os/kernelhwsrv/bsptemplate/asspandvariant/template_variant/config.inc</filepath> is used to set up the platform specific values in the Baseport.
+The comments in the <filepath>config.inc</filepath> file explains
+the various options that can be used to configure the baseport. </p>
+<section id="GUID-67DA5F25-67FB-440D-8473-1261922AFC73"><title>Template
+configuration</title><p>A sample configuration file is available in
+the template. The configuration file looks like the one below:</p><codeblock xml:space="preserve">
+; template\config.inc
+;
+;Include to enable tracing
+;	GBLL	CFG_DebugBootRom
+
+; 
+; Include one of these to select the CPU
+;	GBLL	CFG_CPU_GENERIC_ARM4
+;	GBLL	CFG_CPU_ARM710T
+;	GBLL	CFG_CPU_ARM720T
+;	GBLL	CFG_CPU_SA1
+;	GBLL	CFG_CPU_ARM925T
+;	GBLL	CFG_CPU_ARM926J
+;	GBLL	CFG_CPU_XSCALE
+;	GBLL	CFG_CPU_ARM1136
+;	GBLL	CFG_CPU_ARM1176
+;	GBLL	CFG_CORTEX_A8
+
+; Include the following line if this is a bootloader bootstrap
+;	GBLL	CFG_BootLoader
+
+; TO DO:
+; The following line needs to be removed for target hardware
+GBLL	CFG_Template
+
+; If you want to supply a custom set of initial vectors (including reset vector) include the following line
+;	GBLL	CFG_CustomVectors
+;
+; and provide a custom_vectors.inc file
+
+; Variant Number, just an example:
+	INIT_NUMERIC_CONSTANT	CFG_HWVD, 0x09080001
+
+; On ARM architecture 6 processors, include the following line to override the threshold
+; on total physical RAM size at which the multiple memory model switches into large address space mode
+; i.e. size&gt;threshold -&gt; 2Gb per process, size&lt;=threshold -&gt; 1Gb per process
+; Defaults to 32Mb.
+;	INIT_NUMERIC_CONSTANT	CFG_ARMV6_LARGE_CONFIG_THRESHOLD, ;&lt;value &amp;rt;   
+; For the direct memory model only, include the following line if you wish the exception vectors at the 
+; start of the bootstrap to be used at all times. This is only relevant if an MMU is present - this option 
+; is mandatory if not.
+;	GBLL	CFG_UseBootstrapVectors 
+;
+; If the above option is in use (including if no MMU is present) the following symbol should be defined 
+; to specify the offset from the bootstrap to the kernel image. 	INIT_NUMERIC_CONSTANT	KernelCodeOffset, 0x4000  
+; Include the following line if you wish to include the ROM autodetection code based on data bus 
+; capacitance and image repeats. 
+;	GBLL	CFG_AutoDetectROM  
+; Include the following line to minimise the initial kernel heap size 
+; On the direct memory model the size of the kernel data area (super page to end of kernel heap)  
+; is rounded up to the next 1Mb if this is not included, 4K if it is. 
+; On the moving and multiple models, the size of the initial kernel heap area is rounded up to 
+; the next 64K if this is not included, 4K if it is. 
+;	GBLL	CFG_MinimiseKernelHeap  
+; Include the following line if default memory mapping should use shared memory. 
+; Should be defined on multicore (SMP) devices. 
+;	GBLL	CFG_USE_SHARED_MEMORY  
+; On the moving or multiple memory models, include either or both of the following lines to 
+; specify the size of the initial kernel heap 
+;	INIT_NUMERIC_CONSTANT	CFG_KernelHeapMultiplier, &lt;multiplier&gt; 
+;	INIT_NUMERIC_CONSTANT	CFG_KernelHeapBaseSize, &lt;base&gt; 
+; 
+; The initial kernel heap size is MAX( &lt;base&gt; + &lt;multiplier&gt; * N / 16, value specified in ROMBUILD ) 
+; where N is the total physical RAM size in pages. 
+; &lt;base&gt; defaults to 24K and &lt;multiplier&gt; defaults to 9*16 (ie 9 bytes per page).  
+; Uncomment if using ARM1136 processor and ARM1136 Erratum 353494 
+; "Rare conditions can cause corruption of the Instruction Cache"  
+; is fixed on this hardware. 
+; NOTE: The boot table should use this macro to determine whether RONO or RORO permissions 
+; are used for the exception vectors. If the erratum is not fixed, RORO must be used. 
+;
+;	GBLL	CFG_CPU_ARM1136_ERRATUM_353494_FIXED  
+; Uncomment if using ARM1136 processor and ARM1136 Erratum 364296 
+; "Possible Cache Data Corruption with Hit-Under-Miss" 
+; is fixed on this hardware. 
+; 
+;	GBLL	CFG_CPU_ARM1136_ERRATUM_364296_FIXED  
+; Uncomment if using ARM1136 processor and ARM1136 Erratum 399234 
+; "Write back data cache entry evicted by write through entry causes data corruption" 
+; is fixed on this hardware. 
+;
+; Workaround 
+; The erratum may be avoided by marking all cacheable memory as one of write through or write back. 
+; This requires the memory attributes described in the translation tables to be modified by software 
+; appropriately, or the use of the remapping capability to remap write through regions to non cacheable. 
+; 
+; If this macro is enabled, it should be accompanied by: 
+; 		"macro __CPU_ARM1136_ERRATUM_399234_FIXED" in variant.mmh 
+;	GBLL	CFG_CPU_ARM1136_ERRATUM_399234_FIXED   
+;
+; Uncomment if: 
+;	1)	using ARM1136 processor and ARM1136 Erratum 411920: "Invalidate Entire Instruction Cache 
+;	  	operation might fail to invalidate some lines if coincident with linefill" 
+;  	  	is fixed on this hardware, or 
+;	2)	using ARM1176 processor and ARM1176 Erratum 415045: "Invalidate Entire Instruction Cache 
+; 	  	operation might fail to invalidate some lines if coincident with linefill 
+;	  	is fixed on this hardware. 
+; Workaround: 
+;	1)	Disables the use of of prefetch range cache operations by setting RV bit in Auxiliary Ctrl Reg. 
+;	2)	Replaces Invalidate ICache operation with the sequence defined in the errata document. 
+;
+; If this macro is enabled, it should be accompanied by: 
+; 	"macro __CPU_ARM1136_ERRATUM_411920_FIXED" in variant.mmh 
+; 
+;	GBLL	CFG_CPU_ARM1136_ERRATUM_411920_FIXED   
+;
+; Uncomment if using ARM1136 processor and ARM1136 Erratum 415662: "Invalidate Instruction Cache by 
+; Index might corrupt cache when used with background prefetch range" is fixed on this hardware. 
+; Workaround: 
+; 	Disables the use of of prefetch range cache operations by setting RV bit in Auxiliary Ctrl Reg. 
+; 
+;	GBLL	CFG_CPU_ARM1136_ERRATUM_415662_FIXED   
+;
+; These are deduced from the supplied configuration 
+;	CFG_ARMV6 ;	CFG_MMUPresent 
+;	CFG_CachePresent ;	CFG_WriteBufferPresent 
+;	CFG_SplitCache 
+;	CFG_SplitTLB 
+;	CFG_AltDCachePresent 
+;	CFG_WriteBackCache 
+;	CFG_CacheWriteAllocate 
+;	CFG_CachePhysicalTag 
+;	CFG_CacheFlushByDataRead 
+;	CFG_CacheFlushByWaySetIndex 
+;	CFG_CacheFlushByLineAlloc 
+;	CFG_CachePolicyInPTE 
+;	CFG_TEX 
+;	CFG_SingleEntryDCacheFlush 
+;	CFG_SingleEntryICacheFlush 
+;	CFG_SingleEntryITLBFlush 
+;	CFG_SingleEntryTLBFlush 
+;	CFG_CacheTypeReg 
+;	CFG_BTBPresent 
+;	CFG_CARPresent 
+;	CFG_PrefetchBuffer 
+;	CFG_FCSE_Present 
+;	CFG_ASID_Present 
+;	CFG_IncludeRAMAllocator
+ 	END 
+	</codeblock><note> Ensure that you have made the line <codeph>GBLL	CFG_Template </codeph> a comment and have selected the lines for the required configuration.</note></section>
+</conbody><related-links>
+<link href="GUID-AE486C82-8854-463F-8CB9-B7353D6B2804.dita"><linktext>Baseport
+Template Build Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-10FE825A-4383-4A10-A507-58577BB230FB-master.png has changed
Binary file Adaptation/GUID-10FE825A-4383-4A10-A507-58577BB230FB_d0e89974_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-110DB7EF-5E85-5BC4-9BBB-9A37B2D0C3A6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-110DB7EF-5E85-5BC4-9BBB-9A37B2D0C3A6" xml:lang="en"><title>Dynamic Behavior</title><shortdesc>This topic describes in detail the dynamic relationships
+between a keyboard driver, the Window Server, and related components.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-DACF5D8F-DCA6-5C84-969D-53346034EF48"><title>What
+the keyboard driver does</title> <p>The keyboard driver's job is to
+interpret keyboard presses and to generate key-up and key-down events.
+How the keyboard driver deals with the hardware depends to a great
+extent on that hardware, and also on whether the hardware generates
+interrupts as a result of key presses or whether the driver needs
+to poll the hardware at regular intervals. </p> <p>The template Base
+port, which can be found at <filepath>...\cedar\template\...</filepath>, gives two skeleton implementations, one for an interrupt driven
+implementation and one for a poll driven implementation. See <xref href="GUID-2E42E7EA-FED8-522C-8A5F-F65D799476C9.dita">Keyboard Driver Implementation
+Tutorial</xref>. </p> <p>Whichever type is used, the end result is
+the addition of a stream of events onto the kernel's event queue.
+Events are represented by <xref href="GUID-668CEA36-3933-3BBE-A980-CAB62617B4FD.dita"><apiname>TRawEvent</apiname></xref> objects, and
+each one represents either a key-up or a key-down event, together
+with the scancode value for that key and the accompanying modifier
+key values, for example, <userinput>Shift</userinput> and <userinput>Ctrl</userinput>. The driver adds these events onto the kernel's
+event queue using <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-81C82FED-0E26-351A-901E-806843C808FE"><apiname>Kern::AddEvent()</apiname></xref>. </p> <p>The
+general pattern, taken from the template keyboard driver, is as follows: </p> <codeblock id="GUID-312BE5FF-7E8B-593F-9569-204B571AEED4" xml:space="preserve">TRawEvent e;
+...
+e.Set(TRawEvent::EKeyUp,stdKey,0);
+...
+Kern::AddEvent(e);</codeblock> <codeblock id="GUID-3261FF68-D313-5E33-AFC8-10CF137BC55D" xml:space="preserve">TRawEvent e;
+...
+e.Set(TRawEvent::EKeyDown,stdKey,0);
+...
+Kern::AddEvent(e);</codeblock> <p>More generally, <xref href="GUID-668CEA36-3933-3BBE-A980-CAB62617B4FD.dita"><apiname>TRawEvent</apiname></xref> objects represent and encapsulate information about events such
+as screen pointer events, mouse events, etc. as well as keyboard key
+presses. Such events are mostly intended to result in a change to
+the device display(s) or the finer details of the User Interface,
+and for this reason, such events are captured by the Window Server. </p> <p>The kernel event queue is a mechanism that allows this to happen. <i>It is internal to Symbian platform</i>, but to help you understand
+what happens, it works like this: </p> <ul>
+<li id="GUID-357EC331-CB32-571B-AD17-A772AAED921F"><p>The kernel maintains
+a circular buffer of <xref href="GUID-668CEA36-3933-3BBE-A980-CAB62617B4FD.dita"><apiname>TRawEvent</apiname></xref> objects anchored
+in <codeph>K::EventBufferStart</codeph>, and this buffer is allocated
+at system initialization. </p> </li>
+<li id="GUID-91389CBC-11E4-5019-BA89-202E3ABC3225"><p>As part of its
+initialization, the Window Server calls the <i>internal function</i>  <codeph>UserSvr::CaptureEventHook()</codeph>. This registers the
+Window Server's interest in capturing these events, and subsequent
+to this call, all such events are delivered to the Window Server.
+However, do note that the kernel does not permit any process other
+than the Window Server from registering to receive these events. </p> </li>
+<li id="GUID-5BD630E8-34D5-52F3-BA63-1B337A2E7B26"><p>A call to <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-81C82FED-0E26-351A-901E-806843C808FE"><apiname>Kern::AddEvent()</apiname></xref> causes a <xref href="GUID-668CEA36-3933-3BBE-A980-CAB62617B4FD.dita"><apiname>TRawEvent</apiname></xref> object
+to be added to this queue; the kernel subsequently attempts to deliver
+this to the Window Server. </p> </li>
+<li id="GUID-D6F17A9A-5E13-54EF-8CDC-BCA533A62EC9"><p>The Window Server
+uses an active object to wait for and subsequently dispatch the handling
+of events (and most importantly, key press events). It makes a request
+for further events by a call to the <i>internal function</i>  <codeph>UserSvr::RequestEvent()</codeph>. </p> </li>
+</ul> <fig id="GUID-03C2DFBA-F3C9-5A3F-9DE4-3FE30DECB239">
+<title>Dynamic Behavior</title>
+<image href="GUID-8A1B6104-4B13-5200-AF3D-64B3929707BB_d0e14531_href.png" placement="inline"/>
+</fig> </section>
+<section id="GUID-98528897-D236-56A8-BBDE-6CF09BFDE499"><title>What
+the Window Server does</title> <p>There are two services that the
+Window Server needs when dealing with key presses: </p> <ul>
+<li id="GUID-FBEA62A9-37E4-58AA-97AF-6D3312D7D35E"><p>it needs a translation
+of a (hardware) scancode to a (Symbian platform or logical) keycode. </p> </li>
+<li id="GUID-8A9BE092-ED85-5E36-9670-24F5BF2E39F2"><p>it needs to
+know whether a key and combination of modifier key states is a "hot-key",
+i.e. one that is intended to be sent to a specific window group, instead
+of the window group that currently has focus. Note that, in this context,
+a "hot-key" is more commonly referred to as a <i>capture key</i>. </p> </li>
+</ul> <p>To perform the translation, it creates an instance of a <codeph>CKeyTranslator</codeph> class. </p> <p>To deal with capture keys,
+it creates an instance of a <codeph>CCaptureKeys</codeph> class. </p> <p>Both classes are implemented in <filepath>ektran.dll</filepath>, the key translation DLL, which is built and delivered as part of
+the generic Symbian platform. The Window Server statically links to <filepath>ektran.dll</filepath>. </p> <p>[<i>Note that CKeyTranslator and CCaptureKeys
+are internal to Symbian platform and are not part of the public interface.
+This is an attempt to provide an outline understanding of the mechanisms
+involved.</i>] </p> <p>The Window Server also decides on the name
+of the key mapping tables DLL to be loaded. By default, the name of
+this DLL is <filepath>ekdata.dll</filepath>. However, if the Hardware
+Abstraction Layer (HAL) for the device records a language index, then
+this index value is used to form the name of the DLL to be loaded.
+For example, if the keyboard index value returned by a call to: </p> <codeblock id="GUID-150E4C78-6434-57AA-8C4D-819CB2814801" xml:space="preserve">TInt keyboardIndex;
+HAL::Get(HALData::EKeyboardIndex,keyboardIndex);</codeblock> <p>is
+99, then the DLL loaded is <filepath>ekdata99.dll</filepath>. </p> <p>The loading of this DLL is done by a member of <codeph>CKeyTranslator</codeph>, so although the Window Server decides which DLL is to be loaded,
+the actual loading is done by <filepath>ektran.dll</filepath>. For
+ease of explanation, we will continue to refer to this DLL as <filepath>ekdata.dll</filepath>. </p> <p>On receipt of key-up and key-down
+events, the Window Server calls <codeph>CKeyTranslator::TranslateKey()</codeph>. This function takes the (hardware) scancode and translates it into
+the (logical) keycode. It also reports whether the key and combination
+of modifier key states is a capture key, and if so, returns the handle
+to the window group that is associated with it. </p> <p>Before the
+Window Server can be told that a capture key has been pressed, it
+must previously have registered a pair of items: </p> <ul>
+<li id="GUID-F379A692-70EC-57A7-B5C0-4EAC13672496"><p>the capture
+key itself, i.e. the (logical) keycode and combination of modifier
+key states. </p> </li>
+<li id="GUID-099ADF78-448F-58F3-945C-3CF048FF2AAF"><p>a handle to
+a window group. </p> </li>
+</ul> <p>Registration is simply the act of adding this information
+into the <codeph>CCaptureKey</codeph> object by a call to <codeph>CCaptureKeys::AddCaptureKeyL()</codeph>. The Window Server does this
+as a result of a call to <xref href="GUID-64D4D428-D65F-3D9D-A0D4-C8338C848B25.dita#GUID-64D4D428-D65F-3D9D-A0D4-C8338C848B25/GUID-433AD95D-5F34-3AB2-A077-E9AED2CF0AED"><apiname>RWindowGroup::CaptureKey()</apiname></xref>, either by applications or the UI. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,133 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F" xml:lang="en"><title>Factory
+Implementation</title><shortdesc>Describes how to implement a factory. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Sound Driver PDD must provide a factory class to create channels. All
+PDD factory classes are derived from <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita"><apiname>DPhysicalDevice</apiname></xref>. The
+template PDD factory class <xref href="GUID-CA70CE3A-ACD8-39C7-8F27-D73EA9E6C2E1.dita"><apiname>TemplateSoundScPddFactory</apiname></xref> creates
+the appropriate PDD object when a driver channel is opened on the device.
+As well as the configurations supporting both record and playback, this class
+implements control of those aspects of the audio hardware device that are
+shared between the two channels. </p>
+<p> <xref href="GUID-8720456A-173A-3801-BECB-736ABFA7912A.dita"><apiname>DTemplateSoundScPddFactory</apiname></xref> is defined as: </p>
+<codeblock id="GUID-A66766B6-6953-59AC-9520-A686A8216E0F" xml:space="preserve">class DTemplateSoundScPddFactory : public DPhysicalDevice
+    {
+public:
+    DTemplateSoundScPddFactory();
+    ~DTemplateSoundScPddFactory();
+    virtual TInt Install();
+    virtual void GetCaps(TDes8&amp; aDes) const;
+    virtual TInt Create(DBase*&amp; aChannel, TInt aUnit, const TDesC8* aInfo, const TVersion&amp; aVer);
+    virtual TInt Validate(TInt aUnit, const TDesC8* aInfo, const TVersion&amp; aVer);
+private:
+    /** The DFC queue (used also by the LDD). */ 
+    TDynamicDfcQue* iDfcQ;
+    friend class DTemplateSoundScTxPdd;
+    friend class DTemplateSoundScRxPdd; 
+    };</codeblock>
+<p>The PDD factory class provided by the template Sound Driver creates a new
+DFC queue and associated kernel thread, <codeph>iDfcQ</codeph>, for exclusive
+use by this pair of Sound Driver channels. This is created within the second
+stage constructor function <xref href="GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F.dita#GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F/GUID-48FD1134-253A-56E6-8152-C95260E4CB21">Install()</xref>.
+A pointer to the DFC queue is returned by the PDD function <xref href="GUID-71190437-912E-3E23-8E68-4FA8FF913D7A.dita"><apiname>DfcQ()</apiname></xref>.
+See the <xref href="GUID-AC560324-798C-5D0A-B23D-2419A7688A5B.dita#GUID-AC560324-798C-5D0A-B23D-2419A7688A5B/GUID-61725EEB-5114-5A85-9C28-57A47F14000C">PDD
+class constructor</xref> section. </p>
+<p>The class <xref href="GUID-8720456A-173A-3801-BECB-736ABFA7912A.dita"><apiname>DTemplateSoundScPddFactory</apiname></xref> contains four virtual
+functions, including the constructor, that must be implemented by the PDD
+for both driver channels. The template Sound Driver contains default implementations
+together with a constructor and destructor and, typically, need little or
+no modification: </p>
+<ul>
+<li id="GUID-896078FE-06EF-5AAC-ABDD-4B8AC7B0B72C"><p> <xref href="GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F.dita#GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F/GUID-CE921DE4-77A2-580F-8415-749DBA2782B8">DTemplateSoundScPddFactory constructor</xref>  </p> </li>
+<li id="GUID-A3959AB1-9B25-5892-ADDE-4C79995A611B"><p> <xref href="GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F.dita#GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F/GUID-48FD1134-253A-56E6-8152-C95260E4CB21">Install()</xref> </p> </li>
+<li id="GUID-2D388367-517C-526A-B385-DE86FBB59A5E"><p> <xref href="GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F.dita#GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F/GUID-FFDCBC89-FC11-57AA-A43E-689355B48E5A">Validate()</xref> </p> </li>
+<li id="GUID-06C058F0-5CE7-56F6-A34C-C1CAF67D1E95"><p> <xref href="GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F.dita#GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F/GUID-B28B533E-1630-52F6-9589-F71E3FAFEBBB">Create()</xref>  </p> </li>
+</ul>
+<section id="GUID-CE921DE4-77A2-580F-8415-749DBA2782B8"><title>DTemplateSoundScPddFactory
+constructor</title> <p>Ensure that the inherited data member <codeph>iUnitsMask</codeph> is
+setup correctly according to the unit numbers to be supported. The default
+version enables the PDD to open both the first playback driver channel number <codeph>KSoundScTxUnit0</codeph> and
+the first record driver channel number <codeph>KSoundScRxUnit0</codeph>: </p> <codeblock id="GUID-F294EA90-83AD-557C-8EC7-675062FB768C" xml:space="preserve">// Support units KSoundScTxUnit0 &amp; KSoundScRxUnit0
+iUnitsMask=(1&lt;&lt;KSoundScRxUnit0)|(1&lt;&lt;KSoundScTxUnit0);</codeblock> </section>
+<section id="GUID-48FD1134-253A-56E6-8152-C95260E4CB21"><title>Install()</title> <p>This
+is the second stage constructor for the PDD factory class. The template version
+creates the DFC queue and sets the driver name. </p> <codeblock id="GUID-1A94099F-B0AB-55D4-9D43-E63E7C92482E" xml:space="preserve">_LIT(KSoundScPddName,"SoundSc.Template");
+
+// Definitions for the kernel thread created for this sound driver.
+_LIT(KSoundScDriverThreadName,"SoundDriverThread");
+const TInt KSoundScDriverThreadPriority=26; // One less than DFC thread 0
+
+TInt DTemplateSoundScPddFactory::Install()
+{
+    TInt r=KErrNone;
+    if (iDfcQ==NULL)
+        {
+        // Create a new sound driver DFC queue (and associated kernel thread). 
+        r=Kern::DynamicDfcQCreate(iDfcQ, KSoundScDriverThreadPriority, KSoundScDriverThreadName);
+        }
+    
+    if (r==KErrNone)
+        {
+        r=SetName(&amp;KSoundScPddName); // Set the name of the driver object
+        }
+    return(r);
+    }</codeblock> <p>The physical device is identified by the driver name,
+alter this to reflect your device. The driver name is the same as the LDD
+name, but followed by a dot and a short string to represent the physical device.
+For example, the name used for template is "<codeph>SoundSc.Template</codeph> ". </p> </section>
+<section id="GUID-FFDCBC89-FC11-57AA-A43E-689355B48E5A"><title>Validate()</title> <p>This
+function is called by the kernel device driver framework to see whether this
+PDD is suitable for use with a particular driver channel. Ensure that the
+unit number checking code is correct for the unit numbers that are to be supported.
+The default version enables the PDD to open both the first playback driver
+channel number <codeph>KSoundScTxUnit0</codeph> and the first record driver
+channel number <codeph>KSoundScRxUnit0</codeph>. </p> <codeblock id="GUID-21542AAA-48FA-5D9E-A1EA-5F8363F3FE84" xml:space="preserve">// Check the unit number is compatible
+if (aUnit!=KSoundScTxUnit0 &amp;&amp; aUnit!=KSoundScRxUnit0)
+    return(KErrNotSupported);</codeblock> </section>
+<section id="GUID-B28B533E-1630-52F6-9589-F71E3FAFEBBB"><title>Create()</title> <p>This
+function is called by the kernel device driver framework to create a PDD object.
+Ensure that the unit number checking code is correct for the unit numbers
+that are to be supported. For configurations supporting both playback and
+record, it must be capable of creating either a playback or record PDD object
+according to the channel number specified. The template version is implemented
+as follows: </p> <codeblock id="GUID-B1625466-4560-56C2-A7BF-8700FFAEAAD8" xml:space="preserve">TInt DTemplateSoundScPddFactory::Create(DBase*&amp; aChannel, 
+                                        TInt aUnit,
+                                        const TDesC8* /*anInfo*/, 
+                                        const TVersion&amp; /*aVer*/)
+    {
+    // Create the appropriate PDD channel object.
+    TInt r=KErrNoMemory;
+    if (aUnit==KSoundScRxUnit0)
+        {
+        // Create a record PDD channel object
+        DTemplateSoundScRxPdd* pD=new DTemplateSoundScRxPdd;
+        aChannel=pD;
+        if (pD)
+            {
+            pD-&gt;iPhysicalDevice=this;
+            r=pD-&gt;DoCreate();
+            }
+        }
+       else
+        {
+        // Create a playback PDD channel object
+        DTemplateSoundScTxPdd* pD=new DTemplateSoundScTxPdd;
+        aChannel=pD;
+        if (pD)
+            {
+            pD-&gt;iPhysicalDevice=this;
+            r=pD-&gt;DoCreate();
+            }
+        }
+    return(r);
+    } </codeblock> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-113B3755-1797-5D1B-8E07-8A18F5FE1504.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,43 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-113B3755-1797-5D1B-8E07-8A18F5FE1504" xml:lang="en"><title>Power States</title><shortdesc>Describes three power states that are defined by the kernel.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<ul>
+<li id="GUID-61A3C566-05AA-5F6D-A9DE-B409C873B119"><p> <i>Off</i> -
+a state where the device and all peripherals are powered off or inactive,
+or are characterised by negligible power consumption due to current
+leakage to the electric and electronic circuits that make up the system.
+This state is achieved as a result of controlled system shutdown resulting
+from a user action, an application request, UI inactivity, or as a
+result of accidental loss of power. This may also be achieved as a
+result of putting the system into a hibernation state. Note that a
+reboot is necessary to return the system to the <i>Active</i> state;
+this could be a cold reboot, or a warm reboot if the system was put
+into a hibernation state. </p> </li>
+<li id="GUID-275417B2-B8C8-5C93-B576-15543D80CAC9"><p> <i>Standby</i> - a low power consuming state that results from turning off most
+system resources (clocks, voltages), peripherals, memory banks (where
+possible), cpu and internal logic, while still retaining the state
+prior to the transition. Typically, the only systems that are active
+are those that are required to detect the events that force the transition
+back to the Active state (e.g. RTC, clocks and Peripherals involved
+in detecting hardware events). Returning to the Active state will
+normally take a far shorter period of time than that required to reboot
+the system. This state is achieved as a result of user action or application
+request. </p> </li>
+<li id="GUID-A31A5A3C-C7C2-5D15-88B2-828F7E5F60D8"><p> <i>Active</i> - the fully active state. </p> </li>
+</ul>
+<p>The three power states are defined by the enum values of the <xref href="GUID-87AB8B20-04EE-31D2-8F3D-EA904D05B8D0.dita"><apiname>TPowerState</apiname></xref> enum defined in <filepath>e32power.h</filepath>. </p>
+</conbody><related-links>
+<link href="GUID-E09E4418-4DC3-56A3-BFBE-486C9C8D25C9.dita"><linktext>Domain
+Manager</linktext></link>
+<link href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita"><linktext>Power
+Management</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-124AC7EE-E227-5358-A755-628FFE257250.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,162 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-124AC7EE-E227-5358-A755-628FFE257250" xml:lang="en"><title>HAL Handler Implementation</title><shortdesc>Describes how to implement or change a new HAL handler
+when you create a base port. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>A HAL handler gets or sets hardware-specific settings, for example,
+the display contrast.</p>
+<p>A HAL handler is normally implemented in the kernel extension or
+a driver that provides the hardware-specific functionality. </p>
+<p>The easiest way to see the general pattern for implementing HAL
+handlers is to look at a real example. We will use the screen (i.e.
+video or LCD) driver for the template reference board, which is implemented
+in <filepath>...\template_variant\specific\lcd.cpp</filepath>. </p>
+<section id="GUID-B0EF5EC5-E7DA-5700-A187-4B8D14A3956A"><title>HAL
+handler function signature</title> <p>The HAL handler function has
+a signature that is defined by the <xref href="GUID-A65A16CA-488D-3A16-A034-F01C9C0B9D15.dita"><apiname>THalFunc</apiname></xref> typedef
+that is exported in <filepath>epoc32\include\kernel\kernel.h</filepath>. </p> <p>For example: </p> <codeblock id="GUID-0C6E606C-7916-50D3-8E89-D27BC3EB8C54" xml:space="preserve">TInt halFunction(TAny* aPtr, TInt aFunction, TAny* a1, TAny* a2)</codeblock> </section>
+<section id="GUID-217DAB35-D227-5FB7-8342-7EFD69E6CDBC"><title>Registering
+the HAL handler</title> <p>Before the handler can do anything, the
+extension or driver must register its handler for a specific HAL group.
+It does so by calling: </p> <codeblock id="GUID-0B935CC7-DA21-56A7-9BBE-F90B61EACDE0" xml:space="preserve">Kern::AddHalEntry(group, handler_func, ptr);</codeblock> <p>where: </p> <ul>
+<li id="GUID-17F56160-DFE5-5703-959F-EE93C748F74D"><p> <codeph>group</codeph> is the number of the <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-366CC4B8-C6BD-5DCC-B55D-6D87CD5C8E64">HAL group attribute</xref> for which the HAL handler is being registered. </p> </li>
+<li id="GUID-C6D34824-AD21-514E-BC4E-EE1323E5A9C9"><p> <codeph>handler_func</codeph> is a pointer to the HAL handler function. </p> </li>
+<li id="GUID-195CE0E3-9658-51D4-B5FA-10B0263FBE60"><p> <codeph>ptr</codeph> is a pointer that is passed to the HAL handler function when it
+is called. This is usually a pointer to an object that can handle
+the specified HAL attribute. </p> </li>
+</ul> <p><note> A group can only have one handler, any attempt to
+register another handler returns an error. Typically, a driver will
+register its handler during its initialisation phase. </note></p> <p>Nearly all the functionality of the template screen driver is implemented
+in a single class, the LCD power handler object; its <codeph>DLcdPowerHandler::Create()</codeph> function is called as part of startup processing. It is this function
+that registers the HAL handler: </p> <codeblock id="GUID-09BCD8E9-60DB-5805-9A32-F5652C434AEE" xml:space="preserve">...
+// install the HAL function
+r=Kern::AddHalEntry(EHalGroupDisplay,halFunction,this);
+if (r!=KErrNone)
+    return r;
+...
+</codeblock> <p>Note that the third parameter is, in general, an optional
+pointer. It is a pointer to the current object, i.e. the <codeph>DLcdPowerHandler</codeph> object. It is this pointer that is passed on to the HAL handler
+function as its first argument. </p> </section>
+<section id="GUID-DAE573D1-EAA1-530F-93D4-0F4F8BC7EA60"><title>Common
+implementation pattern</title> <p>Using the template screen driver
+as an example, the driver provides the HAL handler for dealing with
+information related to the display HAL group, <xref href="GUID-7F299BFC-D8A5-3A5A-B8DA-39BF42C99DC6.dita"><apiname>EHalGroupDisplay</apiname></xref>. The HAL handler is the function: </p> <codeblock id="GUID-646A151D-79E3-54A8-8D52-D732C3E5F5AE" xml:space="preserve">LOCAL_C TInt halFunction(TAny* aPtr, TInt aFunction, TAny* a1, TAny* a2)
+    {
+    DLcdPowerHandler* pH=(DLcdPowerHandler*)aPtr;
+    return pH-&gt;HalFunction(aFunction,a1,a2);
+    }
+</codeblock> <p>This is a stand-alone function. The first parameter <codeph>aPtr</codeph> is the pointer that was originally passed to the kernel
+when the HAL handler was registered via the <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-8C8DCE9D-0094-3909-8FDA-2F3134D0BC88"><apiname>Kern::AddHalEntry()</apiname></xref> call, and in this case, points to the LCD's power handler object.
+In this example, the main implementation of the HAL handler is the
+member function <codeph>HalFunction()</codeph> of the <codeph>DLcdPowerHandler</codeph> instance. </p> <p>Whether you use this kind of technique depends
+on the way your drivers are implemented, but it is a pattern that
+is also used by the digitiser and the keyboard driver, as well as
+by the Symbian implemented HAL handlers. </p> <p>The other parameters
+passed to the HAL handler function, i.e. <codeph>aFunction</codeph>, <codeph>a1</codeph>, and <codeph>a2</codeph> are the ones passed
+into a call to <xref href="GUID-9EF04FB9-B36F-3A6F-AF3F-F2238BD181E9.dita#GUID-9EF04FB9-B36F-3A6F-AF3F-F2238BD181E9/GUID-7F07C14C-E69A-3277-8BFF-0CE2A820166D"><apiname>UserSvr::HalFunction()</apiname></xref>, which itself
+is called by the various accessory functions; see <xref href="GUID-9D4B8CDF-60D7-5952-AAAF-94A3C1E8908F.dita">the Architecture</xref> of User-Side Hardware Abstraction (HAL) component. </p> <p>It's useful to note that a single HAL handler may end up being
+called as a result of calls to different accessory functions. For
+example, <codeph>ProcessDisplayCurrentModeInfo()</codeph> and <codeph>GetBacklightPresent()</codeph> are accessory functions that result
+in a call to the screen driver's HAL handler. </p> <p>To further distinguish
+between the different characteristics represented by a group, each
+group has an associated set of function-ids. The function id is the
+second parameter passed to the HAL handler function, and the most
+common pattern for an implementation is to code a simple switch statement
+based on this value. For example, the function-ids associated with
+the <xref href="GUID-7F299BFC-D8A5-3A5A-B8DA-39BF42C99DC6.dita"><apiname>EHalGroupDisplay</apiname></xref> are represented by the set
+of enum values defined by the <xref href="GUID-BB011D9B-105F-345C-9FC0-39B0BA509394.dita"><apiname>TDisplayHalFunction</apiname></xref> enum. This is a fragment taken from the template screen driver: </p> <codeblock id="GUID-F1CA7147-4659-572E-8AEB-437B7E9CA2CF" xml:space="preserve">TInt DLcdPowerHandler::HalFunction(TInt aFunction, TAny* a1, TAny* a2)
+    {
+    TInt r=KErrNone;
+    switch(aFunction)
+        {
+        case EDisplayHalScreenInfo:
+            {
+            TPckgBuf&lt;TScreenInfoV01&gt; vPckg;
+            ScreenInfo(vPckg());
+            Kern::InfoCopy(*(TDes8*)a1,vPckg);
+            break;
+            }
+
+        case EDisplayHalWsRegisterSwitchOnScreenHandling:
+            iWsSwitchOnScreen=(TBool)a1;
+            break;
+        
+        case EDisplayHalWsSwitchOnScreen:
+            WsSwitchOnScreen();
+            break;
+        
+        case EDisplayHalMaxDisplayContrast:
+            {
+            TInt mc=KMaxDisplayContrast;
+            kumemput32(a1,&amp;mc,sizeof(mc));
+            break;
+            }
+        ...
+        default:
+            r=KErrNotSupported;
+            break;
+        }
+    ...
+    }</codeblock> <p>If the HAL handler function does not deal with
+a specific function-id, then it returns <codeph>KErrNotSupported</codeph>. </p> <p>The meaning of the parameters <codeph>a1</codeph> and <codeph>a2</codeph> passed to the HAL handler depends on the group and function-id;
+see the list: <xref href="GUID-857F981E-711B-5CA8-AB37-5C700A6140FA.dita">HAL Groups and Handlers</xref> and <xref href="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita">HAL Attributes and
+Function IDs</xref> for the more detail. </p> <p id="GUID-D75D3A65-590D-5716-84A7-0195DFCD1656"><b>Dealing with the
+HAL::GetAll() function</b> </p> <p>Calls that come through the <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-EF03B832-E9AA-32CF-903F-DFFA63A3E9AB"><apiname>HAL::GetAll()</apiname></xref> function must be dealt with by the HAL handler
+implementation in a particular way. </p> <p> <codeph>GetAll()</codeph> calls the HAL handler and passes -1. The HAL handler must return
+the HAL attribute value when it is passed a -1 as its parameter unless
+the handler requires additional parameters. If the handler expects
+more than one parameter then it must return the error code <codeph>KErrArgument</codeph>. </p> <p>For example, using a <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-573C49D6-7763-37AE-B2B2-4C8FB1327E21"><apiname>HAL::Get()</apiname></xref> request with the attribute <xref href="GUID-DEEDAD63-57EB-3FFC-9D1C-5AD32C424879.dita"><apiname>EDisplayBrightness</apiname></xref> returns the brightness for the <i>specified</i> device (screen). </p> <codeblock id="GUID-27357ABD-D38C-5B09-85B7-3B33440FC911" xml:space="preserve">HALArg = 0;
+ret = HAL::Get(screen, HAL::EDisplayBrightness, HALArg);</codeblock> <p>The information cannot be retrieved by the <codeph>GetAll()</codeph> function. </p> <p>When the HAL handler is expecting a value that
+specifies a particular mode or setting but receives a -1 the HAL handler
+must return the error code <xref href="GUID-0BEA3647-7888-3612-A2D3-7E27AC405E29.dita"><apiname>KErrArgument</apiname></xref> to indicate
+that an additional parameter was expected. </p><p>See <xref href="GUID-85AB6B6F-216E-3716-8A86-D0C44EE8008E.dita"><apiname>&gt;THalImplementation</apiname></xref> and <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-EF03B832-E9AA-32CF-903F-DFFA63A3E9AB"><apiname>HAL::GetAll()</apiname></xref>.</p> </section>
+<section id="GUID-01D6179B-F1B6-5186-A96E-A1A5EDDC7A7A"><title>Context
+of the call to the HAL handler</title> <p>The HAL handler itself is
+only called by the kernel, and is the end result of a sequence that
+starts either with a call to the user interface functions provided
+by the HAL class (<xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-9454F1B2-D525-3D6D-A872-C6457CACD4FC"><apiname>HAL::Set()</apiname></xref>, <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-573C49D6-7763-37AE-B2B2-4C8FB1327E21"><apiname>HAL::Get()</apiname></xref> or <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-EF03B832-E9AA-32CF-903F-DFFA63A3E9AB"><apiname>HAL::GetAll()</apiname></xref>), or with a call to the kernel
+side <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-DA115709-A225-3E2A-BCCD-6E2BB15979B9"><apiname>Kern::HalFunction()</apiname></xref>. </p> <p>The handler runs
+on the kernel side in the context of the calling thread with no kernel
+mutexes or fast mutexes held; the calling thread is not placed into
+a critical section. It is the responsibility of the handler to do
+any thread synchronisation required. The handler returns a <xref href="GUID-7A2A43EC-6125-3BFE-834B-23C37F7B40D5.dita"><apiname>TInt</apiname></xref>, which is passed back to the user side, or the caller
+of <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-DA115709-A225-3E2A-BCCD-6E2BB15979B9"><apiname>Kern::HalFunction()</apiname></xref>. </p> </section>
+<section id="GUID-9C3570E1-50F6-5178-B9A1-99BCBB01ECA3"><title>Platform
+security</title> <p>If you are providing or porting a HAL handler,
+you need to be aware of platform security issues. In principle, for
+each call into the HAL handler, you need to check the capabilities
+of the caller's process. </p> <p>Recall that <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-366CC4B8-C6BD-5DCC-B55D-6D87CD5C8E64">function-ids</xref> are used to distinguish between the different
+requests made on a given HAL handler. Different requests may require
+different capabilities, although many requests require no special
+capabilities. This means that each function-id is associated with
+a capability, and means that code that is dealing with a request associated
+with a specific function-id, must check the associated capability. </p> <p>For example, the screen (i.e. video or LCD) driver must check
+that the caller has the <xref href="GUID-C607209F-6FC5-31DE-8034-E5B799B857A8.dita"><apiname>ECapabilityWriteDeviceData</apiname></xref> capability before proceeding with a request to set the device's
+backlight on. This is a capability that grants write access to settings
+that control the behaviour of the device. </p> <codeblock id="GUID-AC4567DA-400E-53FB-8D90-E3D537AF68A3" xml:space="preserve">TInt DLcdPowerHandler::HalFunction(TInt aFunction, TAny* a1, TAny* a2)
+    {
+    TInt r=KErrNone;
+    switch(aFunction)
+        {
+        ...
+        case EDisplayHalSetBacklightOn:
+        if(!Kern::CurrentThreadHasCapability(ECapabilityWriteDeviceData,__PLATSEC_DIAGNOSTIC_STRING("Checked by Hal function EDisplayHalSetBacklightOn")))
+            {
+            return KErrPermissionDenied;
+            )
+        ...
+        break;
+        ...
+    }</codeblock> <p>To find the capabilities associated with function-ids,
+see the <xref href="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita">HAL
+Attributes and Related Function IDs Tables</xref> section. Capabilities
+are documented as part of the API reference for each function-id. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-12A4418A-9BC6-4BEB-993D-B55E61240A15.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,342 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-12A4418A-9BC6-4BEB-993D-B55E61240A15" xml:lang="en"><title>SDIO
+Client Interface Guide</title><shortdesc>Describes how to use the SDIO interface in a device driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This is a generic description of how to use SDIO in a kernel-side device
+driver. Specifics differ according to hardware and card function.</p>
+<section id="GUID-F6EC5141-075B-4B9A-8207-330FA8EC696A"><title>Socket, stack,
+card and function</title>       <p>SDIO is an input/output protocol originally
+introduced to enable a device to communicate with SDIO (Secure Digital) cards.
+It can also be used as input/output for media such as Bluetooth adapters and
+GPS receivers and for input/output within a device (for instance to talk to
+an internal bus). These different uses of SDIO are called functions.</p><p>Symbian
+platform implements SDIO as part of a larger framework involving SD cards,
+which are a type of MMC (multimedia) card. For this reason, to use SDIO in
+a device driver you will need to use classes representing SD and MMC cards
+and the associated communications stack even if you only want the basic I/O
+functionality. These classes are:</p><ul>
+<li><p><xref href="GUID-45B97680-1756-3559-8A2D-2F2E851AD6A7.dita"><apiname>DMMCSocket</apiname></xref></p></li>
+<li><p><xref href="GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91.dita"><apiname>DSDIOStack</apiname></xref></p></li>
+<li><p><xref href="GUID-731522ED-8259-3CBA-9AD3-09DDAE23257D.dita"><apiname>TSDIOCard</apiname></xref></p></li>
+<li><p><xref href="GUID-1342EC36-363F-3E7D-9B5F-4AFD3BAC98C8.dita"><apiname>TSDIOFunction</apiname></xref></p></li>
+</ul><p>The work of data transfer is performed by reading to and writing from
+registers in response to interrupts, and sometimes the read and write operations
+are performed in sessions. The classes used are these:</p><ul>
+<li><p><xref href="GUID-CC5352E2-DB21-393F-A7A4-108AA3684460.dita"><apiname>DSDIORegInterface</apiname></xref></p></li>
+<li><p><xref href="GUID-5A5218D4-E8AD-322F-BE5B-597137623B3F.dita"><apiname>TSDIOInterrupt</apiname></xref></p></li>
+<li><p><xref href="GUID-36C5854E-6FD4-3630-9FF9-7DB3D578F9BD.dita"><apiname>DSDIOSession</apiname></xref></p></li>
+</ul><p>This document illustrates the use of these classes to create a driver,
+with example code fragments in which the driver being created is called <codeph>DSDIODriver</codeph>.</p> 
+   </section>
+<section id="GUID-6C842F3D-12E5-44A3-8284-4BD8C1770B08"><title>Creation and
+initialization</title><p>The first step in writing a driver using SDIO is
+thus to create socket, stack and card objects.</p><codeblock xml:space="preserve">	DMMCSocket* iSocket = static_cast&lt;DMMCSocket&gt;DPBusSocket::SocketFromId(KSocketNumber));
+	if (NULL == iSocket)
+		return KErrNoMemory;
+
+	DMMCStack* iStack = static_cast&lt;DSDIOStack*&gt;(iSocket-&gt;Stack(KStackNumber));
+	if (NULL == iStack)
+		return KErrNoMemory;
+
+	TSDIOCard* iCard = static_cast&lt;TSDIOCard*&gt;(iStack-&gt;CardP(KCardNumber));
+	if (NULL == iCard)
+		return KErrNoMemory;
+
+</codeblock></section>
+<section id="GUID-6046097E-372A-4C06-941F-C37280668FDD"><title>Function types</title><p>The
+functions supported by SDIO are represented by the enumeration <xref href="GUID-14307AD8-424C-3AEC-964F-0488DE751CBA.dita"><apiname>TSdioFunctionType</apiname></xref><codeph/> which
+is declared in the <xref href="GUID-B05522D8-A05B-334F-AA92-05FDC2451000.dita"><apiname>TSdioFunctionCaps</apiname></xref> class. </p><codeblock xml:space="preserve">enum TSdioFunctionType
+	{
+	/** Not an SDIO standard interface */
+	ESdioFunctionTypeUnknown  = 0,
+	/** SDIO UART standard interface */
+	ESdioFunctionTypeUART	  = 1,
+	/** SDIO 'thin' Bluetooth standard interface */
+	ESdioFunctionTypeThinBT	  = 2,
+	/** SDIO 'complete' Bluetooth standard interface */
+	ESdioFunctionTypeFullBT	  = 3,
+	/** SDIO GPS standard interface */
+	ESdioFunctionTypeGPS	  = 4,
+	/** SDIO Camera standard interface */
+	ESdioFunctionTypeCamera	  = 5,
+	/** SDIO PHS Radio standard interface */
+	ESdioFunctionTypePHS	  = 6,
+	/** SDIO WLAN standard interface (Introduced in SDIO Rev. 1.10f) */
+	ESdioFunctionTypeWLAN	  = 7,
+	/** Extended SDIO standard interface (Introduced in SDIO Rev. 1.10f) */
+	ESdioFunctionTypeExtended = 15,
+	};
+</codeblock></section>
+<section id="GUID-8B81F9BF-167E-4E94-A019-E90EA8281319"><title>Kernel polling</title><p>Kernel
+polling means the use of the <codeph>Kern::PollingWait()</codeph> function
+of the kernel to call a function repeatedly if it is likely to fail on a first
+try. You specify the number of attempts and the delay between them as parameters.
+It is a recommended technique in writing kernel drivers and is used more than
+once in the example code in this document. </p></section>
+<section id="GUID-1784014E-0352-408E-8BDD-EF27F53AF17C"><title>Initialization</title><p>To
+initialize the card you must power it up and test whether it is ready for
+use. The following code uses kernel polling to perform the test 10 times at
+100 millisecond intervals.</p><codeblock xml:space="preserve">	…
+	iSocket-&gt;PowerUp();
+	Kern::PollingWait(CardReady, iCard, 100, 10);
+
+	if (!iCard-&gt;IsReady())
+		return(KErrNotReady);
+	…
+
+
+TBool DSDIODriver::CardReady(TAny* aSelfP)
+	{
+	TSDIOCard&amp; card = *(TSDIOCard*)aSelfP;
+	return card.IsReady();
+	}
+</codeblock><p>You may also want to test that the card is an SDIO card.</p><codeblock xml:space="preserve">	if (!pCard-&gt;IsIOCard())
+		return KErrNotReady;
+</codeblock><p>Next you locate and enable the function of the card (Bluetooth,
+UART etc.) which you want to use. A function has a location which differs
+from card to card and which is stored in a data structure called the CIS (Card
+Information Structure. To use a card's CIS you load it using the <xref href="GUID-98450844-1ED3-3696-B1A6-C1A97AED83A9.dita"><apiname>CheckCis()</apiname></xref> function
+of the <xref href="GUID-731522ED-8259-3CBA-9AD3-09DDAE23257D.dita"><apiname>TSDIOCard</apiname></xref> class.</p><codeblock xml:space="preserve">	TInt err = iCard-&gt;CheckCIS();
+	if (KErrNone != err)
+		return err;
+</codeblock><p>The following code is a simple test to determine whether the
+passed in function type is present on the card.</p><codeblock xml:space="preserve">TSDIOFunction* DSdioDriver::FindFunction(TSdioFunctionType aFunctionType)
+	{
+	// We are going to try to match the function type
+	TUint32 capsMatchMask = TSDIOFunctionCaps::EFunctionType; 
+
+	// Create the caps specification for a BT function
+	TSDIOFunctionCaps functionCaps;
+	functionCaps.iType = aFunctionType;
+ 
+	// Request to find the function on the card
+	TSDIOFunction* pFunction = iCard-&gt;FindFunction(functionCaps, capsMatchMask);
+
+	// If the function cannot be found, pFunction will be NULL
+
+	return pFunction;
+	}
+</codeblock><p>Once you have the location of a function, you register the
+client driver with the stack and enable the function on the card.</p><codeblock xml:space="preserve">	TInt err = iFunction-&gt;RegisterClient(this);
+	if (err != KErrNone)
+		{
+		return err;
+		}
+
+	// Enable the function
+	err = iFunction-&gt;Enable(ETrue);  
+	
+	if (KErrNone == err)
+		{
+		Kern::PollingWait(FunctionReady, this, 100, 10);
+		}
+
+	TBool isReady = EFalse;
+	iFunction-&gt;IsReady(isReady);
+	If (!isReady)
+		return KErrNotReady;
+	…
+
+
+TBool DSdioDriver::FunctionReady(TAny* aSelfP)
+	{
+	TSDIOFunction* pFunction = (TSDIOFunction*)aSelfP;
+	TBool isReady = EFalse;
+	pFunction-&gt;IsReady(isReady);
+	return isReady;
+	}
+</codeblock></section>
+<section id="GUID-44B9EA31-9BDD-4181-BF2F-FF80F5EDCE32"><title>Transferring
+data: registers and shared chunks</title><p>SDIO cards place data to be read
+or written in a register whose address depends on the function and is defined
+in the relevant specification available at <xref href="http://www.sdcard.org/home/" scope="external">www.sdcard.org</xref>. Registers are also used to send commands
+to the card and to enable or disable interrupts. You access the register for
+a function using the <xref href="GUID-6BD11B5F-2269-3317-A40D-6547042CA463.dita"><apiname>DSDIORegisterInterface</apiname></xref> class which
+is obtained from the function pointer like this.</p><p/><codeblock xml:space="preserve">		// Get the register interface
+		DSDIORegisterInterface* pRegIfc = iFunction-&gt;RegisterInterface(this);
+</codeblock><p>Data can be transferred.</p><ul>
+<li><p>as individual bytes,</p></li>
+<li><p>as the contents of byte buffers (both directly and using shared chunks),
+and</p></li>
+<li><p>by setting bits in the register.</p></li>
+</ul><p>The following code uses the <xref href="GUID-53280C38-1734-332D-A432-0A56AB16CD04.dita"><apiname>Read8()</apiname></xref> and <xref href="GUID-BF2E636A-FA49-39F6-9A52-A09E4879F3FC.dita"><apiname>Write8()</apiname></xref> functions
+of the <xref href="GUID-6BD11B5F-2269-3317-A40D-6547042CA463.dita"><apiname>DSDIORegisterInterface</apiname></xref> class to read and write a
+single byte from and to the card function. You typically set registers on
+the card and enable interrupts by this method.</p><codeblock xml:space="preserve">	TUint8 readVal = 0;
+	TInt ret = pRegIfc-&gt;Read8(KReadRegister, &amp;readVal);
+	if (KErrNone != ret)
+		return ret;
+	
+	TUint8 writeVal = readVal + 1;
+	ret = pRegIfc-&gt;Write8(KWriteRegister, writeVal);
+	if (KErrNone != ret)
+		return ret;
+</codeblock><p>This code demonstrates the use of the <xref href="GUID-2E0277CD-3CB8-3A8C-AAD3-8083E8BA7B60.dita"><apiname>ReadMultiple8()</apiname></xref> and <xref href="GUID-F29DFD6B-9CA4-3170-B829-F3881B152614.dita"><apiname>WriteMultiple8()</apiname></xref> functions
+to read to and write from byte buffers.</p><codeblock xml:space="preserve">	TUint8 client[6];
+	memcpy(client, “client”, 6);
+	TInt ret = pRegIfc-&gt;WriteMultiple8(KWriteRegister, client, 6);
+	if (KErrNone != ret)
+		return ret;
+
+	TUint8 server[6];	
+	ret = pRegIfc-&gt;ReadMultiple8(KReadRegister, server, 6);
+	if (KErrNone != ret)
+		return ret;
+
+	if (memcmp(server, “server”) != 0)
+		return KErrNotFound;
+</codeblock><p>When large amounts of data are being transferred it is good
+practice to use a shared chunk. You call the same functions as before with
+the chunk as additional argument. The following example writes 1024 bytes
+with an offset of zero and reads 1024 bytes with an offset of 1024.</p><codeblock xml:space="preserve">	TInt ret = pRegIfc-&gt;WriteMultiple8(KWriteRegister, chunk, 0, 1024);
+	if (KErrNone != ret)
+		return ret;
+
+	ret = pRegIfc-&gt;ReadMultiple8(KReadRegister, chunk, 1024, 1024);
+	if (KErrNone != ret)
+		return ret;
+</codeblock><p>The advantages of shared chunks are that they can be used from
+user space and reduce copying overhead.</p><p>The following code example shows
+how to set and clear bits in a register using the <xref href="GUID-312948B9-5338-3030-9130-821E9BDDCE62.dita"><apiname>Modify8()</apiname></xref> function
+of the <xref href="GUID-6BD11B5F-2269-3317-A40D-6547042CA463.dita"><apiname>DSDIORegisterInterface</apiname></xref> class</p><codeblock xml:space="preserve">	TUint8 setBits = 0x80;
+	TUint8 clearBis = 0x02;
+
+	ret = pRegIfc-&gt;Modify8(KModifyRegister, setBits, clearBits);
+	if (KErrNone != ret)
+		return ret;
+</codeblock><p>Another advantage of shared chunks is that they make it possible
+to send commands to the card while a multibyte data transfer is taking place.
+Not all cards support this functionality: you can check whether a particular
+card does so by reading the SDC bit in the Card Capability register. To do
+this, you need to create a second register interface to write the commands
+in the form of one byte transfers. This second interface (or 'second session')
+must run in a different thread from the interface performing the multibyte
+transfer and it is created in a different way, as in this code:</p><codeblock xml:space="preserve">	// Create a second session
+	DSDIORegisterInterface* interfaceP = new DSDIORegisterInterface(cardP, functionP-&gt;FunctionNumber());
+
+	// Using the second interface run a direct command 
+	TUint8 readVal = 0;
+	ret = interfaceP-&gt;Read8(KReadRegister, &amp;readVal);
+	
+	…
+</codeblock></section>
+<section id="GUID-11562A70-49EF-49BE-9323-6E1E69433907"><title>Controlling
+data transfer: interrupts</title><p>Cards generate interrupts which control
+the process of data transfer: for instance the arrival of data on the function
+of a card generates an interrupt which serves as a signal that a read operation
+should take place. The are two levels of interrupts. A card level interrupt
+indicates which function has triggered it and a separate function level interrupt
+gives information specific to that function which is covered in the documentation
+for a particular card.</p><p>You must provide ISRs (interrupt service routines)
+to handle interrupts. ISRs typically queue DFCs to perform the required actions
+such as read and write operations on the card since ISRs must complete very
+quickly to maintain real-time guarantees whereas data transfer can wait for
+the current time slice to complete. The exact functionality of the DFCs will
+vary depending on the nature of the function and the hardware. Two things
+you must do in any driver implementation are enabling and disabling interrupts
+and binding the ISRs to the stack. Also, when an interrupt is triggered you
+must read the interrupt register to make sure that the interrupt is applicable
+and then clear the function level interrupt and re-enable interrupts.</p><p>You
+enable card level interrupts as in this example code:</p><codeblock xml:space="preserve">	// Enable SDIO card interrupt
+	iFunction-&gt;Interrupt().Enable();
+
+	// Disable SDIO card interrupt
+	iFunction-&gt;Interrupt().Disable();
+</codeblock><p>How you enable function level interrupts is described in the
+documentation for a particular card.</p><p>You bind ISRs to the stack as in
+the following code fragment. </p><codeblock xml:space="preserve">	…
+	// Bind to interrupt
+	err = iFunction-&gt;Interrupt().Bind(DSDIODriver::Isr, this);
+	if (KErrNone != err)
+		return err;
+
+	…
+
+void DSDIODriver::Isr(TAny* aParam)
+	{
+	DSDIODriver* pDriver = (DSDIODriver*)aParam;
+	…
+	}
+</codeblock></section>
+<section id="GUID-458DACCF-1FAD-4F2A-8D79-AD3B77BE75F0"><title>Notifications
+and powering down: callbacks</title><p>Register callbacks to be notified of
+events. This mechanism is standard for handling the removal of a card and
+powering down.</p><p>The SDIO stack can notify clients of events they must
+react to such as power down or the removal of the card. Events of this kind
+are listed in the enumeration <xref href="GUID-84D32429-8E04-39BA-A032-478976C7991C.dita"><apiname>TSDIOFunctionCallbackReason</apiname></xref>.</p><codeblock xml:space="preserve">enum TSDIOFunctionCallbackReason
+	{
+	/** Card has powered up */
+	ESdioNotifyPowerUp			 	 	= 0,
+	/** Card requests to power down */
+	ESdioNotifyPowerDownPending	  	= 1,
+	/** Card has powered down */
+	ESdioNotifyPowerDown		  			= 2,
+	/** Request to enter sleep mode */
+	ESdioNotifyPowerSleep		  	= 3,
+	/** Emergency power down */
+	ESdioNotifyEmergencyPowerDown 	= 4,
+	/** PSU fault */
+	ESdioNotifyPsuFault			  	= 5,
+	/** Card has been removed */
+	ESdioNotifyCardRemoved		  	= 6,
+	/** Card has been inserted */
+	ESdioNotifyCardInserted		  	= 7,
+	};
+</codeblock><p>You respond to notifications with callback functions which
+you write to provide appropriate functionality. Use the callback to initialize
+a <xref href="GUID-C07575EE-FCAA-3050-89F3-F0DF8EF8D122.dita"><apiname>TSDIOFunctionCallback</apiname></xref> object and then register that object
+with the socket. The following code uses an example callback <codeph>FnCallback()</codeph> and
+object <codeph>functionCallback</codeph>.</p><codeblock xml:space="preserve">	TSDIOFunctionCallback functionCallback(DSDIODriver::FnCallback, this);
+
+	// Register the callback
+	functionCallback.Register(iSocket);
+	…
+
+TInt DSDIODriver::FnCallback(TAny* aParam, TSDIOFunctionCallbackReason aReason)
+	{
+	DSDIODriver* pDriver = (DSDIODriver*)aParam;
+
+	switch(aReason)
+		{
+		case ESdioNotifyCardRemoved:
+			…
+			break;
+		}
+	…
+	}
+</codeblock><p>You typically use notifications and callbacks to perform cleanup
+before a pending power down event. The socket class has functions to postpone
+power down at the start of cleanup and to resume power down when cleanup is
+finished. They are used like this.</p><codeblock xml:space="preserve">	iSocket-&gt;RequestAsyncPowerDown();
+
+/* cleanup code here */
+	iSocket-&gt;PowerDownComplete();</codeblock></section>
+<section id="GUID-44A3E6CC-8EF1-45B5-92B9-3F440DC6791B"><title>Tutorials</title>The
+classes and commands used to create a device driver are discussed further
+in the tutorials.<ul>
+<li><p><xref href="GUID-2607CCFA-3D24-4716-A447-74304F861C44.dita">DSDIOREGInterface
+Class Tutorial</xref></p></li>
+<li><p><xref href="GUID-360DEB3A-3E38-413A-9941-6C758BA01ADE.dita">DSDIOSession
+Class Tutorial</xref></p></li>
+<li><p><xref href="GUID-E1277A18-7201-4856-8712-067022F92123.dita">DSDIOStack Class
+Tutorial</xref></p></li>
+<li><p><xref href="GUID-BA3B42A2-141C-49D9-B513-1571C246C19B.dita">TSDIOCard Class
+Tutorial</xref></p></li>
+<li><p><xref href="GUID-C57086D7-7672-4A52-8634-D28B37AC6290.dita">TSDIOFunction
+Class Tutorial</xref></p></li>
+<li><p><xref href="GUID-535C66C9-8B45-4DF3-8404-8ED03ABB4799-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1.dita">TSDIOInterrupt
+Class Tutorial</xref></p></li>
+<li><p><xref href="GUID-BDF1F32B-796B-4D3D-9C91-43FF8E9DDAF9.dita">SDIO Commands
+Tutorial</xref></p></li>
+</ul><p>A reference implementation using Bluetooth is described in <xref href="GUID-53A6E46C-E961-47C7-A5FA-CB0B52266646.dita">SDIO
+BT Example</xref>.</p></section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-12CD8E91-4102-5253-A7DE-E5436028764F-master.png has changed
Binary file Adaptation/GUID-12CD8E91-4102-5253-A7DE-E5436028764F_d0e18431_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-12EFB295-C527-5F96-81F1-6021D335D865.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,57 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-12EFB295-C527-5F96-81F1-6021D335D865" xml:lang="en"><title>Thread
+Termination</title><shortdesc>This topic describes how and in what conditions to kill a kernel
+side thread. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The only way to kill a kernel side thread is for code running in that thread
+to call <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-808B3622-BDC4-376D-96E9-16281BA28AF8"><apiname>Kern::Exit()</apiname></xref>. </p>
+<p>A kernel side thread can kill itself, but cannot kill any other kernel
+side thread. This avoids the overhead of critical sections. Remember that
+a kernel side thread <i>can</i> kill a user side thread. </p>
+<p>In practice, device drivers will create threads that can run queued DFCs
+(Deferred Function Calls) only if they choose not to use the two supplied
+DFC threads, known as DFC thread 0 and DFC thread 1. </p>
+<section id="GUID-A5B308C7-21CE-437E-A033-A373E1E2FE78"><title>How to kill a thread running queued DFCs</title> <p>In principle
+the only way to kill a thread that runs queued DFCs is to schedule a DFC that
+simply calls <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-808B3622-BDC4-376D-96E9-16281BA28AF8"><apiname>Kern::Exit()</apiname></xref>. The DFC should have priority
+0 (the lowest). We refer to this as a 'kill' DFC. </p> <p>In practice you
+create a 'kill' DFC by creating a <xref href="GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB.dita"><apiname>TDfc</apiname></xref> object, and then
+make the DFC's callback function include a call to <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-808B3622-BDC4-376D-96E9-16281BA28AF8"><apiname>Kern::Exit()</apiname></xref>.
+You then queue the DFC onto the DFC queue, a <xref href="GUID-24B2FEDB-9273-351F-A1C6-6F5F91BF83B7.dita"><apiname>TDfcQue</apiname></xref> object,
+from the destructor of the logical device driver's factory class, i.e. the
+destructor of the class derived from <xref href="GUID-7616AA05-83E6-3989-AB9D-11AE01245BEB.dita"><apiname>DLogicalDevice</apiname></xref>. </p> </section>
+<section id="GUID-3DB34648-94EC-4AF4-9550-EF7753FC18BE"><title>Issues to be aware of</title> <ol id="GUID-6335774D-CEDB-52AE-BBED-AFA7CB55DFF5">
+<li id="GUID-0573932A-B43C-50B0-9458-B213A6C4346F"><p>You need to make sure
+that no other DFCs are on that DFC queue at the time that the 'kill' DFC runs
+as there is no automatic cleanup. </p> <p>Perform cleanup by calling <codeph>Cancel()</codeph> (i.e. <xref href="GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB.dita#GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB/GUID-9851B90B-8D05-3C86-B083-44C4564AC140"><apiname>TDfc::Cancel()</apiname></xref>)
+on all queued DFCs. </p> </li>
+<li id="GUID-F9D0239F-9174-54B5-B39B-5D1E54FF6EF5"><p>You need to make sure
+that the DFC queue object, i.e. the <xref href="GUID-24B2FEDB-9273-351F-A1C6-6F5F91BF83B7.dita"><apiname>TDfcQue</apiname></xref> object, and
+the 'kill' DFC object, i.e. the <xref href="GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB.dita"><apiname>TDfc</apiname></xref> object, are not destroyed
+before the 'kill' DFC has a chance to run. </p> <p>You can do this by making
+both the DFC queue object and the 'kill' DFC object static objects within
+the driver. The device driver will only be unloaded from RAM by the null thread.
+By queuing the 'kill' DFC on the DFC thread, you mark it ready-to-run, which
+means that your 'kill' DFC will run before the driver is unloaded and before
+the DFC queue object and the 'kill' DFC object vanish. </p> </li>
+<li id="GUID-29195090-756E-5FB7-BF78-0F6C6C5A7983"><p>You need to make sure
+that any code queued to run on your DFC thread never hangs. </p> <p>The important
+point is that <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-808B3622-BDC4-376D-96E9-16281BA28AF8"><apiname>Kern::Exit()</apiname></xref> can only be used by the thread
+itself, but if the thread hangs, then it can execute nothing. This means that
+kernel side threads must be written very carefully so they cannot hang. Any
+defect in kernel side code is likely to be fatal. </p> <p>It may be that you
+have to consider writing defensive style code; for example, if your thread
+is waiting for an event, you could consider using a timer to wake it up in
+case the expected event never happens. Alternatively, you could consider moving
+some processing to the user side. </p> </li>
+</ol> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-132349A6-9A5F-4866-A54D-F01B6F58ABDD.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-132349A6-9A5F-4866-A54D-F01B6F58ABDD" xml:lang="en"><title>Shared
+Chunks</title><shortdesc>This document describes the use of shared chunks to share data.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-DBFFE006-4E6C-4B4C-9E50-0A9FC9CB51FF">       <title> Shared
+chunks</title>       <p>Device drivers often need to share data between user
+space and kernel space threads. Though there are APIs for doing this, such
+as <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-904A42A8-8077-3FC6-BEF2-29619F079842"><apiname>Kern::ThreadRawRead()</apiname></xref> and <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-182C88F4-326C-376E-9FBE-889E3CB9B68A"><apiname>Kern::ThreadRawWrite()</apiname></xref>,
+these involve an overhead of a memory copy, which can be a problem when there
+is a large amount of data. </p> <p>To avoid unnecessary data transfer, Symbian
+platform provides shared chunks, which are similar to shared memory in other
+operating systems. Shared chunks can be created and used by both a driver
+and user-side code directly. An example application for shared chunks is for
+a camera driver. Without shared chunks, the image data would have to be copied
+from the camera driver to the user process, which would then copy it to the
+display driver. This would have a high memory copy overhead. Using shared
+chunks instead would improve the performance of the camera view finder. </p> <p>A
+shared chunk is created and controlled by the kernel side code, for example,
+the device driver, rather than the user code. This memory is safe to be used
+by ISRs and DMA. A shared chunk can be mapped into multiple user processes
+in sequence or at the same time. The memory object can be transferred between
+another process and another device driver. Multiple drivers and multiple user
+processes can have access to the same shared chunk. </p>     </section>
+<section id="GUID-8C27DA12-5396-4229-8723-480D5846604C"><title>Comparison
+between shared memory and shared I/O buffers</title><p>The EKA1 versions of
+Symbian platform had a mechanism called shared I/O buffers. These are now
+deprecated, and shared chunks should be used instead. The disadvantage of
+a shared I/O buffer is that only one user process can access the chunk at
+a time, and that it does not have a user handle: the user process is only
+supplied with the address and size of the buffer. Shared chunks solve these
+issues, and give more flexibility for users to do safe operations. </p></section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-13664BB9-7D05-594E-95D4-49C0D31D3734-master.png has changed
Binary file Adaptation/GUID-13664BB9-7D05-594E-95D4-49C0D31D3734_d0e18989_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-1391CDCC-9A09-54FB-BA7D-BC7A91DB2351.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE task
+  PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
+<task id="GUID-1391CDCC-9A09-54FB-BA7D-BC7A91DB2351" xml:lang="en"><title>Writable Data Paging (WDP) Tutorial Overview</title><shortdesc>Collection of the tutorials related to writable data paging. </shortdesc><prolog><metadata><keywords/></metadata></prolog><related-links>
+<linklist>
+<desc> The following group of tutorials go through the stages required
+to produce a ROM image that can implement writable data paging and
+are in the  order of the top tutorial downwards:  </desc>
+<link href="GUID-16423056-C435-5C4D-BE3D-4A15F95F7F68.dita"><linktext>Configuration
+Tutorial</linktext></link>
+<link href="GUID-6EF762B8-DE93-51C0-8A5D-89FC5289B7D0.dita"><linktext>MMP
+Tutorial</linktext></link>
+<link href="GUID-4862EA2E-6BFE-5E11-B527-7EBA94BB0EA2.dita"><linktext>OBY
+Tutorial</linktext></link>
+<link href="GUID-6B9041F7-79A6-5CCA-9B4D-B8EF377FD378.dita"><linktext>Building
+ROM Tutorial</linktext></link>
+</linklist>
+<linklist>
+<desc>The next group of tutorials relate to producing device drivers
+that are compatible with writable data paging:  </desc>
+<link href="GUID-E7C55048-5B7A-5BF2-B7F4-4D731659B88C.dita"><linktext>Device
+Driver Writing and Migration Technology Tutorial</linktext></link>
+<link href="GUID-FBE6E61F-5A2E-5A7A-BC59-51F072EBED7D.dita"><linktext>Media
+Driver Migration Guide</linktext></link>
+</linklist>
+<linklist>
+<desc> The final group of tutorials relates to other issues that should
+be  considered when working with writable data paging:  </desc>
+<link href="GUID-44540C74-CD73-5D8E-A9E0-F90F46B4E7B1.dita"><linktext>Preventing
+And Recovering From Thrashing Tutorial</linktext></link>
+</linklist>
+</related-links></task>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-142C21E1-2629-5215-9FBD-B507436E17DB.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-142C21E1-2629-5215-9FBD-B507436E17DB" xml:lang="en"><title>Port
+Implementation Tutorial</title><shortdesc>This section describes the steps to implement a port of
+the USB client controller.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This guide uses the port for the template board as
+an example. Other porting example code is also available. </p>
+</conbody><related-links>
+<link href="GUID-796CB42C-29AC-5ECC-AC6E-35FC6B8CC84E.dita"><linktext>Concepts</linktext>
+</link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-1499E635-B6E3-51A0-AE38-ADF99FF86CD6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-1499E635-B6E3-51A0-AE38-ADF99FF86CD6" xml:lang="en"><title>Sound
+Driver LDD Overview</title><shortdesc>Describes the sound driver LDD part of the sound driver framework. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-0A84C890-65DD-46AE-BC8E-9020996D2899"><title>Purpose</title> <p>The sound driver provides the conduit by
+which Symbian platform can access the audio hardware and hence create sounds:
+for example multi-media applications and ring tones. </p> </section>
+<section id="GUID-2EBA51DD-5599-419C-A251-AB509CE3D407"><title>Required background</title> <p>Since audio hardware is rather
+complex, the reader of this document needs to know what is meant by: </p> <ul>
+<li id="GUID-43DF6FEB-6045-559A-97BC-1C0C20DE1AED"><p>Audio channels </p> </li>
+<li id="GUID-62FD63A2-2901-579E-A33B-D227C5543DDE"><p>Codec </p> </li>
+</ul> </section>
+<section id="GUID-00AD36A1-D39D-4F7F-B1A5-F4DB10487718"><title>Key concepts and terms</title> <dl>
+<dlentry>
+<dt>Codec</dt>
+<dd><p>Stands for COmpressor-DECompressor and refers to the algorithm used
+to compress and decompress the audio data stream. </p> </dd>
+</dlentry>
+</dl> </section>
+<section id="GUID-018D8B6C-D05C-474E-90A2-2B482636CA82"><title>Architecture</title> <p>The LDD for the sound driver sits
+below the <xref href="GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066.dita"><apiname>RBusLogicalChannel</apiname></xref> and the <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita"><apiname>RSoundSc</apiname></xref> classes. </p> <p>The
+communication between the driver and the application on the user-side is handled
+by class <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita"><apiname>RSoundSc</apiname></xref>. </p> </section>
+<section id="GUID-8E0A77A7-4514-44CA-A1B0-F26B7614E2FE"><title>APIs</title> <table id="GUID-56059B35-9466-5067-B136-9AC1D15D33AC">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<thead>
+<row>
+<entry>API</entry>
+<entry>Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita"><apiname>DSoundScLdd</apiname></xref>  </p> </entry>
+<entry><p>Defines each logical channel. One instance of this class is created
+for each driver channel opened. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-6B257FE9-F036-4808-A1A0-186964B25608"><title>Typical uses</title> <p>The sound driver is used whenever
+audio operations are required: for example MP3 player, having a phone call
+and ring tones. </p> <ul>
+<li id="GUID-931CC604-0C09-5990-9DDF-88AEA1086EFE"><p>MP3 player </p> </li>
+<li id="GUID-8680BFA5-52DE-58A3-88D1-24810DBA0BF5"><p>Multi-media </p> </li>
+</ul> </section>
+</conbody><related-links>
+<link href="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita"><linktext>Sound Driver
+Technology</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-14B65BE7-A166-48B6-B43D-DFF267F87F9E-master.png has changed
Binary file Adaptation/GUID-14B65BE7-A166-48B6-B43D-DFF267F87F9E_d0e433_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-159BDA2E-123C-52DF-9F8B-E058379EBFB8.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-159BDA2E-123C-52DF-9F8B-E058379EBFB8" xml:lang="en"><title>Interrupt::SetPriority()</title><shortdesc>The interrupt architecture supports the concept of adjustable
+interrupt priorities.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-FA4CFED7-D694-399C-8F84-FA9FE3C3A171"><apiname>Interrupt::SetPriority()</apiname></xref> function can be
+used to implement adjustable interrupt priorities. </p>
+<p>The function takes the <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-8E58F4C9-0290-55E0-A4FD-B6C2361BE205">Interrupt ID</xref> to identify the interrupt source, and a <xref href="GUID-7A2A43EC-6125-3BFE-834B-23C37F7B40D5.dita"><apiname>TInt</apiname></xref> value specifying the priority value. The meaning of
+the priority value is hardware and implementation dependent and is
+defined by the port. </p>
+<p>At its simplest, the function could be used to decide whether interrupts
+generate an IRQ or FIQ at the ARM. For hardware that supports interrupt
+priority in hardware, priorities can be modified through this function.
+If priority adjustment is not supported, or will not be implemented, <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-FA4CFED7-D694-399C-8F84-FA9FE3C3A171"><apiname>Interrupt::SetPriority()</apiname></xref> should just return <xref href="GUID-F89DA3F0-2A48-3F9B-8F08-29350E92D0E4.dita"><apiname>KErrNotSupported</apiname></xref>. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-15FDDEED-89F1-5BE5-97AD-8DFD3640369A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,101 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-15FDDEED-89F1-5BE5-97AD-8DFD3640369A" xml:lang="en"><title>Playback
+operation</title><shortdesc>Describes the operation of the Sound Driver for sound playback. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-AECB2CE7-CB57-4AB2-B030-62E0A65851C9"><title>Normal operation</title> <p>The client calls <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-DA119B93-6E4D-36DA-878A-D6709039E0EA"><apiname>RSoundSc::PlayData()</apiname></xref> to
+issue an audio request. </p> <p>The LDD breaks the audio request into manageable
+fragments and transfers them to the PDD by calling <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-8C79D09B-317A-3D8E-B9C2-474812F17529"><apiname>DSoundScPdd::TransferData()</apiname></xref>. </p> <p>When
+the PDD has transmitted the fragment it calls <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita#GUID-5807543D-A30F-3EB9-8F28-91A623B0D484/GUID-16853E0D-60E8-3BEC-9E3E-9563BA7CAECE"><apiname>DSoundScLdd::PlayCallback()</apiname></xref> to
+signal to the LDD that it has finished transfer of a fragment. When the client
+request has been completed, the LDD calls <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-FDBEFD98-EE11-3358-869C-DECC3B5CF83A"><apiname>DSoundScPdd::StopTransfer()</apiname></xref> to
+stop the PDD transmitting data and to release any transfer specific resources. </p> <p>To
+ensure uninterrupted playback, a client must have multiple play requests pending
+on the driver. As soon as one request completes, the client issues a further
+request until the end of the track. Typically, a client issues a series of
+calls to <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-DA119B93-6E4D-36DA-878A-D6709039E0EA"><apiname>RSoundSc::PlayData()</apiname></xref> to play an audio track. </p> <p>Each <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-DA119B93-6E4D-36DA-878A-D6709039E0EA"><apiname>RSoundSc::PlayData()</apiname></xref> request
+is handled in the context of the driver's Deferred Function Call (DFC) thread.
+Assuming that the driver is not already in the process of playing data when
+the first request is received, the LDD checks whether the client has specified
+or supplied a <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita">shared
+chunk</xref> to the <xref href="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita#GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6/GUID-4D6A01FE-47E7-5A6F-9DFE-F612B880165B">Driver
+channel</xref> and also whether the audio configuration and volume have both
+been set. If the chunk configuration has not been specified, then the driver
+cannot proceed and returns <codeph>KErrNotReady</codeph>. However, if the
+audio configuration or volume has not been specified, then the LDD simply
+applies default settings to the audio hardware device. These values are returned
+by the PDD functions <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-39AA2B2D-E98B-33A0-9C46-08B783413860"><apiname>DSoundScPdd::SetConfig()</apiname></xref> and <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-D893A29B-1A4B-35AF-876B-84D74B7E783C"><apiname>DSoundScPdd::SetVolume()</apiname></xref> when
+called by the LDD. </p> <p>The LDD may need to break the play request down
+into fragments to support the maximum amount of data that the PDD can handle
+in a single transfer. The function <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-534D46F4-2CB1-3130-9E72-A1C3BF085865"><apiname>DSoundScPdd::MaxTransferLen()</apiname></xref> returns
+this maximum value. The LDD queues as many transfer fragments on the PDD as
+it can accept with a call to <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-8C79D09B-317A-3D8E-B9C2-474812F17529"><apiname>DSoundScPdd::TransferData()</apiname></xref> for
+each fragment. </p> <p>To support uninterrupted transfer of audio data, the
+PDD must be able to accept at least two transfer fragments simultaneously:
+the first being actively transferred by the audio hardware device, the other
+being queued for transfer on the same device. Therefore, as long as the LDD
+has transfer fragments still to queue, it continues to call <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-8C79D09B-317A-3D8E-B9C2-474812F17529"><apiname>DSoundScPdd::TransferData()</apiname></xref> on
+the PDD until this signals that it has temporarily reached its capacity, by
+returning <codeph>KErrNotReady</codeph>. </p> <p>If the PDD accepts all the
+fragments for this initial play request then the LDD moves on to process the
+subsequent requests from the client. These are also fragmented until either
+the PDD reaches its capacity or all pending play requests are queued. </p> <p>Each
+time the PDD completes the transfer of a fragment from a play buffer, it must
+signal this event back to the LDD by calling the function <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita#GUID-5807543D-A30F-3EB9-8F28-91A623B0D484/GUID-16853E0D-60E8-3BEC-9E3E-9563BA7CAECE"><apiname>DSoundScLdd::PlayCallback()</apiname></xref>.
+This must always be called in the context of the driver DFC thread so there
+are no synchronisation problems. For example, where transfer completion interrupts
+the processing of new play requests from the client. </p> <p>In executing <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita#GUID-5807543D-A30F-3EB9-8F28-91A623B0D484/GUID-16853E0D-60E8-3BEC-9E3E-9563BA7CAECE"><apiname>DSoundScLdd::PlayCallback()</apiname></xref>,
+the LDD checks whether the entire transfer for the current request is now
+complete. If so, it signals completion back to the client. Also within the <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita#GUID-5807543D-A30F-3EB9-8F28-91A623B0D484/GUID-16853E0D-60E8-3BEC-9E3E-9563BA7CAECE"><apiname>DSoundScLdd::PlayCallback()</apiname></xref> function,
+the LDD will attempt to queue further fragments on the PDD, by calling <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-8C79D09B-317A-3D8E-B9C2-474812F17529"><apiname>DSoundScPdd::TransferData()</apiname></xref>,
+as the PDD should now have the capability to accept more transfers. The PDD
+must be written to handle calls to <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-8C79D09B-317A-3D8E-B9C2-474812F17529"><apiname>DSoundScPdd::TransferData()</apiname></xref> within
+its callback to <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita#GUID-5807543D-A30F-3EB9-8F28-91A623B0D484/GUID-8440330E-E7B1-3B43-B3C9-2290E24241E3"><apiname>DSoundScLdd::PlayCallBack()</apiname></xref>. </p> <p>If,
+on completing a request from the client, the LDD discovers that there are
+no further play requests pending from the client, then this is treated as
+an underflow situation and <codeph>KErrUnderflow</codeph> is returned to the
+client. If however, the client specified <codeph>KSndFlagLastSample</codeph> as
+the <codeph>aFlag</codeph> argument of the <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-DA119B93-6E4D-36DA-878A-D6709039E0EA"><apiname>RSoundSc::PlayData()</apiname></xref> function
+then an underflow is expected after this request completes. </p> <p>When the
+audio request has been completed the LDD calls <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-FDBEFD98-EE11-3358-869C-DECC3B5CF83A"><apiname>DSoundScPdd::StopTransfer()</apiname></xref> on
+the PDD. This allows the PDD to release any resources necessary for transfer. </p> </section>
+<section id="GUID-E0C18DE6-E5FD-48D2-87A2-4E4C15C10BC0"><title>Pausing and resuming audio playback</title> <p>The client
+may temporarily halt the progress of audio playback at any time by issuing <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita#GUID-5807543D-A30F-3EB9-8F28-91A623B0D484/GUID-D912620F-9C51-3AFC-8A59-31AF9455AC4A"><apiname>DSoundScLdd::Pause()</apiname></xref>.
+In order to configure the audio hardware device to halt playback, the LDD
+calls <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-0608766F-2645-3E28-B804-BD4B953DB5FF"><apiname>DSoundScPdd::PauseTransfer()</apiname></xref> on the PDD. Ideally,
+playback should be suspended in such a way that it can be resumed later, starting
+from <i>next</i> sample following the one last played. </p> <p>The client
+requests resumption of playback by calling <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita#GUID-5807543D-A30F-3EB9-8F28-91A623B0D484/GUID-86BF7277-0CDE-3DCE-8157-DCCD8E8D60F0"><apiname>DSoundScLdd::Resume()</apiname></xref> on
+the LDD. The LDD, in turn tells the PDD to re-commence playback by calling <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-C692BF61-FA3D-3B85-BCC6-1248C9C7D9BF"><apiname>DSoundScPdd::ResumeTransfer()</apiname></xref>  </p> <p>Since
+access to the hardware is required in both cases, pause and resume are handled
+in the context of the driver DFC thread. </p> </section>
+<section id="GUID-A65EF976-2523-4CE0-BDE6-1F6AF8B5DDC4"><title>Error handling during playback</title> <p>If the PDD reports
+an error when setting up the audio device for playback then the LDD immediately
+completes the first play request back to the client returning the error value
+as the result. For example, if the PDD returns a value other than <codeph>KErrNone</codeph> from
+a call to the function <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-54D3CC19-0C00-3FFA-BD1A-62618D36EB20"><apiname>DSoundScPdd::StartTransfer()</apiname></xref>. The
+LDD attempts to re-start playback data transfer when it processes any further
+play requests from the client. </p> <p>If the PDD reports an error when commencing
+transfer or as the result of the transfer of a playback fragment, then the
+LDD ceases transfer of the associated request and instead immediately completes
+the request back to the client returning the error value as the result. </p> <p>Unexpected
+errors from the PDD are returned to the LDD via the functions <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-8C79D09B-317A-3D8E-B9C2-474812F17529"><apiname>DSoundScPdd::TransferData()</apiname></xref> and <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita#GUID-5807543D-A30F-3EB9-8F28-91A623B0D484/GUID-16853E0D-60E8-3BEC-9E3E-9563BA7CAECE"><apiname>DSoundScLdd::PlayCallback()</apiname></xref>. The <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-8C79D09B-317A-3D8E-B9C2-474812F17529"><apiname>DSoundScPdd::TransferData()</apiname></xref> function signals that
+an error has occurred when setting up the transfer of a playback fragment
+by returning an error value other than <codeph>KErrNone</codeph> or <codeph>KErrNotReady</codeph>.
+The <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita#GUID-5807543D-A30F-3EB9-8F28-91A623B0D484/GUID-16853E0D-60E8-3BEC-9E3E-9563BA7CAECE"><apiname>DSoundScLdd::PlayCallback()</apiname></xref> function called by the
+PDD at the end of a transfer, signals an error to the LDD if the value passed
+is not equal to <codeph>KErrNone</codeph>. </p> <p>The LDD does not cancel
+the transfer of other fragments for the same request which are already queued
+on the PDD, but it ignores their outcome. However, the LDD does try to carry
+on with the transfer of subsequent play requests queued by the client. </p> <p>In
+any of the above situations, the client may choose to terminate playback operation
+by cancelling all outstanding play requests when it detects a playback error. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-16423056-C435-5C4D-BE3D-4A15F95F7F68.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,113 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE task
+  PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
+<task id="GUID-16423056-C435-5C4D-BE3D-4A15F95F7F68" xml:lang="en"><title>Configuration
+Tutorial </title><shortdesc>Describes the steps required in producing a ROM that will work
+with Writable Data Paging (WDP). </shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody>
+<context id="GUID-77EC86D2-A74E-574C-868E-4304668A3863"><p>Writable Data Paging
+(WDP) allows allocated memory that is to be written e.g. stacks and heaps
+to be paged in and out of the RAM pool. </p> </context>
+<steps id="GUID-F19DB5BA-CC38-5C2D-A337-12F4EB85F9E3">
+<step id="GUID-DE8E7A0E-DB35-58B5-A5AA-85A2BFC7301C"><cmd/>
+<info>It is recommended to enable WDP kerneltrace warnings if the build is
+being migrated to a data paged system. </info>
+<info>This is done by setting trace bit number 60 of the kernel trace flags. </info>
+<info>The UDEB version of the build has to be used in order for tracing messages
+to be available. </info>
+<info>Once the demand paging build is stable, then the REL version of the
+build can be used. </info>
+</step>
+<step id="GUID-D5F19B3A-3520-576A-8D59-7E1BF29AB97B"><cmd/>
+<info>Set the paging policy for pages of the core ROM image. This is done
+by using the datapagingpolicy and pagingpolicy keywords in the 'ROM_IMAGE[0]
+{}' block. </info>
+</step>
+<step id="GUID-C1DF8A12-8CB4-5E71-8247-7B8F29EE66D5"><cmd/>
+<info>Next, the data paging for ROFS images is enabled by using datapagingoverride
+and pagingoverride keywords for each ROFS partition that contains executables
+that should use data paging. This is done by adding the keywords into each
+relevant 'ROM_IMAGE[&lt;partion&gt;] {}' block. </info>
+</step>
+<step id="GUID-A13FBB84-3885-5A49-9BA9-698F65CBF1BF"><cmd/>
+<info>In order for a ROM to support data paging, it has to have a media driver
+that supports data paging. </info>
+</step>
+</steps>
+<result id="GUID-9565A808-C86C-57CF-931E-2684A382D5E2"><p>The output of this
+tutorial will be a configuration that allows the ROM build to use demand paging. </p> <p> <note> This
+tutorial only describes how to configure the general paging behaviour.</note> </p> </result>
+<example id="GUID-9A892A74-0823-57D7-A146-BC8E14508B99"><title>Example OBY
+configuration file</title> <p>Below is a typical OBY file that uses data paging,
+XIP ROM and code paging: </p> <codeblock id="GUID-1A753A2E-3846-51BC-AF30-06A53785589C" xml:space="preserve">// MyDPConfig.oby 
+// 
+// The section below is used to specify if XIP ROM paging is to be implemented.
+#if !defined PAGED_ROM 
+#define PAGED_ROM 
+#endif 
+
+// The section below is used when code paging is to be implemented.
+#if !defined USE_CODE_PAGING 
+// Comment out the next line if code paging is wanted 
+#define USE_CODE_PAGING 
+#endif
+ 
+#if !defined CODE_PAGING_FROM_ROFS 
+// Comment out the next line if code paging from primary rofs is wanted 
+#define CODE_PAGING_FROM_ROFS 
+#endif 
+
+// The section below is used to configure the RAM pages for writable data paging.
+ROM_IMAGE[0] { 
+pagedrom 
+compress 
+//                 Min   Max   Young/Old 
+//                 Live  Live  Page 
+//                 Pages Pages Ratio 
+demandpagingconfig 256         512            3 
+pagingoverride defaultpaged 
+
+// The section below specifies if the default paging policy is to used.
+#if defined USE_CODE_PAGING &amp;&amp; !defined USE_DATA_PAGING 
+codepagingpolicy defaultpaged 
+#endif
+ 
+#if defined USE_DATA_PAGING 
+#if defined USE_CODE_PAGING 
+codepagingpolicy defaultpaged 
+#endif
+ 
+datapagingpolicy defaultpaged 
+#endif 
+}
+
+#if defined CODE_PAGING_FROM_ROFS || defined USE_DATA_PAGING 
+ROM_IMAGE[1] { 
+pagingoverride defaultpaged 
+}
+#endif 
+</codeblock> <p>The OBY file that determined the start of the primary ROFS
+partition, for example base.iby, would then be adjusted thus: </p> <codeblock id="GUID-7C438B69-DEB8-5598-A338-9707FA23F758" xml:space="preserve">
+#if defined(_NAND) || defined(_NAND2) 
+#if !defined PAGED_ROM || defined CODE_PAGING_FROM_ROFS || defined USE_DATA_PAGING 
+REM Start of ROFS image 
+ROM_IMAGE[1] { 
+#endif 
+#endif </codeblock> <p> <note> Make sure to include media drivers that can
+support writable data paging.</note>  </p> </example>
+<postreq id="GUID-DFC44549-2B7B-5D4F-9686-7E7BEA7E430A"><p>This tutorial only
+covers the configuration of the general demand paging parameters. To see how
+to make individual executables pageable see (<xref href="GUID-16423056-C435-5C4D-BE3D-4A15F95F7F68.dita#GUID-16423056-C435-5C4D-BE3D-4A15F95F7F68/GUID-9A892A74-0823-57D7-A146-BC8E14508B99">the
+mmp configuration tutorial</xref>). </p> <p>The next step is to <xref href="GUID-6B9041F7-79A6-5CCA-9B4D-B8EF377FD378.dita">build
+the writable data paging ROM</xref>  </p> </postreq>
+</taskbody><related-links>
+<link href="GUID-6B9041F7-79A6-5CCA-9B4D-B8EF377FD378.dita"><linktext>Building
+ROM tutorial</linktext></link>
+</related-links></task>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-178E140F-BB15-5A82-99A6-D1BC0E11E018.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-178E140F-BB15-5A82-99A6-D1BC0E11E018" xml:lang="en"><title>Kernel-side
+Messages</title><shortdesc>Kernel-side messages are a means of communication between Symbian
+platform threads executing kernel-side code. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Typically, they are used by device drivers to communicate between a client
+thread, usually a user thread, and a kernel thread running the actual device
+driver code. </p>
+<p>The mechanism consists of a message, containing data, and a queue that
+is associated with a DFC. The DFC runs in order to deal with each message. </p>
+<p>A kernel-side message is represented by a <xref href="GUID-3FDD1B46-1427-3F1C-99D2-AD8446658E5A.dita"><apiname>TMessageBase</apiname></xref> object,
+that allows a single 32-bit argument to be passed, and a single 32-bit return
+value. In general, more arguments can be passed by deriving classes from <codeph>TMessageBase</codeph>.
+In practice, each Symbian platform thread has a <xref href="GUID-D43CB8FA-C212-3B56-AD16-9F1D69DA7551.dita"><apiname>TThreadMessage</apiname></xref> object
+embedded within it. <codeph>TThreadMessage</codeph> is derived from <codeph>TMessageBase</codeph>,
+and contains space for 10 extra 32-bit arguments. These objects are used for
+communication with device driver threads. </p>
+<p>Both <codeph>TMessageBase</codeph> and <codeph>TThreadMessage</codeph> are
+defined in <filepath>...\kernel\kernel.h</filepath>, which is exported to <filepath>epoc32\include\kernel</filepath>. </p>
+<fig id="GUID-230AECE3-5006-543A-9F4F-088C62E14E6D">
+<title>Message threads and queues</title>
+<image href="GUID-D8A3C18B-A107-5557-B882-CD6CDD0F0F1D_d0e76208_href.png" placement="inline"/>
+</fig>
+<p> <xref href="GUID-CAAD5B87-CEE7-30E8-BA6A-08F9407C4C20.dita"><apiname>SDblQueLink</apiname></xref> is simply an object that allows a message
+to be linked to another in the form of a doubly-linked list. </p>
+<p>The message queue is represented by a <xref href="GUID-382DD935-E9D7-3E00-88B2-B28A89CAD4FB.dita"><apiname>TMessageQue</apiname></xref> object,
+which consists of a DFC plus a doubly-linked list of received messages. The
+DFC is attached to the receiving thread’s DFC queue and it runs whenever a
+message becomes available for processing. </p>
+<p> <codeph>TMessageQue</codeph> is defined in <filepath>...include\kernel\kernel.h</filepath>,
+which is exported to <filepath>epoc32\include\kernel</filepath>; <codeph>SDblQueLink</codeph> is
+defined in <filepath>...\nkern\nklib.h</filepath>, which is exported to <filepath>epoc32\include\nkern</filepath>. </p>
+<p>The following shows, in simple terms, the relationship between messages
+and the message queues: </p>
+<fig id="GUID-2D1F4468-5208-51F1-9E48-B5E9DC44B6B2">
+<title>Relationship between messages and message queues</title>
+<image href="GUID-DA7751A1-4EC5-5FBA-A42B-E254133A1D82_d0e76254_href.png" placement="inline"/>
+</fig>
+<p>When a message is sent to the queue, either: </p>
+<ul>
+<li id="GUID-08445948-588F-512B-BA6C-D641F0DDF572"><p>the message is accepted
+immediately, and the receiving thread’s DFC runs. This will happen if the
+message queue is ready to receive, which will be the case if the message queue
+is empty and the receiving thread has requested the next message. </p> </li>
+</ul>
+<p>or </p>
+<ul>
+<li id="GUID-BF81268D-31A4-50D6-A43A-F2C4556B367F"><p>the message is placed
+on the delivered message queue, and the DFC does not run. This will happen
+if there are other messages queued ahead of this one or if the receiving thread
+has not (yet) requested another message. </p> </li>
+</ul>
+<p>A kernel-side message may be in one of three states at any time: </p>
+<ul>
+<li id="GUID-C9CF11B5-0B76-5F8A-87CC-75DF595F657E"><p>FREE - represented by
+the <xref href="GUID-3FDD1B46-1427-3F1C-99D2-AD8446658E5A.dita#GUID-3FDD1B46-1427-3F1C-99D2-AD8446658E5A/GUID-BBF5D5BD-BC64-3EC8-82F4-A7A3EB1FF043"><apiname>TMessageBase::EFree</apiname></xref> enum value. This indicates that
+the message is not currently in use. </p> </li>
+<li id="GUID-924008AC-58F7-5979-95FA-EC11EC5B5D07"><p>DELIVERED - represented
+by the <xref href="GUID-3FDD1B46-1427-3F1C-99D2-AD8446658E5A.dita#GUID-3FDD1B46-1427-3F1C-99D2-AD8446658E5A/GUID-828BA7EF-8962-3CEA-B322-7D92E368957B"><apiname>TMessageBase::EDelivered</apiname></xref> enum value. This indicates
+that the message is attached to a message queue but is not currently in use
+by the receiving thread. It may be removed from the queue and discarded with
+no ill effects on the receiving thread. The client thread pointer may not
+be used while the message is in this state. </p> </li>
+<li id="GUID-57807061-A767-59A4-9D10-6A08A06DA214"><p>ACCEPTED - represented
+by the <xref href="GUID-3FDD1B46-1427-3F1C-99D2-AD8446658E5A.dita#GUID-3FDD1B46-1427-3F1C-99D2-AD8446658E5A/GUID-D4BB85D9-DE00-3BD8-8A9A-4D40C031A94C"><apiname>TMessageBase::EAccepted</apiname></xref> enum value. This indicates
+that the message is not attached to a message queue but is currently in use
+by the receiving thread. The message may not be discarded. </p> </li>
+</ul>
+<p>Transitions between these states, including adding the message to, and
+removing the message from a message queue, occur under the protection of the
+global <xref href="GUID-382DD935-E9D7-3E00-88B2-B28A89CAD4FB.dita#GUID-382DD935-E9D7-3E00-88B2-B28A89CAD4FB/GUID-1134F81A-4427-3B7E-8BF3-1F2DB6698261"><apiname>TMessageQue::MsgLock</apiname></xref> fast mutex. The use of a mutex
+is necessary to avoid queue corruption, for example, when multiple threads
+are sending messages to the same message queue at the same time. The use of
+a fast mutex means that message passing operations may only be invoked from
+a thread context. </p>
+<p>Kernel-side messages may be sent either synchronously or asynchronously.
+Each <xref href="GUID-3FDD1B46-1427-3F1C-99D2-AD8446658E5A.dita"><apiname>TMessageBase</apiname></xref> object contains an <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita"><apiname>NFastSemaphore</apiname></xref> on
+which the sending thread will wait after sending a synchronous message. The
+semaphore is signalled by the receiving thread after the message has been
+processed and the completion code has been written in. The sending thread
+is then released and picks up the return code. The <codeph>NFastSemaphore</codeph> also
+contains a pointer to the sending <xref href="GUID-187D314F-1115-3671-AC46-37AEC5DFB2AC.dita"><apiname>NThread</apiname></xref>; this serves
+to identify the sending thread and is therefore set up for both synchronous
+and asynchronous message send. Note that this pointer is reference counted
+- the access count of the originating <xref href="GUID-38D1534C-AA01-33AF-9937-CDD818A85F97.dita"><apiname>DThread</apiname></xref> is incremented
+when the message is sent. This prevents the sending <codeph>DThread</codeph> object
+disappearing if the thread terminates unexpectedly. When the message is completed
+the extra access is removed asynchronously - the thread completing the message
+will not need to delete the <codeph>DThread</codeph> itself. This is done
+to avoid unpredictable execution times for message completion. Also note that
+even messages sent asynchronously must be completed; this is required to set
+the message state back to FREE and to remove the access count from the sending
+thread. </p>
+<p>The <xref href="GUID-D43CB8FA-C212-3B56-AD16-9F1D69DA7551.dita"><apiname>TThreadMessage</apiname></xref> objects embedded in Symbian platform
+thread control blocks, <xref href="GUID-38D1534C-AA01-33AF-9937-CDD818A85F97.dita"><apiname>DThread</apiname></xref> objects, are always sent
+synchronously - this ensures that one message per thread will always suffice.
+In addition, these messages are cancelled if the corresponding thread terminates.
+Cancelling an ACCEPTED message has no effect, but cancelling a DELIVERED message
+will remove the message from the queue and also remove the access count held
+by the message on the sending thread. Hence the sending thread pointer should
+only be used by the receiving thread if the message is in the ACCEPTED state. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-180973A1-5C0A-5A85-82CC-E6B739A7F207.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,177 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-180973A1-5C0A-5A85-82CC-E6B739A7F207" xml:lang="en"><title>Platform
+Specific Layer Validation</title><shortdesc>Describes the test code to validate a port of the MMC Controller.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There are three stages involved in testing a port of the MultiMediaCard
+controller. The first stage tests the controller in isolation; subsequent
+stages test an additional area of functionality. </p>
+<p>All three stages involve text shell based test programs and test drivers,
+and therefore these tests can be run by just building a text shell ROM. You
+can also run tests on the Emulator. </p>
+<section id="GUID-AB3EBD9F-49E9-5C9C-ACFB-377997C2A838"><title>Testing the
+controller in isolation</title> <p> <filepath>MMCTEST.EXE</filepath> tests
+the MultiMediaCard controller in isolation, at the controller’s client interface
+level. Since the controller’s client API is a kernel side interface, this
+requires a test driver, <filepath>D_MMCIF.LDD</filepath>, as well as the test
+program itself. </p> <p>This is not a 'go/no-go' type test, but is a test
+utility that can perform a small variety of operations. These are selected
+a simple interactive way by pressing appropriate keys. </p> <table id="GUID-A5C02651-82A2-57DB-8BCF-D1EF5F72902A">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>Building <filepath>MMCTEST.EXE</filepath> and <filepath>D_MMCIF.LDD</filepath>  </p> </entry>
+<entry><p>The source and header files needed to build <filepath>MMCTEST.EXE</filepath> can
+be found in <filepath>...\e32utils\pccd</filepath>; the mmp file is <filepath>...\e32utils\group\mmctest.mmp</filepath>. </p> <p>The
+source and header files needed to build the test driver <filepath>D_MMCIF.LDD</filepath> can
+be found in <filepath>...\e32utils\pccd</filepath>; the mmp file is <filepath>...\e32utils\group\d_mmcif.mmp</filepath>. </p> <p>You
+need to build <filepath>MMCTEST.EXE</filepath> for the appropriate CPU target
+architecture (e.g. ARMI,THUMB etc.); you need to build <filepath>D_MMCIF.LDD</filepath> for
+the appropriate platform (e.g. MINT). </p> <p>Include both of these components
+in a ROM </p> </entry>
+</row>
+<row>
+<entry><p>Running the tests </p> </entry>
+<entry><p>Run MMCTEST and perform the following suggested sequence: </p> <ul>
+<li id="GUID-3685E0AA-B3D5-5A30-B6FF-04DE7A53EBCF"><p>Without a card inserted,
+power up the stack by pressing <userinput>P</userinput>, and check that it
+reports that no card is present. </p> </li>
+<li id="GUID-BA816CD0-3FA1-54C3-8480-7F82BA338119"><p>Insert a card, power
+it up, and check that it reports that a card is present. </p> </li>
+<li id="GUID-29403BEA-814F-5F54-85B1-8E598E67BB72"><p>Now that the card is
+powered up, read the card info by pressing <userinput>C</userinput>, and check
+the data returned about the card against the expected card data, by referring
+to the datasheet for the card. </p> </li>
+<li id="GUID-7C7542B2-F46A-5183-8256-1E962094A9B7"><p>Read the first sector
+of the card by pressing <userinput>M</userinput>. </p> </li>
+<li id="GUID-B6F5D3F1-2CF9-55B3-8EAF-4672EBE9B1A9"><p>Now read a few more
+sectors by pressing the space bar. </p> </li>
+<li id="GUID-15FBBB20-8914-566B-A786-BB470312A7D0"><p>Test writing to a sector:
+while still viewing a sector, edit a part of this, by using the direction
+keys and typing in a hex number. Now save the change by pressing <userinput>ESC</userinput>,
+followed by <userinput>Y</userinput>. Now navigate to the same sector again
+and check that it displays the new contents of the sector. </p> </li>
+<li id="GUID-23809955-30D3-5B53-85B6-890C75E63957"><p>Quit the test by pressing <userinput>Q</userinput>. </p> </li>
+</ul> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-9A353066-CE24-5969-B0FD-3F1164ECF3F5"><title>Testing the
+controller with the media driver and the local media sub-system</title> <ol id="GUID-323C60B8-36B4-5975-AECC-659F68AB560D">
+<li id="GUID-97E060B0-8355-54E3-AA35-7FF9B9D59119"><p> <filepath>DRVTEST.EXE</filepath> tests
+the MultiMediaCard controller in conjunction with the media driver and the
+local media sub-system, in effect accessing the card as a local drive. This
+requires a kernel side test driver <filepath>D_DRVIF.LDD</filepath> as well
+as the test program itself. </p> <p>This is not a 'go/no-go' type test, but
+is a test utility that can perform a small variety of operations. These are
+selected a simple interactive way by pressing appropriate keys. It is used
+to test that card initialization and single block read and write requests
+are performed successfully. </p> </li>
+<li id="GUID-BCCDA1BB-7205-5C0D-A0CC-607E44196624"><p> <filepath>T_ATADRV.EXE</filepath> tests
+that card initialization and simple read and write requests succeed. It also
+tests multi-block read/write operations, format requests, accessing the device
+following a media change event, and a machine power down event. </p> <p>This
+is a 'go/no-go' type test. If this test succeeds, you can have fairly high
+confidence that the F32 test suite will run successfully. </p> </li>
+</ol> <table id="GUID-D29E7820-6241-5B6E-B242-4B7037BA7344">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>Building <filepath>DRVTEST.EXE</filepath>, <filepath>D_DRVIF.LDD</filepath>,
+and <filepath>T_ATADRV.EXE</filepath>  </p> </entry>
+<entry><p>The source and header files needed to build <filepath>DRVTEST.EXE</filepath> can
+be found in <filepath>...\e32utils\pccd</filepath>; the mmp file is <filepath>...\e32utils\group\drvtest.mmp</filepath>. </p> <p>The
+source and header files needed to build the test driver <filepath>D_DRVIF.LDD</filepath> can
+be found in <filepath>...\e32utils\pccd</filepath>; the mmp file is <filepath>...\e32utils\group\d_drvif.mmp</filepath>. </p> <p>The
+source and header files needed to build <filepath>T_ATADRV.EXE</filepath> can
+be found in <filepath>...\e32test\pccd</filepath>; the mmp file is <filepath>...\e32test\group\t_atadrv.mmp</filepath>. </p> <p>You
+need to build <filepath>DRVTEST.EXE</filepath> for the appropriate CPU target
+architecture (e.g. ARMI,THUMB etc.) </p> <p>You need to build <filepath>D_DRVIF.LDD</filepath> for
+the appropriate platform (e.g. MINT) </p> <p>You need to build <filepath>T_ATADRV</filepath> for
+the appropriate CPU target architecture (e.g. ARMI,THUMB). </p> <p>Include
+these components in a ROM. </p> </entry>
+</row>
+<row>
+<entry><p>Running the DRVTEST test </p> </entry>
+<entry><p>Run DRVTEST and perform the following suggested sequence: </p> <ul>
+<li id="GUID-22D82528-84D3-58C8-83F1-63B9D63976D0"><p>Without a card inserted,
+power up the stack by pressing <userinput>P</userinput>, and check that it
+reports that no card is present. </p> </li>
+<li id="GUID-646F1CE2-6F6E-58D1-A097-2675CC0285D6"><p>Insert a card, power
+it up, and check that it reports that a card is present. </p> </li>
+<li id="GUID-76B81B73-0F7E-57DE-AEE2-67E03E9422A2"><p>Now that the card is
+powered up, read the card info by pressing <userinput>C</userinput>, and check
+the data returned about the card against the expected card data, by referring
+to the datasheet for the card. </p> </li>
+<li id="GUID-FD9CC21C-5818-5405-B0BA-B5E5344D715F"><p>Read the first sector
+of the card by pressing <userinput>M</userinput>. </p> </li>
+<li id="GUID-B7EF88BE-D2CB-5E8F-844B-47F1A461CC82"><p>Now read a few more
+sectors by pressing the <userinput>space                         bar</userinput>. </p> </li>
+<li id="GUID-96527F35-52E7-5400-AEB1-E7D05D4420C5"><p>Test writing to a sector:
+while still viewing a sector, edit a part of this, by using the direction
+keys and typing in a hex number. Now save the change by pressing <userinput>ESC</userinput>,
+followed by <userinput>Y</userinput>. Now navigate to the same sector again
+and check that it displays the new contents of the sector. </p> </li>
+<li id="GUID-D91CFC9A-C544-5E32-BCAE-3B2BA558AF63"><p>Quit the test by pressing <userinput>Q</userinput>. </p> </li>
+</ul> </entry>
+</row>
+<row>
+<entry><p>Running the T_ATADRV test </p> </entry>
+<entry><p>Run T_ATADRV and follow the on-screen instructions. Check that the
+test runs to the end with no errors. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-9AD20A90-0E4D-56BC-A681-833EBD632DF6"><title> Testing using
+the F32 test suite</title> <p>The final test stage is to run the entire file
+server test suite on a card drive. </p> <p>To perform these tests: </p> <ul>
+<li id="GUID-1C50C6E5-E811-5DFE-8814-F4B18648E389"><p>build a text shell ROM
+that contains the F32 test suite, i.e. build the ROM with the option: </p> <codeblock id="GUID-892CC775-89C7-5B48-AE44-5D63E7A030FD" xml:space="preserve">-t=f32tests</codeblock> </li>
+<li id="GUID-2A5BE4AA-9762-525F-9391-D839153C41F5"><p>boot the test machine
+into the text shell. </p> </li>
+<li id="GUID-C9A22A2C-58F6-59A4-BB85-6D69703520F9"><p>launch the F32 automatic
+tests and check that all of the tests run without error. Use the command option
+"-d" to set the default drive, for example: </p> <codeblock id="GUID-08A2E18B-7CA8-5124-B46E-88311D468C4E" xml:space="preserve">RUNTESTS F32TEST.AUTO.ARMI.BAT -d d</codeblock> </li>
+</ul> </section>
+<section id="GUID-57378A6B-B5FB-5EFF-9FD4-6F948B5F20D1"><title>Emulator-based
+tests</title> <p>It is possible to emulate a user opening and closing the
+MMC drive door, replacing and removing the MMC card, and assigning a password
+to an emulated MMC card. This is important so that you can test: </p> <ul>
+<li id="GUID-2B8F603F-FC12-57E2-B4A7-E86653DAD5C5"><p>how an application behaves
+when the MMC card, from which the application is running, is removed and/or
+swapped </p> </li>
+<li id="GUID-D110DBEA-7070-557E-982A-8A34FACC7256"><p>how an application behaves
+when it is reading and writing data to and from an MMC card </p> </li>
+<li id="GUID-E714BBF6-A97F-5D4A-9D45-A7B8C12238F4"><p>that data stored on
+an MMC card is not lost or corrupted during MMC drive events </p> </li>
+<li id="GUID-EC779E31-2A94-51D4-B93D-4C9C2811726A"><p>that MMC card locking
+and password notification works correctly. </p> </li>
+</ul> <p>The platform independent layer of the MuiltiMediaCard controller,
+as its name implies, is common to all platforms, including the emulator. However,
+the emulator provides its own implementation of the platform specific layer. </p> <p>The
+emulator does not provide access to any kind of MultiMediaCard hardware. Instead,
+the memory area of each emulated card is represented by a file, a <filepath>.bin</filepath> type
+file in the Windows system <filepath>temp</filepath> directory, on the host
+machine. The MultiMediaCard emulator emulates a single stack containing two
+separate cards, the first in slot 0, and the second in slot 1. Each emulated
+card has an associated <filepath>.bin</filepath> file on the host machine.
+As the emulator only supports the swapping of cards in slot 0, there are two <filepath>.bin</filepath> files,
+one for each of the two emulated MMC cards in slot 0. There is no support
+for card swapping on slot 1, and therefore this has only one <filepath>.bin</filepath> file. </p> <p>This
+means that all the test programs described can be run on the emulator, and
+they will exercise the platform independent layer code in the same way as
+on real target hardware. It also means that call entries to, and exits from
+platform specific layer code can be traced, and may be useful for debugging
+problems on real hardware, and to help understand how the controller operates. </p> <p>The
+code for the emulator specific layer code can be found in <filepath>...\wins\specific\mmc.cpp</filepath>. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-18DD4FE5-6641-5A0E-A00E-DC0C00639CE4.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,45 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-18DD4FE5-6641-5A0E-A00E-DC0C00639CE4" xml:lang="en"><title>Set
+the Configuration Descriptors</title><shortdesc>A short document that describes how to set the configuration descriptors. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+
+<section id="GUID-F52A5F12-309F-5E78-A352-BBB0D9E04E6E"><title>Introduction</title> <p>The
+configuration descriptor contains values required by the class drivers. The
+settings are: </p> <ul>
+<li id="GUID-0D8A7917-78D3-5EB9-8F96-FF612AB113B6"><p>number of interfaces
+in the configuration, </p> </li>
+<li id="GUID-96233C25-8EE1-56FF-977D-B7A891C4906B"><p>maximum power taken
+by the device, </p> </li>
+<li id="GUID-30F2978A-9FB3-5B73-B590-47DF2B8F2BA6"><p>is remote wakeup enabled. </p> </li>
+</ul> <p> <b>Note</b>: that the number of interfaces in the configuration
+must be set, all the other settings are optional. </p><p> The size of the
+data to be copied may be obtained by using  <xref href="GUID-0638B42E-9F0E-39F9-ADD3-95DAAE53D231.dita"><apiname>GetConfigurationDescriptorSize()</apiname></xref>.<codeblock xml:space="preserve">TInt desc_size = 0;
+gPort.GetConfigurationDescriptorSize(desc_size);</codeblock></p><p>The size
+should normally be <xref href="GUID-E03E6449-67E8-38EC-B0B6-A036E5C2D2C3.dita"><apiname>KUsbDescSize_Config</apiname></xref> as defined in <filepath>&lt;usb.h&gt;</filepath></p> </section>
+<section><title>Setting configuration descriptors</title> <p>Set the configuration
+descriptor using <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-A2578FBD-5B74-3A24-939E-77D42B83BD55"><apiname>RDevUsbcScClient::SetConfigurationDescriptor()</apiname></xref>. </p> <codeblock id="GUID-116E9BD1-635F-5DC7-941F-DB7A8430C8E4" xml:space="preserve">TBuf8&lt;desc_size&gt; descriptor;
+
+// Invert Remote-Wakup support
+descriptor[KConfDesc_AttribOffset] = (descriptor[KConfDesc_AttribOffset] ^ KUsbDevAttr_RemoteWakeup);
+
+// Change the reported max power to 200mA (2 * 0x64)
+descriptor[KConfDesc_MaxPowerOffset] = 0x64;
+r = gPort.SetConfigurationDescriptor(descriptor);</codeblock> <p>Additional
+values may be set using the <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita"><apiname>RDevUsbcScClient</apiname></xref> class. These
+values can be set, retrieved and removed: </p> <ul>
+<li id="GUID-9344E027-E98A-55BC-8033-1E634DF05CD6"><p>Manufacturer, </p> </li>
+<li id="GUID-8FAD4957-D95E-5C1A-B6F9-3D3FC64D16EA"><p>Product, </p> </li>
+<li id="GUID-C103E88F-C44A-51BC-96F3-BF2CDABA74FC"><p>Serial numbers. </p> </li>
+</ul> </section>
+
+<section><p>After you have set the configuration descriptors you should <xref href="GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita">Set the Interface Descriptors</xref>. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-197A1071-CDAA-5A87-9981-A52FB32C084E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,72 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-197A1071-CDAA-5A87-9981-A52FB32C084E" xml:lang="en"><title>Reference</title><shortdesc>A summary of documentation related to the Keyboard Driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This topic provides a summary of related documentation for the
+Keyboard Driver to which you can refer. </p>
+<section id="GUID-2385A5C0-DA60-58A3-80FE-011CB1280EBB"><title>API
+Reference</title> <p><b>Kernel Architecture 2 </b> </p> <table id="GUID-BCB7CEC3-1016-5073-A608-3D8244108A90">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Item</b>  </p> </entry>
+<entry><p> <b>Header</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-35A21F70-F080-364D-8655-5E1781B378EB.dita"><apiname>SConvSubTable</apiname></xref>  </p> </entry>
+<entry><p> <filepath>k32keys.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-F7DFE751-C534-36A8-9B57-9C8417B1BE06.dita"><apiname>SConvTable</apiname></xref>  </p> </entry>
+<entry><p> <filepath>k32keys.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-3D2F56DB-DD36-3787-8653-C5AC114D69A1.dita"><apiname>SConvTableNode</apiname></xref>  </p> </entry>
+<entry><p> <filepath>k32keys.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-51EE5A29-D529-344C-B4E2-A3B44C69A597.dita"><apiname>SFunc</apiname></xref>  </p> </entry>
+<entry><p> <filepath>k32keys.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9E65683-B476-39B2-9D2D-1FF01EC3E08A.dita"><apiname>SFuncAndState</apiname></xref>  </p> </entry>
+<entry><p> <filepath>k32keys.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-4A224BA9-48D0-314D-84F8-757799B66BE8.dita"><apiname>SFuncTable</apiname></xref>  </p> </entry>
+<entry><p> <filepath>k32keys.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-1F784748-5EEB-3788-98C3-559C220C3CC1.dita"><apiname>SFuncTableEntry</apiname></xref>  </p> </entry>
+<entry><p> <filepath>k32keys.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-14AC8696-F88E-3C2E-90EF-8FB96ADC45FD.dita"><apiname>SFuncTables</apiname></xref>  </p> </entry>
+<entry><p> <filepath>k32keys.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C794A4F1-315A-3F7E-8B2B-CDD63A3EC7AE.dita"><apiname>SKeyCodeList</apiname></xref>  </p> </entry>
+<entry><p> <filepath>k32keys.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-F18D6A71-122E-3202-927B-25DCEF1576A4.dita"><apiname>SScanCodeBlock</apiname></xref>  </p> </entry>
+<entry><p> <filepath>k32keys.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-DB86A3E5-D118-3A1D-8A76-BEC6111993E8.dita"><apiname>SScanCodeBlockList</apiname></xref>  </p> </entry>
+<entry><p> <filepath>k32keys.h</filepath>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-D869DEB3-1DC0-5745-AEF5-08FDA77215E6"><title>Engineering
+Specifications</title> <p>No specifications are published. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-1A72F75A-1930-5C32-93B7-20F4934BCFAA.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-1A72F75A-1930-5C32-93B7-20F4934BCFAA" xml:lang="en"><title>ROM
+Paging Overview</title><shortdesc>Memory may be conserved by only loading the parts of an execute
+in place (XIP) image that are required at any given time. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-3CEEAF8D-F97A-55A8-AD34-5578A149EEFB"><title>Description</title> <p>If
+an XIP ROM image is stored on an XIP media such as NOR flash, it does not
+have to be copied into main memory before it can be executed. If it is stored
+on non-XIP media, such as NAND flash, then it must be copied into main memory
+before it can be executed. The entire XIP image can run to many megabytes,
+and therefore use a lot of main memory. If ROM Paging is used, then only those
+sections of the XIP image which are required are loaded into memory. Additional
+sections are loaded as and when they are needed, and sections which have not
+been used in some time can be discarded. The overall effect is to leave more
+memory available for applications. </p> <p>&lt;add links to memory mapping,
+NOR NAND&gt; </p> <p>If the ROM image is in a non-XIP ROM it has to be loaded
+into RAM before it can be executed. The ROM image is split into two parts: </p> <ul>
+<li id="GUID-74FB13BD-87C6-5591-B522-E2853BB89B76"><p>Paged </p> </li>
+<li id="GUID-E3226DFC-D8C3-5E31-A188-D9549697C210"><p>Unpaged </p> </li>
+</ul> <p>The unpaged part of the ROM image is loaded by the bootloader and
+it always present in RAM. The paged part of the ROM image is paged in on demand. </p> </section>
+<section id="GUID-B4DB09C1-B16C-4A45-ADCF-C0A10D577CFA"><title>Using ROM Paging</title> <p>The type of paging used and the
+area of memory to use first is specified in the oby and mmp files and then
+built by using specific parameters in the buildrom utility. </p> </section>
+</conbody><related-links>
+<link href="GUID-0AFF5666-6BF9-5022-ADBC-5EFFA743B288.dita"><linktext>ROM Paging
+Guide</linktext></link>
+<link href="GUID-5A71755A-E67F-5007-8C55-5B8FA65B3C04.dita"><linktext>ROM file
+system</linktext></link>
+<link href="GUID-D6C2202C-778C-558A-97AA-649CD6DB5E87.dita"><linktext>ROFS file
+system</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-1A92047A-3C1D-5B4C-949B-98D770F5F530-master.png has changed
Binary file Adaptation/GUID-1A92047A-3C1D-5B4C-949B-98D770F5F530_d0e32642_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-1AFAD1C4-340B-4119-94A8-F50E9D8DA8E6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-1AFAD1C4-340B-4119-94A8-F50E9D8DA8E6" xml:lang="en"><title>Timers</title><shortdesc>This document introduces the use of timers by device drivers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-B6850D59-E4F8-472E-BED0-1E025CFC45A2">      
+      <p>Device drivers use timers for tasks such as providing timeouts for
+device operations, and to wait for programming device timing. </p> <p>The
+Kernel provides timer APIs that device drivers can use, for example, <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita"><apiname>NTimer</apiname></xref>.
+The following sections discuss these. </p>     </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-1BB379B6-C0B5-5099-90A0-1BA39DC2C7DD-master.png has changed
Binary file Adaptation/GUID-1BB379B6-C0B5-5099-90A0-1BA39DC2C7DD_d0e25918_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,130 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC" xml:lang="en"><title>Inactivity
+Monitoring and Peripheral Low Power States</title><shortdesc>Peripheral inactivity can be defined as the state when that peripheral’s
+driver has no pending request and is not performing background tasks.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>It is recommended that peripheral drivers monitor peripheral inactivity
+because they are in the best position to understand the current hardware requirement. </p>
+<p>The preferred approach is to implement inactivity monitoring in the platform
+specific portion of peripheral drivers. However it is not always possible
+to safely do it that way. In this case, an interface between the platform
+specific and generic portions of the driver might need to be devised leading
+to, in the future, inactivity monitoring functionality or assistance being
+included in generic components. </p>
+<p>In some cases the developer of the driver might decide to implement inactivity
+monitoring with a grace delay, using timers. For example, consider a peripheral
+used as a data input device. If the only way that the platform specific layer
+of the peripheral driver has any knowledge that an input request is pending,
+and that data is arriving, is when an incoming unit of data causes an interrupt,
+then the resulting ISR (or deferred DFC) could re-start a timer with a suitable
+period. Inactivity could be monitored in the timer callback. This guarantees
+that if another unit of data arrives before the timer expiration, the peripheral
+is still in its operational power state. </p>
+<ul>
+<li id="GUID-D72B1509-0CFD-55D2-B4D3-84A6130AC3C8"><p> <xref href="GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC.dita#GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC/GUID-1817A738-2351-526F-881D-7EB479E93C4C">Peripheral Power States</xref> </p> </li>
+<li id="GUID-C6CAE535-2406-53FF-85C6-18552831DB94"><p> <xref href="GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC.dita#GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC/GUID-1E31C6B9-6F69-50C5-908A-BCC648D4D8B1">Peripheral standby</xref> </p> </li>
+<li id="GUID-36E6FC1E-C3E8-5A78-AF77-D54486719BFF"><p> <xref href="GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC.dita#GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC/GUID-DCB8EA90-9B5F-5BA1-8D22-124980AC6B34">Moving peripherals to a low power state</xref> </p> </li>
+<li id="GUID-927DF4E2-18A3-51B5-9A46-02C63013954C"><p> <xref href="GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC.dita#GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC/GUID-81231D49-0F35-582D-BDB3-DC1A08C2E448">High latency low power states and non-transparent transitions</xref> </p> </li>
+<li id="GUID-9DC49460-BE85-5979-B52D-DB6AC7E218D5"><p> <xref href="GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC.dita#GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC/GUID-CA1BB80F-5A1C-5B66-8091-84625A0A9CFB">Peripheral power state diagram and transitions</xref> </p> </li>
+</ul>
+<section id="GUID-1817A738-2351-526F-881D-7EB479E93C4C"><title>Peripheral
+Power States</title> <p>It is possible that a particular ASSP allows peripheral
+hardware blocks to be independently transitioned to a low power state. From
+the point of view of power consumption, the base port might consider that
+those peripherals have three logical power states: </p> <ul>
+<li id="GUID-49BC931A-15BE-5AC3-8F8F-1C3EFBFC0806"><p> <i>Operational Power</i> –
+the peripheral is either processing some request, or performing a background
+task with data transactions to or from it, or the peripheral is being kept
+in this state in anticipation that data will be input to it, and is drawing
+an amount of power corresponding to one of its possible modes of operation. </p> </li>
+<li id="GUID-93AA050E-44F7-5B73-A8A2-4F70A2067E42"><p> <i>Low Power</i> –
+the peripheral is “idling” after a period of inactivity has been detected,
+drawing a minimal amount of power required to preserve its internal state.
+The peripheral should be able to keep its internal state and transition from
+this to the Operational Power state with a negligible delay and with no impact
+on the performance of either the peripheral driver or the upper layer components
+that use it. </p> </li>
+<li id="GUID-8A39F42D-B928-5DE2-B79A-A1EABBF696E4"><p> <i>Off</i> – the peripheral
+power has been cut off, and only leakage accounts for power consumption. No
+state is preserved and the delay to a return to full power is not negligible. </p> </li>
+</ul> <p>Note that peripheral power states are a notion that only applies
+to the peripheral hardware block, and not to the driver. The peripheral driver
+is the component that requests the peripheral to transition between these
+states. </p> <p>Note also that both Operational and Low Power states are subsets
+of the Peripheral "Active" state. In some cases the differences in power consumption
+between the Operational and Low Power modes might not be significant as, with
+some hardware, only part of the peripheral needs to be operational to service
+a particular type of request. </p> </section>
+<section id="GUID-1E31C6B9-6F69-50C5-908A-BCC648D4D8B1"><title>Peripheral
+standby</title> <p>Some ASSPs make provision for a peripheral standby mode,
+where individual peripherals can be transitioned to a low power consumption
+mode of operation under software control, usually by writing to an ASIC internal
+register. </p> <p>If the peripheral is capable of keeping its internal state,
+and the transition out of this mode is either done automatically on hardware,
+or controlled by software, but has no impact on the performance of the peripheral
+driver or on the users of this peripheral, and can be done with negligible
+delay, then the peripheral standby mode could be considered a low power state
+as above. </p> </section>
+<section id="GUID-DCB8EA90-9B5F-5BA1-8D22-124980AC6B34"><title>Moving peripherals
+to a low power state</title> <p>It is assumed that peripherals can be transitioned
+between power states under the peripheral driver's software control. However,
+transitioning peripherals to a low power state should only be performed if
+it can be done transparently to the users and consumers of the services provided
+by that peripheral. Negligible interactive delays may be acceptable, data
+loss is not acceptable. </p> <p>The transition of a peripheral to a low power
+state can be requested by the platform-dependent layers of that peripheral
+driver after inactivity, as defined above, has been detected. That request
+usually assumes the form of a request to turn a controllable power resource
+off. The request should be handled by the ASSP/Variant component that manages
+platform power resources (the resource manager). </p> <p>It can also assume
+the form of an operation required to put the peripheral in standby mode. In
+this case the peripheral driver is totally responsible for handling the transition
+to the low power state. </p> </section>
+<section id="GUID-81231D49-0F35-582D-BDB3-DC1A08C2E448"><title>High latency
+low power states and non-transparent transitions</title> <p>This guide is
+only concerned with peripheral low power states that can be reached and left
+with no impact on system performance. However, it is possible that transitions
+to and from a peripheral low power state are long enough to have an impact
+on system performance, or cause loss of data, or the peripheral is not capable
+of detecting the hardware events required to guarantee correct operation while
+in a low power state. If this is the case, then the decision to transition
+to a low power state cannot be taken solely by the peripheral driver, and
+will have to be taken in agreement with the users and consumers of the services
+provided by this peripheral. </p> </section>
+<section id="GUID-CA1BB80F-5A1C-5B66-8091-84625A0A9CFB"><title>Peripheral
+power state diagram and transitions</title> <fig id="GUID-A1F2E1D2-FA3B-55C3-B7A3-1AECBDC37453">
+<title>Peripheral power state diagram</title>
+<image href="GUID-E55B594F-CC84-5984-9307-9819F6EBEB7F_d0e29647_href.png" placement="inline"/>
+</fig> <p>It can be assumed that when the peripheral driver is loaded, the
+peripheral is put into the <i>Low Power</i> state. If a new request is asserted
+on that peripheral driver from a user of that peripheral (which can include
+another dependent peripheral driver or user side Engine/server/application),
+the peripheral should move to its <i>Operational Power</i> state. The driver
+can then start monitoring for peripheral inactivity, and when that is detected,
+and no other dependent peripheral is using this peripheral, it can move the
+peripheral back to the <i>Low Power</i> state. </p> <p>If, however, the power
+manager requests the driver to power down the peripheral and no other dependent
+peripheral is using it, it then moves into its <i>Off</i> state from which
+it can only return to the <i>Operational Power</i> state when the power manager
+issues a power up request. Moving from the <i>Off</i> state to the <i>Operational
+Power</i> state is a relatively lengthy operation and requires resetting the
+internal state of the peripheral. </p> <p>If another dependent peripheral
+is using this peripheral, and the power manager issues a power down request,
+then the driver keeps the peripheral in its operational power state until
+the dependent peripheral relinquishes its request on it. </p> <p>From the <i>Low
+Power</i> state, a peripheral can also be turned Off (unconditionally) if
+the power manager so requests. It can be moved back to the <i>Operational
+Power</i> state on an internal event (Interrupt, Timer). </p> <fig id="GUID-C5AED7DE-18A1-5FBF-B1E4-44067F246CC2">
+<title>Peripheral power states</title>
+<image href="GUID-EFEACBE5-B9E1-5315-88CA-DA3B7C1BFCE0_d0e29694_href.png" placement="inline"/>
+</fig> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-1E43E258-A926-5D24-B0A5-8756491C687F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,384 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-1E43E258-A926-5D24-B0A5-8756491C687F" xml:lang="en"><title>Call
+Stack Information Commands</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Describes how to use the debug monitor commands to get information about
+the call stack. </p>
+<ul>
+<li id="GUID-9D1E42B6-658E-59DF-AC7D-0551B8EF6B61"><p> <xref href="GUID-1E43E258-A926-5D24-B0A5-8756491C687F.dita#GUID-1E43E258-A926-5D24-B0A5-8756491C687F/GUID-D8F141D7-3BE2-5ADB-8A55-CFFE85E89804">General points</xref>  </p> </li>
+<li id="GUID-92B8F3E9-11C1-5260-A862-6CE017984DB0"><p> <xref href="GUID-1E43E258-A926-5D24-B0A5-8756491C687F.dita#GUID-1E43E258-A926-5D24-B0A5-8756491C687F/GUID-1EC3F2E7-6BFF-56BE-B042-DA6940CC909E">Finding the stack</xref>  </p> </li>
+<li id="GUID-CEFC5F08-C19E-53DD-A0E2-C9C4FFFF3490"><p> <xref href="GUID-1E43E258-A926-5D24-B0A5-8756491C687F.dita#GUID-1E43E258-A926-5D24-B0A5-8756491C687F/GUID-877742A5-F07F-54B6-B871-255FAAE790EB">Tracing through the call stack heuristically</xref>  </p> </li>
+<li id="GUID-8D00F8C3-B367-5C75-89E4-B712002E942D"><p> <xref href="GUID-1E43E258-A926-5D24-B0A5-8756491C687F.dita#GUID-1E43E258-A926-5D24-B0A5-8756491C687F/GUID-7F160B0F-9921-578B-B9B0-7CC4CA3B24C3">Walking through the call stack</xref>  </p> </li>
+</ul>
+<section id="GUID-D8F141D7-3BE2-5ADB-8A55-CFFE85E89804"><title>General points</title> <p>Tracing
+the call stack is an advanced use of the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-2A0D5950-F1A5-5EE1-87A3-840B1EAD6AAD">m</xref> command that allows you to <xref href="GUID-DC2CF276-95E2-5810-9B8D-EB8B72E04FEC.dita">examine
+memory</xref>. </p> <p>Every time a function is called, the return address
+is automatically saved into register <codeph>R14</codeph> (Link Register).
+In addition to this the return address is generally pushed onto the call stack;
+it is always pushed in debug builds but the push operation is sometimes optimized
+out in release builds. This allows you to trace back through the value of <codeph>R14</codeph> and
+these saved addresses to see the sequence of function calls. Unfortunately
+this is quite tedious to do because the stack is also used for automatic variables
+and other data. You need to work out which values on the stack refer to return
+addresses. </p> <p>When you are debugging only ROM-based code, it is relatively
+easy to identify the pushed return addresses because all code addresses will
+be in the ROM range: <codeph>0xF800000</codeph> to <codeph>0xFFEFFFFF</codeph> for
+the <xref href="GUID-D520CBC3-FCAC-5A53-AE1A-E5254ABBC6A2.dita#GUID-D520CBC3-FCAC-5A53-AE1A-E5254ABBC6A2/GUID-A5845A0C-2C88-52BB-B7DE-210C2DE481B9">moving
+model</xref>. However, there is also data in the ROM, which means that an
+address on the stack which is in the ROM range could point to data instead
+of code. If you want to trace applications loaded into RAM, i.e. anything
+not run from drive Z:, then stack tracing is more difficult because the code
+can move about and RAM-loaded code is given an address assigned at load time. </p> <p>Note
+that <xref href="GUID-DA62FD4F-2E74-5B2F-B703-4A40DF5F01CA.dita">using the MAKSYM
+tool</xref> is essential for tracing back through the stack. </p> </section>
+<section id="GUID-1EC3F2E7-6BFF-56BE-B042-DA6940CC909E"><title>Finding the
+stack</title> <p>To trace back through a thread’s kernel or user stack, you
+first need to find the stack pointer value. On the ARM, <codeph>R13</codeph> always
+points to the stack, but there are different <codeph>R13</codeph> registers
+for each processor mode: </p> <ul>
+<li id="GUID-756C8CDD-AF47-561B-BAA7-EA8FBDEE5245"><p>In thread context: </p> <ul>
+<li id="GUID-81BC92C2-6022-5EBF-BF60-C4D69131C720"><p> <codeph>R13usr</codeph> points
+to the thread’s user stack, </p> </li>
+<li id="GUID-CA6CF8C9-0BA3-5BD4-AECE-80AB3DFCFAD1"><p> <codeph>R13svc</codeph> points
+to the thread’s kernel stack. </p> </li>
+</ul> </li>
+<li id="GUID-C4A1AD73-64E8-56F7-A7DF-129B2A35FC9D"><p>When handling interrupts,
+dedicated stacks are used: </p> <ul>
+<li id="GUID-7D27A691-1479-578B-9B05-7946C8D84010"><p> <codeph>R13Fiq</codeph> points
+to the stack used when processing fast interrupts (FIQ). </p> </li>
+<li id="GUID-CE76BE0F-A6BA-55A6-8CDD-B1E40D97A42D"><p> <codeph>R13Irq</codeph> points
+to the stack used when processing general purpose interrupts (IRQ). </p> </li>
+</ul> </li>
+</ul> <p>To find out which stack to inspect, you need to know what mode the
+CPU was in when the fault occurred. The <xref href="GUID-7ECDCF7B-3B2A-561F-9136-04BC4DAE46E4.dita#GUID-7ECDCF7B-3B2A-561F-9136-04BC4DAE46E4/GUID-BFA2235C-1598-59E6-9F1F-A8281F13A957">processor
+mode</xref> is identified by the five least-significant bits of the CPSR register.
+To get the value of the CPSR register: </p> <ul>
+<li id="GUID-2FAF9E34-CCF0-5C6E-AA6A-9D274433FC49"><p>use the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-D5F2E0AF-EF03-5150-813B-DF989F12C47B">f</xref> command when the debug monitor is triggered by a hardware exception. </p> </li>
+<li id="GUID-EECA647F-38C8-5B57-80EA-B4D9EBA1928B"><p>use the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-0CDF0190-A445-526B-AC1F-D9D58095B18B">r</xref> command when the debug monitor is triggered by a panic. </p> </li>
+</ul> <p>The following examples show how to find the stack(s): </p> <ul>
+<li id="GUID-A5533A14-EEF7-5A9F-B93B-E6E41ECF3928"><p> <xref href="GUID-1E43E258-A926-5D24-B0A5-8756491C687F.dita#GUID-1E43E258-A926-5D24-B0A5-8756491C687F/GUID-4E735CB7-3171-58FB-9D93-EE86702952F6">Kernel &amp; user stacks of the current thread after a hardware exception</xref>  </p> </li>
+<li id="GUID-750F8489-5918-5062-9ABC-C8951E50716A"><p> <xref href="GUID-1E43E258-A926-5D24-B0A5-8756491C687F.dita#GUID-1E43E258-A926-5D24-B0A5-8756491C687F/GUID-FB9D2307-01D9-562A-A46F-AAD91D61C32E">Kernel &amp; user stacks of the current thread after a panic</xref>  </p> </li>
+<li id="GUID-0ADBB680-827C-5AEF-96F9-B5684B146097"><p> <xref href="GUID-1E43E258-A926-5D24-B0A5-8756491C687F.dita#GUID-1E43E258-A926-5D24-B0A5-8756491C687F/GUID-C265F9C5-3280-5A4F-B023-56E33D52DDE0">Interrupt stacks</xref>  </p> </li>
+<li id="GUID-B7CA8584-317C-5ECB-9D4D-2EEFED3F51EA"><p> <xref href="GUID-1E43E258-A926-5D24-B0A5-8756491C687F.dita#GUID-1E43E258-A926-5D24-B0A5-8756491C687F/GUID-9637574E-A9A0-509D-B9B1-C672E2B13431">Kernel &amp; user stacks of a non-current thread</xref>  </p> </li>
+</ul> <p id="GUID-4E735CB7-3171-58FB-9D93-EE86702952F6"><b>Kernel &amp; user stacks
+of the current thread after a hardware exception</b> </p> <p>Use the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-D5F2E0AF-EF03-5150-813B-DF989F12C47B">f</xref> command. </p> <codeblock id="GUID-A92D63C6-1594-5C95-AAC2-42D2FDE5160F" xml:space="preserve">Fault Category: Exception  Fault Reason: 10000000
+ExcId 00000001 CodeAddr f816c908 DataAddr 80000001 Extra c0007003
+Exc 1 Cpsr=60000010 FAR=80000001 FSR=c0007003
+ R0=00000000  R1=00000000  R2=30000000  R3=80000001
+ R4=00000001  R5=00403d88  R6=00002000  R7=f816c768
+ R8=00000012  R9=00000040 R10=00000000 R11=00403fa4
+R12=00403d5c R13=00403d70 R14=f80906f8 R15=f816c908
+R13Svc=6571e000 R14Svc=f80074bc SpsrSvc=80000010
+</codeblock> <p>In this example: </p> <ul>
+<li id="GUID-7C35AE63-13E9-5D8D-A77F-CD1A0B9A5EF4"><p>the kernel stack is
+the value of <codeph>R13Svc</codeph>, i.e. <codeph>0x6571e00</codeph>. </p> </li>
+<li id="GUID-D70628B9-A750-5557-BACF-471D2D75A2E4"><p>the user stack is the
+value of <codeph>R13</codeph>, i.e. <codeph>0x00403d70</codeph>. </p> </li>
+</ul> <p id="GUID-FB9D2307-01D9-562A-A46F-AAD91D61C32E"><b>Kernel &amp; user stacks
+of the current thread after a panic</b> </p> <p>Use the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-0CDF0190-A445-526B-AC1F-D9D58095B18B">r</xref> command. </p> <codeblock id="GUID-705AF9EC-4513-5C3C-BD28-A91992D73296" xml:space="preserve">MODE_USR:
+ R0=6571de54  R1=0000002a  R2=00000002  R3=ffffffff
+ R4=0000002a  R5=f8170414  R6=6571df14  R7=6403cc50
+ R8=00000001  R9=6403c44c R10=640002f8 R11=6571de70
+R12=00000020 R13=00404e00 R14=f80818c0 R15=f800bfa8
+CPSR=60000013
+MODE_FIQ:
+ R8=00000000  R9=ffffffff R10=ffffffff R11=00000000
+R12=00000000 R13=64000d0c R14=c080079c SPSR=e00000dc
+MODE_IRQ:
+R13=6400110c R14=00000013 SPSR=20000013
+MODE_SVC:
+R13=6571de54 R14=f80328bc SPSR=60000010
+MODE_ABT:
+R13=6400090c R14=ccbfd0e0 SPSR=b00000d9
+MODE_UND:
+R13=6400090c R14=b5a39950 SPSR=f000009d
+</codeblock> <p>In this example: </p> <ul>
+<li id="GUID-C23A3F68-FAEB-596A-AF51-810E7429D17B"><p>the kernel stack is
+the value of <codeph>R13</codeph> under <codeph>MODE_SVC:</codeph>, i.e. <codeph>0x6571de54</codeph>. </p> </li>
+<li id="GUID-98FD71CA-BD17-5CB3-B0A8-0FBECFBF3ECF"><p>the user stack is the
+value of <codeph>R13</codeph> under <codeph>MODE_USR:</codeph>, i.e. <codeph>0x00404e00</codeph>. </p> </li>
+</ul> <p id="GUID-C265F9C5-3280-5A4F-B023-56E33D52DDE0"><b>Interrupt stacks</b> </p> <p>Use
+the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-0CDF0190-A445-526B-AC1F-D9D58095B18B">r</xref> command. </p> <codeblock id="GUID-28065EA2-194E-5D8D-8C1B-D85299B91431" xml:space="preserve">MODE_USR:
+ R0=6571de54  R1=0000002a  R2=00000002  R3=ffffffff
+ R4=0000002a  R5=f8170414  R6=6571df14  R7=6403cc50
+ R8=00000001  R9=6403c44c R10=640002f8 R11=6571de70
+R12=00000020 R13=00404e00 R14=f80818c0 R15=f800bfa8
+CPSR=60000013
+MODE_FIQ:
+ R8=00000000  R9=ffffffff R10=ffffffff R11=00000000
+R12=00000000 R13=64000d0c R14=c080079c SPSR=e00000dc
+MODE_IRQ:
+R13=6400110c R14=00000013 SPSR=20000013
+MODE_SVC:
+R13=6571de54 R14=f80328bc SPSR=60000010
+MODE_ABT:
+R13=6400090c R14=ccbfd0e0 SPSR=b00000d9
+MODE_UND:
+R13=6400090c R14=b5a39950 SPSR=f000009d
+</codeblock> <p>In this example: </p> <ul>
+<li id="GUID-6A48007B-973A-50F1-BCF5-31A72EC68D57"><p>the IRQ stack is the
+value of <codeph>R13</codeph> under <codeph>MODE_IRQ:</codeph>, i.e. <codeph>0x6400110c</codeph>. </p> </li>
+<li id="GUID-65CD3376-7D50-548F-A473-04B049034D0D"><p>the FRQ stack is the
+value of <codeph>R13</codeph> under <codeph>MODE_FIQ:</codeph>, i.e. <codeph>0x64000d0c</codeph>. </p> </li>
+</ul> <p id="GUID-9637574E-A9A0-509D-B9B1-C672E2B13431"><b>Kernel &amp; user stacks
+of a non-current thread</b> </p> <p>Use the output of the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-D0175D78-6F84-5F4F-BA90-2C591B473C69">i</xref>, <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-1DED2B2F-E780-50A0-8325-5DA22BC7D3E0">q</xref> and <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-FB2E24A6-9744-5169-BA90-DDF84DF1D3E5">c0</xref> commands. </p> <codeblock id="GUID-F45908AC-ADF8-5B92-AA8C-4C33D77D24B8" xml:space="preserve">THREAD at 6403c194 VPTR=f8046c18 AccessCount=5 Owner=6403bb4c
+Full name t_dmasim::Main
+Thread MState READY
+Default priority 12 WaitLink Priority 12
+ExitInfo 3,0,
+Flags 00000002, Handles 6403b418
+Supervisor stack base 6571d000 size 1000
+User stack base 00403000 size 2000
+Id=25, Alctr=00700000, Created alctr=00700000, Frame=00000000
+Trap handler=00000000, ActiveScheduler=007000c8, Exception handler=00000000
+TempObj=00000000 TempAlloc=00000000
+NThread @ 6403c44c Pri 12 NState READY
+Next=6403c44c Prev=6403c44c Att=03 iUserContextType=02
+HeldFM=00000000 WaitFM=00000000 AddrSp=6403bb4c
+Time=0 Timeslice=20 ReqCount=0
+SuspendCount=0 CsCount=1 CsFunction=00000000
+SavedSP=6571df98
+DACR f800bd2c
+R13_USR 0d404c38 R14_USR 00000001 SPSR_SVC 00000000
+ R4 f8022d84  R5 6571dfd4  R6 6571dfbc  R7 f8022db8
+ R8 f800bddc  R9 f800a454 R10 00000000 R11 f801daac
+ PC 60000010
+</codeblock> <p>In this example: </p> <ul>
+<li id="GUID-A4217DD4-A46C-5EAE-85D3-2EEAD763B726"><p>the kernel stack is
+the value of <codeph>SavedSP</codeph>, i.e. <codeph>0x6571df98</codeph>. </p> </li>
+<li id="GUID-8220888D-7411-5AC5-AD20-89E892301188"><p>the user stack is the
+value of <codeph>R13_USR</codeph>, i.e. <codeph>0x0d404c38</codeph>. </p> </li>
+</ul> </section>
+<section id="GUID-877742A5-F07F-54B6-B871-255FAAE790EB"><title>Tracing through
+the stack heuristically</title> <p>One way of tracing through the call stack
+is to assume that every word on the stack which looks like a ROM code address
+is a saved return address. We say that this heuristic because: </p> <ul>
+<li id="GUID-B5BF6BD6-0163-55F9-A34D-EB78982848B0"><p>some data words may
+look like code addresses in ROM. </p> </li>
+<li id="GUID-0A978212-73B6-5C89-B805-84327B9CF733"><p>there may be saved return
+addresses left over from previous function calls. For example, suppose that <codeph>F()</codeph> calls <codeph>A()</codeph> and
+then <codeph>B()</codeph> in sequence. <codeph>A()</codeph> itself calls <codeph>X()</codeph>,
+which calls <codeph>Y()</codeph>. If a crash occurs in <codeph>B()</codeph>,
+the saved return addresses from the calls to <codeph>X()</codeph> and <codeph>Y()</codeph> are
+still present on the stack and may be mistaken for function calls occuring
+while <codeph>B()</codeph> is active. </p> <p>This scenario happens frequently
+when <codeph>B()</codeph> allocates a buffer (e.g. <xref href="GUID-0B9C8884-6BFF-35E2-AA6F-E4057B85AFCF.dita"><apiname>TBuf</apiname></xref>)
+on the stack which overlaps old stack frames. </p> <fig id="GUID-FED8CC0F-F1A0-59C9-B082-2D3B499D00D5">
+<image href="GUID-A328F9E3-7D91-594A-A589-E8CE5FA9227A_d0e69077_href.png" placement="inline"/>
+</fig> </li>
+</ul> <p>If you want to trace applications loaded into RAM, then stack tracing
+is more difficult because RAM-loaded DLLs are given addresses assigned at
+load time. </p> <p>On ARM, the stack pointer starts at the higher address
+end and moves 'down' towards the lower address end. This means that values
+at the top of the memory dump are more recent. You need to look back through
+this for code addresses. For ROM code this will be words with most significant
+byte in the range <codeph>0xF8</codeph> to <codeph>0xFF</codeph>, remembering
+that they are little-endian. This can either be done manually, or automatically
+using the <filepath>printsym.pl</filepath> perl script, which can be found
+in <codeph>...\epoc32\tools</codeph>. </p> <p>Let's follow this in an example
+session: </p> <ul>
+<li id="GUID-D761405E-86BD-55ED-ACC6-C6D2125FDCE7"><p>Decide whether the crash
+has been caused by a panic or an exception using the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-D5F2E0AF-EF03-5150-813B-DF989F12C47B">f</xref> command: </p> <codeblock id="GUID-480D9B52-C556-5733-91E2-87D7F12651FC" xml:space="preserve">.f
+Fault Category: EXAMPLE  Fault Reason: 0000002a
+ExcId 00000000 CodeAddr 00000000 DataAddr 00000000 Extra 00000000
+</codeblock> </li>
+<li id="GUID-73690262-2895-51ED-9532-E76638B0EC1E"><p>This shows that the
+crash was caused by a panic, so now use the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-0CDF0190-A445-526B-AC1F-D9D58095B18B">r</xref> command to find the CPU mode and the stack pointer: </p> <codeblock id="GUID-1FB9E3E1-54FF-5109-804D-2D6109626A66" xml:space="preserve">.r
+MODE_USR:
+ R0=6571de54  R1=0000002a  R2=00000002  R3=ffffffff
+ R4=0000002a  R5=f8170414  R6=6571df14  R7=6403cba8
+ R8=00000001  R9=6403c41c R10=640002f8 R11=6571de70
+R12=00000020 R13=00404e00 R14=f80818c0 R15=f800bfa8
+CPSR=60000013
+MODE_FIQ:
+ R8=00000000  R9=ffffffff R10=ffffffff R11=00000000
+R12=00000000 R13=64000d0c R14=c080079c SPSR=e00000dc
+MODE_IRQ:
+R13=6400110c R14=00000013 SPSR=20000013
+MODE_SVC:
+R13=6571de54 R14=f80328bc SPSR=60000010
+MODE_ABT:
+R13=6400090c R14=ffff0010 SPSR=400000d7
+MODE_UND:
+R13=6400090c R14=95221110 SPSR=f000009d
+</codeblock> <p>The panic happened in supervisor mode, because <codeph>CPSR
+&amp;                 0x1F == 0x13</codeph>, so <codeph>R13Svc</codeph>, i.e.
+the value of <codeph>R13</codeph> shown under <codeph>MODE_SVC:</codeph> in
+the above display, is the stack pointer to look at; this has the value <codeph>0x6571DE54</codeph>. </p> </li>
+<li id="GUID-CE74A8F7-97EF-5ACD-BA16-A35CDA293B3D"><p>Using the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-2A0D5950-F1A5-5EE1-87A3-840B1EAD6AAD">m</xref> command to look at memory starting at location <codeph>0x6571DE54</codeph> gives: </p> <codeblock id="GUID-BF6D6BD9-ADDE-587F-85B6-39140620B9AC" xml:space="preserve">.m6571de54+200
+6571de54: 07 00 00 10 14 04 17 f8 00 00 00 00 d4 4e 40 00 .............N@.
+6571de64: e8 de 71 65 74 de 71 65 74 fb 16 f8 88 28 03 f8 ..qet.qet....(..
+6571de74: 0c d4 03 f8 64 35 03 f8 00 00 00 00 00 00 00 00 ....d5..........
+6571de84: d0 00 00 00 14 df 71 65 a8 cb 03 64 a8 cb 03 64 ......qe...d...d
+6571de94: d0 00 00 00 14 df 71 65 1c df 71 65 ec 4e 40 00 ......qe..qe.N@.
+6571dea4: 1c c4 03 64 b4 2a 03 f8 00 00 00 00 14 df 71 65 ...d.*........qe
+6571deb4: d0 de 71 65 c4 de 71 65 b0 ab 03 f8 00 00 00 00 ..qe..qe........
+6571dec4: e0 ba 03 64 14 df 71 65 1c df 71 65 01 00 00 00 ...d..qe..qe....
+6571ded4: 1c c4 03 64 f8 02 00 64 10 df 71 65 ec de 71 65 ...d...d..qe..qe
+6571dee4: 84 da 01 f8 5c fb 16 f8 00 4e 40 00 00 00 00 00 ....\....N@.....
+6571def4: 00 4e 40 00 00 00 00 00 d3 00 00 00 ec 4e 40 00 .N@..........N@.
+6571df04: d4 df 71 65 14 df 71 65 e0 db 01 f8 c0 d9 01 f8 ..qe..qe........
+6571df14: a8 cb 03 64 e0 ba 03 64 01 00 01 00 00 00 00 00 ...d...d........
+6571df24: 00 00 00 00 d4 4e 40 00 00 00 00 30 40 00 00 00 .....N@....0@...
+6571df34: 13 00 00 60 98 df 71 65 48 df 71 65 f4 81 00 f8 ...`..qeH.qe....
+6571df44: 8c 7a 00 f8 68 df 71 65 58 df 71 65 6c df 71 65 .z..h.qeX.qel.qe
+6571df54: 60 df 71 65 0c 2b 00 f8 bc 2a 00 f8 84 df 71 65 `.qe.+...*....qe
+6571df64: 70 df 71 65 e4 7d 04 f8 08 2b 00 f8 0d 00 00 00 p.qe.}...+......
+6571df74: 0a 00 00 30 40 00 00 00 54 65 73 74 44 6d 61 53 ...0@...TestDmaS
+6571df84: 69 6d 04 f8 a9 4b 40 00 b8 df 71 65 9c df 71 65 im...K@...qe..qe
+6571df94: 2c be 00 f8 2c bd 00 f8 38 4c 40 0d 01 00 00 00 ,...,...8L@.....
+6571dfa4: 00 00 00 00 84 2d 02 f8 d4 df 71 65 bc df 71 65 .....-....qe..qe
+6571dfb4: b8 2d 02 f8 dc bd 00 f8 54 a4 00 f8 00 00 00 00 .-......T.......
+6571dfc4: ac da 01 f8 10 00 00 60 d8 df 71 65 70 74 00 f8 .......`..qept..
+6571dfd4: b8 da 01 f8 d4 4e 40 00 20 f7 16 f8 d0 4e 40 00 .....N@. ....N@.
+6571dfe4: 00 00 00 00 00 00 00 00 ec 4e 40 00 40 00 00 00 .........N@.@...
+</codeblock> <p>We can look for potential ROM addresses by scanning the log
+and look up the corresponding function name in the symbol file generated <xref href="GUID-DA62FD4F-2E74-5B2F-B703-4A40DF5F01CA.dita">using the MAKSYM tool</xref> .
+The first one is <codeph>0xF8170414</codeph> at offset <codeph>4</codeph> in
+the memory dump. </p> </li>
+<li id="GUID-3197B03A-FD94-5D78-B699-22BDCE71DD1D"><p>Alternatively, we can
+use the <filepath>printsym.pl</filepath> perl script, passing it the dump
+output. The following is part of the output: </p> <codeblock id="GUID-B4289E03-6E98-591D-9E26-CEEDC3CD9437" xml:space="preserve">R:\base\e32\rombuild&gt;perl -S printsym.pl ASSABETARM4D.symbol
+ROM Symbols from ASSABETARM4D.symbol
+Please enter data to be decoded
+6571de54: 07 00 00 10 14 04 17 f8 00 00 00 00 d4 4e 40 00 .............N@.
+= 10000007 ....    
+= f8170414 ....  etext=. + 0x0
+= 00000000 ....
+= 00404ed4 .N@.
+6571de64: e8 de 71 65 74 de 71 65 74 fb 16 f8 88 28 03 f8 ..qet.qet....(..
+= 6571dee8 ..qe
+= 6571de74 t.qe
+= f816fb74 t...  DDmaTestChannel::DoCreate(int, TDesC8 const *, TVersion const &amp;
+) + 0x24
+= f8032888 .(..  Kern::Fault(char const *, int) + 0xc
+6571de74: 0c d4 03 f8 64 35 03 f8 00 00 00 00 00 00 00 00 ....d5..........
+= f803d40c ....  RHeap::Alloc(int) + 0xf4
+= f8033564 d5..  Kern::MutexSignal(DMutex &amp;) + 0xc
+= 00000000 ....
+= 00000000 ....
+
+[............ truncated ...............]
+
+= f801da84 ....  DLogicalDevice::ChannelCreate(DLogicalChannelBase *&amp;, TChannelC
+reateInfo &amp;) + 0xd0
+= f816fb5c \...  DDmaTestChannel::DoCreate(int, TDesC8 const *, TVersion const &amp;
+) + 0xc
+= 00404e00 .N@.
+= 00000000 ....
+6571def4: 00 4e 40 00 00 00 00 00 d3 00 00 00 ec 4e 40 00 .N@..........N@.
+= 00404e00 .N@.
+= 00000000 ....
+= 000000d3 ....
+= 00404eec .N@.
+6571df04: d4 df 71 65 14 df 71 65 e0 db 01 f8 c0 d9 01 f8 ..qe..qe........
+= 6571dfd4 ..qe
+= 6571df14 ..qe
+= f801dbe0 ....  ExecHandler::ChannelCreate(TDesC8 const &amp;, TChannelCreateInfo &amp;
+, int) + 0x134
+= f801d9c0 ....  DLogicalDevice::ChannelCreate(DLogicalChannelBase *&amp;, TChannelC
+reateInfo &amp;) + 0xc
+
+[.......................... truncated .........................]
+
+= f8022db8 .-..  ExecHandler::DebugPrint(void *, int) + 0x34
+= f800bddc ....  A::UserDebugPrint(unsigned char const *, int, int) + 0xc
+= f800a454 T...  EpocSlowExecTable + 0xc
+= 00000000 ....
+6571dfc4: ac da 01 f8 10 00 00 60 d8 df 71 65 70 74 00 f8 .......`..qept..
+= f801daac ....  ExecHandler::ChannelCreate(TDesC8 const &amp;, TChannelCreateInfo &amp;
+, int) + 0x0
+= 60000010 ...`
+= 6571dfd8 ..qe
+= f8007470 pt..  __ArmVectorSwi + 0xd8
+6571dfd4: b8 da 01 f8 d4 4e 40 00 20 f7 16 f8 d0 4e 40 00 .....N@. ....N@.
+= f801dab8 ....  ExecHandler::ChannelCreate(TDesC8 const &amp;, TChannelCreateInfo &amp;
+, int) + 0xc
+= 00404ed4 .N@.
+= f816f720  ...  etext=. + 0x560
+= 00404ed0 .N@.
+6571dfe4: 00 00 00 00 00 00 00 00 ec 4e 40 00 40 00 00 00 .........N@.@...
+= 00000000 ....
+= 00000000 ....
+= 00404eec .N@.
+= 00000040 @...
+^C
+R:\base\e32\rombuild&gt;
+</codeblock> <p>There are several false positives in this output (and even
+more in the truncated parts). So some study of the source code is needed to
+discard the noise and find the actual call stack. Here it is (innermost frame
+first): </p> <ul>
+<li id="GUID-C83CA525-1731-56BC-8C98-4AEEB5809780"><p> <codeph>Kern::Fault</codeph>  </p> </li>
+<li id="GUID-40B7B48A-F6A0-5CD6-9C0C-2E432FF760BA"><p> <codeph>DDmaTestChannel::DoCreate</codeph>  </p> </li>
+<li id="GUID-E9327B91-F69C-5BC1-B964-FE1B90CA314C"><p> <codeph>ExecHandler::ChannelCreate</codeph>  </p> </li>
+<li id="GUID-0391ADD8-EF56-51F9-987F-B9111903EAC7"><p> <codeph> __ArmVectorSwi</codeph>  </p> </li>
+</ul> <p>Note that for the sake of the example, a call to <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-45337A03-5893-3D0D-948C-23BDCF8AECBD"><apiname>Kern::Fault()</apiname></xref> was
+deliberately inserted into <xref href="GUID-63F99C5E-55C4-305B-BA86-CF73B0CF1520.dita#GUID-63F99C5E-55C4-305B-BA86-CF73B0CF1520/GUID-F0A1E76C-A0E1-39C9-845C-BE19FE2EB415"><apiname>DDmaTestChannel::DoCreate()</apiname></xref>. </p> <p>All
+other function names are false positives and should be ignored. </p> </li>
+</ul> </section>
+<section id="GUID-7F160B0F-9921-578B-B9B0-7CC4CA3B24C3"><title>Walking through
+the call stack</title> <p>The heuristic method is quick but produces lots
+of false positives. Another option is to manually reconstitute the call stack
+from the memory dump. This is relatively easy for debug builds because GCC
+uses R11 as a frame pointer (FP) and generates the same prologue/epilogue
+for every function. </p> <p>For release builds, there is no generic solution.
+It is necessary to check the generated assembler code as there is no standard
+prologue/epilogue and R11 is not used as frame pointer. </p> <p>A typical
+prologue for a debug ARM function looks like this: </p> <codeblock id="GUID-9C1F71E0-5F2A-50FF-ABD2-035EB9B5B4D9" xml:space="preserve">mov        ip, sp
+stmfd    sp!, {fp, ip, lr, pc}
+sub        fp, ip, #4        /* FP now points to base of stack frame */
+sub        sp, sp, #16    /* space for local variables */
+</codeblock> <p>noting that: <codeph>SP = R13</codeph>, <codeph>FP = R11</codeph>, <codeph>IP
+=           R12</codeph>, <codeph>LR = R14</codeph>, and <codeph>PC = R15</codeph>. </p> <p>This
+code creates the following stack frame: </p> <fig id="GUID-5CE044A2-CDD0-5A09-B824-BAF46324AB27">
+<image href="GUID-F12437C5-BD96-5B43-AD76-614CFAB104D2_d0e69275_href.png" placement="inline"/>
+</fig> <p>Looking at the example session listed in when <xref href="GUID-1E43E258-A926-5D24-B0A5-8756491C687F.dita#GUID-1E43E258-A926-5D24-B0A5-8756491C687F/GUID-877742A5-F07F-54B6-B871-255FAAE790EB">tracing through the stack heuristically</xref>. in which the crash is due
+to a panic, the FP value is the R11 value; this is <codeph>0x6571de70</codeph>.
+This gives us the innermost stack frame: </p> <codeblock id="GUID-DE5FFB23-A85D-562F-858B-CFF407448E36" xml:space="preserve">6571de64:    e8 de 71 65 &lt;------------- pointer to previous stack frame 
+            74 de 71 65 
+            74 fb 16 f8 &lt;------------- Saved return address 
+            88 28 03 f8 &lt;------------- FP points to this word
+</codeblock> <p>Looking up the saved return address, <codeph>0xf816fb74</codeph>,
+in the symbol file shows that the current function was called from <codeph>DDmaChannel::DoCreate()</codeph>. </p> <codeblock id="GUID-576615AE-2253-595C-97F5-1DC05F79B750" xml:space="preserve">f816fb50    0198    DDmaTestChannel::DoCreate(int, TDesC8 const *, TVersion const &amp;)
+f816fce8    007c    DDmaTestChannel::~DDmaTestChannel(void)
+f816fd64    0294    DDmaTestChannel::Request(int, void *, void *)
+</codeblock> <p>Using the pointer to the previous stack frame saved into the
+current frame, we can decode the next frame: </p> <codeblock id="GUID-570DB2F6-A76F-5858-816F-7A0E8562B35A" xml:space="preserve">6571ded4:    1c c4 03 64 
+            f8 02 00 64 
+            10 df 71 65 &lt;------------- pointer to previous stack frame 
+            ec de 71 65 
+
+6571dee4:    84 da 01 f8 &lt;------------- saved return address 
+            5c fb 16 f8 &lt;------------- start of second stack frame 
+            00 4e 40 00 
+            00 00 00 00 
+</codeblock> <p>Looking up the saved return address, <codeph>0xf801da84</codeph>,
+in the symbol file shows that <codeph>DDmaTestChannel::DoCreate()</codeph> was
+called from <codeph>DLogicalDevice::ChannelCreate()</codeph>. </p> <codeblock id="GUID-B36A9D49-5414-5CC3-8CBF-A2A0EE332B3C" xml:space="preserve">f801d9b4    00f8    DLogicalDevice::ChannelCreate(DLogicalChannelBase *&amp;, TChannelCreateInfo &amp;)
+f801daac    01b8    ExecHandler::ChannelCreate(TDesC8 const &amp;, TChannelCreateInfo &amp;, int)
+f801dc64    00e4    ExecHandler::ChannelRequest(DLogicalChannelBase *, int, void *, void *)
+</codeblock> <p>And here is the third stack frame: </p> <codeblock id="GUID-B07DEA17-BA2F-5FEA-8781-E44682BE2D1D" xml:space="preserve">6571df04:    d4 df 71 65 &lt;------------- pointer to previous stack frame 
+            14 df 71 65 
+            e0 db 01 f8 &lt;------------- saved return address 
+            c0 d9 01 f8 &lt;------------- start of third stack frame 
+</codeblock> <p>So <codeph>DLogicalDevice::ChannelCreate()</codeph> was called
+from <codeph>ExecHandler::ChannelCreate()</codeph>. </p> <p>Note that this
+mechanical way of walking the stack is valid only for debug functions. For
+release functions, it is necessary to study the code generated by the compiler. </p> <p>For
+completness, this is a typical prologue for a debug THUMB function: </p> <codeblock id="GUID-2DC6601E-6304-5638-A1F6-F44F1AB26288" xml:space="preserve">push    { r7, lr }
+sub        sp, #28
+add        r7, sp, #12 /* R7 is THUMB frame pointer */
+</codeblock> <p>and this creates the following stack frame: </p> <fig id="GUID-85FAEE94-6D61-5D6B-84CB-6A9491927077">
+<image href="GUID-5CF162CA-4395-58AC-A318-2BF178276A57_d0e69352_href.png" placement="inline"/>
+</fig> <p>A call stack can mix ARM and THUMB frames. Odd return addresses
+are used for THUMB code and even ones for ARM code. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,468 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A" xml:lang="en"><title>Kernel
+State Information Commands</title><shortdesc>Describes how to use the <codeph>i</codeph> command to get detailed
+information on the current process, thread, user process, user thread, and
+the state of the kernel. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The output shown below is a typical result of using the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-D0175D78-6F84-5F4F-BA90-2C591B473C69">i</xref> command, and we use this to illustrate how information can be extracted
+about the: </p>
+<ul>
+<li id="GUID-FCDEBC28-363F-539C-BCF7-C472ED279C5A"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-D64C53F4-78D4-51FC-B7DD-27E10B435CFD">Scheduler state</xref>  </p> </li>
+<li id="GUID-12616D76-643A-5814-833A-0C3CDD92BD97"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-31DF5393-FD03-56B7-B5F2-1F6DBD86D7C4">Current thread state</xref>  </p> </li>
+<li id="GUID-EF2FF4EC-7F11-5F72-BEC3-7F25762889F3"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-2424E413-F2F3-5625-932D-515860911424">Current process state</xref>  </p> </li>
+<li id="GUID-4B3694AB-AB36-5AEC-A514-CB858F5EFEB0"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-877907D5-6A04-510B-AE99-C3856A0469E7">Current data section process</xref>  </p> </li>
+</ul>
+<codeblock id="GUID-8ACEF4EF-0C02-50A9-8E2B-EB3917E9B726" xml:space="preserve">SCHEDULER @64000348: CurrentThread 640396b0
+RescheduleNeeded=00 DfcPending=00 KernCSLocked=00000001
+DFCS: next 64000458 prev 64000458
+ProcessHandler=f8014904, AddressSpace=64038d5c
+SYSLOCK: HoldingThread 00000000 iWaiting 00000000
+Extras 0: 64038d5c 1: 64038d5c 2: 64038d5c 3: 00000000
+Extras 4: 00000000 5: 00000000 6: 00000000 7: 00000000
+Extras 8: 00000000 9: 00000000 A: 00000000 B: 00000000
+Extras C: 00000000 D: 00000000 E: 00000000 F: 00000000
+
+TheCurrentThread=64039408
+THREAD at 64039408 VPTR=f803423c AccessCount=3 Owner=64038d5c
+Full name test2.exe::Main
+Thread MState READY
+Default priority 16 WaitLink Priority 16
+ExitInfo 2,100,USER
+Flags 00000004, Handles 640330bc
+Supervisor stack base 6571f000 size 1000
+User stack base 00402000 size 2000
+Id=26, Alctr=00600000, Created alctr=00600000, Frame=00000000
+Trap handler=00000000, ActiveScheduler=00000000, Exception handler=00000000
+TempObj=00000000 TempAlloc=00000000 IpcCount=00000000
+NThread @ 640396b0 Pri 16 NState READY
+Next=640396b0 Prev=640396b0 Att=03 iUserContextType=0b
+HeldFM=00000000 WaitFM=00000000 AddrSp=64038d5c
+Time=17 Timeslice=20 ReqCount=0
+SuspendCount=0 CsCount=1 CsFunction=fffffffe
+SavedSP=6571ff34 ExtraContext=00000000 ExtraContextSize=0000
+DACR 63990000
+R13_USR 6571ff88 R14_USR f8025bc0 SPSR_SVC 10000004
+ R4 f8033794  R5 64039408  R6 640396b0  R7 f8028518
+ R8 640396b0  R9 640396b0 R10 00000000 R11 f80284d8
+ PC 00000000
+
+TheCurrentProcess=64038d5c
+PROCESS at 64038d5c VPTR=f80342a4 AccessCount=6 Owner=00000000
+Full name test2.exe
+ExitInfo 3,0,
+Flags a0000000, Handles 6403860c, Attributes 60010000
+DataBssChunk 64039234, CodeSeg 6403919c
+DllLock 64039044, Process Lock 64038eec SID 00000000
+TempCodeSeg 00000000 CodeSeg 6403919c Capability 00000000 0003ffff
+CodeSegs: Count=0
+NumChunks=2
+0: Chunk 64039234, run 00400000, access count 1
+1: Chunk 6403613c, run 00600000, access count 1
+Process shared IO buffers cookie 0000031d
+Process has no shared IO buffers
+Domain -1, DACR 55555507
+TheCurrentAddressSpace=64038d5c
+TheCurrentVMProcess=64038d5c
+PROCESS at 64038d5c VPTR=f80342a4 AccessCount=6 Owner=00000000
+Full name test2.exe
+ExitInfo 3,0,
+Flags a0000000, Handles 6403860c, Attributes 60010000
+DataBssChunk 64039234, CodeSeg 6403919c
+DllLock 64039044, Process Lock 64038eec SID 00000000
+TempCodeSeg 00000000 CodeSeg 6403919c Capability 00000000 0003ffff
+CodeSegs: Count=0
+NumChunks=2
+0: Chunk 64039234, run 00400000, access count 1
+1: Chunk 6403613c, run 00600000, access count 1
+Process shared IO buffers cookie 0000031d
+Process has no shared IO buffers
+Domain -1, DACR 55555507
+TheCurrentDataSectionProcess=64038d5c
+TheCompleteDataSectionProcess=64038d5c
+PROCESS at 64038d5c VPTR=f80342a4 AccessCount=6 Owner=00000000
+Full name test2.exe
+ExitInfo 3,0,
+Flags a0000000, Handles 6403860c, Attributes 60010000
+DataBssChunk 64039234, CodeSeg 6403919c
+DllLock 64039044, Process Lock 64038eec SID 00000000
+TempCodeSeg 00000000 CodeSeg 6403919c Capability 00000000 0003ffff
+CodeSegs: Count=0
+NumChunks=2
+0: Chunk 64039234, run 00400000, access count 1
+1: Chunk 6403613c, run 00600000, access count 1
+Process shared IO buffers cookie 0000031d
+Process has no shared IO buffers
+Domain -1, DACR 55555507
+</codeblock>
+<section id="GUID-D64C53F4-78D4-51FC-B7DD-27E10B435CFD"><title>Scheduler state</title> <p>The
+first three lines and the fifth line of the output show the state of the kernel
+scheduler. This information is mainly of interest to kernel engineers, although
+the state of the kernel and the system locks can be useful when debugging
+device driver crashes. </p> <codeblock id="GUID-D21A9A99-C956-5276-AEE1-3609CE72DB6E" xml:space="preserve">SCHEDULER @64000348: CurrentThread 640396b0
+RescheduleNeeded=00 DfcPending=00 KernCSLocked=00000001
+DFCS: next 64000458 prev 64000458
+...
+SYSLOCK: HoldingThread 00000000 iWaiting 00000000
+</codeblock> <p>The values are interpreted as follows: </p> <table id="GUID-E13DE258-ACD5-5EEB-AFC7-988747AA3863">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>SCHEDULER @</codeph>  </p> </entry>
+<entry><p>This is the address of the kernel’s scheduler instance; this is
+not very useful. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>CurrentThread</codeph>  </p> </entry>
+<entry><p>The address of the kernel object for the current kernel thread. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RescheduleNeeded</codeph>  </p> </entry>
+<entry><p>This is set to non-zero by the kernel to force a reschedule, for
+example if a thread has been signalled </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>DfcPending</codeph>  </p> </entry>
+<entry><p>This is non-zero when there are DFCs queued. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KernCSLocked</codeph>  </p> </entry>
+<entry><p>This is incremented each time the kernel is locked by a call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-7CBBF72B-4519-38DD-92CA-38AF636AFD8A"><apiname>NKern::Lock()</apiname></xref>,
+and decremented by calls to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-A1A42137-906C-30F1-AF61-4F786FC372DE"><apiname>NKern::Unlock()</apiname></xref>. A value of
+zero means that the kernel is not locked. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>DFCS:</codeph>  </p> </entry>
+<entry><p>The addresses of the next and the previous items on the DFC queue </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>HoldingThread</codeph>  </p> </entry>
+<entry><p>The address of the thread holding the system lock mutex. The system
+lock is set by call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-B3837744-B8CC-3DC0-BA1D-417016E88EE9"><apiname>NKern::LockSystem()</apiname></xref> and unset by
+call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-63B882C8-C5D0-3595-BBF1-74E942A5060A"><apiname>NKern::UnlockSystem()</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>iWaiting</codeph>  </p> </entry>
+<entry><p>Non-zero, if any thread is waiting for the system lock mutex. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-31DF5393-FD03-56B7-B5F2-1F6DBD86D7C4"><title>Current thread
+state</title> <p>The current thread is the thread that was executing when
+the fault occurred. The 23 lines starting at line 10 of the output gives information
+relating to the current thread: </p> <codeblock id="GUID-2AB3CE2B-3428-5CFD-8480-FE33B07972C3" xml:space="preserve">TheCurrentThread=64039408
+THREAD at 64039408 VPTR=f803423c AccessCount=3 Owner=64038d5c
+Full name test2.exe::Main
+Thread MState READY
+Default priority 16 WaitLink Priority 16
+ExitInfo 2,100,USER
+Flags 00000004, Handles 640330bc
+Supervisor stack base 6571f000 size 1000
+User stack base 00402000 size 2000
+Id=26, Alctr=00600000, Created alctr=00600000, Frame=00000000
+Trap handler=00000000, ActiveScheduler=00000000, Exception handler=00000000
+TempObj=00000000 TempAlloc=00000000 IpcCount=00000000
+NThread @ 640396b0 Pri 16 NState READY
+Next=640396b0 Prev=640396b0 Att=03 iUserContextType=0b
+HeldFM=00000000 WaitFM=00000000 AddrSp=64038d5c
+Time=17 Timeslice=20 ReqCount=0
+SuspendCount=0 CsCount=1 CsFunction=fffffffe
+SavedSP=6571ff34 ExtraContext=00000000 ExtraContextSize=0000
+DACR 63990000
+R13_USR 6571ff88 R14_USR f8025bc0 SPSR_SVC 10000004
+ R4 f8033794  R5 64039408  R6 640396b0  R7 f8028518
+ R8 640396b0  R9 640396b0 R10 00000000 R11 f80284d8
+ PC 00000000</codeblock> <ul>
+<li id="GUID-0CEB1586-DB4D-5390-AEB8-987681EA07B2"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-38E186F9-73E3-5A15-9AAF-3CEFCDC0540B">Thread object and access count</xref>  </p> </li>
+<li id="GUID-48F79826-183C-5EE0-9B00-FB1D0B66040D"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-73FCD8C6-089B-54E1-A6CA-798DAC33B6DF">The thread name</xref>  </p> </li>
+<li id="GUID-75A20FEF-7C66-567C-A774-657065912FF3"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-2581D5E1-6CA2-55AC-ABD9-9E67AF4AE692">The thread state, exit information, priority</xref>  </p> </li>
+<li id="GUID-DA7CBB15-0537-5116-8026-F0873AB537F9"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-58B010AF-587A-556D-B831-B083C5BC11EE">Thread flags</xref>  </p> </li>
+<li id="GUID-B7DA3F70-5CC8-538D-A2ED-F98EB30D8577"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-026A5C10-C2F5-564A-B5CC-AE2B76A144A9">Handles</xref>  </p> </li>
+<li id="GUID-6820DE1D-5109-555B-9BF3-F9FF55507393"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-033C939E-BA01-5FC4-AD77-17FD891FE724">Kernel &amp; user stack addresses</xref>  </p> </li>
+<li id="GUID-6FA4EFD8-AE98-5E73-AF5D-8BC202419EB8"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-595813CE-C13C-5E27-9016-63A9FEA393C0">Thread id, RAllocator instances, trap frame</xref>  </p> </li>
+<li id="GUID-0144EA8F-E1A8-5F3C-9826-FC4642135FE0"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-71901B6F-6BBF-5DCC-8F3F-DC601DB21543">Trap handler, active scheduler and user-side exception handler</xref>  </p> </li>
+<li id="GUID-1FCA2909-CE38-5DE8-A5EA-4A4516D6BBA2"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-62666275-C252-5EE0-B3F5-21F65600AD1D">Temporary object, temporary allocation, IPC count</xref>  </p> </li>
+<li id="GUID-5A1CC314-6891-53DA-AF5E-1E4DE0598E4B"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-6C42738E-2644-5064-B349-B48266BF286D">Underlying nanokernel thread</xref>  </p> </li>
+<li id="GUID-3F5BD294-813F-595D-93DF-802C9A1E519D"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-3C1A2A53-E2BE-5959-9F2D-C63400F6AABA">Fast mutexes</xref>  </p> </li>
+<li id="GUID-70CC2F58-E3FC-59D5-A645-AD27BC3C184C"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-36E24838-15FB-5A69-9122-7AFF98F219AE">Timing, request semaphore count</xref>  </p> </li>
+</ul> <p id="GUID-38E186F9-73E3-5A15-9AAF-3CEFCDC0540B"><b>Thread object and access
+count</b> </p> <codeblock id="GUID-15EEA149-76AF-57BD-A67D-4337020933E8" xml:space="preserve">THREAD at 64039408 VPTR=f803423c AccessCount=3 Owner=64038d5c</codeblock> <p>The <codeph>THread at</codeph> field contains a pointer to the <codeph>DThread</codeph> object
+representing the thread. </p> <p>The <codeph>AccessCount</codeph> field contains
+the reference count on the thread object. </p> <p>The <codeph>owner</codeph> field
+contains a pointer to the object that owns this <codeph>DThread</codeph> object. </p> <p id="GUID-73FCD8C6-089B-54E1-A6CA-798DAC33B6DF"><b>The thread name</b> </p> <codeblock id="GUID-05E008EE-375F-51D0-B738-42A978B167E4" xml:space="preserve">Full name test2.exe::Main</codeblock> <p>The
+thread name is the part after the colons. The part before the colons is the
+process name. This means that the thread is called <b>Main</b> inside the
+process <b>test2.exe</b>. </p> <p id="GUID-2581D5E1-6CA2-55AC-ABD9-9E67AF4AE692"><b>The thread state, exit information,
+priority</b> </p> <codeblock id="GUID-FCFE05EE-FE8B-514D-9EC9-44C14A5DE700" xml:space="preserve">Thread MState READY
+Default priority 16 WaitLink Priority 16
+ExitInfo 2,100,USER</codeblock> <p>The information that characterises the
+thread exit is described by <codeph>ExitInfo</codeph>; this is shown as exit
+type, exit reason and exit category. In this example: </p> <ul>
+<li id="GUID-E9CE2364-F8B2-5990-8AFD-94BDD0C9782A"><p>the thread has panicked,
+as indicated by: <b>exit type 2</b>; See also <xref href="GUID-0296BFC6-7F7C-3259-AF21-7E9B5C304B24.dita"><apiname>TExitType</apiname></xref>. </p> </li>
+<li id="GUID-96DACA09-4212-5E6C-8834-53F5B4EE6A82"><p>the panic category was: <b>USER</b>  </p> </li>
+<li id="GUID-1077CDFF-4C1D-5256-8A32-FA4B6118541A"><p>the panic number was:<b>100</b>  </p> </li>
+<li id="GUID-E42997ED-A327-57BC-BA7B-0D6EEA8BEA95"><p>the thread was running
+or it was in a ready-to-run state: <b>MState READY</b>  </p> </li>
+</ul> <p>The priority shown is for the underlying thread, see also <xref href="GUID-49379616-C235-598D-AE43-668998AD072B.dita#GUID-49379616-C235-598D-AE43-668998AD072B/GUID-4D7F6A1F-3120-5547-B027-344C08A01D83">Process and thread priorities</xref>. </p> <p id="GUID-58B010AF-587A-556D-B831-B083C5BC11EE"><b>Thread flags</b> </p> <codeblock id="GUID-7D1F17F6-ED74-5A3A-9214-D85B91D52CC4" xml:space="preserve">Flags 00000004, Handles 640330bc</codeblock> <p>The <codeph>Flags</codeph> field
+contains information about the state of the thread. The possible values in
+this field are defined by the <codeph>KThread...</codeph> constants in <filepath>u32std.h</filepath>.
+While the symbols are internal to Symbian platform, the following table summarises
+the values and their meaning. </p> <table id="GUID-46D4FB94-284B-5415-8E8A-54EED6C4E37F">
+<tgroup cols="3"><colspec colname="col0"/><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p> <b>Symbol</b>  </p> </entry>
+<entry><p> <b>Value</b>  </p> </entry>
+<entry><p> <b>Meaning</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KThreadFlagProcessCritical</codeph>  </p> </entry>
+<entry><p> <codeph>0x00000001</codeph>  </p> </entry>
+<entry><p>A thread panic causes the process to panic. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KThreadFlagProcessPermanent</codeph>  </p> </entry>
+<entry><p> <codeph>0x00000002</codeph>  </p> </entry>
+<entry><p>If the thread exits for any reason, then this causes the process
+to exit. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KThreadFlagSystemCritical</codeph>  </p> </entry>
+<entry><p> <codeph>0x00000004</codeph>  </p> </entry>
+<entry><p>If the thread panics, then this causes the entire system to reboot. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KThreadFlagSystemPermanent</codeph>  </p> </entry>
+<entry><p> <codeph>0x00000008</codeph>  </p> </entry>
+<entry><p>If the thread exits for any reason, then this causes the entire
+system to reboot. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KThreadFlagOriginal</codeph>  </p> </entry>
+<entry><p> <codeph>0x00000010</codeph>  </p> </entry>
+<entry><p>Reserved for future use. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KThreadFlagLastChance</codeph>  </p> </entry>
+<entry><p> <codeph>0x00000020</codeph>  </p> </entry>
+<entry><p>Set if the thread is currently handling an exception. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-026A5C10-C2F5-564A-B5CC-AE2B76A144A9"><b>Handles</b> </p> <codeblock id="GUID-8FF13D5A-D4F2-5B04-B306-B91DB54AA4C3" xml:space="preserve">Flags 00000004, Handles 640330bc</codeblock> <p>The <codeph>Handles</codeph> field
+contains the address of a <codeph>DObjectIx</codeph> object that contains
+the handles owned by the thread. </p> <p id="GUID-033C939E-BA01-5FC4-AD77-17FD891FE724"><b>Kernel &amp; user stack
+addresses</b> </p> <codeblock id="GUID-FA6F4E36-AC78-5518-B82A-82AB7BE9BA9A" xml:space="preserve">Supervisor stack base 6571f000 size 1000
+User stack base 00402000 size 2000
+</codeblock> <p>These fields give the base address and size, in bytes, of
+the kernel and user stacks respectively. </p> <p id="GUID-595813CE-C13C-5E27-9016-63A9FEA393C0"><b>Thread id, RAllocator instances,
+trap frame</b> </p> <codeblock id="GUID-E28677AC-E286-5043-AFE7-7E775D836A3A" xml:space="preserve">Id=26, Alctr=00600000, Created alctr=00600000, Frame=00000000</codeblock> <p>The <codeph>Id</codeph> field contains the thread id. </p> <p>The <codeph>Alctr</codeph> field
+contains a pointer to the current <xref href="GUID-9DB4A58C-6FC8-3292-A547-4C161BD188FC.dita"><apiname>RAllocator</apiname></xref> instance used
+for heap allocation. </p> <p>The <codeph>Created alctr</codeph> field contains
+a pointer to the original <xref href="GUID-9DB4A58C-6FC8-3292-A547-4C161BD188FC.dita"><apiname>RAllocator</apiname></xref> instance used for
+heap allocation. This may be different from the current instance if <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-988B1323-D1E2-33DE-923A-A987F2CAFBB7"><apiname>User::SwitchAllocator()</apiname></xref> has
+been called. </p> <p>The <codeph>Frame</codeph> field contains a pointer to
+the current trap frame, an instance of the <codeph>TTrap</codeph> class, on
+the cleanup stack. </p> <p id="GUID-71901B6F-6BBF-5DCC-8F3F-DC601DB21543"><b>Trap handler, active scheduler,
+user-side exception handler</b> </p> <codeblock id="GUID-21E4E26F-9F2F-5BC2-9324-0988A50CD376" xml:space="preserve">Trap handler=00000000, ActiveScheduler=00000000, Exception handler=00000000</codeblock> <p>The <codeph>Trap handler</codeph> field contains a pointer to the current
+trap handler, an instance of <xref href="GUID-1C6ED16E-2105-3C17-81C7-026D211DCCC0.dita"><apiname>TTrapHandler</apiname></xref>, for the cleanup
+stack. </p> <p>The <codeph>ActiveScheduler</codeph> field contains a pointer
+to the current active scheduler. </p> <p>The <codeph>Exception handler</codeph> field
+contains a pointer to the current user-side exception handler. </p> <p id="GUID-62666275-C252-5EE0-B3F5-21F65600AD1D"><b>Temporary object, temporary
+allocation, IPC count</b> </p> <codeblock id="GUID-DCBEBEBE-35FD-57EE-9A8B-DEF0C59A4042" xml:space="preserve">TempObj=00000000 TempAlloc=00000000 IpcCount=00000000</codeblock> <p>The <codeph>Tempobj</codeph> field contains a pointer to an instance
+of a <xref href="GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497.dita"><apiname>DObject</apiname></xref> derived class that must be closed when the
+thread terminates. </p> <p>The <codeph>TempAlloc</codeph> field contains a
+pointer to a kernel heap cell that must be freed when the thread terminates.
+Both this and <codeph>Tempobj</codeph> are used to avoid leaks if the thread
+terminates unexpectedly. </p> <p>The <codeph>IpcCount</codeph> field contains
+the number of messages currently queued to this thread. </p> <p id="GUID-6C42738E-2644-5064-B349-B48266BF286D"><b>Underlying nanokernel thread</b> </p> <codeblock id="GUID-6A4598D5-CD52-54C5-B314-8DF7AD14F4A9" xml:space="preserve">NThread @ 640396b0 Pri 16 NState READY
+Next=640396b0 Prev=640396b0 Att=03 iUserContextType=0b</codeblock> <p>The <codeph>NThread</codeph> field
+contains a pointer to the underlying nanokernel thread object, an instance
+of the <xref href="GUID-187D314F-1115-3671-AC46-37AEC5DFB2AC.dita"><apiname>NThread</apiname></xref> class. </p> <p>The <codeph>Pri</codeph> field
+contains the current priority of the underlying nanokernel thread. </p> <p>The <codeph>NState</codeph> field
+shows the current state of the underlying nanokernel thread. Note that this
+state is often referred to as the N-state, as compared to the to M-state,
+the state of a Symbian platform thread. See the <xref href="GUID-49379616-C235-598D-AE43-668998AD072B.dita#GUID-49379616-C235-598D-AE43-668998AD072B/GUID-DDC45F0A-6B62-5EE6-9E42-D21F07BCF4B4">Thread
+state summary</xref>. </p> <p>The <codeph>Next</codeph> field points to the
+next nanokernel thread object. </p> <p>The <codeph>Prev</codeph> field points
+to the previous nanokernel thread object. </p> <p>The <codeph>Att</codeph> field
+contains the nanokernel thread attributes, which is an 8-bit mask that controls
+how the thread is scheduled in certain cases. Two attributes are defined: </p> <table id="GUID-A241F528-3E55-504B-ACD8-F33AAB7F0D87">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph> KThreadAttImplicitSystemLock</codeph>  </p> </entry>
+<entry><p>This attribute signifies that the thread may not be scheduled if
+another thread currently holds the system lock, unless the the former thread
+holds another fast mutex. This attribute is used in implementing address space
+switching in the moving memory model and also in implementing change of user
+context in order to allow exceptions to be raised on other threads. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KThreadAttAddressSpace</codeph>  </p> </entry>
+<entry><p>This attribute signifies that the thread may require a change of
+address space to schedule it. This attribute is used in conjunction with the
+thread’s <codeph>iAddressSpace</codeph> field; if this does not match the
+scheduler’s <codeph>iAddressSpace</codeph> field at the point where the thread
+is scheduled an address space switch will occur. Note that this is not required
+if the address space change is limited to the ARM domain permissions since
+these are saved and restored as part of the thread context. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-3C1A2A53-E2BE-5959-9F2D-C63400F6AABA"><b>Fast mutexes</b> </p> <codeblock id="GUID-09E41C50-99C1-56CC-AD16-2A5C1A47104B" xml:space="preserve">HeldFM=00000000 WaitFM=00000000 AddrSp=64038d5c</codeblock> <p>The <codeph>HeldFM</codeph> field
+contains a pointer to the fast mutex held by this thread; this is NULL if
+no fast mutext was held. </p> <p>The <codeph>WaitFM</codeph> field contains
+a pointer to the fast mutex that this thread was waiting on; this is NULL
+if this thread was not waiting on a fast mutex. </p> <p>The <codeph>AddrSp</codeph> field
+is the address space identifier used by the scheduler to determine whether
+an address space change is required when scheduling in a new thread. </p> <p id="GUID-36E24838-15FB-5A69-9122-7AFF98F219AE"><b>Timing, request semaphore
+count</b> </p> <codeblock id="GUID-486FAC6A-5FE5-5937-8E15-FA526E65BDE6" xml:space="preserve">Time=17 Timeslice=20 ReqCount=0</codeblock> <p>The <codeph>Time</codeph> field
+contains the number of nanokernel ticks, usually in milliseconds, to go before
+the thread is preempted. </p> <p>The <codeph>Timeslice</codeph> field contains
+the maximum number of ticks for which the thread can run before being preempted. </p> <p>The <codeph>ReqCount</codeph> contains
+the request semaphore counter. If the value is negative, then the thread is
+blocked waiting for a request to complete; if it is positive, then one or
+more requests have completed. </p> <p id="GUID-BE914CFE-EE27-5661-A8E5-E85E897E880B"><b>Suspend count, critical
+section counter, register values</b> </p> <codeblock id="GUID-2F12508F-70D3-5F74-AC62-3BCAA1E00C69" xml:space="preserve">SuspendCount=0 CsCount=1 CsFunction=fffffffe
+SavedSP=6571ff34 ExtraContext=00000000 ExtraContextSize=0000
+DACR 63990000
+R13_USR 6571ff88 R14_USR f8025bc0 SPSR_SVC 10000004
+ R4 f8033794  R5 64039408  R6 640396b0  R7 f8028518
+ R8 640396b0  R9 640396b0 R10 00000000 R11 f80284d8
+ PC 00000000
+</codeblock> <p>The <codeph>SuspendCount</codeph> field contains the number
+of times that the thread has been suspended. </p> <p>The <codeph>CsCount</codeph> field
+critical section counter. When this value is greater than zero, then the thread
+is in a critical section and cannot be suspended or killed. </p> <p>The remaining
+content is a list of register values. <i>Note that they are not the register
+values when the thread panicked.</i> They are the values in the registers
+the last time that this thread was pre-empted. </p> </section>
+<section id="GUID-2424E413-F2F3-5625-932D-515860911424"><title>Current process
+state</title> <p>The current process is the process in whose address space
+the current thread was executing when the fault occurred. The 15 lines starting
+at line 33 of the output gives information relating to the current process.
+This has some similarities with the current thread information: </p> <codeblock id="GUID-9A11F0D0-6939-5EB5-8CA0-D8501699563B" xml:space="preserve">TheCurrentProcess=64038d5c
+PROCESS at 64038d5c VPTR=f80342a4 AccessCount=6 Owner=00000000
+Full name test2.exe
+ExitInfo 3,0,
+Flags a0000000, Handles 6403860c, Attributes 60010000
+DataBssChunk 64039234, CodeSeg 6403919c
+DllLock 64039044, Process Lock 64038eec SID 00000000
+TempCodeSeg 00000000 CodeSeg 6403919c Capability 00000000 0003ffff
+CodeSegs: Count=0
+NumChunks=2
+0: Chunk 64039234, run 00400000, access count 1
+1: Chunk 6403613c, run 00600000, access count 1
+Process shared IO buffers cookie 0000031d
+Process has no shared IO buffers
+Domain -1, DACR 55555507</codeblock> <ul>
+<li id="GUID-958232EF-0C57-5BE8-B7FD-9CE32E8868BA"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-C34D3FEF-E3F9-5123-9F30-40DBDA77C64C">Process object and access count</xref>  </p> </li>
+<li id="GUID-883E0C90-C62A-556B-8F7C-8A94EBBBCACD"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-BFACCA5F-FE1A-5580-9A1A-6FF79D60C7C2">The process name</xref>  </p> </li>
+<li id="GUID-9F8C813C-A45E-5CF6-8ED7-10F9C684A2EA"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-F229C034-2497-5F64-B2D2-8C677731BA2C">Exit information</xref>  </p> </li>
+<li id="GUID-D2C617EB-D70E-5847-8E27-ADF85BBD781E"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-6758C73B-BC11-59FC-9836-E8853665AF47">Process flags</xref>  </p> </li>
+<li id="GUID-93008AC0-CA9C-5663-BD48-BC57B767F030"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-026A5C10-C2F5-564A-B5CC-AE2B76A144A9">Handles</xref>  </p> </li>
+<li id="GUID-8D9F7DCE-E8E2-5414-87FE-21272BFAF590"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-41734978-89CD-5B5D-8361-2F74378ADB63">Attributes</xref> </p> </li>
+<li id="GUID-AA619815-2474-5741-93DD-F5734C2B5617"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-9A4BB007-9B90-51A4-BEA7-FC7108031C6A">Information about memory</xref>  </p> </li>
+<li id="GUID-52E95BE0-1123-544C-ADD4-CE087107EEF7"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-BCFE81CD-1E22-58F9-9370-7CA7EFD4B505">Secure id</xref>  </p> </li>
+<li id="GUID-053B4284-3873-56DA-9CC3-FC2C3E869E09"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-FF5194C1-B2AB-5665-B9DE-EF4AB08BEA3F">Capability</xref> </p> </li>
+<li id="GUID-05E35250-1EE3-5FF5-8622-51B24025FBC6"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-5F4276A9-7EDC-5D5C-840A-06A3EC1903CC">Code segments</xref>  </p> </li>
+<li id="GUID-45F0E651-1154-565C-AB4D-6ECA1AA7A7EC"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-E4C48F4E-6EF9-5937-A8DA-6DFA1968557E">Chunks owned by the process</xref>  </p> </li>
+<li id="GUID-73763927-40A9-5B34-B702-3FE90F56219C"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-2D147ABB-E9D7-540C-BC98-CB0E9E4B89FF">Shared IO buffer information</xref>  </p> </li>
+<li id="GUID-226E15CD-5382-51E6-B65D-8DA4DBD7CE4F"><p> <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-9CB0F4F8-C3E9-5108-AB7E-B23057C48BA4">Domain information</xref>  </p> </li>
+</ul> <p id="GUID-C34D3FEF-E3F9-5123-9F30-40DBDA77C64C"><b>Process object and access
+count</b> </p> <codeblock id="GUID-33CB81C9-8585-5C75-8F5C-2F1D897BA5F9" xml:space="preserve">PROCESS at 64038d5c VPTR=f80342a4 AccessCount=6 Owner=00000000</codeblock> <p>The <codeph>Process at</codeph> field contains a pointer to the <codeph>DProcess</codeph> object
+representing the process. </p> <p>The <codeph>AccessCount</codeph> field contains
+the reference count on the process object. </p> <p>The <codeph>owner</codeph> field
+contains a pointer to the object that owns this <codeph>DProcess</codeph> object. </p> <p id="GUID-BFACCA5F-FE1A-5580-9A1A-6FF79D60C7C2"><b>The process name</b> </p> <codeblock id="GUID-FD1903A5-AC86-59CE-BCC5-EC9E434DD5F8" xml:space="preserve">Full name test2.exe</codeblock> <p>The <codeph>Full
+name</codeph> field gives the name of the process. In this example, the name
+of the process is <b>test2.exe</b>. </p> <p>See <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-73FCD8C6-089B-54E1-A6CA-798DAC33B6DF">the
+thread name</xref>. </p> <p id="GUID-F229C034-2497-5F64-B2D2-8C677731BA2C"><b>Exit information</b> </p> <codeblock id="GUID-101BECBC-D613-5928-AB4E-70D292FBFDA7" xml:space="preserve">ExitInfo 3,0,</codeblock> <p>The <codeph>ExitInfo</codeph> field
+contains the information that characterises the process exit. In this example,
+the value is 3, meaning that this process has not exited. See also <xref href="GUID-0296BFC6-7F7C-3259-AF21-7E9B5C304B24.dita"><apiname>TExitType</apiname></xref>. </p> <p id="GUID-6758C73B-BC11-59FC-9836-E8853665AF47"><b>Process flags</b> </p> <codeblock id="GUID-163D2DFD-F5AF-594F-A618-A6795DBE88DC" xml:space="preserve">Flags a0000000, Handles 6403860c, Attributes 60010000</codeblock> <p>The <codeph>Flags</codeph> field
+contains information about the state of the process. The possible values in
+this field are defined by the <codeph>KProcess...</codeph> constants in <filepath>u32std.h</filepath>.
+While the symbols are internal to Symbian platform, the following
+table summarises the values and their meaning. </p> <table id="GUID-1913BCFB-93DD-58F5-B603-2B44A21C4621">
+<tgroup cols="3"><colspec colname="col0"/><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p> <b>Symbol</b>  </p> </entry>
+<entry><p> <b>Value</b>  </p> </entry>
+<entry><p> <b>Meaning</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KProcessFlagSystemCritical</codeph>  </p> </entry>
+<entry><p> <codeph>0x00000004</codeph>  </p> </entry>
+<entry><p>A process panic causes the entire system to reboot. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KProcessFlagSystemPermanent</codeph>  </p> </entry>
+<entry><p> <codeph>0x00000008</codeph>  </p> </entry>
+<entry><p>If the process exits for any reason, then this causes the entire
+system to reboot. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KProcessFlagPriorityControl</codeph>  </p> </entry>
+<entry><p> <codeph> 0x40000000</codeph>  </p> </entry>
+<entry><p>If set, then other threads are allowed to change this thread’s priority. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KProcessFlagJustInTime</codeph>  </p> </entry>
+<entry><p> <codeph>0x80000000</codeph>  </p> </entry>
+<entry><p>If set, then just-in-time debug is enabled for this thread. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-1969D689-9BDD-5564-BA08-5424534EE1F2"><b>Handles</b> </p> <codeblock id="GUID-1DEFC9E1-7597-51DB-AF9A-3690F5D69507" xml:space="preserve">Flags a0000000, Handles 6403860c, Attributes 60010000</codeblock> <p>The <codeph>Handles</codeph> field
+contains the address of a <codeph>DObjectIx</codeph> object that contains
+the handles owned by the process. </p> <p id="GUID-41734978-89CD-5B5D-8361-2F74378ADB63"><b>Attributes</b> </p> <codeblock id="GUID-D526B23E-67A6-5667-A7E0-3761D83D84FA" xml:space="preserve">Flags a0000000, Handles 6403860c, Attributes 60010000</codeblock> <p>The <codeph>Attributes</codeph> field contains the attributes of the process. Some are generic, as defined
+by <xref href="GUID-5B2E4FFA-8E41-3D62-A386-11BFD3EBB436.dita#GUID-5B2E4FFA-8E41-3D62-A386-11BFD3EBB436/GUID-6B8684BC-CDCB-3A01-9937-FF20FB613FE6"><apiname>DProcess::TProcessAttributes</apiname></xref>, but others depend on the
+memory model. </p> <p id="GUID-9A4BB007-9B90-51A4-BEA7-FC7108031C6A"><b>Information about memory</b> </p> <codeblock id="GUID-3361448E-5135-5C20-B6D0-133885565EB8" xml:space="preserve">DataBssChunk 64039234, CodeSeg 6403919c</codeblock> <p>The <codeph>DataBssChunk</codeph> field
+contains a pointer to the <codeph>DChunk</codeph> object representing the
+chunk that contains the process data and <codeph>.bss</codeph> memory. Be
+aware that this is not the same as the heap - heaps are allocated to threads,
+and chunk information is found in the <codeph>DThread</codeph> object. </p> <p>The <codeph>CodeSeg</codeph> field
+contains a pointer to the <codeph>DCodeSeg</codeph> object that represents
+the code segment. </p> <p id="GUID-BCFE81CD-1E22-58F9-9370-7CA7EFD4B505"><b>Secure id</b> </p> <codeblock id="GUID-0DF422C0-D066-5A3C-A5CE-EF86F312D6D8" xml:space="preserve">DllLock 64039044, Process Lock 64038eec SID 00000000</codeblock> <p>The <codeph>SID</codeph> field
+contains the secure id of the process. </p> <p id="GUID-FF5194C1-B2AB-5665-B9DE-EF4AB08BEA3F"><b>Capability</b> </p> <codeblock id="GUID-2C600784-5877-572C-8D7B-5362C6B25998" xml:space="preserve">TempCodeSeg 00000000 CodeSeg 6403919c Capability 00000000 0003ffff</codeblock> <p>The
+second four bytes of the Capability field contains the set of bits that define
+the capability for this process. This defines what the process can and cannot
+do. </p> <p id="GUID-5F4276A9-7EDC-5D5C-840A-06A3EC1903CC"><b>Code segments</b> </p> <codeblock id="GUID-E2E5055C-0C98-533C-AC64-B12AFF22EC20" xml:space="preserve">CodeSegs: Count=0</codeblock> <p>The <codeph>CodeSegs:
+Count</codeph> field contains the number of code segments that have been dynamically
+loaded into the process. This will be zero if the process is XIP. </p> <p id="GUID-E4C48F4E-6EF9-5937-A8DA-6DFA1968557E"><b>Chunks owned by the process</b> </p> <codeblock id="GUID-CA07A45D-8905-55DA-A1B3-140C6B318B82" xml:space="preserve">NumChunks=2
+0: Chunk 64039234, run 00400000, access count 1
+1: Chunk 6403613c, run 00600000, access count 1
+</codeblock> <p>The NumChunks field contains the number of chunks owned by
+the process. </p> <p>Successive lines contain information about each chunk: </p> <ul>
+<li id="GUID-632AEB6C-FF47-5139-A6E6-79DAF1E25214"><p>the <codeph>Chunk</codeph> field
+contains the address of a kernel <codeph>DChunk</codeph> object. </p> </li>
+<li id="GUID-7E0EA444-2FE0-56D2-AEF5-CA31DAD1A165"><p>the <codeph>run</codeph> field
+contains the virtual address at which the chunk resides when this is the current
+process. </p> </li>
+<li id="GUID-8472FA34-1569-52A3-ABC1-951115A7FA4E"><p>the <codeph>access count</codeph> field
+contains the reference count of the object. </p> </li>
+</ul> <p id="GUID-2D147ABB-E9D7-540C-BC98-CB0E9E4B89FF"><b>Shared IO buffer information</b> </p> <codeblock id="GUID-05E4BBE9-CA87-5123-BD2C-49B10DE56295" xml:space="preserve">Process shared IO buffers cookie 0000031d
+Process has no shared IO buffers
+</codeblock> <p>This is information about shared IO buffers. The cookie is
+only really of interest to base engineers. </p> <p id="GUID-9CB0F4F8-C3E9-5108-AB7E-B23057C48BA4"><b>Domain information</b> </p> <codeblock id="GUID-43108D24-448E-5D94-BD4C-D62B59F52633" xml:space="preserve">Domain -1, DACR 55555507</codeblock> <p>This
+is ARM MMU-specific protection information. Processes have domain -1 and DACR
+0xFFFFFFFF. </p> </section>
+<section id="GUID-877907D5-6A04-510B-AE99-C3856A0469E7"><title>Current data
+section process</title> <p>In the moving memory model the current process
+could be a fixed process, in which case there is also a current moving process.
+The current data section process is the current moving process. </p> <codeblock id="GUID-4E0FA397-16BF-581C-93FD-0D10BAE7B1B3" xml:space="preserve">TheCurrentDataSectionProcess=64038d5c</codeblock> <p>This
+field contains a pointer to the <codeph>DProcess</codeph> object for the current
+moving process. This line is followed by detailed information about the process
+itself; the format is the same as that described for the <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita#GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A/GUID-2424E413-F2F3-5625-932D-515860911424">Current process state</xref>. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-209514AE-9457-4ED2-AFE0-FDC059CE2B30.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-209514AE-9457-4ED2-AFE0-FDC059CE2B30" xml:lang="en"><title>Time Client Interface</title><shortdesc>The basic steps to use the client interface of the Time
+platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Time client interface provides the Real Time Clock (RTC) functionality
+to the OS.</p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-20F8DA2A-9157-54C5-97D0-4CCA50AB0631.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-20F8DA2A-9157-54C5-97D0-4CCA50AB0631" xml:lang="en"><title>Reference</title><shortdesc>This section describes the macros that can be used in the Bootstrap.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2281F91F-67BD-5B85-A47F-30A5E683BBF6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2281F91F-67BD-5B85-A47F-30A5E683BBF6" xml:lang="en"><title>Double
+Buffers</title><shortdesc>To improve throughput, Symbian platform provides the double buffer
+mechanism. This is a feature that allows a block of data to be prepared by
+the media driver while the hardware transfers a block of data. DMA transfers
+data without interrupting the CPU. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The MultiMediaCard subsystem performs multiple data transfers in a single
+bus transaction. </p>
+<p>If your implementation uses double buffers, you must set the <codeph>ESupportsDoubleBuffering</codeph> flag
+into the <xref href="GUID-A8C79421-AA44-345D-9863-EA21F5FEEE72.dita#GUID-A8C79421-AA44-345D-9863-EA21F5FEEE72/GUID-8B9C1B71-9664-35B8-B3B3-EC5508E8E76A"><apiname>TMMCMachineInfoV4::iFlags</apiname></xref> data member in your
+implementation of <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-3E5532A5-4645-3F77-A7A9-7AFF334FA5A4"><apiname>DMMCStack::MachineInfo()</apiname></xref>. This flag causes
+the platform independent layer to provide the support you need. </p>
+<p>If your MultiMediaCard controller uses DMA and your platform specific layer
+supports physical addresses, you must use double buffers. </p>
+<p>See also: </p>
+<ul>
+<li id="GUID-629116CA-4B19-5F48-9F0D-0FEED4D26FEB"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-CEF0EDF7-4B33-5452-8635-51C5319F78AE">MachineInfo()</xref> </p> </li>
+<li id="GUID-5EF23F02-273E-5382-86C4-C04520AFD91E"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-E50081BC-C923-5DAF-950C-9E1411916FED">Implement double buffers</xref>  </p> </li>
+</ul>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-22CCA5B5-D4AB-4ABC-94C6-CD85EC470238.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,86 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-22CCA5B5-D4AB-4ABC-94C6-CD85EC470238" xml:lang="en"><title>System
+Information</title><shortdesc>This topic describes various system information related to the
+device drivers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-8968BABB-32E5-4998-8E69-C8389D1E6B63">       <title>Presence
+of PDD</title>       <p>Some drivers may only require an LDD, and not provide
+a PDD. However, if the driver has a PDD, then the driver must inform the framework
+of this. The LDD should set the <xref href="GUID-7616AA05-83E6-3989-AB9D-11AE01245BEB.dita#GUID-7616AA05-83E6-3989-AB9D-11AE01245BEB/GUID-EB891156-94D9-323A-AB23-7B5994CD95E3"><apiname>DLogicalDevice::iParseMask</apiname></xref> bitmask
+with the <xref href="GUID-DD3574F6-5EA7-3E2E-B906-E1E320DE10CD.dita"><apiname>KDeviceAllowPhysicalDevice</apiname></xref> flag. If this flag
+is not set, then the Kernel assumes that the driver does not have a PDD. </p> <codeblock id="GUID-F4A44E78-EA90-5D75-BC1F-48EF684F7F58" xml:space="preserve">// Logical Channel Second stage constructor
+DExDriverLogicalDevice:: DExDriverLogicalDevice ()
+    {
+    iParseMask = KDeviceAllowPhysicalDevice | KDeviceAllowUnit;
+    ...
+    }</codeblock>     </section>
+<section id="GUID-EFC4AE5D-6506-4B1F-A4E4-DBA31B456593"/>
+<section id="GUID-E983D7DF-52C4-46FC-B633-BF08519D949D"><title>Capabilities</title> <p>The
+device driver framework provides a method to set and provide general information
+to the user on the capabilities of the device driver. Typically, implementations
+simply return the version number of the LDD. The device driver framework allows
+both the LDD and PDD to set the device capabilities. </p> <p>The user typically
+calls the <xref href="GUID-92BAC78E-8ACF-3952-8E77-CCF93ED3BDC9.dita#GUID-92BAC78E-8ACF-3952-8E77-CCF93ED3BDC9/GUID-9C38652A-0135-360D-A54F-A9542C45E608"><apiname>RDevice::GetCaps()</apiname></xref> function to retrieve the device
+capabilities. </p> <codeblock id="GUID-6801C06D-EEA1-505B-968A-8EF354961183" xml:space="preserve">RDevice device;
+r = device.Open(KDriverName);
+if (r==KErrNone)
+    {
+    TPckgBuf&lt;RExDriver::TUartCaps&gt; caps;
+    device.GetCaps(caps);         
+    ...
+    device.Close();
+    }</codeblock> <p> <i>Note:</i> The device capabilities in this context
+refer to the services that the driver can offer. Do not confuse this with
+the idea of platform security capabilities, which are completely different. </p></section>
+<section id="GUID-73AD1B0E-2A31-4D44-A19C-E64A78281C27"><title> HAL handlers</title> <p>Symbian
+platform provides a Hardware Abstraction Layer (HAL) interface that can be
+used by device drivers and kernel extensions to provide information on device
+specific attributes to user code. It comprises set and get interfaces used
+by the Kernel and by user code. The attributes are divided into groups of
+similar functionality, each of which is managed by a function called a HAL
+handler. </p> <p>Drivers must register any HAL handlers they provide, and
+de-register them when unloading. Kernel extensions do not remove their HAL
+handlers. </p> <codeblock id="GUID-EE9D2192-92F1-5C9D-9E9C-4CFD5D2C6304" xml:space="preserve">// Adds a HAL entry handling function for the specified group of 
+// HAL entries.
+Kern::AddHalEntry(EHalGroupDisplay, &amp;handler, this, 1);
+
+// Removes the HAL handler
+TInt Kern::RemoveHalEntry(EHalGroupDisplay);</codeblock> <p>The arguments
+to <codeph>AddHalEntry()</codeph> are the ID of a HAL group, a pointer to
+the handler function and a pointer to a data structure that will be passed
+to the handler function. The HAL handler function prototype is defined by <xref href="GUID-A65A16CA-488D-3A16-A034-F01C9C0B9D15.dita"><apiname>THalFunc</apiname></xref>. </p> <codeblock id="GUID-B3B4A844-FA9B-54CC-A02C-90BB2388AFC8" xml:space="preserve">// Implementation of the kernel extension's exported function
+EXPORT_C void TExClientInterface::MyExAPI()
+    {
+    …
+    ExController-&gt;MyExAPI();
+    …
+    }
+
+LOCAL_C TInt halFunction(TAny* aPtr, TInt aFunction, TAny* a1, 
+        TAny* a2)
+    {
+    DLcdPowerHandler* pH=(DLcdPowerHandler*)aPtr;
+    return pH-&gt;HalFunction(aFunction,a1,a2);
+    }
+
+TInt DLcdPowerHandler::HalFunction(TInt aFunction, TAny* a1, 
+TAny* a2)
+    {
+    ...
+    switch(aFunction)
+        {
+        ...
+        }
+    }</codeblock> <p>When the user calls <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-9454F1B2-D525-3D6D-A872-C6457CACD4FC"><apiname>HAL::Set()</apiname></xref> or <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-573C49D6-7763-37AE-B2B2-4C8FB1327E21"><apiname>HAL::Get()</apiname></xref>,
+it invokes the corresponding <codeph>halFunction()</codeph> of the HAL function
+group. </p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2344B900-5EC5-4467-BEAD-AB55C88CE63E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,134 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2344B900-5EC5-4467-BEAD-AB55C88CE63E" xml:lang="en"><title>Stack
+Implementation Guide</title><shortdesc>How to implement the platform-specific class for an SDIO stack
+of an SDIO-based hardware component.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The stack is provided by the <xref href="GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91.dita"><apiname>DSDIOStack</apiname></xref> class. The developers
+porting the SDIO Controller must derive the <codeph>DSDIOStack</codeph> class
+and implement three platform-specific functions: <codeph>IssueMMCCommandSM()</codeph>, <codeph>EnableSDIOInterrupt()</codeph> and <codeph>MaxBlockSize()</codeph>. </p>
+<p>The following sections describe how to implement these functions in the <codeph>DMySdioStack</codeph> class
+derived from <codeph>DSIOStack</codeph>.</p>
+<section id="GUID-727CDF1D-9C0A-4793-8B27-DCC33A0D9E16"><title>Hardware registers</title><p>The <codeph>DMySdioStack</codeph> class
+needs to have access to the values and offsets of the SDIO configuration registers.
+Refer to the platform documentation and declare appropriate constants in the
+header file of the stack class. </p></section>
+<section id="GUID-94DC0BD9-0588-40A6-A9B9-5DBC2FDBA9E1"><title>IssueMMCCommandSM()</title><p>If
+you have not declared it already, declare the following function in the definition
+of <codeph>DMySdioStack</codeph>:<codeblock xml:space="preserve">TMMCErr IssueMMCCommandSM();</codeblock></p><p><xref href="GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91.dita#GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91/GUID-C4395EDB-2CB8-3BA7-A1C6-6B65A3A1FC46"><apiname>DSDIOStack::IssueMMCCommandSM()</apiname></xref> handles the commands to the bus and must be extended to support the SDIO
+protocol. See also <xref href="GUID-E194A923-99E7-5DC1-BB78-D050A4793A60.dita#GUID-E194A923-99E7-5DC1-BB78-D050A4793A60/GUID-3E6B3479-39B6-47BA-BD1A-18EA2F2A8597">DSDStack::IssueMMCCommandsSM()</xref>.</p><p>Rely on the platform documentation to perform the operations and
+update appropriate hardware registers when you intercept the following commands:<ul>
+<li><p><codeph>IO_OP_COND</codeph> (CMD5)</p></li>
+<li><p><codeph>IO_RW_DIRECT</codeph> (CMD52)</p></li>
+<li><p><codeph>IO_RW_EXTENDED</codeph> (CMD53)</p></li>
+</ul></p><p>You should also handle the additional <codeph>IO_SEND_OP_COND</codeph> (R4)
+and <codeph>IO_RW_DIRECT</codeph> (R5) responses.</p><p>In the following example,
+the hypothetical hardware platform has two requirements, which are implemented
+by the <codeph>IssueMMCCommandSM()</codeph> function. The function disables
+the CRC7 check when receiving an R4 response to an CMD5 command, and disables
+the SDIO interrupt before issuing a CMD52 command.<codeblock xml:space="preserve">void DMySdioStack::IssueMMCCommandSM()
+	{
+	TMMCCommandDesc&amp; cmd = Command();
+	...
+	// CMD5 
+	// Disable the CRC7 check for R4 responses
+	if (cmd.iCommand == ECmd5)
+		{	    
+		// Clear the MMC_CRC7_R4_ENABLE bit
+		// MMC_SDIO_REG_SLOT0 is a 32-bit hardware register for SDIO in slot 0
+		AsspRegister::Modify32(MMC_SDIO_REG_SLOT0, MMC_CRC7_R4_ENABLE, 0);
+		}
+	else     
+		{
+		// Set the MMC_CRC7_R4_ENABLE bit
+		AsspRegister::Modify32(MMC_SDIO_REG_SLOT0, 0, MMC_CRC7_R4_ENABLE);
+	    	}
+
+	// CMD52
+	// Disable SDIO interrupts for CMD 52	
+	if (cmd.iCommand == ECmd52)
+		{	    
+		EnableSDIOInterrupt(EFalse);
+		}
+	...
+	}
+</codeblock></p><p>As the SDIO Controller is instantiated at run-time, the
+memory used to support the SDIO transfer mechanisms must be allocated dynamically.
+Therefore, you can use two different types of memory and of data transfer: <ul>
+<li><p>Programmatic input/output using virtual memory</p></li>
+<li><p>DMA using physically-allocated <xref href="GUID-85454082-6734-3F1D-983F-734D4C2AB12D.dita"><apiname>DChunk</apiname></xref> objects.</p></li>
+</ul></p><p>The <codeph>KMMCCmdFlagDMARamValid</codeph> flag of the <xref href="GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A.dita"><apiname>TMMCCommandDesc</apiname></xref> object
+indicates which kind of memory transfer to use. </p><p>If you use the Programmatic I/O method, you need to queue pending data transfers
+while you handle hardware interrupts. Your platform's documentation specifies
+which interrupts may be received during transfers.</p></section>
+<section id="GUID-21B00930-0D6E-464D-8F50-37355D189FE4"><title>EnableSDIOInterrupt()</title><p>Declare
+the following function in the definition of <codeph>DMySdioStack</codeph>:<codeblock xml:space="preserve">virtual void EnableSDIOInterrupt(TBool aEnable);</codeblock></p><p><xref href="GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91.dita#GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91/GUID-F547703F-62A6-359D-9AC6-818689DDE2DB"><apiname>DSDIOStack::EnableSDIOInterrupt()</apiname></xref> enables or disables
+the SDIO interrupt. </p><p>The following example is a typical implementation
+of <codeph>EnableSDIOInterrupt()</codeph>:<codeblock xml:space="preserve">void DMySdioStack::EnableSDIOInterrupt(TBool aEnable)
+	{
+	if (aEnable)
+		{
+		// Set the Interrupt Enable Master Bit
+		// MMC_SDIO_REG_SLOT0 is a 32-bit hardware register for SDIO in slot 0
+		AsspRegister:: Modify32(MMC_SDIO_REG_SLOT0, SDIO_IENM, 0);
+		}
+	else
+		{
+		// Set the Interrupt Enable Master Bit
+		AsspRegister:: Modify32(MMC_SDIO_REG_SLOT0, 0, SDIO_IENM);
+		}
+	}
+</codeblock></p><p>You must also ensure that your interrupt handler checks
+the SDIO interrupt register and the card slot before forwarding the interrupt
+to the stack. <note>If checking the card slot is likely to take too long,
+use a DFC (Delayed Function Call) for the interrupt handler to preserve real-time
+performance.</note></p>The following example illustrates how to implement
+this aspect of the interrupt handler:<codeblock xml:space="preserve">void DMySdioInterrupt::Service(TAny* aSelf)
+	{
+	... 
+	// Get access to the stack
+	DPlatMMCStack* stack = (reinterpret_cast&lt;DMySdioInterrupt*&gt;(aSelf))-&gt;Stack();
+
+	// MMC_SDIO_REG_SLOT0 is a 32-bit hardware register for SDIO in slot 0
+	TInt32 sdioReg = AsspRegister::Read32(MMC_SDIO_REG_SLOT0);
+	// Test for the SDIO interrupt
+	if (sdioReg &amp; KMMC_SDIO_IntPending)
+		{
+		// Trigger the PIL’s interrupt handler for slot 0
+		stack-&gt;HandleSDIOInterrupt(0);
+		return;
+		}
+
+	// MMC_SDIO_REG_SLOT1 is a 32-bit hardware register for SDIO in slot 1
+	sdioReg = AsspRegister::Read32(MMC_SDIO_REG_SLOT1);
+	// Test for the SDIO interrupt
+	if (sdioReg &amp; KMMC_SDIO_IntPending)
+		{
+		// Trigger the PIL’s interrupt handler for slot 1
+		stack-&gt;HandleSDIOInterrupt(1);
+		return;
+		}
+
+	...
+	}
+</codeblock></section>
+<section id="GUID-CF9A5D3D-E46D-4343-9A71-89128217C3F1"><title>MaxBlockSize() </title><p>Declare
+the following function in the definition of <codeph>DMySdioStack</codeph>:<codeblock xml:space="preserve">virtual TUint32 MaxBlockSize() const;</codeblock></p><p><xref href="GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91.dita#GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91/GUID-CE55D746-6F55-316B-86F3-6799F29F19B4"><apiname>DSDIOStack::MaxBlockSize()</apiname></xref> returns the maximum block size in bytes
+that can be transferred on the SDIO bus. Extended read/write commands require
+this information.</p><p>In the SD protocol, the block size must be a power
+of two. SDIO does not have the same constraint and the block size can be anything
+between 1 and 2048.</p><p>The following example is a typical implementation
+of <codeph>MaxBlockSize()</codeph>:<codeblock xml:space="preserve">TUint32 DMySdioStack::MaxBlockSize() const
+	{
+	return(512); 
+	}
+</codeblock></p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2380FDDE-5489-5B1C-87BB-1FD882E385D2.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,238 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2380FDDE-5489-5B1C-87BB-1FD882E385D2" xml:lang="en"><title>Migration
+Tutorial: Direct Memory Addressing</title><shortdesc>To handle direct memory addressing, you must to make the following
+changes to your code. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>If a media driver uses a data transfer mechanism like <xref href="GUID-E5576D91-BC5C-588E-BF90-5A1E3C445133.dita">DMA</xref>,
+data transfer can be faster if the media driver knows that an address passed
+in an I/O request is a physical address. This is known as direct memory addressing. </p>
+<ul>
+<li id="GUID-E2C6E9D0-0150-529C-953E-32DFDEA68E77"><p> <xref href="GUID-2380FDDE-5489-5B1C-87BB-1FD882E385D2.dita#GUID-2380FDDE-5489-5B1C-87BB-1FD882E385D2/GUID-621EB44F-25BB-5B71-BF74-ED0304B7B591">Changes to registration</xref>  </p> </li>
+<li id="GUID-62701989-76A6-52D5-A713-226343BED4EE"><p> <xref href="GUID-2380FDDE-5489-5B1C-87BB-1FD882E385D2.dita#GUID-2380FDDE-5489-5B1C-87BB-1FD882E385D2/GUID-49992CF9-404A-585C-8770-E9034434A344">Changes to request handling</xref>  </p> </li>
+<li id="GUID-79FF128E-98B3-5613-B02A-08A81FC5B82D"><p> <xref href="GUID-2380FDDE-5489-5B1C-87BB-1FD882E385D2.dita#GUID-2380FDDE-5489-5B1C-87BB-1FD882E385D2/GUID-5F4A392F-0EAF-5E69-B902-D987B8FFD610">Issues about physical addresses</xref>  </p> </li>
+</ul>
+<section id="GUID-621EB44F-25BB-5B71-BF74-ED0304B7B591"><title>Changes to
+registration</title> <p>If the media driver code can handle physical addresses,
+it must tell the local media subsystem. This process is called registration.
+The media driver calls <xref href="GUID-9E60E8D9-619E-3A76-BAC8-93A60D62C7DF.dita#GUID-9E60E8D9-619E-3A76-BAC8-93A60D62C7DF/GUID-57B3380F-3CA6-3FF4-9D79-05B718E0743A"><apiname>LocDrv::RegisterDmaDevice()</apiname></xref> to register
+as part of the <xref href="GUID-A70A01D2-467E-5BA8-A01D-6182558F3F52.dita">media
+driver initialisation</xref> process. The media driver calls <codeph>RegisterDmaDevice()</codeph> after
+the media driver has <xref href="GUID-A70A01D2-467E-5BA8-A01D-6182558F3F52.dita#GUID-A70A01D2-467E-5BA8-A01D-6182558F3F52/GUID-4A8DEEAB-32C4-5431-8226-5623E2BD9098">registered
+with the local media subsystem</xref>. </p> <p>After the call to <xref href="GUID-9E60E8D9-619E-3A76-BAC8-93A60D62C7DF.dita#GUID-9E60E8D9-619E-3A76-BAC8-93A60D62C7DF/GUID-57B3380F-3CA6-3FF4-9D79-05B718E0743A"><apiname>LocDrv::RegisterDmaDevice()</apiname></xref>,
+the local media subsystem will test if the address in an I/O request is a
+physical address or a virtual address. The local media subsystem extracts
+the information that the media driver requires. The media driver gets this
+information through calls to the functions: </p> <ul>
+<li id="GUID-93AEF5CB-CB70-5369-BC33-9F2B51903FFE"><p> <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-DD6773B4-9EF5-322F-B53D-29174DF3B3BF"><apiname>TLocDrvRequest::IsPhysicalAddress()</apiname></xref>. </p> </li>
+<li id="GUID-33328F10-BE3D-5ADA-8FFE-5E19764E43F1"><p> <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-9879145B-D996-327E-87F6-3B8337A86A56"><apiname>TLocDrvRequest::GetNextPhysicalAddress()</apiname></xref>. </p> </li>
+</ul> <p>A <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita"><apiname>TLocDrvRequest</apiname></xref> object represents an I/O request
+and is passed to the media driver. </p> <p>There are three pieces of information
+that the local media subsystem needs from the media driver when the media
+driver registers: </p> <ul>
+<li id="GUID-7A889D6A-52E0-5FBB-BC2F-A1E10A0F0D4D"><p>The <i>minimum number
+of bytes</i> that the media device can transfer. For example, the architecture
+of some memory card types requires data transfer in blocks of 512 bytes. The
+local media subsystem can not support I/O requests for physical addresses
+where the length of the data is smaller than this minimum number. This limit
+prevents accidental access of the data outside the limits of the request. </p> </li>
+<li id="GUID-C778CC22-699B-5B01-B217-C6567CBE01E3"><p>The <i>maximum number
+of bytes</i> that the media driver can transfer in one burst. This value depends
+on the hardware. For eaxample,<xref href="GUID-0D2F811C-81C3-526F-8EA4-98E50261BF4B.dita">DMA
+Framework</xref> has limits that depend on the DMA controller. </p> </li>
+<li id="GUID-49B448A8-B8ED-5EF6-9AB2-BA43FD6ED34F"><p>The <i>alignment of
+memory</i> that the DMA controller requires. For example: a DMA controller
+might require 2 byte (word or 16 bit) alignment or 4 byte (double word or
+32 bit) alignment. For 2 byte alignment, specify 2; for 4 byte alignment specify
+4 etc. The local media subsystem can not support I/O requests for physical
+addresses that are not aligned according to this value. </p> </li>
+</ul> <p>You get all of this information from the documentation for the platform. </p> <p>This
+example code extends the code shown in the section <xref href="GUID-A70A01D2-467E-5BA8-A01D-6182558F3F52.dita">Media
+driver initialisation before the system is initialised</xref>. It adds a call
+to <xref href="GUID-9E60E8D9-619E-3A76-BAC8-93A60D62C7DF.dita#GUID-9E60E8D9-619E-3A76-BAC8-93A60D62C7DF/GUID-57B3380F-3CA6-3FF4-9D79-05B718E0743A"><apiname>LocDrv::RegisterDmaDevice()</apiname></xref>. This call follows registration
+of the media driver with the local media subsystem. </p> <codeblock id="GUID-A56AFE4C-729A-57DA-B232-60A29CE7F735" xml:space="preserve">DECLARE_STANDARD_EXTENSION()
+    {
+    TInt r=KErrNoMemory;
+    DPrimaryMediaBase* pM=new DPrimaryMediaBase;
+    if (pM)
+        {//…Required here for Asynchronous creation (if supported)
+        pM-&gt;iDfcQ = &amp;MyDfcQ;
+ 
+        // Perform registration here
+        r = LocDrv::RegisterMediaDevice(MEDIA_DEVICE_TYPE,
+                                        MEDIA_DRIVECOUNT,
+                                        &amp;IMediaDriveNumbers[0],
+                                        pM,MEDIA_NUMMEDIA,KMediaDriveName
+                                       );
+        if ® != KErrNone)
+            {
+            return r;
+            }
+       
+        // Register support for physical addressing.
+        //
+        // Note : in practice the values passed to RegisterDmaDevice() would be
+        // either symbolic constants or functions that return values. If the 
+        // media driver is split into platform independent and platform dependent
+        // layers, and this code is in the independent layer, then you will need 
+        // functions in the dependent layer to provide these values.
+        r = LocDrv::RegisterDmaDevice(pM,
+                                                    512,  // Block Addressing 512 Bytes
+                                                    1024, // 1024 Byte address range
+                                                    2 );  // 2 Byte alignment
+        if ® != KErrNone)
+            {
+            return r;
+            }
+        ...
+        }
+    return®);
+    }
+      </codeblock> </section>
+<section id="GUID-49992CF9-404A-585C-8770-E9034434A344"><title> Changes to
+request handling</title> <p>To use physical addreses, you need to make changes
+to the code that deals with <codeph>ERead</codeph> and <codeph>EWrite</codeph> requests
+in your implementation of the <xref href="GUID-EBF025DB-1552-5E99-8C07-09932DB60552.dita#GUID-EBF025DB-1552-5E99-8C07-09932DB60552/GUID-EC193360-31C2-5012-8ED2-19F1C48C8FC5">DMediaDriver::Request()</xref> function. This section discusses the issues with <codeph>ERead</codeph> requests,
+but the principles apply to <codeph>EWrite</codeph> requests. </p> <p>There
+are a number of points to consider: </p> <p><b>Check if the address is physical </b> </p> <p>Call <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-DD6773B4-9EF5-322F-B53D-29174DF3B3BF"><apiname>TLocDrvRequest::IsPhysicalAddress()</apiname></xref> to
+test if the address passed is a physical address. For example, for a <codeph>ERead</codeph> request: </p> <codeblock id="GUID-90F1EE30-DAE5-5DE5-B42E-9EF48EB12509" xml:space="preserve">...
+   // iReadReq points to a TLocDrvRequest object
+   ...
+   iMediaStartPos = iReadReq-&gt;Pos();
+   iTotalLength   = I64LOW(iReadReq-&gt;Length()); 
+   iDoPhysicalAddress = iReadReq-&gt;IsPhysicalAddress();
+   if(iDoPhysicalAddress)
+      {
+      ..&lt; Physical address memory code &gt;..
+      }
+   else
+      {
+      ...&lt; Virtual address memory code &gt;...</codeblock> <p><b>Physical address code </b> </p> <p>If you want to use the physical address,
+you need to get the physical address and the length of contiguous memory at
+this location. Call <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-9879145B-D996-327E-87F6-3B8337A86A56"><apiname>TLocDrvRequest::GetNextPhysicalAddress()</apiname></xref> to
+get the physical address and the length of physically contiguous memory. The
+length of physically contiguous memory can be smaller than the length supplied
+in the read request, because physical memory can be fragmented into a number
+of small blocks. If the length is smaller than the length supplied in the
+read or write request, you call <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-9879145B-D996-327E-87F6-3B8337A86A56"><apiname>TLocDrvRequest::GetNextPhysicalAddress()</apiname></xref> again
+to get the address of the next physically contiguous block of memory. You
+repeat this operation until the read request is complete. For example, for
+a <codeph>ERead</codeph> request: </p> <codeblock id="GUID-2311A626-38BF-582F-B310-8E30D73AA1A7" xml:space="preserve">...
+   // iReadReq points to a TLocDrvRequest object
+   ...
+   TPhysAddr physAddr; 
+   TInt physLength;
+   TInt err = KErrNone;                
+   err = iReadReq-&gt;GetNextPhysicalAddress(physAddr, physLength);
+   if(err == KErrNone)
+      {                       
+      if (physLength &lt; iTotalLength)
+         {
+         // Memory is fragmented, note remainder. You will need 
+         // to use this code again using the remainder value.
+         iRemaining    = iTotalLength – physLength;
+         iTotalLength -= physLength;
+         }
+      
+      // Start data transfer into the current physically
+      // contiguous block of physical memory.
+      DoDataTransfer(iMediaStartPos, physLength, physAddr);
+      ...
+      }
+</codeblock> <p>If you do not want to deal with fragmented physical memory,
+you can use your original code. </p> <p><b>Virtual to physical address translation </b> </p> <p>Your code must not
+perform a virtual to physical address translation when it deals with physical
+memory. For example: </p> <codeblock id="GUID-4377A0D5-8E41-59AF-B26E-C468ABAFCF47" xml:space="preserve">void DMMCRxDmaHelp::ChannelTransfer(const SDmaPseudoDes&amp; aDes)
+      {
+      …
+      TPhysAddr dest;
+
+      if (iCurrentReq-&gt;IsPhysicalAddress())
+         dest = (TPhysAddr) aDes.iDest;
+      else
+         dest = Epoc::LinearToPhysical(aDes.iDest);
+      TPlatDma::SetDMARegister(KHoDMA_CDSA(iChno), dest);
+      …
+      }</codeblock> <p><b>Eliminate inter-process copy </b> </p> <p>You must change your code to
+remove calls to <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-842F91FF-C780-3E2A-8860-8F34815452FC"><apiname>TLocDrvRequest::WriteRemote()</apiname></xref>. For <codeph>ERead</codeph> requests,
+data for transfer is already at the physical address. For example: </p> <codeblock id="GUID-1B14C66A-476C-5E3F-B0D7-502B54324D74" xml:space="preserve">if (!iCurrentReq-&gt;IsPhysicalAddress())
+      {
+      if( (id == DMediaPagingDevice::ERomPageInRequest)||
+          (id == DMediaPagingDevice::ECodePageInRequest) )
+         {
+         r = iCurrentReq-&gt;WriteToPageHandler((TUint8 *)(&amp; iBufPtr [0]), len, usrOfst);
+         }
+      else if(id==DLocalDrive::ERead)
+         {
+         r = iCurrentReq-&gt;WriteRemote(&amp;iBufPtr,usrOfst);
+         }
+      }</codeblock> <p>The same logic applies to <codeph>EWrite</codeph> requests.
+You need to remove calls to <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-96B80631-AD1C-35E8-8613-0A630BD7D9E9"><apiname>TLocDrvRequest::ReadRemote()</apiname></xref>. </p> <p><b>Test your changes </b> </p> <p>You are recommended to run regression tests
+on your changed code to makes sure that the media driver operates correctly. </p> </section>
+<section id="GUID-5F4A392F-0EAF-5E69-B902-D987B8FFD610"><title>Issues about
+physical addresses</title> <p>If the media driver can use physical addresses,
+you need to be aware of a number of issues. </p> <p><b>The address scheme used by the hardware </b> </p> <p>All media devices
+have a minimum number of bytes that they can transfer. For example, the architecture
+of some memory card types requires data transfer in blocks of 512 bytes. To
+read one byte from this type of media device, the media driver must read a
+block of 512 bytes and extract the byte from the block. To write one byte
+to a media device, the media driver must read a block of 512 bytes, change
+the content of the byte, and write the block to the media device. </p> <p><b>Data transfer smaller than the minimum size </b> </p> <p>If the local
+media subsystem receives a request to transfer data with a length smaller
+than the minimum transfer size, the local media subsystem does not make a
+physical address available to the media driver. A call to <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-DD6773B4-9EF5-322F-B53D-29174DF3B3BF"><apiname>TLocDrvRequest::IsPhysicalAddress()</apiname></xref> returns
+false. It is considered unsafe to give access to the physical data surrounding
+the requested memory location. </p> <p><b>Data transfer not aligned to the media device block boundary </b> </p> <p>If
+the local media subsystem receives a request to transfer data, and the address
+on the media device is <i>not aligned</i> to the media device block boundary,
+you need to adopt the technique suggested below. The local media subsystem
+will make the physical address available to the media driver. A call to <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-DD6773B4-9EF5-322F-B53D-29174DF3B3BF"><apiname>TLocDrvRequest::IsPhysicalAddress()</apiname></xref> returns
+true. </p> <p>Consider the following case. A request has been made to read
+1024 bytes from a media device that has a block size of 512 bytes. The 1024
+bytes start at offset +256 on the media device. </p> <fig id="GUID-2689C022-180B-51EF-A02D-E63ACA832EB2">
+<image href="GUID-647ADEDA-AB5A-548F-93C3-D099EAE6A030_d0e17089_href.png" placement="inline"/>
+</fig> <p>To get the first 256 bytes, you must read the first block of 512
+bytes from the media device. This can corrupt the physical memory passed in
+the I/O request. The solution is to read the first block from the media device
+into an intermediate buffer. Copy the 256 bytes from that buffer into the
+physical memory passed in the I/O request. </p> <p>To get the last 256 bytes,
+you must read the third block of 512 bytes from the media device into the
+intermediate buffer. Copy the 256 bytes from that buffer into the correct
+position in the physical memory passed in the I/O request. </p> <p>The middle
+512 bytes are aligned on the media device block boundary. The media driver
+can read this data into the correct position in the physical memory passed
+in the I/O request. </p> <p><b>Scatter/Gather DMA controllers </b> </p> <p>DMA controllers can support
+the Scatter/Gather mode of operation. Each request in this mode of operation
+consists of a set of smaller requests chained together. This chain of requests
+is called the Scatter/Gather list. Each item in the list consists of a physical
+address and a length. </p> <p>Use <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-9879145B-D996-327E-87F6-3B8337A86A56"><apiname>TLocDrvRequest::GetNextPhysicalAddress()</apiname></xref> to
+help you populate the Scatter/Gather list. </p> <p>The following code fragment
+shows how you do this. The example assumes that the DMA controller supports
+a Scatter/Gather list with an unlimited number of entries. In practice, the
+number of entries in the list is finite. </p> <codeblock id="GUID-EC3A441C-080F-5EB8-B0E8-E658F80687D4" xml:space="preserve">TPhysAddr physAddr; 
+   TInt physLength;
+   TInt err = KErrNone;
+
+   while (iRemaining &gt; 0)
+      {
+      err = iCurrentReq-&gt;GetNextPhysicalAddress(physAddr, physLength);
+      if(err != KErrNone)
+         return err;
+
+      iRemaining -= physLength;
+      PopulateScatterGatherList(physAddr, physLength);
+      }                            
+
+   return DoDataTransfer(pos, length);</codeblock> </section>
+</conbody><related-links>
+<link href="GUID-86082C0C-B0EE-5E7C-85B4-4A509066012F.dita"><linktext>MMC Porting
+Implementation Tutorial</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-240EE926-BAFC-4A53-A8F8-D559BA7BB672.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-240EE926-BAFC-4A53-A8F8-D559BA7BB672" xml:lang="en"><title>DMA Client Interface Quick Start</title><shortdesc>Basic steps to use the Client  interface of the DMA framework.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The DMA framework provides an interface for clients, such as device
+drivers, to perform data transfers. </p>
+<section id="GUID-051DBDD4-38FA-4935-B639-178524414A1E">       <title>Basic steps</title>       <p>The following are the basic steps to
+use the DMA framework:</p><ol>
+<li id="GUID-2781CFB5-B83D-4F52-8516-BCBE849AE7C4"><p>The <xref href="GUID-4E3C086B-25BE-4DAC-9E21-CFC4F8B792A5.dita">DMA Technology Guide</xref> describes the basic concepts of the DMA framework.</p></li>
+<li id="GUID-40076E18-E559-4F28-8B41-AC32FE2D27FE"><p>The <xref href="GUID-EE50283A-543C-446F-A5D1-E64043F988ED.dita">DMA Device Driver
+Guide</xref> explains the concepts of device driver guide. </p></li>
+<li id="GUID-E51EA88B-8FB8-42B9-A9BA-2E59AAD9B099"><p>The <xref href="GUID-D5ED62EB-744D-42EB-B8CF-D5623BDA5B38.dita">DMA Client Interface
+Guide</xref> explains the interface and how to use it.</p></li>
+<li id="GUID-C152E4CF-03F6-4584-A1DE-06A2627CE3B0"><p>The <xref href="GUID-C2114C7B-705C-4527-836A-C6E72227111A.dita">DMA Testing Guide</xref> provides the location of the test application.</p></li>
+</ol>     </section>
+</conbody><related-links>
+<link href="GUID-AB5370D9-9F0B-4583-A825-11CBF7C6365C.dita"><linktext>DMA
+Tutorials Overview</linktext></link>
+<link href="GUID-6873E764-4132-46C8-8444-6301CF4D2033.dita"><linktext>DMA
+Hardware Interface</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2490DA46-A57B-4DFD-AA9C-2004D58486E3.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2490DA46-A57B-4DFD-AA9C-2004D58486E3" xml:lang="en"><title>Interrupt Testing Guide</title><shortdesc>Describes the test suites required to test the platform
+service implementation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There is no specific test suite available for the Interrupt platform
+service at the moment.</p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2559E3F7-314B-5DCC-A7FE-A08162A89721.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,56 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2559E3F7-314B-5DCC-A7FE-A08162A89721" xml:lang="en"><title>Local
+Media Subsystem Overview</title><shortdesc>Provides the logical device driver for the internal and removable
+storage media on a phone. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-F7C4ED03-1A25-4F13-8B48-8A5463510422"><title>Purpose</title> <p>The local media sub-system allows the Symbian
+platform file system and other programs to communicate with local media devices. </p> </section>
+<section id="GUID-80F9C844-882C-4EA4-85C4-58D62C11685A"><title>Required background</title> <p>The local media sub-system
+requires an understanding of the Symbian platform file system and local media
+devices. </p> </section>
+<section id="GUID-E70E10E5-2676-4C0F-B28B-060F823DECCF"><title>Key concepts and terms</title> <dl>
+<dlentry>
+<dt>local drive</dt>
+<dd><p>A media drive mounted within the phone. </p> </dd>
+</dlentry>
+</dl> </section>
+<section id="GUID-08F96B25-71FA-4A62-A77B-5076F509AE23"><title>Architecture</title> <p>The <xref href="GUID-32659A02-6541-3D15-AB88-B70FBD7DF9B0.dita"><apiname>TBusLocalDrive</apiname></xref> class
+provides an interface to the local media sub-system. Each instance of this
+class represents a channel of communication with a local drive. To establish
+a channel a client connects an instance of the class to a specified drive.
+The file server contains 16 instances of <xref href="GUID-32659A02-6541-3D15-AB88-B70FBD7DF9B0.dita"><apiname>TBusLocalDrive</apiname></xref>,
+one for each local drive. Programs other than the file server may also create
+instances to access a local drive. Drives are abstracted by the <xref href="GUID-2E1AEAC0-CEDF-31A5-B36A-FC4749B979A5.dita"><apiname>TDrive</apiname></xref> class. </p> </section>
+<section id="GUID-3495E8DD-C6AA-47D3-A64F-4431C2A90850"><title>Local Media Sub-system Summary</title> <p>The local media
+subsystem provides the following: </p> <ul>
+<li id="GUID-79E68BE5-9713-5E24-B3C6-D0123CD13056"><p> <b>Local media LDD</b>  </p> <p> <filepath>elocd.ldd</filepath>  </p> <p>The
+kernel-side logical device driver which implements communication between physical
+devices and applications which use them. </p> </li>
+</ul> </section>
+<section id="GUID-74061F49-2659-47D1-9DB8-2FF3CB10B2E8"><title>Typical uses</title> <p>The <xref href="GUID-32659A02-6541-3D15-AB88-B70FBD7DF9B0.dita"><apiname>TBusLocalDrive</apiname></xref> class
+is used to connect to and disconnect from local drives, to read to and write
+from them, to provide information about the capabilities of the drives, to
+format them, and to mount and remount drives on specified media drivers. </p> <p>Local
+media subsystem: </p> <ul>
+<li id="GUID-1A411257-57A7-5206-AE12-811B5F71727A"><p>Manages device connections </p> </li>
+<li id="GUID-74C8A86A-D797-5473-8192-A4EA6DE1C8B0"><p>Manages data transfer </p> </li>
+<li id="GUID-5D62718F-3B7F-5D0E-9B95-BDA2C1FB77D3"><p>Handles notifications
+and device configuration. </p> </li>
+</ul> </section>
+</conbody><related-links>
+<link href="GUID-F3BD37EC-0CCB-5859-908F-215E22C9FC20.dita#GUID-F3BD37EC-0CCB-5859-908F-215E22C9FC20/GUID-143780ED-4A23-5E72-A923-F605172EC8B5">
+<linktext>File Server</linktext></link>
+<link href="GUID-6CF2F4EF-383F-5850-A522-F425A83AA89E.dita#GUID-6CF2F4EF-383F-5850-A522-F425A83AA89E/GUID-20E09BC9-35CA-594A-BA91-D8D0C928FD98">
+<linktext>File Systems</linktext></link>
+<link href="GUID-9540A82E-F83D-55F5-B441-868CF77468E9.dita#GUID-9540A82E-F83D-55F5-B441-868CF77468E9/GUID-CFED15B1-E768-534E-9043-7AADE45EE9AF">
+<linktext>Media Drivers</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,285 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C" xml:lang="en"><title>Bootstrap Source Macros</title><shortdesc>Describes the macros used in source files.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This set of macros is available for use in source files, but not in platform
+specific configuration header files. Their definitions are obtained by including <filepath>os/kernelhwsrv/kernel/eka/include/kernel/arm/bootcpu.inc</filepath>. </p>
+<section id="GUID-B4783B78-8320-5315-B88D-40BCC8FDF64B"><title>General macros</title> <p><b>GETCPSR</b> </p><codeblock id="GUID-DE99B191-1C2F-5843-B6FC-776996CDB238" xml:space="preserve">GETCPSR    reg</codeblock><p>Reads
+the CPSR into the specified ARM general register <codeph>reg</codeph>. </p><p>This
+macro should be used in preference to MRS instructions to avoid problems related
+to syntax incompatibility between different assembler versions. </p> <p><b>CGETCPSR</b> </p><codeblock id="GUID-7F37007A-9407-5BBA-B42A-DB447B32F4A6" xml:space="preserve">CGETCPSR reg, cc</codeblock><p>Reads
+the CPSR into the specified ARM general register <codeph>reg</codeph>. This
+is conditionally executed using <codeph>cc</codeph> as the execution condition. </p><p>This
+macro should be used in preference to MRS instructions to avoid problems related
+to syntax incompatibility between different assembler versions. </p> <p><b>GETSPSR</b> </p><codeblock id="GUID-8636F4DC-EE5F-5121-A397-4AD5B66EB4A4" xml:space="preserve">GETSPSR    reg</codeblock><p>Reads
+the SPSR into the specified ARM general register <codeph>reg</codeph>. </p><p>This
+macro should be used in preference to MRS instructions to avoid problems related
+to syntax incompatibility between different assembler versions. </p> <p><b>CGETSPSR</b> </p><codeblock id="GUID-EA9861EC-AA09-5E52-9A84-D35DA301EE1E" xml:space="preserve">CGETSPSR reg, cc</codeblock><p>Reads
+the SPSR into the specified ARM general register <codeph>reg</codeph>. This
+is conditionally executed using <codeph>cc</codeph> as the execution condition. </p><p>This
+macro should be used in preference to MRS instructions to avoid problems related
+to syntax incompatibility between different assembler versions. </p> <p><b>SETCPSR</b> </p> <codeblock id="GUID-5AC38C91-DF6D-5842-B669-7D54D9E1C580" xml:space="preserve">SETCPSR    reg</codeblock> <p>Writes
+the entire (all 32 bits) CPSR from the specified ARM general register <codeph>reg</codeph>.</p><p>This
+macro should be used in preference to MRS instructions to avoid problems related
+to syntax incompatibility between different assembler versions. </p> <p><b>CSETCPSR</b> </p><codeblock id="GUID-B2ED96F7-0985-5673-8D22-5E036F73B308" xml:space="preserve">CSETCPSR reg, cc</codeblock><p>Writes
+the entire (all 32 bits) CPSR from the specified ARM general register <codeph>reg</codeph>.
+This is conditionally executed using <codeph>cc</codeph> as the execution
+condition. </p><p>This macro should be used in preference to MRS instructions
+to avoid problems related to syntax incompatibility between different assembler
+versions. </p> <p><b>SETSPSR</b> </p><codeblock id="GUID-A5DA9C4A-1D08-5CCE-B507-25E778B80A2D" xml:space="preserve">SETSPSR    reg</codeblock><p>Writes
+the entire (all 32 bits) SPSR from the specified ARM general register <codeph>reg</codeph>. </p><p>This
+macro should be used in preference to MRS instructions to avoid problems related
+to syntax incompatibility between different assembler versions. </p> <p><b>CSETSPSR</b> </p><codeblock id="GUID-94F1C1A0-92E1-5F7D-B49A-A283303D10BC" xml:space="preserve">CSETSPSR reg, cc</codeblock><p>Writes
+the entire (all 32 bits) SPSR from the specified ARM general register <codeph>reg</codeph>.
+This is conditionally executed using <codeph>cc</codeph> as the execution
+condition. </p><p>This macro should be used in preference to MRS instructions
+to avoid problems related to syntax incompatibility between different assembler
+versions. </p> <p><b>BOOTCALL</b> </p><codeblock id="GUID-EDAA1A5D-8067-5754-8FED-2B0C5E68F687" xml:space="preserve">BOOTCALL call_numbe</codeblock><p>Calls
+the specified function via the boot table. <codeph>call_number</codeph> should
+be one of the <codeph>BTF_*</codeph> values in the <codeph>TBootTableEntry</codeph> enumeration,
+defined in <filepath>os/kernelhwsrv/kernel/eka/include/kernel/arm/bootdefs.h</filepath>. </p><p>The
+macro is transparent; the function is entered with all registers and flags
+having the same values as immediately before the macro. </p> <p><b>GETPARAM</b> </p><codeblock id="GUID-3A25AFEF-8195-555B-B328-4BA1A8988D1F" xml:space="preserve">GETPARAM pnum, default</codeblock><p>Retrieves
+the parameter with number <codeph>pnum</codeph> from the boot parameter table,
+and returns its value in <codeph>R0</codeph>. If the parameter is not present
+in the table, then <codeph>R0</codeph> is loaded with value <codeph>default</codeph>. </p><p>See
+the description of <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-4DEA1D4C-EC7B-5F9A-A293-A7F80899044B">BTF_Params</xref> for
+more information on the boot parameter table. </p> <p><b>GETMPARAM</b> </p><codeblock id="GUID-5DA2A8EA-6D2E-5ECD-80B9-FDD1CDEE1797" xml:space="preserve">GETMPARAM pnum</codeblock><p>Retrieves
+the parameter with number <codeph>pnum</codeph> from the boot parameter table,
+and returns its value in <codeph>R0</codeph>. If the parameter is not present
+in the table, then the macro faults the system. </p><p>See the description
+of <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-4DEA1D4C-EC7B-5F9A-A293-A7F80899044B">BTF_Params</xref> for
+more information on the boot parameter table. </p> <p><b>FAULT</b> </p><codeblock id="GUID-8C551296-DAF8-57D3-9048-3B06387820AB" xml:space="preserve">FAULT cc</codeblock><p>Faults
+the system if condition <codeph>cc</codeph> is true. The condition is a standard
+ARM condition code. </p> <p id="GUID-B5EC22B5-B995-5D54-8F33-1B6FCE11BB3F"><b>BTP_ENTRY</b></p> <p>Declares
+MMU permissions and cache attributes. The macro takes a variable number of
+arguments depending on the processor in use. </p><p>For ARM architecture 6
+CPUs: </p><codeblock id="GUID-7CD2FE06-23C4-569A-AFBB-D62BE8CE2CC9" xml:space="preserve">BTP_ENTRY $domain, $perm, $cache, $execute, $global, $P, $S</codeblock> <p>For
+XScale CPUs: </p><codeblock id="GUID-1E6704C5-AABA-51E3-8C6B-233E6A188829" xml:space="preserve">BTP_ENTRY $domain, $perm, $cache, $P</codeblock> <p>For
+other CPUs: </p><codeblock id="GUID-1D95F820-E5FC-5A95-B4D7-051F9A5DD70C" xml:space="preserve">BTP_ENTRY $domain, $perm, $cache</codeblock> <table id="GUID-99F49C22-9194-565E-8C8A-F4D864311A8B">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>$domain </p> </entry>
+<entry><p>ARM domain number 0-15. In general only one memory-model-dependent
+value is used here and the symbol <codeph>CLIENT_DOMAIN</codeph> specifies
+this. </p></entry>
+</row>
+<row>
+<entry><p>$perm </p> </entry>
+<entry><p>Permissions for mapping. </p><p>For architecture 6 CPUs, use one
+of <codeph>PERM_NONO</codeph>, <codeph>PERM_RWNO</codeph>, <codeph>PERM_RWRO</codeph>, <codeph>PERM_RWRW</codeph>, <codeph>PERM_RONO</codeph>, <codeph>PERM_RORO</codeph>. </p><p>For other CPUs, use one of <codeph>PERM_RORO</codeph>, <codeph>PERM_RWNO</codeph>, <codeph>PERM_RWRO</codeph>, <codeph>PERM_RWRW</codeph>. </p><p>In each of these names the first pair of letters
+refers to supervisor, and the second pair to user access, so <codeph>PERM_RWNO</codeph> means
+supervisor read/write, user no access. </p></entry>
+</row>
+<row>
+<entry><p>$cache </p> </entry>
+<entry><p>Cache attributes for mapping. These are processor dependent - see
+the <codeph>CACHE_*</codeph> macros in <filepath>os/kernelhwsrv/kernel/eka/include/kernel/arm/bootcpu.inc</filepath>. </p></entry>
+</row>
+<row>
+<entry><p>$execute </p> </entry>
+<entry><p>ARM architecture 6 only. Determines whether code can be executed
+from the mapped region; either <codeph>BTPERM_EXECUTE</codeph> or <codeph>BTPERM_NO_EXECUTE</codeph>. </p> </entry>
+</row>
+<row>
+<entry><p>$global </p> </entry>
+<entry><p>ARM architecture 6 only. Determines whether the mapped region is
+ASID specific (local) or non-ASID specific (global); either <codeph>BTPERM_LOCAL</codeph> or <codeph>BTPERM_GLOBAL</codeph>. </p> </entry>
+</row>
+<row>
+<entry><p>$P </p> </entry>
+<entry><p>ARM architecture 6 and XScale only. Determines whether or not ECC
+should be used on the mapped region (assuming hardware supports ECC); either <codeph>BTPERM_ECC</codeph> or <codeph>BTPERM_NON_ECC</codeph>. </p> </entry>
+</row>
+<row>
+<entry><p>$S </p> </entry>
+<entry><p>ARM architecture 6 only. Determines whether the mapped region is
+shared between multiple CPUs or not; either <codeph>BTPERM_SHARED</codeph> or <codeph>BTPERM_NON_SHARED</codeph>. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-7361BC74-7164-52EE-9A5B-D254560D1939"><b>ROM_BANK</b> </p><codeblock id="GUID-7685BA97-8DC4-537C-AEBC-110AB0981DD0" xml:space="preserve">ROM_BANK PHYS, SIZE, LIN, WIDTH, TYPE, RAND, SEQ</codeblock><p>Declares
+an XIP ROM bank entry. </p> <table id="GUID-F701B695-A499-57E0-97B6-7C5701E09F77">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>PHYS </p> </entry>
+<entry><p>The physical base address of the ROM bank. </p> </entry>
+</row>
+<row>
+<entry><p>SIZE </p> </entry>
+<entry><p>The size of the ROM bank. </p> </entry>
+</row>
+<row>
+<entry><p>LIN </p> </entry>
+<entry><p>Linear address override (usually 0). </p> </entry>
+</row>
+<row>
+<entry><p>WIDTH </p> </entry>
+<entry><p>Bus width. One of: <codeph>ROM_WIDTH_8</codeph>, <codeph>ROM_WIDTH_16</codeph> or <codeph>ROM_WIDTH_32</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p>TYPE </p> </entry>
+<entry><p>The ROM type; see the <xref href="GUID-C1232A34-6E4C-3AAF-8E97-8BA2303B9508.dita"><apiname>TRomType</apiname></xref> enumeration. </p> </entry>
+</row>
+<row>
+<entry><p>RAND </p> </entry>
+<entry><p>Random access speed. </p> </entry>
+</row>
+<row>
+<entry><p>SEQ </p> </entry>
+<entry><p>Sequential access speed. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>See also <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-52792290-48DA-5F1A-A7AD-0105A8AA37CF">BTF_RomBanks</xref> in <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita">Boot Table Functions</xref>. </p> </section>
+<section id="GUID-7728C7F2-BB04-518B-8B0A-752CB799A561"><title>Macros for
+declaring I/O mappings</title> <p id="GUID-13254CB0-3659-5338-A3C2-1277F6869CA7"><b>HW_MAPPING</b> </p><codeblock id="GUID-5A4745F8-8B21-593B-85AF-4C56D7DA7075" xml:space="preserve">HW_MAPPING PHYS,SIZE,MULT</codeblock><p>Defines
+an I/O mapping using the standard permissions and cache attributes for I/O
+mappings, i.e. those defined for the <codeph>BTP_Hw</codeph> boot table entry.
+See <xref href="GUID-C92CC81A-35A1-5860-AA08-C8C08B39804C.dita">Boot Table MMU
+Permission and Cache Attribute Definitions</xref>. </p> <table id="GUID-9B975DEB-0D16-5DEE-8E11-7109E052D409">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>PHYS </p> </entry>
+<entry><p>Physical base address. </p> </entry>
+</row>
+<row>
+<entry><p>SIZE </p> </entry>
+<entry><p>Size of the mapping. </p> </entry>
+</row>
+<row>
+<entry><p>MULT </p> </entry>
+<entry><p> <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-B13C34B2-69E5-51A2-8807-5576FD091C34">Granularity
+of the I/O mapping</xref> (below). </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>See also: </p><ul>
+<li id="GUID-75387946-50A1-5D24-A5C4-4AED7954ACAF"><p><xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-20A2344A-1BE2-5AFD-BC37-997F08E2A28C">Determining the linear address</xref> (below). </p> </li>
+<li id="GUID-2DD01E2F-841B-5242-9757-A48F6036AE6A"><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-62CD8D6F-6E12-5DFC-85BC-EA24000BA588">BTF_HwBanks</xref> in <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita">Boot
+Table Functions</xref>. </p></li>
+</ul> <p id="GUID-EF703014-E498-5623-ACC6-8E3E9882C681"><b>HW_MAPPING_EXT</b> </p><codeblock id="GUID-EEAFCF55-9C2F-5EE6-9A37-287772F4BCF4" xml:space="preserve">HW_MAPPING_EXT    PHYS,SIZE,MULT</codeblock><p>Defines
+an I/O mapping using the permissions and cache attributes defined by a <codeph>BTP_ENTRY</codeph> macro
+that immediately follows this macro. See <xref href="GUID-C92CC81A-35A1-5860-AA08-C8C08B39804C.dita">Boot
+Table MMU Permission and Cache Attribute Definitions</xref>. </p><table id="GUID-8186D7BA-30AC-5A3A-BF25-6AB6984B0A45">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>PHYS </p> </entry>
+<entry><p>Physical base address. </p> </entry>
+</row>
+<row>
+<entry><p>SIZE </p> </entry>
+<entry><p>Size of the mapping. </p> </entry>
+</row>
+<row>
+<entry><p>MULT </p> </entry>
+<entry><p> <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-B13C34B2-69E5-51A2-8807-5576FD091C34">Granularity
+of the I/O mapping</xref> (below). </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>See also: </p> <ul>
+<li id="GUID-460D2F0F-F42B-58CD-910B-5DEEE210F061"><p> <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-20A2344A-1BE2-5AFD-BC37-997F08E2A28C">Determining the linear address</xref> (below). </p> </li>
+<li id="GUID-D13EB05F-E447-51EA-BF15-0AA3870BE101"><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-62CD8D6F-6E12-5DFC-85BC-EA24000BA588">BTF_HwBanks</xref> in <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita">Boot
+Table Functions</xref>. </p> </li>
+</ul> <p id="GUID-7402DE22-6CB9-5236-BA3B-99D6CE40A381"><b>HW_MAPPING_EXT2</b> </p><codeblock id="GUID-6F0B0F0D-CBE6-5320-9F51-39388B4181E6" xml:space="preserve">HW_MAPPING_EXT2    PHYS,SIZE,MULT,LIN</codeblock><p>Defines
+an I/O mapping using the standard permissions and cache attributes for I/O
+mappings, i.e. those defined for the <codeph>BTP_Hw</codeph> boot table entry.
+See <xref href="GUID-C92CC81A-35A1-5860-AA08-C8C08B39804C.dita">Boot Table MMU
+Permission and Cache Attribute Definitions</xref>. </p> <table id="GUID-55243AD3-DF9F-5D9D-9549-35F577C20E83">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>PHYS </p> </entry>
+<entry><p>Physical base address. </p> </entry>
+</row>
+<row>
+<entry><p>SIZE </p> </entry>
+<entry><p>Size of the mapping. </p> </entry>
+</row>
+<row>
+<entry><p>MULT </p> </entry>
+<entry><p> <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-B13C34B2-69E5-51A2-8807-5576FD091C34">Granularity
+of the I/O mapping</xref> (below). </p> </entry>
+</row>
+<row>
+<entry><p>LIN </p> </entry>
+<entry><p>Linear address. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>See also <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-62CD8D6F-6E12-5DFC-85BC-EA24000BA588">BTF_HwBanks</xref> in <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita">Boot Table Functions</xref>. </p> <p id="GUID-9F79FF06-C8E8-599A-875A-D772FB6E8862"><b>HW_MAPPING_EXT3</b> </p><codeblock id="GUID-C1948F05-F4C7-5DCC-A266-0489F5A0BC00" xml:space="preserve">HW_MAPPING_EXT3 PHYS,SIZE,MULT,LIN</codeblock><p>Defines
+an I/O mapping using the permissions and cache attributes defined by a <codeph>BTP_ENTRY</codeph> macro
+that immediately follows this macro. See <xref href="GUID-C92CC81A-35A1-5860-AA08-C8C08B39804C.dita">Boot
+Table MMU Permission and Cache Attribute Definitions</xref>. </p> <table id="GUID-D7252A3A-F7ED-5A78-94B2-B736AC61046E">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>PHYS </p> </entry>
+<entry><p>Physical base address. </p> </entry>
+</row>
+<row>
+<entry><p>SIZE </p> </entry>
+<entry><p>Size of the mapping. </p> </entry>
+</row>
+<row>
+<entry><p>MULT </p> </entry>
+<entry><p> <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-B13C34B2-69E5-51A2-8807-5576FD091C34">Granularity
+of the I/O mapping</xref> (below). </p> </entry>
+</row>
+<row>
+<entry><p>LIN </p> </entry>
+<entry><p>Linear address. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>See also <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-62CD8D6F-6E12-5DFC-85BC-EA24000BA588">BTF_HwBanks</xref> in <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita">Boot Table Functions</xref>.. </p> <p id="GUID-B13C34B2-69E5-51A2-8807-5576FD091C34"><b>Granularity of the I/O mapping</b> </p> <p>The
+granularity of the I/O mapping is defined by the <codeph>MULT</codeph> parameter
+of the I/O mapping macros: <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-13254CB0-3659-5338-A3C2-1277F6869CA7">HW_MAPPING</xref>, <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-EF703014-E498-5623-ACC6-8E3E9882C681">HW_MAPPING_EXT</xref>, <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-7402DE22-6CB9-5236-BA3B-99D6CE40A381">HW_MAPPING_EXT2</xref> and <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-9F79FF06-C8E8-599A-875A-D772FB6E8862">HW_MAPPING_EXT3</xref>. </p> <p>The <codeph>MULT</codeph> parameter specifies the granularity of the mapping. It takes one of the
+following values: </p> <ul>
+<li id="GUID-AA1B0CD5-6336-5C02-AF02-562AB4A44FA3"><p> <codeph>HW_MULT_4K</codeph> use
+4K pages. The <codeph>PHYS</codeph> and <codeph>LIN</codeph> parameters must
+be multiples of 4K. </p> </li>
+<li id="GUID-15DC0CE0-B90C-500C-90FD-F750F61F509B"><p> <codeph>HW_MULT_64K</codeph> use
+64K pages. The <codeph>PHYS</codeph> and <codeph>LIN</codeph> parameters must
+be multiples of 64K. </p> </li>
+<li id="GUID-DE644971-8E56-5921-85BD-BC79AAD66C49"><p> <codeph>HW_MULT_1M</codeph> use
+1M sections. The <codeph>PHYS</codeph> and <codeph>LIN</codeph> parameters
+must be multiples of 1M. </p> </li>
+</ul> <p>In each case the unit in which the <codeph>SIZE</codeph> parameter
+is specified is <codeph>MULT</codeph>, that is to say the actual mapping size
+in bytes is <codeph>SIZE*MULT</codeph>. For example: </p><codeblock id="GUID-5B389113-F6DB-5011-8B59-93F599519E94" xml:space="preserve">HW_MAPPING    0x80000000, 1, HW_MULT_4K
+HW_MAPPING    0x80010000, 3, HW_MULT_64K</codeblock><p>declares a mapping
+of size 4K starting at physical address <codeph>0x80000000</codeph> followed
+by a mapping of 192K in 64K pages starting at physical address <codeph>0x80010000</codeph>. </p> <p id="GUID-20A2344A-1BE2-5AFD-BC37-997F08E2A28C"><b>Determining the linear address</b> </p> <p>For
+those macros that don't specify a linear address: <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-13254CB0-3659-5338-A3C2-1277F6869CA7">HW_MAPPING</xref> and <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-EF703014-E498-5623-ACC6-8E3E9882C681">HW_MAPPING_EXT</xref>,
+it is determined as follows: </p> <ul>
+<li id="GUID-37DB1D7B-0D4B-5E3C-9E7F-F195D7A1B95C"><p>On the direct memory
+model, it is equal to the physical address. </p> </li>
+<li id="GUID-77168F6C-3B11-5B32-AEF1-B77046A0EC78"><p>On the moving memory
+model and the multiple memory model, the first such mapping is placed at <codeph>KPrimaryIOBase</codeph> (<codeph>0x63000000</codeph> on
+the moving model, <codeph>0xC3000000</codeph> on the multiple model). Each
+mapping first rounds the linear address counter up to the next multiple of <codeph>MULT</codeph> before
+making the mapping, then increments it by <codeph>SIZE*MULT</codeph> after
+making it. </p> </li>
+</ul> <p>For example, on the moving memory model, the following mappings would
+have linear addresses <codeph>0x63000000</codeph>, <codeph>0x63002000</codeph>, <codeph>0x63010000</codeph>, <codeph>0x63020000</codeph> and <codeph>0x63100000</codeph> respectively: </p><codeblock id="GUID-529F87FB-7DD6-521F-8397-667C710843E2" xml:space="preserve">HW_MAPPING    0x80000000, 2, HW_MULT_4K
+HW_MAPPING    0x80010000, 1, HW_MULT_4K
+HW_MAPPING    0x80100000, 1, HW_MULT_64K
+HW_MAPPING    0x80200000, 1, HW_MULT_4K
+HW_MAPPING    0x90000000, 1, HW_MULT_1M</codeblock> <p>For the direct memory
+model, all I/O mappings required by the system must be listed here since it
+is not possible to make further mappings once the kernel is running. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2607CCFA-3D24-4716-A447-74304F861C44.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,490 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2607CCFA-3D24-4716-A447-74304F861C44" xml:lang="en"><title>DSDIORegisterInterface
+Class Tutorial</title><shortdesc>Describes the DSDIORegisterInterface API class.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-22A35782-49B5-4646-9125-042578A010C1"><title>Description</title><p>This
+class provides the main client API between the SDIO implementation and the
+rest of the system.</p><p>For portability reasons, it is recommended that
+this class is allocated on behalf of the client by the appropriate function
+class after the client has been registered with the SDIO function.</p><p><note> Unless
+stated otherwise, all the register offsets are defined to be relative to offsets
+within the SDIO function.</note></p><table id="GUID-F453D4C2-EECF-4BE4-9776-922C009BB246">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p>Header file</p></entry>
+<entry><p><filepath>regifc.h</filepath></p></entry>
+</row>
+<row>
+<entry><p>Source code file</p></entry>
+<entry><p><filepath>regifc.cpp</filepath></p></entry>
+</row>
+<row>
+<entry><p>Required libraries</p></entry>
+<entry><p>EPBUSSDIO</p></entry>
+</row>
+<row>
+<entry><p>Class declaration</p></entry>
+<entry><p><codeph>class DSDIORegisterInterface: public DSDIOSession</codeph></p></entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-76BC7A1A-A54A-47D3-ADAC-9D075A7A667F"><title>Read8()</title><p>The
+function declaration for the <xref href="GUID-53280C38-1734-332D-A432-0A56AB16CD04.dita"><apiname>Read8()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt Read8(TUint32 aReg, TUint8* aReadDataP);</codeblock><p><b>Description</b></p><p>This method reads a single 8 bit value from the
+specified register.</p><p><b>Parameters</b></p><table id="GUID-DC782836-BB2D-4A01-9A94-CEDB655FB269">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aReq</codeph></p></entry>
+<entry><p>The Source register address.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8* aReadDataP</codeph></p></entry>
+<entry><p>The location of the byte to read into.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><table id="GUID-F5165642-EAE8-4E66-AD96-5185D337F716">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>The result of the operation. KErrNone if the operation was successful,
+otherwise a system wide error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-3DAF62F4-4A57-4BB1-B32A-6F623A1A17B6"><title>Write8()</title><p>The
+function declaration for the <xref href="GUID-BF2E636A-FA49-39F6-9A52-A09E4879F3FC.dita"><apiname>Write8()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt Write8(TUint32 aReg, TUint8  aWriteVal);</codeblock><p><b>Description</b></p><p>This method writes a single 8 bit value to the
+register specified.</p><p><b>Parameters</b></p><table id="GUID-620A412A-44B3-4B73-B2D1-3DD588F93BED">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aReg</codeph></p></entry>
+<entry><p>The destination register address.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8 aWriteVal</codeph></p></entry>
+<entry><p>The 8 bit value to be written.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><table id="GUID-954C9104-569D-4E48-A7E0-9AFF93CD267A">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>The result of the operation. <codeph>KErrNone</codeph> if the operation
+was successful, otherwise a system wide error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-17DAC528-073D-4981-B908-529156DD5329"><title>Modify8()</title><p>The
+function declaration for the <xref href="GUID-312948B9-5338-3030-9130-821E9BDDCE62.dita"><apiname>Modify8()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt Modify8(TUint32 aReg, TUint8 aSet, TUint8 aClr);
+</codeblock><p><b>Description</b></p><p>This method performs a bitwise read-modify-write
+operation on the specified register.</p><p><b>Parameters</b></p><table id="GUID-9DC3C571-7270-4306-B3B2-2CF35AC0B643">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aReg</codeph></p></entry>
+<entry><p>The destination register address.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8 aSet</codeph></p></entry>
+<entry><p>A bitmask of the values to be set.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8 aClr</codeph></p></entry>
+<entry><p>A bitmask of the values to be cleared.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><table id="GUID-A7BB8C27-B5DD-4FB2-9225-78877E5F7255">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>The result of the operation. <codeph>KErrNone</codeph> if the operation
+was successful, otherwise a system wide error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-44105A9A-C2E6-4A8C-B6F7-04A154A11EE1"><title>Modify8() with
+read-after-write</title><p>The function declaration for the <xref href="GUID-312948B9-5338-3030-9130-821E9BDDCE62.dita"><apiname>Modify8()</apiname></xref> with
+read-after-write method is:</p><codeblock xml:space="preserve">IMPORT_C TInt Modify8(TUint32 aReg, TUint8 aSet, TUint8 aClr, TUint8* aReadDataP);</codeblock><p><b>Description</b></p><p>This method performs a bitwise read-modify-write operation on the
+specified register.</p><p><b>Parameters</b></p><table id="GUID-9F7DB1E5-C679-4D25-AB28-313CE2EF5802">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aReg</codeph></p></entry>
+<entry><p>The destination register address.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8 aSet</codeph></p></entry>
+<entry><p>A bitmask of the values to be set.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8 aClr</codeph></p></entry>
+<entry><p>A bitmask of the values to be cleared.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8* aReadDataP</codeph></p></entry>
+<entry><p>The address of the byte to read into. The result of the operation
+is stored in this buffer.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><table id="GUID-78F38934-81F8-4E93-8400-09AED7138883">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>The result of the operation. <codeph>KErrNone</codeph> if the operation
+was successful, otherwise a system wide error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-C079E54E-24B3-488B-BAB2-7625565871C1"><title>ReadMultiple8()</title><p>The
+function declaration for the <xref href="GUID-2E0277CD-3CB8-3A8C-AAD3-8083E8BA7B60.dita"><apiname>ReadMultiple8()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt ReadMultiple8(TUint32 aReg, TUint8* aDataP, TUint32 aLen);
+</codeblock><p><b>Description</b></p><p>This method reads the specified number
+of bytes starting at the specified register offset.</p><p><b>Parameters</b></p><table id="GUID-1FC8E85C-821E-4123-BF5C-7F163D4C31C0">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aReg</codeph></p></entry>
+<entry><p>The source register address.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8* aDataP</codeph></p></entry>
+<entry><p>The start address of the destination buffer.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint32 aLen</codeph></p></entry>
+<entry><p>The number of bytes to be read.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><table id="GUID-0A75AC37-3D8A-4F75-BE0D-FBC2BADD84FE">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>The result of the operation. <codeph>KErrNone</codeph> if the operation
+was successful, otherwise a system wide error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-06A354DC-92E9-426E-BCEA-8B141731A4E8"><title>ReadMultiple8()
+with auto-increment</title><p>The function declaration for the <xref href="GUID-2E0277CD-3CB8-3A8C-AAD3-8083E8BA7B60.dita"><apiname>ReadMultiple8()</apiname></xref> 
+method with auto-increment is:</p><codeblock xml:space="preserve">IMPORT_C TInt ReadMultiple8(TUint32 aReg, TUint8* aDataP, TUint32 aLen, TBool aAutoInc);
+</codeblock><p><b>Description</b></p><p>This method reads the specified number
+of bytes starting at the specified register offset.</p><p><b>Parameters</b></p><table id="GUID-6DAFE385-A10D-4FE1-BD9F-73DF32C57317">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aReg</codeph></p></entry>
+<entry><p>The source register address.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8* aDataP</codeph></p></entry>
+<entry><p>The start address of the destination buffer.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint32 aLen</codeph></p></entry>
+<entry><p>The number of bytes that are to be read.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TBool aAutoInc</codeph></p></entry>
+<entry><p>Enable or disable the auto-increment functionality.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><table id="GUID-A2B48766-0BD9-468F-8840-7AF6EF74E886">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>The result of the operation. <codeph>KErrNone</codeph> if the operation
+was successful, otherwise a system wide error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-2F0B67C8-AB5F-4224-B1DB-328FBB17DC7B"><title>ReadMultiple8()
+using shared chunks</title><p>The function declaration for the <xref href="GUID-2E0277CD-3CB8-3A8C-AAD3-8083E8BA7B60.dita"><apiname>ReadMultiple8()</apiname></xref>method
+using shared chunks is:</p><codeblock xml:space="preserve">IMPORT_C TInt ReadMultiple8(TUint32 aReg, DChunk* aChunk, TUint32 aOffset, TUint32 aLen);
+</codeblock><p><b>Description</b></p><p>This method reads the specified number
+of bytes starting at the specified register offset.</p><p><b>Parameters</b></p><table id="GUID-C8BB983E-3625-4F75-A7C3-8392D3D83115">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aReg</codeph></p></entry>
+<entry><p>The source register address.</p></entry>
+</row>
+<row>
+<entry><p><codeph>DChunk* aChunk</codeph></p></entry>
+<entry><p>The chunk that hosts the destination buffer.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint32 aOffset</codeph></p></entry>
+<entry><p>The offset from the start of the chunk to the start of the destination
+buffer.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint32 aLen</codeph></p></entry>
+<entry><p>The number of bytes to be read.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><table id="GUID-33386AAB-BDAE-4469-9C57-7B5C1B111B93">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p>TInt</p></entry>
+<entry><p>The result of the operation. <codeph>KErrNone</codeph> if the operation
+was successful, otherwise a system wide error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-84D13B57-DB1B-47DB-A1F5-9AF23BE62D35"><title>ReadMultiple8()
+with auto-increment using shared chunks</title><p>The function declaration
+for the <xref href="GUID-2E0277CD-3CB8-3A8C-AAD3-8083E8BA7B60.dita"><apiname>ReadMultiple8()</apiname></xref> method with auto-increment using
+shared chunks is:</p><codeblock xml:space="preserve">IMPORT_C TInt ReadMultiple8(TUint32 aReg, DChunk* aChunk, TUint32 aOffset, TUint32 aLen, TBool aAutoInc);</codeblock><p><b>Description</b></p><p>This method reads the specified number of bytes
+starting at the specified register offset.</p><p><b>Parameters</b></p><table id="GUID-BF998853-26C6-45C7-86A2-C8497D0CB2AB">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aReg</codeph></p></entry>
+<entry><p>The source register address.</p></entry>
+</row>
+<row>
+<entry><p><codeph>DChunk* aChunk</codeph></p></entry>
+<entry><p>The chunk that hosts the destination buffer.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint32 aOffset</codeph></p></entry>
+<entry><p>The offset from the start of the chunk to the start of the destination
+buffer.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint32 aLen</codeph></p></entry>
+<entry><p>The number of bytes to be read.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TBool aAutoInc</codeph></p></entry>
+<entry><p>Enable or disable the auto-increment functionality.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><table id="GUID-99B8EF1A-3E0B-4F1A-897F-1161AF7DC4F6">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>The result of the operation. <codeph>KErrNone</codeph> if the operation
+was successful, otherwise a system wide error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-05558100-F758-4167-B8DD-55DD9D804A96"><title>WriteMultiple8()</title><p>The
+function declaration for the <xref href="GUID-F29DFD6B-9CA4-3170-B829-F3881B152614.dita"><apiname>WriteMultiple8()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt WriteMultiple8(TUint32 aReg, TUint8* aDataP, TUint32 aLen);
+</codeblock><p><b>Description</b></p><p>This method writes the specified length
+of bytes starting at the specified register.</p><p><b>Parameters</b></p><table id="GUID-601B2EDB-99F9-4166-A3A4-66FDFA4875B7">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aReg</codeph></p></entry>
+<entry><p>The destination register address.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8* aDataP</codeph></p></entry>
+<entry><p>The start address of the source buffer.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint32 aLen</codeph></p></entry>
+<entry><p>The number of bytes to be written.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><table id="GUID-73063CCB-18C7-4989-AE97-64F3C851FE38">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>The result of the operation. <codeph>KErrNone</codeph> if the operation
+was successful, otherwise a system wide error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-38B1302E-4410-4230-9AE9-E6ABD84F4EF1"><title>WriteMultiple8()
+with auto-increment</title><p>The function declaration for the <xref href="GUID-F29DFD6B-9CA4-3170-B829-F3881B152614.dita"><apiname>WriteMultiple8()</apiname></xref> method
+with auto-increment is:</p><codeblock xml:space="preserve">IMPORT_C TInt WriteMultiple8(TUint32 aReg, TUint8* aDataP, TUint32 aLen, TBool aAutoInc);
+</codeblock><p><b>Description</b></p><p>This method writes the specified length
+of bytes starting at the specified register.</p><p><b>Parameters</b></p><table id="GUID-FFA05F8A-2459-4581-8B0F-0E5636C53BEE">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aReg</codeph></p></entry>
+<entry><p>The destination register address.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8* aDataP</codeph></p></entry>
+<entry><p>The start address of the source buffer.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint32 aLen</codeph></p></entry>
+<entry><p>The number of bytes to be written.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TBool aAutoInc</codeph></p></entry>
+<entry><p>Enable or disable the auto-increment functionality.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><table id="GUID-BCF4DAA6-7BF8-41F1-9406-40B15363A545">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>The result of the operation. <codeph>KErrNone</codeph> if the operation
+was successful, otherwise a system wide error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-8A745F5C-9EF4-413E-9E55-AF74FB95B507"><title>WriteMultiple8()
+using shared chunks</title><p>The function declaration for the <xref href="GUID-F29DFD6B-9CA4-3170-B829-F3881B152614.dita"><apiname>WriteMultiple8()</apiname></xref> method
+using shared chunks is:</p><codeblock xml:space="preserve">IMPORT_C TInt WriteMultiple8(TUint32 aReg, DChunk* aChunk, TUint32 aOffset, TUint32 aLen);
+</codeblock><p><b>Description</b></p><p>This method writes the specified length
+of bytes starting at the specified register.</p><p><b>Parameters</b></p><table id="GUID-F545CC9C-B098-402C-B940-9994E6CA2FC3-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-5-1-3-12-7">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aReg</codeph></p></entry>
+<entry><p>The destination register address.</p></entry>
+</row>
+<row>
+<entry><p><codeph>DChunk* aChunk</codeph></p></entry>
+<entry><p>The chunk that hosts the source buffer.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint32 aOffset</codeph></p></entry>
+<entry><p>The offset from the start of the chunk and the start address of
+the source buffer.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint32 aLen</codeph></p></entry>
+<entry><p>The number of bytes to be written.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><table id="GUID-47EC4DFC-65B0-4AD8-806C-2AEF74F58217">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>The result of the operation. <codeph>KErrNone</codeph> if the operation
+was successful, otherwise a system wide error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-2481C7F9-C9ED-4EE1-B7FA-C8274CDE78E6"><title>WriteMultiple8(
+) with auto-increment using shared chunks</title><p>The function declaration
+for the <xref href="GUID-F29DFD6B-9CA4-3170-B829-F3881B152614.dita"><apiname>WriteMultiple8()</apiname></xref> method with autoincrement using
+shared chunks is:</p><codeblock xml:space="preserve">IMPORT_C TInt WriteMultiple8(TUint32 aReg, DChunk* aChunk, TUint32 aOffset, TUint32 aLen, TBool aAutoInc);</codeblock><p><b>Description</b></p><p>This method writes the specified length of bytes
+starting at the specified register.</p><p><b>Parameters</b></p><table id="GUID-F545CC9C-B098-402C-B940-9994E6CA2FC3-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-5-1-3-13-7">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aReg</codeph></p></entry>
+<entry><p>The destination register address.</p></entry>
+</row>
+<row>
+<entry><p><codeph>DChunk* aChunk</codeph></p></entry>
+<entry><p>The chunk that hosts the source buffer.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint32 aOffset</codeph></p></entry>
+<entry><p>The offset from the start of the chunk and the start address of
+the source buffer.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint32 aLen</codeph></p></entry>
+<entry><p>The number of bytes to be written.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TBool aAutoInc</codeph></p></entry>
+<entry><p>Enable or disable the auto-increment functionality.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><table id="GUID-281E7616-B0AC-49BE-9D62-3A69F1D8FBF8">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>The result of the operation. <codeph>KErrNone</codeph> if the operation
+was successful, otherwise a system wide error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-43FDE59E-0B10-4F29-8604-E097B183E233"><title>SetAsync()</title><p>The
+function declaration for the <xref href="GUID-AB2D8414-3C4D-3660-A426-6826DC11F37A.dita"><apiname>SetAsync()</apiname></xref>  method is:</p><codeblock xml:space="preserve">IMPORT_C TBool SetAsync(TMMCCallBack&amp; aCallback);
+</codeblock><p><b>Description</b></p><p>This function allows the user to disable
+the synchronous nature of the DSDIORegInterface class, by using the specified
+callback function to indicate the completion of an operation.</p><p><b>Parameters</b></p><table id="GUID-875A5023-8E1B-4823-94AB-69C0732AC2AB">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TMMCCallback&amp; aCallback</codeph></p></entry>
+<entry><p>Reference to the callback function.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><table id="GUID-D745AAFF-6647-4243-95D6-5E8CA44F2397">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TBool</codeph></p></entry>
+<entry><p>The result of the operation. <codeph>KErrNone</codeph> if the operation
+was successful, otherwise a system wide error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-B47D146E-458A-4340-8C9B-F73BEDBE171F"><title>SetSync()</title><p>The
+function declaration for the <xref href="GUID-6B24ACA7-87A3-3477-97F9-1F13BA53AE0D.dita"><apiname>SetSync()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TBool SetSync();</codeblock><p><b>Description</b></p><p>Allows the synchronous nature of the DSDIORegInterface class to be enabled.</p><p>When
+the synchronous nature of the DSDIORegInterface class is enabled, then completion
+of an operation is specified by waiting on a semaphore.</p><p><b>Parameters</b></p><p>None</p><p><b>Return
+value</b></p><table id="GUID-B8033632-5CF2-4C1D-B778-D75F209F3153">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TBool</codeph></p></entry>
+<entry><p>The result of the operation. <codeph>KErrNone</codeph> if the operation
+was successful, otherwise a system wide error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-2622DE31-AA12-5FAD-86FB-B13259EFC6D9-master.png has changed
Binary file Adaptation/GUID-2622DE31-AA12-5FAD-86FB-B13259EFC6D9_d0e9239_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2648B61C-6EBD-4668-AACD-EA4B2C435BB2.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,90 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2648B61C-6EBD-4668-AACD-EA4B2C435BB2" xml:lang="en"><title>Message
+Handling</title><shortdesc>This document describes message queues and message handling.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-AE9A6778-85AE-4D1D-BF61-EE06339549D9"><title>Message queues</title> <p>The
+request handling kernel side DFC is managed by a message queue object of the <xref href="GUID-F10B7D2F-D546-3997-A020-37A0D894F1CD.dita"><apiname>TMessageQueue</apiname></xref> type.
+The message queue consists of a DFC and a doubly linked list of received messages.
+The messages are represented by <xref href="GUID-D43CB8FA-C212-3B56-AD16-9F1D69DA7551.dita"><apiname>TThreadMessage</apiname></xref> objects
+and are owned by each user thread. Requests are queued as message objects
+on the message queue. </p> <p>The driver framework requires that the driver
+sets a DFC queue to use with the message queue. This is done by calling <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita#GUID-A3CC1D95-4681-3349-A67C-F113A614041D/GUID-EB160A2E-39A9-3739-ABDE-C91E2A28D26D"><apiname>DLogicalChannel::SetDfcQ()</apiname></xref>.
+The message queue must also be enabled to receive incoming messages by calling <xref href="GUID-382DD935-E9D7-3E00-88B2-B28A89CAD4FB.dita#GUID-382DD935-E9D7-3E00-88B2-B28A89CAD4FB/GUID-EF06556E-9EC6-3D1C-AEE9-0CDDF6B42A24"><apiname>TMessageQue::Receive()</apiname></xref>. </p> <codeblock id="GUID-A995A927-113D-5CB6-B813-DF88DC02D0C1" xml:space="preserve">// Logical Channel Second stage constructor
+TInt DExDriverLogicalChannel::DoCreate(TInt /*aUnit*/, const TDesC8*
+        /*anInfo*/, const TVersion&amp; aVer)
+    {
+    ...
+    // Set up the DFC queue for this driver. Here, the DFC 
+    // queue is created by the PDD dedicated for this driver.
+    SetDfcQ(Pdd()-&gt;DfcQ());
+
+    // Start receiving the incoming requests on the message queue
+    iMsgQ.Receive();
+    ...
+    }</codeblock> <p>The Kernel provides a standard DFC queue, which runs
+on a dedicated kernel thread called <codeph>DFCThread0</codeph>, for general
+use by drivers. However, it is recommended that the driver creates its own
+DFC thread to process its requests. The following example shows how a PDD
+can implement the <codeph>DfcQ()</codeph> function to return a newly created
+DFC thread: </p> <codeblock id="GUID-4753E5B1-8B8F-5589-8547-C94B48B7D66A" xml:space="preserve">// DfcQ - Creates a DFC queue dedicated for the tutorial driver
+TDynamicDfcQue* DExUartPhysicalChannelH4::DfcQ()
+    {
+    // Create a DFC queue dedicated to the driver with a specified 
+    // priority
+    TInt r = Kern::DynamicDfcQCreate(pDfcQ,KExUartDfcPriority,
+    KExUartDfcName);
+    if (r!=KErrNone)
+        {
+        // DfcQ failed, return NULL
+        return NULL;
+        }
+    return iDfcQueue;
+    }</codeblock> <p>The DFC thread that is created for the driver must be
+destroyed after use. To do this, the driver can create an Exit or Kill DFC
+request and queue it to the thread to be destroyed in the logical channel
+destructor. This exit DFC function cancels any other requests pending using <xref href="GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB.dita#GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB/GUID-9851B90B-8D05-3C86-B083-44C4564AC140"><apiname>TDfc::Cancel()</apiname></xref> and
+calls <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-808B3622-BDC4-376D-96E9-16281BA28AF8"><apiname>Kern::Exit()</apiname></xref> to terminate the thread. </p> <p>The <xref href="GUID-D9111A26-FAA3-3D8E-AB41-5B1263FABB6A.dita"><apiname>TDynamicDfcQue</apiname></xref> has
+a destroy method that can be run on the channel destructor. The destroy method
+destroys the DFC queue, kills the DFC thread and deletes the <xref href="GUID-D9111A26-FAA3-3D8E-AB41-5B1263FABB6A.dita"><apiname>TDynamicDfcQue</apiname></xref> object
+itself. This avoids the possibilities of memory leaks in the DFC. </p></section>
+<section id="GUID-2463763E-1838-4D7D-80F2-D77420B49D09"><title>Message handling</title> <p>All
+synchronous and asynchronous requests are passed to the <xref href="GUID-621F4531-996F-33BB-8081-4B2067CC262A.dita"><apiname>HandleMsg()</apiname></xref> function
+by the framework, with the message as an argument. A driver should implement
+the function to identify the message type and handle the messages accordingly. </p> <p>The
+client thread is blocked until the message is completed, as the request uses
+the thread's message object. If the client thread was left free, it would
+corrupt the message if another request was issued. </p> <p>When the driver
+has completed handling the message, it notifies the framework by calling <xref href="GUID-D43CB8FA-C212-3B56-AD16-9F1D69DA7551.dita#GUID-D43CB8FA-C212-3B56-AD16-9F1D69DA7551/GUID-20CFC972-7C07-36D8-BAC8-BB63AA4612B6"><apiname>TThreadMessage::Complete()</apiname></xref>.
+The client thread is then unblocked, and can either block on the thread semaphore
+or issue further requests before blocking. </p> <p>For synchronous requests,
+the message is not completed until the request itself is complete, and the
+driver calls the <codeph>TThreadMessage::Complete()</codeph> function after
+the actual completion of the request. However, for asynchronous requests,
+the message is completed after the driver has accepted the request, but not
+necessarily after the actual completion of the request, which can happen later.
+This means that the driver calls <codeph>TThreadMessage::Complete()</codeph> as
+soon as it has received the message and initiated the required processing
+to complete the request. </p> <codeblock id="GUID-C178DFFA-2321-5396-AED6-5244BBF98388" xml:space="preserve">void DExDriverLogicalChannel::HandleMsg(TMessageBase* aMsg)
+    {            
+    TThreadMessage&amp; m = *(TThreadMessage*)aMsg;        
+    // obtain the function id value to determine the request nature
+    TInt id = m.iValue;        
+    ...
+    if (id&gt;=0)    // Synchronous messages
+        {
+        // call synchronous message handler function, DoControl()    
+        TInt r = DoControl(id,m.Ptr0(),m.Ptr1());
+        m.Complete(r,ETrue);
+        return;
+        }    
+    }</codeblock></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-26621CA5-B686-53FB-AF3E-96CDD38C8520.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,148 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-26621CA5-B686-53FB-AF3E-96CDD38C8520" xml:lang="en"><title> Physical
+RAM Defragmentation</title><shortdesc>Describes Symbian platform RAM defragmentation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Symbian platform physical RAM defragmentation is the process of moving
+physical pages, used to back virtual allocations, in order to create empty
+physical ranges. This enables the powering off of individual RAM banks or,
+if required, the allocation of a large contiguous buffer, for example, for
+a CCD image. This functionality allows a more efficient use of RAM in terms
+of both memory and power consumption. </p>
+<p> <note> Symbian platform RAM defragmentation is used to create large areas
+of contiguous RAM and/or allow the powering down of surplus RAM ICs: it does
+not locate and consolidate fragmented files and folders. This functionality
+enables more efficient use of physical RAM and may enable a lower Bill Of
+Materials (BOM), or increase battery life.</note> </p>
+<p>There are two interrelated use cases for defragmenting physical RAM: </p>
+<ul>
+<li id="GUID-51F2B5D3-78B2-5EA3-BEBD-6AB9F21D40BD"><p>many device drivers
+require physical RAM for use for buffers. For example, a camera driver may
+require a physically contiguous buffer for holding the output of the CCD.
+In releases 9.3 and before such memory was typically allocated at boot time.
+This practice increases initial RAM consumption after boot. Total RAM consumption
+can be reduced if memory for such buffers is only allocated as required, rather
+than at boot time. It is not possible to provide an absolute guarantee that
+the RAM will be available when needed, but it should succeed in all but exceptional
+cases. </p> </li>
+<li id="GUID-7865AD99-69C9-511D-9591-1F10A6A62827"><p>typically, memory consumption
+of a phone while idle is less than the total memory available. Idle and active
+power consumption can be decreased by powering down unused RAM chips or unused
+RAM banks within a RAM chip. This may also involve cooperation with a higher
+level component in the UI which can shut down unused applications to reclaim
+more memory. </p> </li>
+</ul>
+<section id="GUID-DD63E767-B31C-5311-A4A3-AA6A09B55622"><title>Defragmention
+of RAM</title> <p> <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita"><apiname>TRamDefragRequest</apiname></xref> is the class used
+by device drivers to perform all defragmentation operations. The three defragmentation
+operations provided are: </p> <ul>
+<li id="GUID-B8D5E8DA-2E7F-5F08-A86C-FEBB6EAA6011"><p> <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-B4825007-E3DB-3559-9D58-637150EF3DB9"><apiname>TRamDefragRequest::DefragRam()</apiname></xref> –
+Performs a general defragmentation. </p> </li>
+<li id="GUID-0F001B46-EDB2-551C-8D3D-A1FD51D782FF"><p> <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-8C2CB0BA-6596-3639-90F7-CFEF2D839DB1"><apiname>TRamDefragRequest::ClaimRamZone()</apiname></xref> –
+Attempts to claim a whole RAM zone. </p> </li>
+<li id="GUID-7E7E62DF-C7F4-5849-A88B-95D7F94F9C75"><p> <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-866259FA-F7D0-360B-AB5D-A1C170383713"><apiname>TRamDefragRequest::EmptyRamZone()</apiname></xref> –
+Removes allocated pages from a RAM zone. </p> </li>
+</ul> <p>There are three overloads for each of these <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita"><apiname>TRamDefragRequest</apiname></xref> defragmentation
+methods which behave differently: </p> <ul>
+<li id="GUID-88C45975-36FC-580F-883F-4429FCE0FFC8"><p>The first overload is
+synchronous and blocks the calling thread until the defragmentation is complete
+(or is cancelled using <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-2903D832-559C-3FE9-9F9F-317DBD28A7E7"><apiname>TRamDefragRequest::Cancel</apiname></xref>). In this
+case, the return value is the result of the defragmentation – an appropriate
+system-wide error code. </p> </li>
+<li id="GUID-5DEFF839-0303-5494-BBCC-04DA3EE8B517"><p>The second overload
+is asynchronous and takes a pointer to an <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita"><apiname>NFastSemaphore</apiname></xref>.
+The semaphore is signalled when the defragmentation is complete. The return
+value is <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref> unless there was a problem initializing
+the request, in which case an appropriate system-wide error code is returned.
+The result of the defragmentation can be obtained by calling <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-F3B3F56D-E4D4-3CF5-AE6A-F2607BB4022B"><apiname>TRamDefragRequest::Result()</apiname></xref> after
+the semaphore has been signalled. </p> </li>
+<li id="GUID-AF7C4053-9317-5B25-B8D9-4B97134969D2"><p>The third overload is
+asynchronous and takes a DFC. The DFC is queued when the defragmentation is
+complete. The return value is <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref> unless there was
+a problem initializing the request, in which case an appropriate system-wide
+error code is returned. The result of the defragmentation can be obtained
+by calling <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-F3B3F56D-E4D4-3CF5-AE6A-F2607BB4022B"><apiname>TRamDefragRequest::Result()</apiname></xref>. </p> </li>
+</ul> <p>All <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita"><apiname>TRamDefragRequest</apiname></xref> defragmentation operations
+are placed onto a FIFO queue. Any currently running defragmentation operation
+must complete or be cancelled before a new defragmentation operation can begin. </p> <p>All
+the <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita"><apiname>TRamDefragRequest</apiname></xref> defragmentation methods have the
+following parameter in common: </p> <p><b>aPriority </b> </p> <p> <xref href="GUID-80B69100-6D39-3987-B585-522576AA295B.dita"><apiname>aPriority</apiname></xref> specifies the priority
+of the thread that performs the defragmentation. If <codeph>aPriority</codeph> = <xref href="GUID-6A6931F2-FC2D-3F8C-8B30-0F17CDBBD2C5.dita"><apiname>KInheritPriority</apiname></xref>,
+the default, then the defragmentation thread will execute with the same priority
+as thread that invokes the defragmentation operation. </p> <p id="GUID-E514CE19-D643-5447-A3C1-84EDCF84B9C7"><b>Determining the result of
+a defragmentation operation</b> </p> <p>For synchronous overloads of the defragmentation
+methods the error code returned by the defragmentation method can be used
+to determine the result of the defragmentation operation. <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref> signifies
+that the defragmentation operation was successful. </p> <p>For asynchronous
+overloads of the defragmentation methods the result of the defragmentation
+operation is determined by invoking <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-F3B3F56D-E4D4-3CF5-AE6A-F2607BB4022B"><apiname>TRamDefragRequest::Result()</apiname></xref> after
+it has signalled that it has completed. Again, <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref> signifies
+that the defragmentation operation was successful. </p> <p id="GUID-19C6DCE9-739F-5085-92FF-626D74F332B1"><b>Cancelling a defragmentation
+operation</b> </p> <p>A defragmentation operation can be cancelled by invoking
+the <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-EA6C990F-F5B6-3EA6-97A3-F40AAB35351D"><apiname>TRamDefragRequest::Cancel()</apiname></xref> method. This method cancels
+the defragmentation, if it is in progress or is in the queue, and causes it
+to complete with <xref href="GUID-6F4A88DA-F54E-3848-9C32-942D6F5F4F3E.dita"><apiname>KErrCancel</apiname></xref>. If the defragmentation operation
+has already completed, this method has no effect and the result remains as
+it was. </p> </section>
+<section id="GUID-B4F8543F-538D-5B3A-8F5D-74ACFAAF852F"><title>General defragmentation</title> <p> <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-B4825007-E3DB-3559-9D58-637150EF3DB9"><apiname>TRamDefragRequest::DefragRam()</apiname></xref> initiates a general defragmentation. A general defragmentation attempts
+to arrange the currently allocated pages so that only the minimum number and
+the most preferable RAM zones required are powered and refreshed. Each time
+the general defragmentation successfully empties a RAM zone the base port
+invokes the RAM zone call back function with <codeph>aOp = </codeph> <xref href="GUID-74DA7B02-CB90-325D-8A84-454004AEB5C8.dita"><apiname>ERamZoneOp_PowerDown</apiname></xref> see <xref href="GUID-C376486D-B9BF-5D00-8B1A-1527FC1F83AD.dita#GUID-C376486D-B9BF-5D00-8B1A-1527FC1F83AD/GUID-A0273264-8876-523D-B1F0-F6D430FFAECA">RAM
+zone call back function</xref>. This informs the base port that it can decide
+to, not refresh or power down the empty RAM zone when it deems it to be appropriate. </p> <p>Depending
+on the current state of the system and the value of <codeph>aMaxPages</codeph>,
+a general defragmentation may require a significant amount of time to complete.
+Therefore, if a general defragmentation is performed too frequently the power
+saving benefits achieved by powering down or not refreshing RAM zones, may
+prove to be less than the power consumed while performing the general defragmentation.
+It is recommended that a general defragmentation is only performed once the
+device has been idle for a significant period of time. </p> <p><b>aMaxPages </b> </p> <p> <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-B4825007-E3DB-3559-9D58-637150EF3DB9"><apiname> TRamDefragRequest::DefragRam()</apiname></xref> is
+similar to the other defragmentation methods, except that it has an additional
+parameter <codeph>aMaxPages</codeph>. <codeph>aMaxPages</codeph> specifies
+a limit on the number of pages that can be moved during a general defragmentation
+when set to zero there is no limit. This can be useful in limiting the amount
+of processing a general defragmentation performs and therefore the power consumed
+by the general defragmentation. However, setting <codeph>aMaxPages</codeph> too
+low may prevent the general defragmentation from being able to empty a single
+RAM zone despite there being enough free pages in the most preferable RAM
+zones. </p> </section>
+<section id="GUID-0BEBEE41-A8DB-56F9-9FCE-E9301CC9864F"><title>RAM defragmentation
+of Physically contiguous allocations</title> <p>Some devices may define <xref href="GUID-C13DFF33-7C54-5113-9277-CAD96215F075.dita">RAM Zones</xref> for use
+by particular applications or hardware peripherals requiring a block of physically
+contiguous RAM. <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-8C2CB0BA-6596-3639-90F7-CFEF2D839DB1"><apiname>TRamDefragRequest::ClaimRamZone()</apiname></xref> is used
+by the device driver when it requires use of the pre-determined RAM zone to
+be used for the block of physically contiguous RAM. </p> <p> <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-8C2CB0BA-6596-3639-90F7-CFEF2D839DB1"><apiname> TRamDefragRequest::ClaimRamZone()</apiname></xref> is
+similar to the other defragmentation methods, except that it has two extra
+parameters: </p> <ul>
+<li id="GUID-25BF6436-C6F1-5495-B622-D68EE38764C5"><p> <codeph>aId</codeph> –
+the ID of the RAM zone to be claimed. </p> </li>
+<li id="GUID-B333AD9A-9DEB-5E54-8156-E2FB3587EA9F"><p> <codeph>aPhysAddr</codeph> –
+on successful completion of the claim operation this is loaded with the physical
+base address of the claimed RAM zone. </p> </li>
+</ul> <p>Once a RAM zone has been successfully claimed its memory can be used
+by the device driver after being mapped into a <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita">shared
+chunk</xref>. When the claimed RAM zone is no longer required, the device
+driver must use <xref href="GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680.dita#GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680/GUID-89B28752-7371-3EA8-B213-80F599691D7D"><apiname>Epoc::FreePhysicalRam</apiname></xref> to release it for
+use by the rest of the system. </p> </section>
+<section id="GUID-91358408-F617-5F0F-B88B-BE9F205AD5FB"><title>Zone specific
+allocations</title> <p>A device driver may attempt to allocate memory from
+a specific RAM zone using <xref href="GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680.dita#GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680/GUID-43DE887E-9CE0-397E-9AEF-42A051354AE3"><apiname>Epoc::ZoneAllocPhysicalRam()</apiname></xref>.
+If the allocation fails then use <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-866259FA-F7D0-360B-AB5D-A1C170383713"><apiname>TRamDefragRequest::EmptyRamZone()</apiname></xref> to
+remove as many pages as is reasonable from the RAM zone. </p> <p> <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-866259FA-F7D0-360B-AB5D-A1C170383713"><apiname> TRamDefragRequest::EmptyRamZone()</apiname></xref> is
+similar to the other defragmentation methods, as described in <xref href="GUID-26621CA5-B686-53FB-AF3E-96CDD38C8520.dita#GUID-26621CA5-B686-53FB-AF3E-96CDD38C8520/GUID-DD63E767-B31C-5311-A4A3-AA6A09B55622">Defragmention of RAM</xref>, except that it has an extra parameter: </p> <ul>
+<li id="GUID-9C78686E-3AE8-56C0-A7B2-EE2138930935"><p>aId – the ID of the
+RAM zone to be emptied. </p> </li>
+</ul> <p>Once the empty defragmentation operation has completed the RAM zone
+specific allocation can be attempted again. However, the RAM zone specific
+allocation may still fail in high RAM usage situations or if the RAM zone
+has too many fixed pages allocated. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-26714A57-B6B4-5E81-B512-FB520718482B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-26714A57-B6B4-5E81-B512-FB520718482B" xml:lang="en"><title>Debug Monitor
+Tool</title><shortdesc>Describes how to get basic information about the system state when
+problems occur on hardware to help you debug your software.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Device drivers are typically run and debugged on target hardware rather
+than on the Emulator. The tool that provides this information is called the <i>debug
+monitor</i> or the <i>crash debugger</i>. </p>
+<p>The debug monitor is used when the Kernel faults. This can happen because
+there is a fault in a kernel-side component, such as a device driver, or because
+a thread or process marked as system-critical crashes. </p>
+<p>Note that the debug monitor is one of the basic ways of debugging software
+problems on target hardware. Full interactive debugging on reference hardware
+and some real phones is available through commercial IDEs. </p>
+</conbody><related-links>
+<link href="GUID-B4259E9C-624F-5B73-8ADF-BAC9EDEF898C.dita#GUID-B4259E9C-624F-5B73-8ADF-BAC9EDEF898C/GUID-AC0567A7-D467-5F9C-8BFE-A5DC81D7AFF7">
+<linktext>H4 in the Debug   Monitor (or Why is the board flashing?)</linktext>
+</link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2700AAC8-A034-5E7D-B0E0-26B49E68BB18.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,73 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2700AAC8-A034-5E7D-B0E0-26B49E68BB18" xml:lang="en"><title>Personality Layer for Real Time Applications</title><shortdesc>A base port can add a software layer called a personality
+layer to the Kernel to provide an emulation of a real time operating
+system (RTOS)</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>. You can provide a personality layer so that a phone can run existing
+protocol stacks, for example, mobile telephony signalling stacks,
+or Bluetooth stacks, on the same CPU that runs the Symbian platform
+applications. </p>
+<p>Such protocol stacks, often referred to as Real Time Applications
+(RTA), almost always run on an RTOS, and the aim of the personality
+layer is to provide the same API as the RTOS, or at least as much
+of it as is required by the RTA. The RTA can then run, using the Kernel
+Architecture 2 Nanokernel layer as the underlying real time kernel. </p>
+<p>The following diagram illustrates the point simply. </p>
+<fig id="GUID-AA5502A3-37BE-5A73-A8D9-1B18DDCC8C96">
+<image href="GUID-058FAE44-DF72-53E2-BE62-EDC840A7C87F_d0e25110_href.png" placement="inline"/>
+</fig>
+<p>There is sample code at <filepath>...\e32\personality\...</filepath> that you should refer to while reading this. </p>
+<section id="GUID-D1217729-E0E4-5A02-A02F-524EA9F1D679"><title>RTOS
+environment features</title> <p>As a basis for emulating an RTOS,
+the RTOS is assumed to provide the following features: </p> <ul>
+<li id="GUID-107CEB20-80DA-5AF8-A116-C5FA5E437993"><p>Threads </p> </li>
+<li id="GUID-496701DC-E711-5509-B593-5B5A51A7DFC2"><p>Thread synchronisation/communication </p> </li>
+<li id="GUID-5ADDB09E-7528-50E0-8661-C64C91AF32CA"><p>Thread scheduling
+following a hardware interrupt </p> </li>
+<li id="GUID-4856FE5E-95E6-5455-B226-9314071F948E"><p>Timer management
+functionality </p> </li>
+<li id="GUID-C721F13B-14F9-5E01-9721-19E9475A421B"><p>Memory management. </p> </li>
+</ul> <p><b>Threads</b> </p> <p>Threads are independent units of execution,
+usually scheduled on a strict highest-priority-first basis. There
+are generally a fixed number of priorities. Round robin scheduling
+of equal priority threads may be available but is usually not used
+in real time applications. Dynamic creation and destruction of threads
+may or may not be possible. </p> <p><b>Thread synchronisation/communication</b> </p> <p>Typical examples
+of such thread synchronisation and communication mechanisms are semaphores,
+message queues and event flags. </p> <p>There is wide variation between
+systems as to which primitives are provided and what features they
+support. Again, dynamic creation and destruction of such synchronisation
+and communication objects may or may not be supported. Mutual exclusion
+protection is often achieved by simply disabling interrupts, or occasionally
+by disabling rescheduling. </p> <p><b>Thread scheduling following a hardware interrupt</b> </p> <p>This
+is usually achieved by allowing interrupt service routines (ISRs)
+to make system calls which perform operations such as signalling a
+semaphore, posting a message to a queue or setting event flags, which
+would cause a thread waiting on the semaphore, message queue or event
+flag to run. </p> <p>Some systems don't allow ISRs to perform these
+operations directly but require them to queue some kind of deferred
+function call. This is a function which runs at a lower priority than
+hardware interrupts (i.e. with interrupts enabled) but at a higher
+priority than any thread - for example a Nucleus Plus HISR. The deferred
+function call then performs the operation which causes thread rescheduling. </p> <p><b>Timer management functionality</b> </p> <p>A timer management
+function is usually also provided, allowing several software timers
+to be driven from a single hardware timer. On expiry, a software timer
+may call a supplied timer handler, post a message to a queue or set
+an event flag. </p> <p><b>Memory management</b> </p> <p>An RTOS often provides memory management,
+usually in the form of fixed size block management as that allows
+real time allocation and deallocation. Some RTOSs may also support
+full variable size block management. However most RTOSs do not support
+use of a hardware MMU and, even if the RTOS supports it (for example
+OSE does), the real time applications under consideration do not make
+use of such support since they are generally written to run on hardware
+without an MMU. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-28844FE0-AE0F-531C-826E-CDA8400A0581.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-28844FE0-AE0F-531C-826E-CDA8400A0581" xml:lang="en"><title>Sessions
+and Request Management</title><shortdesc>Describes how the MultiMediaCard Controller manages the sessions
+and sets the order of requests. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>When a number of drivers have a session with the MultiMediaCard Controller,
+the MultiMediaCard Controller can have many requests to service. </p>
+<section id="GUID-9A51615A-4C00-572F-9AF4-1ED9CBC358F3"><title>Session queues</title> <p>To
+handle sessions, the MultiMediaCard controller implements a scheduler. The
+MultiMediaCard stack has three internal queues: </p> <ul>
+<li id="GUID-0EB9FF38-2B49-5897-B663-352CEDAD8EF8"><p>an entry queue - this
+is the queue onto which a session is initially added when a client submits
+the session object by calling <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita#GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A/GUID-8DA6B49E-FED0-3E83-8D2F-EA7B61C28015"><apiname>DMMCSession::Engage()</apiname></xref> on
+it. This is anchored in the <codeph>DMMCStack::iEntryQueue</codeph> private
+member. </p> </li>
+<li id="GUID-21EF4132-1FA5-5FB2-9E9E-543DCD8AC8F7"><p>a ready queue - this
+is the queue into which a session is moved when it is ready to be handled;
+the scheduler moves all the sessions from the entry queue into the ready queue
+when it can. This is anchored in the <codeph>DMMCStack::iReadyQueue</codeph> private
+member. </p> </li>
+<li id="GUID-5C903A7D-0540-5F09-9F41-147A98A5B4B9"><p>a working set queue
+- this is the queue of sessions to be processed as chosen by the scheduler.
+This queue is limited to eight sessions. The scheduler moves a session from
+the ready queue to the working set queue if all current sessions in the working
+set queue are blocked and there are less than eight sessions in it. This is
+anchored in the <codeph>DMMCStack::iWorkSet</codeph> private member. </p> </li>
+</ul> <p>All three queues are circular queues as implemented using the internal
+Symbian platform class <codeph>TMMCSessionRing</codeph>. </p> <fig id="GUID-E8B1FA7F-1759-52BC-A9D8-80FF7E39FE51">
+<image href="GUID-B30D6027-EB0F-578F-9B2F-AFC2DFD27E39_d0e19057_href.png" placement="inline"/>
+</fig> </section>
+<section id="GUID-FF74AAF0-D1F6-59A7-A859-B73DF946C92F"><title>The scheduler</title> <p>Every
+time one of the following events occurs, the MultiMediaCard stack invokes
+its scheduler to deal with that event: </p> <ul>
+<li id="GUID-06C336CB-581E-59A3-96BA-D9C4BD43154E"><p>a client submitting
+a session to the MultiMediaCard controller </p> </li>
+<li id="GUID-FFA95B03-F68F-5B1A-8A36-2D8F0D490AD1"><p>a client aborting a
+session </p> </li>
+<li id="GUID-00D34161-C53E-5BED-9818-F0CCEED8FDF4"><p>a card interrupt occurring. </p> </li>
+</ul> <p>The stack invokes the scheduler by calling the internal function <codeph>DMMCStack::Scheduler()</codeph>. </p> </section>
+<section id="GUID-193EAA8E-32F0-4331-A137-39DB3A47623D"><title>Blocking a
+session</title><p>Sometimes, the MultiMediaCard controller has to perform
+its processing in a DFC context. In those cases the Controller postpones operation
+by queuing a DFC; the DFC call-back function then resumes the operation by
+invoking the scheduler again. This means that the scheduler may be running
+as part of a kernel executive call, a DFC or an interrupt service routine. </p> <p>In
+general, the MultiMediaCard controller processes a session in stages, issuing
+commands, checking responses, reading or writing data etc. Each stage is usually
+done asynchronously, first setting up the activity and then setting up a means
+of being notified when that activity is complete, for whatever reason (e.g.
+issuing a command and setting up an interrupt when a response has been received). </p> <p>If
+a session is waiting on an asynchronous operation, it is blocked. When one
+session is blocked, the stack tries to process another session which isn’t
+blocked. </p> <p>The blocking of sessions is set up and implemented internally
+to Symbian platform. However, the platform specific layer can block a session
+by calling the <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-E7B38752-F9AB-3A66-8FB6-E321717A63B5"><apiname>DMMCStack::BlockCurrentSession()</apiname></xref> function
+with the <xref href="GUID-8A9A2DD2-C630-3651-8374-17BCF2A09AC4.dita"><apiname>KMMCBlockOnASSPFunction</apiname></xref> bit set in the parameter
+passed to that function. </p> <p>Internally, the <codeph>DMMCSession::iBlockOn</codeph> private
+data member is set when a session is blocked. This is a bit-mask variable
+containing the reason that the session is blocked. </p></section>
+<section id="GUID-E0D63F8B-D4BC-48E5-8601-D1B0FCFB1644"><title>Scheduler algorithm</title><p>The
+following flow-diagram shows the algorithm used by the scheduler. </p> <fig id="GUID-78F3CD78-61F3-5DD8-8D0D-9D5251D11158">
+<image href="GUID-AA53650C-664C-53F0-8BE9-445677FC1FE2_d0e19130_href.png" placement="inline"/>
+</fig> <p>The <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita"><apiname>DMMCStack</apiname></xref> private members referenced in this
+diagram have the following meaning: </p> <table id="GUID-E1F971E8-949B-527B-B0EC-8D21BBB0EDE0">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>DMMCStack::iAbortReq</codeph> </p> </entry>
+<entry><p>Set to <xref href="GUID-781E8158-805B-3784-8FED-D7A191822FC3.dita"><apiname>ETrue</apiname></xref> when there are sessions on the stack
+that have been marked for abort by the client. This is set as a result of
+a call to <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita#GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A/GUID-84B74DDE-4D86-3D25-BDC6-CEF580E8C0FB"><apiname>DMMCSession::Abort()</apiname></xref>. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>DMMCStack::iAttention</codeph> </p> </entry>
+<entry><p>Set to <xref href="GUID-781E8158-805B-3784-8FED-D7A191822FC3.dita"><apiname>ETrue</apiname></xref> when there are sessions ready to
+run. This is set when a session is submitted to the stack as a result of a
+call to <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita#GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A/GUID-8DA6B49E-FED0-3E83-8D2F-EA7B61C28015"><apiname>DMMCSession::Engage()</apiname></xref>, or when a session becomes
+unblocked. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>DMMCStack::iCompReq</codeph> </p> </entry>
+<entry><p>Set to <xref href="GUID-781E8158-805B-3784-8FED-D7A191822FC3.dita"><apiname>ETrue</apiname></xref> when there are sessions on the stack
+ready to complete. This is set internally by the controller through calls
+to the private functions <codeph>DMMCStack::MarkComplete()</codeph> or <codeph>DMMCStack::CompleteAll()</codeph>. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>DMMCStack::iInitialise</codeph> </p> </entry>
+<entry><p>Set to <xref href="GUID-781E8158-805B-3784-8FED-D7A191822FC3.dita"><apiname>ETrue</apiname></xref> when stack initialization (CIM_INIT_STACK)
+has been forced. This is set when the controller needs to re-power the stack,
+and to power up a card on client requests. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-28F3F720-A2E0-59C9-8BB4-B6124CFC6C89-master.png has changed
Binary file Adaptation/GUID-28F3F720-A2E0-59C9-8BB4-B6124CFC6C89_d0e11050_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-29B84A67-9DB7-5F4C-A4D1-A3BDC69015A8.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,113 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-29B84A67-9DB7-5F4C-A4D1-A3BDC69015A8" xml:lang="en"><title>Additional
+System Wide Power States</title><shortdesc>A base port can add new power states to improve power management
+for phone hardware. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Kernel defines three system wide power states. A base port can add
+new power states to improve power management for phone hardware. </p>
+<p>The generic system wide power states that are defined are <i>Active</i>, <i>Standby</i> and <i>Off</i>.
+Any additional sub-states of the <i>Active</i> power state must be wholly
+managed by the base port. These states may not need to be declared explicitly
+and may result from peripherals, or groups of peripherals, having moved to
+their low power state (see also <xref href="GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC.dita#GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC/GUID-DCB8EA90-9B5F-5BA1-8D22-124980AC6B34">moving
+to their low power state</xref>). The device will then “trickle“ into one
+of these sub-states instead of transitioning into them as a result of a user
+action or system policy decision. </p>
+<p>Usually, the transition of the system into one of the additional low power
+states happens when the CPU enters the idle mode. The transition may be automatic
+and wholly managed by the ASSP hardware or may result from an action taken
+by the software routine that prepares the CPU to go to idle mode. </p>
+<section id="GUID-22A20CBB-6BF2-495F-B32C-63834DD4624C"><title>Sleeping in idle mode</title> <p>An example of this is when
+the base port uses the idle mode to put the CPU and the device into hardware
+“Sleep” mode similar to that which can be achieved with a transition to <i>Standby</i> mode
+as described in the implementation issues for <xref href="GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita#GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703/GUID-1F77C71C-D226-58BB-ABAE-43F958CC0C61">implementing
+DPowerController::PowerDown()</xref>  </p> <p>When called, the power controller’s <xref href="GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita#GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703/GUID-E2A072D0-A67F-5E6D-81ED-CFD77B6ED4F1">DPowerController::CpuIdle() </xref> implementation
+could take the necessary steps to prepare the CPU and the platform to go to
+“Sleep”. </p> <p>There is a balance between the power savings obtained from
+moving the CPU and platform into “Sleep” mode in Idle and the performance
+hit resulting from spending time restoring the status after coming out of
+“Sleep” mode. Usually the <codeph>CpuIdle()</codeph> routine investigates
+the timer queue (using <xref href="GUID-C54D99AA-FF6E-3023-8260-8F5A88FBFBE0.dita#GUID-C54D99AA-FF6E-3023-8260-8F5A88FBFBE0/GUID-69103F26-2C21-3ECA-9DB5-C31A41F6C238"><apiname>NTimerQ::IdleTime()</apiname></xref>) for the next
+timer expiration and decides to move or not to move the CPU and platform into
+“Sleep” mode based on how much time there is before the next timer expiration.
+The threshold above which it is considered productive to move into “Sleep”
+is dependent on the base port. </p> <p>The decision to move into “Sleep” mode
+may also be based on the current level of activity, or collected metrics on
+the length of time spent in Idle, or other historical information. This can
+be implemented entirely by the base port, or it may require the services of
+an external component (such as, for example, Speed Management). </p> <p>The
+transition to a hardware “Sleep” mode may also depend on shared peripherals
+being in a particular state, for example, no pending requests from other peripherals.
+This means that the power controller may need to check with the peripheral
+driver before initiating the change. The power controller could use the ASSP/Variant
+method to access the resource manager and check the usage of a shared peripheral
+using its <codeph>GetCount()</codeph> API. </p> <p>The decision to move into
+“Sleep” mode could be dependent on a number of peripherals (shared and not
+shared) being in Standby and a number of controllable power resources being
+turned off. Therefore the power controller may also need to check with the
+resource manager (through the Variant or ASSP) for the state of a specific
+set of controllable power resources (using the <codeph>ResourceManager::GetResourceState()</codeph> API). </p> <p>On
+going to “Sleep”, an action or set of actions might need to be taken that
+would affect the whole platform. An example of this is when DRAM is put into
+self-refresh mode on entering the CPU Idle mode after all peripherals that
+might access it (including the LCD controller and DSP) are in low power state.
+Unused DRAM banks may also be powered down. </p> <p>The following diagram
+exemplifies how the evolution of system power would look like on a system
+when the most power saving “Sleep” mode can only be reached – from Idle -
+when Peripherals A, B and C are already in their low power mode. On going
+to the most power saving “Sleep” mode, additional actions can be taken to
+lower the system power level: </p> <fig id="GUID-05ED7A51-E1A1-5D2E-AF81-A11A9EC80D7F">
+<title>System power use over time</title>
+<image href="GUID-BF157EE2-B680-554A-AE32-69C652B61FA6_d0e29926_href.png" placement="inline"/>
+</fig> <ul>
+<li id="GUID-FD4E14B6-9471-5A91-B215-E42595645A94"><p>The system is active
+when a request for service is made on peripheral A; the peripheral driver
+for peripheral A requests its transition to operational state increasing the
+system power requirement (a). </p> </li>
+<li id="GUID-FB7914E6-13BC-57C7-BA02-A7DAA3A4F968"><p>After a period of activity
+related to servicing the request, the system enters the idle thread; in <codeph>CpuIdle()</codeph> the
+time for the next timer expiration is investigated and is found to be long
+enough to send the system to sleep, powering down peripherals A, B and C to
+their low power state and other system resources (b). </p> </li>
+<li id="GUID-44F96E35-4DA5-5A34-8D12-6E99D4B96856"><p>The timer expires and
+the system wakes up to the same power level as before (c). </p> </li>
+<li id="GUID-61124A91-05C6-589D-884B-F4CE5FF9A970"><p>The inactivity timer
+implemented in the peripheral driver for peripheral A expires: the peripheral
+is transitioned to the low power state (d). </p> </li>
+<li id="GUID-1A1BF422-6C3A-5F90-BB8E-E84A31478723"><p>At (e) the system enters
+the idle thread again: the timer queue is investigated and then enters sleep
+mode, waking up again when an interrupt occurs (f). </p> </li>
+<li id="GUID-14C0126F-4333-5A96-93CE-7BBA17A422EF"><p>The inactivity timer
+associated with the peripheral drive for peripheral B expires and the peripheral
+is transitioned to its low power state (g). </p> </li>
+<li id="GUID-3CC1A70B-832A-53EC-BD04-9FA58F58F97D"><p>On the next call to <codeph>CpuIdle()</codeph> the
+time for the next timer expiration is not long enough to power off peripherals
+and other system resources: only limited power savings can be made (h) until
+the system wakes up again (i). </p> </li>
+<li id="GUID-FC9FE747-CF6D-501A-B36F-4776F53E5317"><p>Finally, the inactivity
+timer for peripheral C expires and the peripheral is transitioned to low power
+state (j). On reaching another period of system idle all conditions are met
+to send the system to the deepest sleep mode available accompanied by the
+switching off other power resources (k). </p> </li>
+<li id="GUID-6E283027-9516-50AA-94A7-BEA5C1A1E115"><p>On waking up (l) the
+system resources are restored to the same power level as before. </p> </li>
+</ul> <p>Any transition to and from these low power states must be transparent
+to the rest of the system. A transparent transition is one that can be instantly
+reversed, perhaps automatically in hardware, and has no noticeable impact
+on system performance. In other words, it should be possible to wake the processor
+up and move the entire device to Active Mode as if coming from a “normal”
+Idle Mode. </p> <p>To perform a system wide power change which is not transparent,
+peripherals that may be affected by the transition would need to be examined,
+and interfaces would have to be provided so that the users of these peripherals
+could query the peripheral and allow or disallow the system transition into
+that state. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2ADB873A-1580-476A-9642-AB47D13D4A98.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,102 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2ADB873A-1580-476A-9642-AB47D13D4A98" xml:lang="en"><title>Driver
+Source Files</title><shortdesc>This document details the directory structure and file types of
+logical device drivers and physical device drivers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-437190D1-9F2D-450E-A659-B2EDE09A98B6">       <title>Directory
+structure</title>       <p>Device driver DLLs come in two types - the logical
+device driver (LDD), and the physical device driver (PDD). Typically, a single
+LDD supports functionality common to a class of hardware devices, whereas
+a PDD supports a specific member of that class. </p> <p>In Symbian platform
+source code, PDDs are part of variant baseports, while LDDs are stored in
+a shared location that is not specific to a particular variant: </p> <ul>
+<li id="GUID-AA32E34F-DA8E-5093-B2F2-A05C6FF5878C"><p>PDD source files (<filepath>.cpp</filepath>, <filepath>.h</filepath> and <filepath>.mmp</filepath>) for peripherals for the H4 variant are in source directories named <filepath>base\omap_hrp\h4\</filepath> &lt;<i>driver_pdd</i> &gt;. </p> </li>
+<li id="GUID-59BCB89E-4DDA-5EC5-9CE7-766929578688"><p>PDD source files (<filepath>.cpp</filepath>, <filepath>.h</filepath> and <filepath>.mmp</filepath>) for peripherals for the Emulator variant are in source directories named <filepath>base\wins\</filepath> &lt;<i>driver_pdd</i> &gt;. </p> </li>
+<li id="GUID-E6C48B50-6ACA-58DE-A17A-159FECCC419E"><p>LDD source files are
+in source directories named <filepath>base\e32\</filepath> &lt;<i>driver</i> _<i>ldd</i> &gt;,
+which are shared for all variants. </p> </li>
+<li id="GUID-79EFD591-60E9-5949-B1DB-1E7F9BFEF94A"><p>Common test application
+source files are in source directories named <filepath>base\e32test\</filepath> &lt;<i>driver_test</i> &gt;. </p> </li>
+</ul> <p>For both types of driver, the source files are generally organised
+in the following sub-directories: </p> <ul>
+<li id="GUID-7C92DAB4-607D-5E28-B40E-CE6BE889F54D"><p>&lt;<i>driver</i> &gt;<filepath>\group</filepath> – <filepath>.mmp</filepath> files </p> </li>
+<li id="GUID-D4D7A72B-B45D-5142-9567-23D913AE09D1"><p>&lt;<i>driver</i> &gt;<filepath>\inc</filepath> – <filepath>.h</filepath> files </p> </li>
+<li id="GUID-5C955F3B-B490-5CB1-90EA-AB51F2B86ECD"><p>&lt;<i>driver</i> &gt;<filepath>\src</filepath> – <filepath>.cpp</filepath> files </p> </li>
+</ul>     </section>
+<section id="GUID-F0256258-9C68-4598-9848-54D1BE43C63D"><title>File extensions</title> <p>The
+project files of a device driver that is part of the Kernel code are similar
+to those for other components in Symbian platform. The following tables summarise
+the source and binary file types you will see: </p> <table id="GUID-0EFAD42A-E690-5143-93A8-29EC596B72B6">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Source File Type</b>  </p> </entry>
+<entry><p> <b>Description</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <filepath> .h</filepath>  </p> </entry>
+<entry><p>Include files </p> </entry>
+</row>
+<row>
+<entry><p> <filepath> .cpp</filepath>  </p> </entry>
+<entry><p>Source files </p> </entry>
+</row>
+<row>
+<entry><p> <filepath> .inl</filepath>  </p> </entry>
+<entry><p>Inline files </p> </entry>
+</row>
+<row>
+<entry><p> <filepath> .mmp</filepath>  </p> </entry>
+<entry><p>Project file, similar to a makefile in other operating systems </p> </entry>
+</row>
+<row>
+<entry><p> <filepath> .inf</filepath>  </p> </entry>
+<entry><p>Build file grouping multiple mmp files. Command line builds are
+done from this file's directory. </p> </entry>
+</row>
+<row>
+<entry><p> <filepath> .iby</filepath>  </p> </entry>
+<entry><p>ROM include file. This file specifies the built files that need
+to be included in a ROM image. This is not used in builds for the Emulator. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p> </p> <table id="GUID-23EBCA5D-F979-54D7-B3D8-75CB1BEFBC92">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Binary File Type</b>  </p> </entry>
+<entry><p> <b>Description</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <filepath> .ldd</filepath>  </p> </entry>
+<entry><p>Logical Device Driver target. A LDD contains code that is common
+to a class of hardware devices. </p> </entry>
+</row>
+<row>
+<entry><p> <filepath> .pdd</filepath>  </p> </entry>
+<entry><p>Physical Device Driver target. A PDD contains code that is specific
+to one particular type of device. </p> </entry>
+</row>
+<row>
+<entry><p> <filepath> .exe</filepath>  </p> </entry>
+<entry><p>Application executable target. </p> </entry>
+</row>
+<row>
+<entry><p> <filepath> .ext</filepath>  </p> </entry>
+<entry><p>Kernel extension target, a driver that is started when the kernel
+boots. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-2AE438CC-F2E4-5FCB-971F-CFFAE5EF81E4-master.png has changed
Binary file Adaptation/GUID-2AE438CC-F2E4-5FCB-971F-CFFAE5EF81E4_d0e93636_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2B7D04D9-98DE-5284-836D-01DB4FA8949D.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2B7D04D9-98DE-5284-836D-01DB4FA8949D" xml:lang="en"><title>Writable Data
+Paging</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Describes writable data paging and how to use it. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2BDDB4F8-3175-411B-A206-FAE27DEBF678.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2BDDB4F8-3175-411B-A206-FAE27DEBF678" xml:lang="en"><title>DMA Tools Guide</title><shortdesc>Tools used to debug the DMA implementation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>You implement DMA with the standard base porting tools (a compiler
+and hardware-specific debugger). There are no tools specifically required
+for DMA implementation.</p>
+</conbody><related-links>
+<link href="GUID-EDC1C30B-4078-4434-95AC-2E37AF809A51.dita"><linktext>DMA
+Implementation Overview</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2C1B74C4-C80D-5EF9-B822-2DA2FCF9B006.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2C1B74C4-C80D-5EF9-B822-2DA2FCF9B006" xml:lang="en"><title>General
+Macros</title><shortdesc>Describes macros that can be used in the platform-specific configuration
+header and in bootstrap code. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-B30AB815-54B8-48BB-9D3C-5607AF7B17C7"><title>INIT_LOGICAL_SYMBOL</title><codeblock id="GUID-CC5AE5B8-282D-59A9-9DD6-2D1D3A44944A" xml:space="preserve">INIT_LOGICAL_SYMBOL SYM, COUNT</codeblock><p>Checks if the symbol <codeph>SYM</codeph> is defined. If so, it sets it to
+a value which is logically TRUE and increments symbol <codeph>COUNT</codeph> by
+one; <codeph>COUNT</codeph> may be omitted if not required. </p><p>If the
+symbol <codeph>SYM</codeph> is not defined, then the macro defines it, and
+sets it to a logically <codeph>FALSE</codeph> value. </p> </section>
+<section id="GUID-5C119585-EA08-4981-AC57-47D38E3959DD"><title>INIT_NUMERIC_SYMBOL</title><codeblock id="GUID-A3603B75-AD74-5764-B822-8D91D21F5058" xml:space="preserve">INIT_NUMERIC_SYMBOL    SYM, DEFAULT</codeblock><p>Checks if the symbol <codeph>SYM</codeph> is defined. If so, its value
+is left unchanged. </p><p>If <codeph>SYM</codeph> is not defined, then the
+macro defines it as a numeric variable and sets its value to <codeph>DEFAULT</codeph>. </p> </section>
+<section id="GUID-09DF08C5-F1CC-4ADA-89AA-41EA99B0F084"><title>INIT_NUMERIC_CONSTANT</title><codeblock id="GUID-DA525C7F-ABAC-5121-B752-3E5C81BB29B9" xml:space="preserve">INIT_NUMERIC_CONSTANT    SYM, DEFAULT</codeblock><p>Checks if the symbol <codeph>SYM</codeph> is defined. If so, its value
+is left unchanged. </p><p>If <codeph>SYM</codeph> is not defined, then the
+macro defines it as a numeric constant and sets its value to <codeph>DEFAULT</codeph>. </p> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-2C312536-2410-42D7-B976-F7CF99492DEA-master.png has changed
Binary file Adaptation/GUID-2C312536-2410-42D7-B976-F7CF99492DEA_d0e344_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2C6B7D51-C201-453D-ABBA-C9EC6B3DBDB2.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE reference
+  PUBLIC "-//OASIS//DTD DITA Reference//EN" "reference.dtd">
+<reference id="GUID-2C6B7D51-C201-453D-ABBA-C9EC6B3DBDB2" xml:lang="en"><title>Client Interface</title><shortdesc>The boundary between the generic implementation and any
+part of the OS that uses the client interface. </shortdesc><prolog><metadata><keywords/></metadata></prolog><refbody>
+<section id="GUID-06638575-C184-44CD-9039-AA5792A5E724"> 			 		</section>
+</refbody></reference>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2C915A03-AD8C-5924-87BB-953AE323E0FA.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2C915A03-AD8C-5924-87BB-953AE323E0FA" xml:lang="en"><title>Set
+Up</title><shortdesc>Describes how to use the template port to start your port. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The template port digitizer code can be found in <filepath>...\template\template_variant\specific\xyin.cpp</filepath>. </p>
+<p>The template <filepath>.mmp</filepath> file can be found in <filepath>...\template\template_variant\exxytemplate.mmp</filepath>. </p>
+<p>Following the general pattern, your implementation will be contained in
+the directory: <filepath>&lt;path to your variant&gt;\specific</filepath>. Create
+a copy of the template port implementation file <filepath>xyin.cpp</filepath> and
+copy it into your variant specific directory. </p>
+<p>Rename the class <codeph>DTemplateDigitiser</codeph> to reflect the name
+of your device. You should also be prepared to add your own private data and
+functions into it. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2D8B8FF1-7A35-5E98-BDDB-2B0BD8DE6215.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2D8B8FF1-7A35-5E98-BDDB-2B0BD8DE6215" xml:lang="en"><title>Writable Data
+Paging Tutorial</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Contains the guides that describe various aspects of writable data paging
+in more detail. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8" xml:lang="en"><title>User-Side Hardware Abstraction</title><shortdesc>The User-Side Hardware Abstraction (HAL) component provides a simple
+interface for programs to read and set hardware-specific settings, for example,
+the display contrast. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>A base port must define the attributes that clients can use on a phone,
+and implement any functions that are required to get and set the attributes.</p>
+<p id="GUID-4DA41221-40B9-5BC7-B2C6-7C6EB4522508"> To define attributes, you
+must change the source of the <filepath>hal.dll</filepath> library and rebuild
+it. Functions that get and set attributes are implemented as HAL handler functions
+in kernel-side programs, for example, device drivers. </p>
+</conbody><related-links>
+<link href="GUID-8C22AF20-EE0E-5AD2-BEFD-FED5A7DBB09B.dita"><linktext>LCD   Extension</linktext>
+</link>
+<link href="GUID-54042C84-6216-5930-9CBF-BAF635CECD4D.dita"><linktext>Power HAL
+  Handler</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-2D98DB88-BA48-5EF8-A5F9-0CB8688B0B63-master.png has changed
Binary file Adaptation/GUID-2D98DB88-BA48-5EF8-A5F9-0CB8688B0B63_d0e32099_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2E402D4E-53A9-5BA6-9FBD-B2713DBC7858.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,101 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2E402D4E-53A9-5BA6-9FBD-B2713DBC7858" xml:lang="en"><title>Peripheral
+Power Domains</title><shortdesc>A peripheral power domain can be defined as being a peripheral,
+or group of peripherals, whose power supply can be controlled independently
+from the rest of the device, but not independently from other peripherals
+within the same power domain. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Power domains depend on the physical wiring of a device, and this must
+be taken into account by the base port. They are usually manipulated when
+peripherals or groups of peripherals transition between the <i>Operational
+Power</i> and <i>Off</i> states. </p>
+<p>The following diagram is an example of such an arrangement. </p>
+<fig id="GUID-A9CA379B-F3B9-550C-9BDC-C072BFCA642D">
+<title>Example of peripheral power domains</title>
+<image href="GUID-A568F9D3-58E3-58D6-8A6E-4EC6BEC41A4D_d0e29723_href.png" placement="inline"/>
+</fig>
+<p>To reduce power leakage, it may be useful to cut the power supply to an
+area or a group of peripherals in the ASIC or the hardware platform, when
+all peripherals on that peripheral power domain have moved to the <i>Off</i> state. </p>
+<p>In the arrangement shown here, when all peripherals on a power domain have
+been powered down, the power supply to that domain can be cut off, using the
+RESn signal. </p>
+<p>A suggested implementation would have peripheral power domains modelled
+by a <xref href="GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A.dita"><apiname>MPowerInput</apiname></xref> reference counted object, and controlled
+using the <xref href="GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A.dita#GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A/GUID-2BCA5312-43D9-3763-9636-3B2EB046D2C1"><apiname>MPowerInput::Use()</apiname></xref> and <xref href="GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A.dita#GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A/GUID-606ECD77-A5F7-3408-9B63-C68C0A7B73C6"><apiname>MPowerInput::Release()</apiname></xref> interfaces
+that would enable the domain on request. The peripheral driver’s request on
+that power resource would only be changed when entering the <i>Operational
+Power</i> state from the <i>Off</i> state, or when entering or exiting the <i>Off</i> states.
+In other words, a peripheral power domain should only be turned off when all
+peripherals in that domain have transitioned to their <i>Off</i> state. </p>
+<p>This is a suggested definition for a peripheral power domain class. </p>
+<codeblock id="GUID-49E76C4B-F162-5735-8499-3198071111CD" xml:space="preserve">class PeripheralPowerDomain : public MPowerInput
+    {
+public:
+    void InitPowerDomain();        // (optional) handles any initialisation
+    void Use();                    // implementation of pure virtual
+    void Release()                // implementation of pure virtual
+    TUint GetCount();
+private:
+    TInt TurnSupplyOn();        // re-establishes power supply to this domain (asynch)
+    TInt TurnSupplyOff();        // cuts power supply to this domain 
+    };
+      </codeblock>
+<p>The <codeph>Use()</codeph> and <codeph>Release()</codeph> functions implement
+a usage count. Peripheral drivers for peripherals on that domain will call
+these functions whenever their power handler’s <codeph>PowerUp()</codeph> and <codeph>PowerDown()</codeph> member
+functions are called, respectively. If the usage count is 0 and <codeph>Use()</codeph> is
+called, it should call <codeph>TurnSupplyOn()</codeph>. If <codeph>Release()</codeph> is
+called and the usage count is decremented to 0, <codeph>TurnSupplyOff()</codeph> is
+called. </p>
+<p>Often, re-establishing the power supply to a power domain is a lengthy
+operation and should be modelled by an asynchronous operation. In that case <codeph>TurnSupplyOn()</codeph> should
+be able to sleep the thread in which this function is called until the power
+supply is stable. </p>
+<p>We recommend that peripheral power domains are defined as part of, and
+accessed through, a resource manager object as suggested in the discussion
+of <xref href="GUID-3B6544CD-FA6E-5AB2-AA63-61186F52167D.dita">Controllable Power
+Resources</xref>. Extending the original <xref href="GUID-3B6544CD-FA6E-5AB2-AA63-61186F52167D.dita#GUID-3B6544CD-FA6E-5AB2-AA63-61186F52167D/GUID-37A4098A-5E44-5744-BCE1-CDC8B876E654">A
+suggested implementation of a resource manager</xref> would give us: </p>
+<codeblock id="GUID-F4D57698-C77F-5CD0-BF7B-FCBECD96F64F" xml:space="preserve">class ResourceManager
+    {
+public:    
+    void InitResources();                        // called by your Asic::Init3()/Asic::Init1()
+    void Modify(TUint aSetMask, TUint aClrMask); // only 32 simple Resources can be managed
+    TBool GetResourceState(TUint aResBitMask);   // only 1 bit set on this mask, returns On/Off
+public:
+    (MPowerInput-derived) iSharedResource1;      // 1 per shared resource
+    (MPowerInput-derived) iSharedResource2;
+    ...
+    PeripheralPowerDomain iPeripheralPowerDomain1;
+    PeripheralPowerDomain iPeripheralPowerDomain2;
+    PeripheralPowerDomain iPeripheralPowerDomain3;
+    ...
+    };
+      </codeblock>
+<p>where <codeph>InitResources()</codeph> could call each <codeph>PeripheralPowerDomain::InitPowerDomain()</codeph>. </p>
+<p>Peripheral power domains may also be a useful concept when transitioning
+peripherals to low power mode after peripheral inactivity detection. It is
+only after all peripherals on a peripheral power domain have requested moving
+the resource to the level corresponding to low power that the resource level
+can be changed. This is exemplified again in the block diagram above: when
+all peripherals in a domain have requested transitioning to low power (using
+a <codeph>ReleaseToLevel()</codeph> -type call) the power supply level to
+that power domain can be set to VLowPwr. </p>
+<p>The following base port software architecture diagram could be used to
+address control of the peripheral power domains shown in the hardware block
+diagram above: </p>
+<fig id="GUID-2C8E6AF1-D82A-5539-96C3-921D9B3E2846">
+<title>Base port software architecture diagram</title>
+<image href="GUID-C3CE35FF-240E-5385-9088-38EF926ABB7B_d0e29836_href.png" placement="inline"/>
+</fig>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2E42E7EA-FED8-522C-8A5F-F65D799476C9.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,131 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2E42E7EA-FED8-522C-8A5F-F65D799476C9" xml:lang="en"><title>Keyboard Driver Implementation Tutorial</title><shortdesc>This topic describes how to implement an interrupt driven
+keyboard driver. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The steps are: </p>
+<ul>
+<li id="GUID-BC3A7259-A750-5D5F-8363-6F8BBC03E8EB"><p>Implement the
+driver entry point function and initialisation code. This function
+is called when the extension is loaded. </p> <p>The initialisation
+code binds the hardware interrupt to the Interrupt Service Routine
+(ISR) and enables the interrupt. </p> </li>
+<li id="GUID-3A050F21-FE10-5C0F-8BFE-C44692C0BDE2"><p>Implement an
+ISR to handle key events. The ISR queues a keyboard DFC. </p> </li>
+<li id="GUID-6580FC61-3D9E-5370-88AD-50CC1FB28E5F"><p>Implement a
+keyboard DFC. This function interrogates the keyboard, converts the
+scancode to a keypress event, and places it onto the kernel's event
+queue. </p> </li>
+</ul>
+<section id="GUID-B4B6A6C6-39D0-49FC-A630-1979368056B0"><title>Set
+Up</title> <p>In the template reference board port, the <filepath>.mmp</filepath> file for the keyboard driver is <filepath>...\template_variant\exkey_inttemplate.mmp</filepath>. This is one of the PRJ_MMPFILES referenced in the template variant's <filepath>bld.inf</filepath> file in the <filepath>...\template_variant\...</filepath> directory, and means that the keyboard driver is built as part of
+the Variant. </p> <p>The source for the driver is contained entirely
+within <filepath>...\template_variant\specific\keyboard_interrupt.cpp</filepath>. </p> <p>The driver is defined as a kernel extension and is loaded
+early in the boot sequence. </p> </section>
+<section id="GUID-547A2791-82D8-4C86-86E6-B4B9CEF04E3B"><title>Entry
+point implementation</title> <p>The driver functionality is encapsulated
+by the <codeph>DKeyboardTemplate</codeph> class, and an instance of
+this is created when the extension is loaded. </p> <p>As the driver
+is a kernel extension, it must have a <codeph>DECLARE_STANDARD_EXTENSION()</codeph> statement. In the template port, this is implemented: </p> <codeblock id="GUID-69F707CF-642D-5D03-AC78-4914549C4413" xml:space="preserve">DECLARE_STANDARD_EXTENSION()
+    {
+    __KTRACE_OPT(KEXTENSION,Kern::Printf("Starting keyboard driver"));
+
+    // create keyboard driver
+    TInt r=KErrNoMemory;
+    DKeyboardTemplate* pK=new DKeyboardTemplate;
+    if (pK)
+        r=pK-&gt;Create();
+
+    __KTRACE_OPT(KEXTENSION,Kern::Printf("Returns %d",r));
+    return r;
+    }
+
+</codeblock> <p>It simply creates an instance of the <codeph>DKeyboardTemplate</codeph> class and then performs a second-phase initialisation, which is
+a common pattern in Symbian platform and third party applications. </p> <p><b>Initialisation on construction</b> </p> <p>The constructor
+of the <codeph>DKeyboardTemplate</codeph> class has the following
+signature: </p> <codeblock id="GUID-5D247843-FF8C-5157-8BE5-53B5883F00B2" xml:space="preserve">DKeyboardTemplate::DKeyboardTemplate()
+    :    DPowerHandler(KLitKeyboard), 
+        iMsgQ(rxMsg,this,NULL,1),
+        iPowerUpDfc(PowerUpDfcFn,this,6),
+        iPowerDownDfc(PowerDownDfcFn,this,7),
+        iEventDfc(EventDfcFn,this,1)
+    {
+    }
+
+</codeblock> <p>See also <xref href="GUID-3C34724F-B476-5329-B0B1-6D5A34294979.dita">Interrupt Dispatcher
+Tutorial</xref>. </p> </section>
+<section id="GUID-F11265AA-D280-4B4E-92DA-38F12E7D5E30"><title> Interrupt
+Service Routine (ISR) implementation</title> <p>The ISR (Interrupt
+Service Routine) just schedules the DFC that handles the keypress.
+It can also optionally contribute the timing of key interrupts as
+a source of random data for the Random Number Generator (see <xref href="GUID-8290AAF0-577C-51D2-8AC1-0D37A10F45CB.dita">CSPRNG Implementation
+in Kernel</xref>). On the template reference board, this is implemented
+as: </p> <codeblock id="GUID-866CEA65-78AC-5A2C-AF08-29DF8FE53DD5" xml:space="preserve">void DKeyboardTemplate::Isr(TAny* aPtr)
+	{
+	Interrupt::Disable(KIntIdKeyboard);
+	
+	// Add the timing of key interrupts as entropy data for the RNG
+	Interrupt::AddTimingEntropy();
+	
+	k.iEventDfc.Add();
+	}
+</codeblock> <p>The ISR disables the keyboard interrupt, as repeated
+ISRs are not allowed to queue further DFC routines. </p> </section>
+<section id="GUID-E53E0FE1-3100-4B8B-BE90-250C1BDDE15C"><title>DFC
+function implementation</title> <p>The DFC is the function <codeph>DKeyboardTemplate::EventDfcFn</codeph> which is implemented as a
+call to <codeph>DKeyboardTemplate::EventDfc()</codeph>. </p> <codeblock id="GUID-2A1B334A-441E-57C3-B40C-603D992F934F" xml:space="preserve">void DKeyboardTemplate::EventDfcFn(TAny* aPtr)
+    {
+    ((DKeyboardTemplate*)aPtr)-&gt;EventDfc();
+    }
+
+void DKeyboardTemplate::EventDfc()
+    {
+    __KTRACE_OPT(KHARDWARE,Kern::Printf("DKeyboardTemplate::EventDfc"));
+
+    TInt irq=NKern::DisableAllInterrupts();
+    while (IsKeyReady())                        // while there are keys in the controller's output buffer
+        {
+        NKern::RestoreInterrupts(irq);
+        TRawEvent e;
+        TUint keyCode=GetKeyCode();                // Read keycodes from controller
+        __KTRACE_OPT(KHARDWARE,Kern::Printf("#%02x",keyCode));
+
+        //
+        // TO DO: (mandatory)
+        //
+        // Convert from hardware scancode to EPOC scancode and send the scancode as an event (key pressed or released)
+        // as per below EXAMPLE ONLY:
+        //
+        TUint bareCode=keyCode&amp;~KFlagKeyPressed;
+        TUint8 stdKey=convertCode[bareCode];
+        if (keyCode&amp;KFlagKeyPressed)
+            e.Set(TRawEvent::EKeyUp,stdKey,0);
+        else
+            e.Set(TRawEvent::EKeyDown,stdKey,0);
+        Kern::AddEvent(e);
+        NKern::Sleep(1);                        // pause before reading more keycodes
+        irq=NKern::DisableAllInterrupts();
+        }
+    Interrupt::Enable(KIntIdKeyboard);
+    NKern::RestoreInterrupts(irq);
+    }</codeblock> <p>This: </p> <ul>
+<li id="GUID-8A202894-34F8-5E7B-B791-20D4B6C8B914"><p>reads the scan
+code data by calling <codeph>DKeyboardTemplate::GetKeyCode()</codeph>  </p> </li>
+<li id="GUID-D553B662-F60C-575F-893D-347A9344F9B9"><p>re-enables the
+keyboard interrupt, now that the DFC has freed up the input data register </p> </li>
+<li id="GUID-BFC75E95-A9AE-584E-8A17-CCAF9C2F5913"><p>translates the
+keypress event into a Symbian scancode </p> </li>
+<li id="GUID-20BC22AF-C58C-56DC-B777-B5C8681668D6"><p>puts the translated
+event on to the event queue. </p> </li>
+</ul> </section>
+<section id="GUID-437735D9-916C-4308-913C-3839CC7F0002"><title>See
+also</title> <p> <xref href="GUID-EB76FAF8-CD4B-5CB6-9F23-C852ED91866F.dita">Concepts</xref>  </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2E4F8732-F253-5E0D-9A37-9476541E6004.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,83 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2E4F8732-F253-5E0D-9A37-9476541E6004" xml:lang="en"><title>Platform-Specific
+Configuration Header</title><shortdesc>Describes how to write the file providing build-time configuration
+options.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The platform-specific configuration header is a file that provides the
+configuration options that must be known at build time. </p>
+<p>The configuration header is an include file written in assembler, and is
+named <filepath>config.inc</filepath>. </p>
+<p>Use the configuration header file in the Template port in <filepath>os/kernelhwsrv/bsptemplate/asspandvariant/template_variant/config.inc</filepath> as the basis of your own configuration header file. </p>
+<p>The file consists of a number of global logical symbol definitions (<codeph>GBLL</codeph> statements),
+including the following: </p>
+<ul>
+<li id="GUID-79707935-D1DD-5221-B77E-7F26AE27ADD0"><p>symbols that define
+the CPU, listed below </p> </li>
+<li id="GUID-AAD39A6F-256C-5904-8869-B90005A550E7"><p>a number of less commonly
+used macros and symbols, which are documented in the template configuration
+header file </p> </li>
+<li id="GUID-DC757D0B-5F4A-5C3C-AF23-D8F1893DEBF3"><p>a set of general bootstrap
+macros described in the <xref href="GUID-20F8DA2A-9157-54C5-97D0-4CCA50AB0631.dita">Reference</xref> section,
+including the macros that define the presence of Level 2 cache (L210 cache
+and L220 cache). </p> </li>
+</ul>
+<section id="GUID-2B3B9AA4-317C-5D83-8635-B64CBFD9B180"><title>CPU
+symbols</title><p>The CPU that the bootstrap runs on is indicated by defining <i>one</i> of
+the following symbols: </p><ul>
+<li id="GUID-23065718-F6B8-5882-A51A-8E6BE234B1CE"><p> <codeph>CFG_CPU_ARM710T</codeph></p></li>
+<li id="GUID-004CBA53-105B-52B9-92FD-C96076853126"><p> <codeph>CFG_CPU_ARM720T</codeph></p> </li>
+<li id="GUID-43DC423C-1FFB-59A9-9DEA-37BFEEBD102E"><p> <codeph>CFG_CPU_SA1</codeph></p></li>
+<li id="GUID-4B3C55D3-5D61-52F7-A6E1-007BD9AF4F2A"><p> <codeph>CFG_CPU_ARM920T</codeph></p> </li>
+<li id="GUID-16EC89F4-93A0-5838-B287-E275644F454F"><p> <codeph>CFG_CPU_ARM925T</codeph></p></li>
+<li id="GUID-B74887BE-55E8-5B15-B4F0-456174B76E4A"><p> <codeph>CFG_CPU_ARM926J</codeph></p></li>
+<li id="GUID-AD501BE6-E722-593C-8B37-BDD7187CB023"><p> <codeph>CFG_CPU_XSCALE</codeph></p></li>
+<li id="GUID-36BBE46F-0D2E-54B8-B306-88FDEAD029F6"><p> <codeph>CFG_CPU_ARM1136</codeph></p></li>
+<li id="GUID-6FDF00B0-4685-57D0-9619-E8663C7F3CAC"><p> <codeph>CFG_CPU_GENERIC_ARM4</codeph></p></li>
+</ul> <p>Note that <codeph>CFG_CPU_GENERIC_ARM4</codeph> refers to an ARM
+architecture 4, or later device, with no MMU. </p> <p>The template file contains
+all these symbol definitions; just move the comment symbol (<codeph>;</codeph>)
+as appropriate for your platform. </p> </section>
+<section id="GUID-CA93F9E2-B48F-4A25-9A72-60F994579E26"><title>Other symbols</title><table id="GUID-65CE2BC3-A0EB-5D10-A5FA-5DDF7FC16C86">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>CFG_DebugBootRom</codeph>  </p> </entry>
+<entry><p>Define this symbol to enable debug tracing in the bootstrap. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>CFG_BootLoader</codeph>  </p> </entry>
+<entry><p>Define this symbol if the bootstrap is a bootloader. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-C1E1FB5B-C3AB-4B0A-BBED-B51C3DD12F7E"><title>Derived
+symbols</title> <p>A number of commonly used symbols are derived from the
+supplied configuration options, and may be used in your code. </p> <p>Precisely <i>one</i> of
+the following three logical symbols is true, indicating the memory model in
+use: </p> <ul>
+<li id="GUID-87BF8EC3-CCBE-5BB8-85AB-074F246FF59A"><p> <codeph>CFG_MMDirect</codeph>  </p> </li>
+<li id="GUID-3B5EF71B-1938-5DB7-AE23-E485CDC15BA7"><p> <codeph>CFG_MMMoving</codeph>  </p> </li>
+<li id="GUID-C09F2227-966E-5324-9A56-0D2996D60B83"><p> <codeph>CFG_MMMultiple</codeph>  </p> </li>
+</ul> <p>The following logical symbols are true or false depending on whether
+the CPU in use has the corresponding property. The property represented by
+the symbol is given by the symbol name. </p> <ul>
+<li id="GUID-5502D0E2-E2CF-57D4-8B08-C56E1B75ECE2"><p> <codeph>CFG_ARMV6</codeph>  </p> </li>
+<li id="GUID-AFAAF34C-BAF0-56D2-90FD-463DEA31C1C8"><p> <codeph>CFG_MMUPresent</codeph>  </p> </li>
+<li id="GUID-5B162135-6F71-52DF-AC5E-14419A960916"><p> <codeph>CFG_CachePresent</codeph>  </p> </li>
+<li id="GUID-399918E2-D9C9-5860-B765-92890BC025C0"><p> <codeph>CFG_WriteBufferPresent</codeph>  </p> </li>
+<li id="GUID-2520D9C2-2FDF-5D8A-8CCC-C8226F3B4CA6"><p> <codeph>CFG_SplitCache</codeph>  </p> </li>
+<li id="GUID-042ED020-22D0-5BC1-8C6C-94B484348110"><p> <codeph>CFG_SplitTLB</codeph>  </p> </li>
+<li id="GUID-B77CC0D9-02AA-59A7-BAD9-9AA57BEC81FB"><p> <codeph>CFG_AltDCachePresent</codeph>  </p> </li>
+<li id="GUID-CD2E1CDC-0503-548E-BC3A-637354581BFB"><p> <codeph>CFG_WriteBackCache</codeph>  </p> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2E54DA7D-1094-41C6-AFB0-9999471991F8.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,430 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2E54DA7D-1094-41C6-AFB0-9999471991F8" xml:lang="en"><title>Interrupt Implementation Guide</title><shortdesc>Describes how to implement the Interrupt class.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-514E76B0-009C-48D4-935C-FBE48FDD3631-GENID-1-2-1-10-1-5-1-7-1-1-9-1-4-1-3-1"><title>Introduction</title>             <p>Interrupt handling is implemented by writing platform
+specific versions of the structures and functions of the Interrupt
+class. The details of the implementation depend on hardware and the
+architecture of the device. This document describes a simple implementation
+of the structures and functions and then discusses more elaborate
+strategies required with the use of device specific interrupts , chained
+interrupts and multiple interrupt sources. It also covers implementation
+on unicore platforms only. The SMP version of the  kernel now implements
+support for the ARM Generic Interrupt Controller and relies on its
+use.</p><ul>
+<li><p>Chained interrupts are interrupts which are output by one controller
+and input to another. They need to be distinguished in the ISR table
+and require extensions to the handler functions.</p></li>
+<li><p>Multiple interrupt sources to the same ISR require the use
+of pseudo-interrupts.</p></li>
+<li><p>When a Symbian port is split into an ASSP and variant (common
+and device specific) layer, the variant may include additional interrupt
+sources. Their API is defined by the port. Device specific interrupts
+are sometimes used to handle interrupts from peripherals: another
+technique is to route peripheral interrupts to a GPIO pin. Peripheral
+interrupts cannot be specified as part of the ASSP layer.</p></li>
+</ul><p>The Template Baseport provides a skeleton implementation for
+developers to modify at <filepath>kernelhwsrv/bsptemplate/asspandvariant/template_assp/interrupts.cpp</filepath>.</p>         </section>
+<section id="GUID-35383FC7-4099-4048-B4B8-F84D10259036"><title>The
+ISR table</title><p>The ISR table is a data structure which pairs
+each ISR with the interrupt source to which it will be bound. It must
+have enough space for each interrupt source on the device. It is implemented
+as an array of <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-B864263D-7682-3938-9180-030C3D123174"><apiname>Interrupt::SInterruptHander</apiname></xref> of size <xref href="GUID-2A04B9AF-92F3-3A5C-93AD-3DD52E20A6D3.dita"><apiname>KINterruptSourceCount</apiname></xref> in which the interrupt Id is used
+as an index to the table. This example code assumes a size of 32.</p><codeblock xml:space="preserve">...
+const TInt KInterruptSourceCount = 32;
+SInterruptHandler IsrHandlers[KInterruptSourceCount];
+...</codeblock></section>
+<section id="GUID-393C43D1-6A48-473F-AE6F-E3E6F474762B"><title>DisableAndClearAll()</title><p>Interrupts must be disabled and cleared with a call to <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-3486EC50-55C5-366B-8BE2-E1180F52AB05"><apiname>Interrupt::DisableAndClearAll()</apiname></xref> before the call to <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-41FEFEA2-27C8-33F3-8781-89C092AE41B6"><apiname>Interrupt::Init1()</apiname></xref> at the start of initialization. Implementation
+of this function is entirely hardware dependent.</p></section>
+<section id="GUID-7CD1BE2F-CDDC-46DC-95CE-4ADF909F0494"><title>Init1()</title><p>The kernel is initialized in phases, interrupts being involved
+in the first phase and sometimes the third. The Init1() function should
+be implemented to</p><ul>
+<li><p>Initialize the ISR table, binding all ISRs to the spurious
+interrupts handler.</p></li>
+<li><p>Register the dispatcher functions.</p></li>
+<li><p>Bind ISRs which handle chained or pseudo interrupts.</p></li>
+</ul><p>Interrupts must be disabled during first phase initialization.</p><p>This example code illustrates initialization of the ISR table.</p><codeblock xml:space="preserve">...
+const TInt KInterruptSourceCount = 32;
+SInterruptHandler IsrHandlers[KInterruptSourceCount];
+...
+
+for( TInt i = 0; i &lt; KInterruptSourceCount; ++i )
+    {
+    IsrHandlers[i].iIsr = SpuriousHandler;
+    IsrHandlers[i].iPtr = (TAny*)i;
+    }</codeblock><p>This example code illustrates an implementation
+of <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-41FEFEA2-27C8-33F3-8781-89C092AE41B6"><apiname>Interrupt::Init1()</apiname></xref> after the point at which
+the ISR table has been initialized.</p><codeblock xml:space="preserve">void TemplateInterrupt::Init1()
+    {
+     //
+     // need to hook the ARM IRQ and FIQ handlers as early as possible
+     // and disable and clear all interrupt sources
+     //
+     ... 
+     DisableAndClearAll();
+     Arm::SetIrqHandler((TLinAddr)TemplateInterrupt::IrqDispatch);
+     Arm::SetFiqHandler((TLinAddr)TemplateInterrupt::FiqDispatch);
+    }
+</codeblock></section>
+<section id="GUID-3FCBCFFC-C3E6-4439-86A4-4845B21CF3CF"><title>Init3()</title><p>Third phase initialization involves initializing various interrupt
+handlers and sources which can only be initialized when the kernel
+is fully functional. This is done with a call to <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-D77022E6-FA45-3C00-95A3-B62792359997"><apiname>Interrupt::Init3()</apiname></xref>.</p><p>It is important to remember that interrupts are enabled during
+third phase initialization.</p></section>
+<section id="GUID-C4CD4CA8-175B-4995-8DC3-7D7F7D62E3FB"><title>Spurious()</title><p>Interrupts not bound to a real ISR must be bound to a 'spurious'
+handler function <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-701CE497-EF6D-3557-8558-5C9354C1039B"><apiname>Interrupt::Spurious()</apiname></xref> which returns
+an error with the number of the interrupt.</p></section>
+<section id="GUID-D5367FEE-AC77-4317-B0CA-A8F0690AACD1"><title>Bind()</title><p>The <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-4E3CB472-3525-32F8-9BC4-8ECFEE931E7B"><apiname>Interrupt::Bind()</apiname></xref> function binds ISRs to
+interrupt sources.</p><p>The argument <codeph>aId</codeph> is the
+Id of an interrupt source and is used to index an entry in the ISR
+table. Set the <codeph>iPtr</codeph> and <codeph>iIsr</codeph> members
+of that entry (ISR parameter and ISR pointer) to the passed in values <codeph>aPtr</codeph> and <codeph>aIsr</codeph>.</p><p>The implementation
+should perform some preliminary checks.</p><ul>
+<li><p>The interrupt Id must be checked for validity</p></li>
+<li><p>The ISR must not already be bound to a real interrupt. It should
+have been bound to the spurious interrupt handler at initialization.</p></li>
+</ul><p>All interrupts must be disabled during binding.</p><p>This
+example code provides a basic implementation.</p><codeblock xml:space="preserve">EXPORT_C TInt Interrupt::Bind(TInt aId, TIsr aIsr, TAny* aPtr)
+    {
+       TInt r = KErrNone;
+    If(TUint(aId)&gt;=TUint(KInterruptSourceCount))
+        {
+        r = KErrArgument; // Illegal interrupt number
+        }
+       else 
+        {
+           SInterruptHandler&amp; h = IsrHandlers[aId];
+        TInt irq = NKern::DisableAllInterrupts();
+        if (h.iIsr != &amp;SpuriousHandler)
+            {
+            r = KErrInUse; // Already bound to an ISR
+            }
+           else
+            {
+            h.iPtr = aPtr; // The ISR parameter
+            h.iIsr = aIsr; // Pointer to the ISR
+            }
+        NKern::RestoreInterrupts(irq);
+        }
+    return r;
+    }
+</codeblock><p>The implementation of <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-4E3CB472-3525-32F8-9BC4-8ECFEE931E7B"><apiname>Interrupt::Bind()</apiname></xref> can be more complicated in the case of chained interrupts, multiple
+interrupt sources, pseudo interrupt sources and device interrupts:
+see the discussion of those topics.</p></section>
+<section id="GUID-BEB323CF-9DDC-4486-AD32-682B78AF2072"><title>Unbind()</title><p>The <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-CCC9A397-608C-3EAF-830F-A59800C2E8E5"><apiname>Interrupt::Unbind()</apiname></xref> function unbinds ISRs
+from interrupt sources.</p><p>The argument <codeph>aId</codeph> is
+the Id of an interrupt source and is used to index an entry in the
+ISR table. Reset the entry in the ISR table to reference the spurious
+handler function.</p><p>The implementation should perform some preliminary
+checks.</p><ul>
+<li><p>The interrupt Id must be checked for validity</p></li>
+<li><p>The ISR must not already be unbound (that is, bound to the
+spurious interrupt handler).</p></li>
+</ul><p>All interrupts must be disabled during unbinding.</p><p>This
+example code provides a basic implementation.</p><codeblock xml:space="preserve">EXPORT_C TInt Interrupt::Unbind(TInt aId)
+    {
+       TInt r = KErrNone;
+       if (TUint(aId) &gt;= TUint(KInterruptSourceCount))
+        {
+        r = KErrArgument;    // Illegal interrupt number
+        }
+       else
+        {
+        SInterruptHandler&amp; h = IsrHandlers[aId];
+        TInt irq = NKern::DisableAllInterrupts();
+        if (h.iIsr == &amp;SpuriousHandler)
+            {
+            r = KErrGeneral; // Already unbound
+            }
+        else
+            {
+            h.iPtr =(TAny*)aId;
+            h.iIsr = SpuriousHandler;  // Replace with spurious handler
+            // NOTE: at this point it may be wise to
+            // force the hardware interrupt source to disabled.
+            }
+        NKern::RestoreInterrupts(irq);
+        }
+    return r;
+       }
+</codeblock><p>The implementation of <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-CCC9A397-608C-3EAF-830F-A59800C2E8E5"><apiname>Interrupt::Unbind()</apiname></xref> can be more complicated in the case of chained interrupts, multiple
+interrupt sources, pseudo interrupt sources and device interrupts:
+see the discussion of those topics below.</p></section>
+<section id="GUID-F8859FAE-9FA3-494E-A294-0ACF7158BD40"><title>Enable()</title><p>Device drivers call the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-BB169E6E-D8F9-3762-899D-6DBA4B29CF87"><apiname>Interrupt::Enable()</apiname></xref> function to enable the interrupt source identified by the argument <codeph>anId</codeph> in the interrupt controller hardware. </p><p>The implementation
+is entirely hardware dependent.</p><p>This example involves a check
+for chained interrupts, which are discussed in their own section below.</p><codeblock xml:space="preserve">EXPORT_C TInt Interrupt::Enable(TInt anId)
+    {
+     TInt r=KErrNone;
+     // if ID indicates a chained interrupt, call variant...
+     if (anId&lt;0 &amp;&amp; ((((TUint)anId)&gt;&gt;16)&amp;0x7fff)&lt;(TUint)KNumTemplateInts)
+         r=TemplateAssp::Variant-&gt;InterruptEnable(anId);
+     else if ((TUint)anId&gt;=(TUint)KNumTemplateInts)
+         r=KErrArgument;
+     else if (TemplateInterrupt::Handlers[anId].iIsr==TemplateInterrupt::Spurious)
+         r=KErrNotReady;
+     else
+         {
+         //
+         // TO DO: (mandatory)
+         //
+         // Enable the corresponding Hardware Interrupt source
+         //
+         }
+     return r;
+    }
+</codeblock></section>
+<section id="GUID-A508AA5E-E81A-4FC0-97DD-41543FF458E6"><title>Disable()</title><p>Device drivers call the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-2D14E023-E6ED-39BF-8B31-6FA510957A8A"><apiname>Interrupt::Disable()</apiname></xref> function to disable the interrupt source identified by the argument <codeph>anId</codeph>  in the interrupt controller hardware. The implementation
+is entirely hardware dependent.</p></section>
+<section id="GUID-53F6AAE1-3AE7-49E6-845D-135E43449F9F"><title>Clear()</title><p>Device drivers call the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-DB641A23-82B2-373E-A514-E11118CB6E69"><apiname>Interrupt::Clear()</apiname></xref> function
+to acknowledge that they have serviced the interrupt and cleared the
+pending flag in the interrupt controller hardware. The implementation
+is entirely hardware dependent.</p><p><xref href="GUID-5BCEAABF-D060-3F29-A8AE-0C14A8DFC1D2.dita"><apiname>Clear()</apiname></xref> is
+a useful function in cases where an interrupt must be cleared explicitly
+rather than as a side effect of I/O register access: for instance
+in PC card and MMC controller code.</p></section>
+<section id="GUID-3EB891CD-91C7-4B66-B41F-6F19CAF717CF"><title>SetPriority()</title><p>The <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-FA4CFED7-D694-399C-8F84-FA9FE3C3A171"><apiname>Interrupt::SetPriority()</apiname></xref> function associates
+a priority value (passed as a<codeph> TInt</codeph>) with an  interrupt
+Id. The meaning of the priority value is entirely hardware dependent.</p><p>Priority is a property of interrupts on some hardware, an example
+being OMAP. Where the hardware is of this type, <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-FA4CFED7-D694-399C-8F84-FA9FE3C3A171"><apiname>Interrupt::SetPriority()</apiname></xref> can be used to modify priorities in hardware. A simple use is to
+determine whether an interrupt generates an IRQ or an FIQ. If priority
+adjustment is not supported or not specified, the function should
+simply return <codeph>KErrNotSupported</codeph>.</p><p>The implementation
+is entirely hardware dependent.</p></section>
+<section id="GUID-ABE454D5-E219-48D0-A38C-7A63FBB0C088"><title>IrqDispatch()
+and FiqDispatch()</title><p>The functions <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-9CD4CECF-9DF9-3E94-BF17-45F387228A76"><apiname>Interrupt::IrqDispatch()</apiname></xref> and <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-B12F9319-11D6-3E43-AE66-6654DF15D1E3"><apiname>Interrupt::FiqDispatch()</apiname></xref> dispatch an interrupt
+by calling the associated ISR. Interrupts are either IRQ or FIQ interrupts
+and separate dispatch functions must be provided for each type. What
+follows refers to IRQs but applies equally to FIQs as the distinction only operates at the level of hardware and the two
+dispatch functions look the same.</p><p>In the simplest implementation,
+the interrupt Id is used as an index into the ISR table. The <codeph>iIsr</codeph> member of the entry is called as a function with the <codeph>iPtr</codeph> member as its argument. The interrupt Id is taken from
+a list of pending IRQs as in this example code.</p><codeblock xml:space="preserve">void IrqDispatch()
+    {
+    TUint32 pendingIrqs = TheAssp::IrqPendingRegister();
+    // for the purposes of this example we assume that reading
+    // this register also clears the pending flags
+
+    TInt index = 0;
+    while( pendingIrqs )
+        {
+        // while there is at least one pending IRQ
+        if( pendingIrqs &amp; 1 )
+            {
+            // the next interrupt is pending - dispatch it
+            (IsrHandlers[index].iIsr)(IsrHandlers[index].iPtr);
+            }
+        ++index;
+        pendingIrqs &gt;&gt;= 1;
+        }
+    }
+</codeblock><p>This code is a simplified example which assumes that</p><ul>
+<li><p>The interrupt controller provides 32 interrupt sources and
+has a 32 bit pending interrupt register where a 1 indicates a pending
+interrupt and all ones are cleared when the register is read.</p></li>
+<li><p>The interrupt source represented by the low order bit in the
+pending interrupt register is represented by interrupt Id 0 and so
+on.</p></li>
+</ul><p>Implementation will be more complex where chained interrupts
+and multiple interrupt sources are involved, as discussed below.</p><p>Dispatch functions are time critical. You will probably write
+an initial implementation in C++ to get them working and then rewrite
+in assembler for maximum efficiency.</p><codeblock xml:space="preserve"/></section>
+<section id="GUID-457E3092-8FE3-4CB4-8910-11E03DD8C82D"><title>Chained
+interrupts</title><p>A platform often has multiple interrupt controllers
+of higher and lower priority (higher and lower level controllers),
+organized so that the output of a lower level controller is one of
+the inputs to a higher level controller. Interrupt sources organized
+in this way are called chained interrupts.</p><p>In a system with
+chained interrupts, the ISR table must be structured so that interrupts
+from higher and lower level controllers can be distinguished by their
+Ids.</p><p>The <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-4E3CB472-3525-32F8-9BC4-8ECFEE931E7B"><apiname>Interrupt::Bind()</apiname></xref> and <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-CCC9A397-608C-3EAF-830F-A59800C2E8E5"><apiname>Interrupt::Unbind()</apiname></xref> functions are the same whether interrupts are chained or not.</p><p>In a system with chained interrupts it can be desirable to write
+the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-BB169E6E-D8F9-3762-899D-6DBA4B29CF87"><apiname>Interrupt::Enable()</apiname></xref> and <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-2D14E023-E6ED-39BF-8B31-6FA510957A8A"><apiname>Interrupt::Disable()</apiname></xref> functions so as to disable not the interrupt itself but a the higher
+level interrupt on the controller to which it is the input.</p><p>The <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-9CD4CECF-9DF9-3E94-BF17-45F387228A76"><apiname>Interrupt::IrqDispatch()</apiname></xref> and <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-B12F9319-11D6-3E43-AE66-6654DF15D1E3"><apiname>Interrupt::FiqDispatch()</apiname></xref> functions need to be extended in a system with chained interrupts.
+There are two techniques for doing this, both of which involve a separate
+second level dispatch function, but which differ in the way it is
+called. </p><ul>
+<li><p>In one technique, the main interrupt dispatcher calls the second
+level dispatcher if the relevant condition is satisfied. </p></li>
+<li><p>In the other technique, the second level dispatcher is bound
+directly to an interrupt source as its ISR. </p></li>
+</ul><p>The first technique works well in cases where there is only
+a main and a secondary interrupt controller. It does not scale well
+in cases which make use of multiple controllers chained to substantial
+depth.</p><p>You need to allocate locations in your ISR table for
+the secondary controllers so that the interrupt Id identifies which
+hardware controller the input is on. For example, if each interrupt
+controller handles 32 interrupt sources, you could allocate the first
+32 Ids to the highest level controller, the next 32 to a second level
+controller and so on.</p><p>This example code illustrates a main dispatcher
+which calls a second level dispatcher.</p><codeblock xml:space="preserve">void IrqDispatch()
+    {
+    TUint32 pendingIrqs = TheAssp::IrqPendingRegister();
+
+    TInt index = 0;
+    while( pendingIrqs )
+        {
+        if( pendingIrqs &amp; 1 )
+            {
+            if( index == EMainIntChainIrq )
+                {
+                // second-level controller is signalling
+                SecondLevelIrqDispatch();
+                }
+            else
+                {
+                // call ISR
+                (IsrHandlers[index].iIsr)(IsrHandlers[index].iPtr);
+                }
+            }
+        ++index;
+        pendingIrqs &gt;&gt;= 1;
+        }
+    }
+</codeblock><p>This example code illustrates a second level dispatcher
+bound directly to an interrupt source.</p><codeblock xml:space="preserve">void IrqDispatch()
+    // MAIN IRQ DISPATCHER, FIRST-LEVEL INTERRUPT
+    {
+    TUint32 pendingIrqs = TheAssp::IrqPendingRegister();
+
+    TInt index = 0;
+    while( pendingIrqs )
+        {
+        if( pendingIrqs &amp; 1 )
+            {
+            (IsrHandlers[index].iIsr)(IsrHandlers[index].iPtr);
+            }
+        ++index;
+        pendingIrqs &gt;&gt;= 1;
+        }
+    }
+void SecondLevelIrqDispatch( TAny* /* aParam */ )
+    {
+    TUint32 pendingIrqs = TheAssp::SecondLevelIrqPendingRegister();
+ 
+    TInt index = EStartOfSecondLevelIntId;
+    while( pendingIrqs )
+        {
+        if( pendingIrqs &amp; 1 )
+            {
+            (IsrHandlers[index].iIsr)(IsrHandlers[index].iPtr);
+            }
+        ++index;
+        pendingIrqs &gt;&gt;= 1;
+        }
+    }
+void InitialiseSecondLevelDispatch()
+    // Bind and enable the second-level dispatcher
+    {
+    Interrupt::Bind(EMainIntChainIrq,SecondLevelIrqDispatch,NULL);
+    Interrupt::Enable( EMainIntChainIrq );
+    }
+</codeblock><p>This example assumes an ISR table in which the second
+level interrupt ISRs begin at location 32 (<codeph>EStartOfSecondLevelIntId</codeph>). <codeph>EMainIntChainIrq</codeph> is the interrupt Id of the chained
+interrupt source to the main interrupt controller. The second level
+dispatcher is itself an ISR with an argument <codeph>TAny</codeph>* which is not needed in this example (possible uses are to distinguish
+between core and device specific ISR tables or to point to I/O addresses).</p></section>
+<section id="GUID-8953F8D5-8EA7-46B2-9030-A2932F06032F"><title>Multiple
+interrupt sources</title><p>In cases where multiple  peripherals are
+connected to the same interrupt source, multiple sources may generate
+the same interrupt which will then require a different ISR depending
+on the specific source. However, EKA2 does not allow binding of multiple
+ISRs to the same interrupt. There are two strategies for solving this
+problem, both of which involve assigning the multiple ISRs not to
+the real interrupt but to pseudo-interrupt Ids. In one strategy the
+dispatcher examines the hardware to determine where the interrupt
+originated and calls the appropriate ISR. In the other strategy, the
+ISRs are written so that they examine their peripheral hardware and
+only run if it is actually signalling an interrupt: in this strategy
+the dispatcher calls all the ISRs bound to the real interrupt but
+only one of them runs.</p><p>There is no requirement to extend the
+implementation of <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-4E3CB472-3525-32F8-9BC4-8ECFEE931E7B"><apiname>Interrupt::Bind()</apiname></xref> and <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-CCC9A397-608C-3EAF-830F-A59800C2E8E5"><apiname>Interrupt::Unbind()</apiname></xref> where multiple interrupt sources are
+involved.</p><p>Multiple interrupt sources require you to extend the
+implementation of <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-BB169E6E-D8F9-3762-899D-6DBA4B29CF87"><apiname>Interrupt::Enable()</apiname></xref> and <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-2D14E023-E6ED-39BF-8B31-6FA510957A8A"><apiname>Interrupt::Disable()</apiname></xref> to enable and disable the true interrupt
+source.</p><p>The dispatch functions should be extended in the same
+way as with chained interrupts, using one of the two techniques described
+for that case.</p><p>The ISR table should be structured so that the
+interrupt Id identifies the hardware controller the interrupt is on.
+For instance the first 32 Ids might refer to the highest level controller,
+the next 32 to a second level controller and so on.</p></section>
+<section id="GUID-26850469-13E9-4A50-B6B0-946E317085AD"><title>Device
+specific interrupts</title><p>Interrupts generated by peripherals
+are sometimes routed to a GPIO pin and sometimes included in a variant
+layer. Where they are part of the variant layer, they must be listed
+in a separate ISR table which is part of the device implementation.
+However, we want device drivers to be able to use the Interrupt class
+functions on interrupts of either type. The solution is to write separate
+device specific functions derived from those of the core class. Core
+class functions are then written in such a way as to identify device
+specific interrupts and pass them on to the derived functions.</p><p>A recommended way of labelling interrupts as being device specific
+is to assign negative numbers as their Ids. The core functions can
+then identify negative Ids as belonging to device specific interrupts
+and pass them to the device specific derived functions. The device
+specific functions can convert them to positive numbers which serve
+as indexes to the device specific ISR table.</p><p>This example code
+illustrates device specific interrupt handling.</p><codeblock xml:space="preserve">EXPORT_C TInt Interrupt::Bind(TInt aId, TIsr aIsr, TAny* aPtr)
+    {
+    TInt r = KErrNone;
+    if(aId &lt; 0 )
+        {
+        return MyAsic-&gt;VariantBind( aId, aIsr, aPtr ); // Device specific ID, call variant
+        }
+    else if (aId &gt;= KInterruptSourceCount)
+            {
+            r = KErrArgument; // Illegal interrupt number
+            }
+        else
+            {
+            SInterruptHandler&amp; h = IsrHandlers[aId];
+            TInt irq = NKern::DisableAllInterrupts();
+            if (h.iIsr != SpuriousHandler)
+                {
+                r = KErrInUse; // Already bound to an ISR
+                }
+            else
+                {
+                h.iPtr = aPtr;
+                h.iIsr = anIsr;
+                }
+            NKern::RestoreInterrupts(irq);
+            }
+    return r;
+    }
+
+SInterruptHandler VariantHandlers[KNumVariantInts];
+EXPORT_C TInt TMyVariant::VariantBind(TInt aId, TIsr aIsr, TAny* aPtr)
+    {
+    TInt r = KErrNone;
+    aId = (-aId)-1;    // convert to positive number &gt;=0
+    If (aId &gt;= KInterruptSourceCount || aId &lt; 0)
+        {
+        r = KErrArgument; // Illegal interrupt number
+        }
+    else
+        {
+        SInterruptHandler&amp; h = VariantHandlers[aId];
+        TInt irq = NKern::DisableAllInterrupts();
+        if (h.iIsr != VariantSpuriousHandler)
+            {
+            r = KErrInUse; // Already bound to an ISR
+            }
+        else
+            {
+            h.iPtr = aPtr;
+            h.iIsr = anIsr;
+            }
+        NKern::RestoreInterrupts(irq);
+        }
+    return r;
+    }</codeblock><p>The example provides a version of <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-4E3CB472-3525-32F8-9BC4-8ECFEE931E7B"><apiname>Interrupt::Bind()</apiname></xref> which calls a variant layer function<codeph> VariantBind()</codeph> to process device specific interrupts (here assigned negative Ids)
+to ISRs held in the variant specific table <codeph>VariantHandlers</codeph>.</p></section>
+</conbody><related-links>
+<link href="GUID-654A788A-526A-4C3F-838C-05B09F0D5445.dita"><linktext>Interrupt
+Technology Guide</linktext></link>
+<link href="GUID-D0F5D40A-28D2-4A2E-9B40-180537E60F56.dita"><linktext>Interrupt
+Client Interface Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2EC16C9C-7241-46B2-B569-B89751933C57.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2EC16C9C-7241-46B2-B569-B89751933C57" xml:lang="en"><title>DMA Configuration Overview</title><shortdesc>How to configure a DMA controller in the Platform Specific
+Layer.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,106 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9" xml:lang="en"><title>Porting the Power Resource Manager</title><shortdesc>This tutorial describes how to port the Platform Specific
+Layer (PSL) of the Power Resource Manager (<keyword>PRM</keyword>)
+and how to modify clients, such as device drivers, to use the PRM
+framework.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-97905214-40EC-44A1-95D6-7F2C1636C638"><title>Purpose</title> <p>The PRM is a framework for managing system power resources. This
+framework improves portability across different platforms and reduces
+device driver complexity. </p> <p>The PRM framework is split into
+two layers: </p> <ul>
+<li id="GUID-17F4DFA5-2848-5CA9-BE5D-F7F52BB1705F"><p>Platform Independent
+Layer - the PIL is a generic software layer that is implemented by
+Symbian. This is the base virtual class for the Power Resource Controller
+(<xref href="GUID-46F2174F-0206-345B-8C5D-F8B5763652E0.dita"><apiname>DPowerResourceController</apiname></xref>), </p> </li>
+<li id="GUID-B6499506-0B33-588F-BEFC-12A4D9FDF239"><p>Platform Specific
+Layer - the PSL is developed specifically to interface with the target
+hardware by licensees. This is the class derived from <codeph>DPowerResourceController</codeph>. </p> </li>
+</ul> <p>Other acronyms used in this document set: </p> <ul>
+<li id="GUID-97B58DBF-51DA-5982-A2D2-BF3453B062F2"><p>LDD - Logical
+Device Driver. The higher layer of abstraction within the Symbian
+platform device driver framework which implements common functionality
+among differing pieces of hardware of one type, </p> </li>
+<li id="GUID-547FA744-0D75-516A-954A-E9D1DBCBAC87"><p>PDD - Physical
+Device Driver. The lower layer of abstraction within the Symbian platform
+device driver framework which implements functionality that is specific
+to a particular piece of hardware. </p> </li>
+</ul> <p><b>Intended audience</b> </p> <p>This document is intended
+to be used by Symbian platform device creators. </p> <p><b>Required
+background</b> </p> <p>The reader of this document is assumed to have
+knowledge of the Symbian platform device driver model and <keyword>base port</keyword> layering and components. </p> <ul>
+<li id="GUID-611721D2-17C4-56F4-9101-6088B062BB2C"><p> <xref href="GUID-8D80AA51-5108-5D4B-B6B9-7FA47570AB89.dita">Device Driver Concepts</xref>, </p> </li>
+</ul> <p><b>Introduction</b> </p> <p>The PRM provides a unique place
+where all the current power states for resources can be obtained at
+any time. The sum of all internal and external power states defines
+the current system-wide power state. </p> <p id="GUID-0F328055-DBCE-5B2B-A1EB-77F73BA1FC82"><b>Setup and configuration
+requirements</b> </p> <p>The PRM component is implemented as a kernel
+extension with an exported public interface that is accessible to
+kernel side components through statically linking against its export
+library. The export library is built from the resource manager and
+the resource manager libraries. </p> <p>There are two versions available: </p> <ul>
+<li id="GUID-982137EB-A7C2-5420-8279-477AC52D5350"><p>basic resource
+manager - provides essential or required functionality for static
+resources. </p> <p>The basic version of the PIL layer is compiled
+into <filepath>resmanpsl.lib</filepath>. This kernel library must
+be included by the PSL to produce the kernel extension. </p> </li>
+<li id="GUID-0F8863B3-044C-5B5A-831D-DB20B72459C8"><p>extended resource
+manager - provides additional support for dynamic resources and resource
+dependencies. </p> <p>The extended version of the PIL layer is complied
+into <filepath>resmanextenedpsl.lib</filepath>. This kernel library
+must be included by the PSL to produce the kernel extension. </p> </li>
+</ul> <p>Device drivers that require the use of the PRM should link
+against the appropriate library. <filepath>resman.lib</filepath> to
+use the basic version and <filepath>resmanextended.lib</filepath> to
+use the extended version of the PRM. </p> <p><b>Building the PRM for
+the target platform</b> </p> <p>The PRM is an early extension, so
+the <codeph>targettype</codeph> in the <keyword>mmp</keyword> file
+must be set to <codeph>kext</codeph>. If the PRM is implemented as
+a PDD the <codeph>targettype</codeph> in the mmp file should be should
+be <codeph>pdd</codeph>. </p> <p><b>Boot sequence</b> </p> <p>The
+PRM cannot be used to operate on power resources until later in the
+boot sequence when the kernel allows the scheduling of other threads.
+During this time it is not possible to read or change the state of
+resources, but <xref href="GUID-46F2174F-0206-345B-8C5D-F8B5763652E0.dita#GUID-46F2174F-0206-345B-8C5D-F8B5763652E0/GUID-9D07A9C1-C0AE-36E9-8438-3BF71D3CBB0C"><apiname>DPowerResourceController::PostBootLevel()</apiname></xref> can be used to specify the state of specific resources and the PRM
+can change the state of resources to appropriate levels before the
+PRM is fully initialised. </p> <p> <codeph>PostBootLevel()</codeph> is used within the extension entry point, during this time PRM is
+not fully initialised. <b>Note</b>: This function can only be used
+for static resources and static resources with dependencies. </p> <codeblock id="GUID-F8E2125A-0DA8-5991-8FED-BF6DA48EC79D" xml:space="preserve">static TInt PostBootLevel(TUint aResId, TInt aLevel);</codeblock> <p> <codeph>PostBootLevel()</codeph> takes the resource ID and the
+post boot level that the level a resource needs to be after it is
+initialised. Typically the post boot level is only known to the PSL.
+However kernel extensions (and the variant) may request a post boot
+level. </p> <p>If a kernel extension needs to know if certain resources
+have reached the post boot state in order to complete its own initialisation
+then the kernel extension should queue resource state change notifications
+for the resource when first registering as clients with the PRM. <b>Note</b>: notification requests are accepted before the PRM is fully
+initialised. </p> <p>Variants or kernel extensions can register static
+resources before the PRM is fully initialised with <xref href="GUID-46F2174F-0206-345B-8C5D-F8B5763652E0.dita#GUID-46F2174F-0206-345B-8C5D-F8B5763652E0/GUID-6F74C10F-5055-37D2-968D-FCAB7D0F8FDF"><apiname>DPowerResourceController::RegisterStaticResource()</apiname></xref>. This API can only be used by static resources and not by static
+resource that support dependency. See <xref href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita#GUID-66FD040B-133E-57CF-80DD-9369F62709C6/GUID-61471315-14E1-5A0F-A164-92CF928C3604">DoRegisterStaticResources()</xref>. </p> </section>
+<section id="GUID-EBBEF707-27E5-4E10-ADCA-A02C119EB075"><title>Using
+the Power Resource Manager</title> <p>Porting the PRM consists of
+implementing the PSL layer for a given hardware platform and modifying
+clients, such as device drivers, to use the PRM framework. </p> <p>The following tasks are covered in this tutorial: </p> <ul>
+<li id="GUID-21093CEB-845E-528F-81DF-BD21084E3A27"><p> <xref href="GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671.dita"> Implement the controllable
+power resources</xref>, </p> </li>
+<li id="GUID-93B8B5A9-D7EE-56A0-B96B-BA2FC8DE1CE7"><p> <xref href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita"> Implement the PSL
+for the target</xref>, </p> </li>
+<li id="GUID-417CE38C-66CC-5186-B833-B1A6E8CE21B8"><p> <xref href="GUID-E7F91A65-235D-589C-9A8C-0B207D19A24B.dita"> Port the client
+drivers to use the PRM</xref> (to control the implemented resources), </p> </li>
+<li id="GUID-1420B749-8618-5FF3-93E3-F1A5E4579061"><p> <xref href="GUID-C8DF0CB0-92F4-5F9E-A8F1-7DE50954C4F1.dita">Debugging the PRM</xref>, </p> </li>
+<li id="GUID-4EEEC53B-C162-5E3F-B047-ABD4951F9C46"><p> <xref href="GUID-66E5F769-1156-54CA-94BC-8912159A1240.dita"> Testing the PRM
+PSL</xref>. </p> </li>
+</ul> </section>
+</conbody><related-links>
+<link href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita"><linktext>Power
+Resource Manager (PRM)</linktext></link>
+<link href="GUID-3773A78D-F491-52EB-AA1D-201636497F28.dita"><linktext>Power
+Management Tutorials</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-3046453A-AB3A-5491-87A0-00F3514D4768.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,109 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-3046453A-AB3A-5491-87A0-00F3514D4768" xml:lang="en"><title>Vector
+Floating Point Implementation Tutorial</title><shortdesc>This topic describes how to configure a base port to use the floating
+point coprocessor. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>ARM provide a hardware floating point coprocessor that provides floating
+point computation that is fully compliant with IEEE Std 754-1985. </p>
+<p>To support a coprocessor, you need to: </p>
+<ul>
+<li id="GUID-8C123E7F-C1DA-576A-8BFE-4B663E8A4EDE"><p>Configure the Kernel
+to use VFP through a macro setting in the Variant. </p> </li>
+<li id="GUID-74071911-77B1-5DD0-A035-7F5D51BEE573"><p>Configure the ROM to
+include a Kernel extension to support IEEE-without-exceptions mode. </p> </li>
+<li id="GUID-7740A4E2-3289-5DB3-B18B-0CAA4716611F"><p>Configure the ROM to
+include VFP support libraries. </p> </li>
+<li id="GUID-F58E5909-2C0E-5D84-A737-98BC3B5CC927"><p>Port the User Library
+to implement its <xref href="GUID-1DB7AE7A-A505-3530-AC2B-EBAEFCD3F36A.dita"><apiname>Math</apiname></xref> class functions to use VFP-enabled
+functions. This is described in the <xref href="GUID-7A3CEE5F-16FF-5204-97CC-31C932ACA732.dita">Math
+Class Port Tutorial</xref>. </p> </li>
+</ul>
+<section id="GUID-BDE8DDF7-ED9E-4459-9CF8-066E25E949D5"><title>Variant configuration</title> <p>Define the macro <codeph>__CPU_HAS_VFP</codeph> in
+the base port’s <filepath>variant.mmh</filepath>. This macro forces the inclusion
+of VFP support when the kernel is re-compiled. As an example, see the Integrator
+CM1136 base port, and specifically: <filepath>...\integrator\core\cm1136\variant.mmh</filepath>.
+When the kernel is re-compiled, VFP support is included. </p> </section>
+<section id="GUID-24F6699B-11F7-45B1-97E9-5508D7EFD3AF"><title>HAL configuration</title> <p>Add the HAL attribute for VFP
+to your base port's <filepath>config.hcf</filepath> file, by adding the following
+line to this file: </p> <codeblock id="GUID-01DE6AF2-08EC-5F21-BEC4-1A810224E813" xml:space="preserve">EHardwareFloatingPoint = GetHardwareFloatingPoint</codeblock> <p>As an example, see the Integrator CM1136 base port, and specifically: <filepath>...\integrator\core\cm920\hal\config.hcf</filepath>  </p> <p>See
+also <xref href="GUID-52583CC7-483E-54B5-8094-F0F61BD46B7F.dita">Creating the Config
+&amp; Values files</xref> in the HAL <xref href="GUID-05DAF5EF-6F2E-562D-9DB1-0985AD4A1E48.dita">Port
+Implementation Tutorial</xref> for more information. </p> </section>
+<section id="GUID-81817100-C0D5-5EC3-B941-C3CA43079C72"><title>IEEE-without-exceptions
+mode</title> <p>Symbian platform supports two execution modes : </p> <table id="GUID-4CA333F4-DA86-59E6-8E70-AF5CD6E9B26B">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>RunFast</codeph>  </p> </entry>
+<entry><p>In this mode, denormalised numbers, i.e. those outside the range
+of normal floating point values, are treated as zero, and a default <codeph>NaN</codeph> (<i>Not
+a Number</i>) value is used for all <codeph>NaN</codeph> situations regardless
+of the inputs. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>IEEE-without-exceptions </codeph>  </p> </entry>
+<entry><p>In this mode, denormalised numbers are treated as their actual values,
+and the IEEE754-mandated values for <codeph>NaN</codeph> s are used. </p> <p>The
+floating point model mandated by the Java specification is identical to this
+mode, and means that this mode is sufficient to implement a VFP-accelerated
+JVM. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>NOTE: There may be some applications that depend on the correct
+handling of calculations involving, or resulting in, very small numbers; for
+such applications, <codeph>RunFast</codeph> mode may not be appropriate. </p> <p id="GUID-7D2BECB4-3180-5802-809D-6C9041890AF4"><b>RunFast mode</b> </p> <p>For <codeph>RunFast</codeph> execution
+mode, nothing else needs to be implemented, and no extra components need to
+be added to the ROM. </p> <p id="GUID-F8F27E94-79DE-53DF-88E4-071EBFEBB7AB"><b>IEEE-without-exceptions
+mode</b> </p> <p>For <codeph>IEEE-without-exceptions</codeph> mode, you need
+to include the kernel extension <filepath>evfp.dll</filepath> in the ROM image
+by adding the following line into the <filepath>.iby</filepath> or <filepath>.oby</filepath> file
+for your port: </p> <codeblock id="GUID-BA13AEF5-0980-5227-8983-257BEB78B4CB" xml:space="preserve">extension[VARID]=KERNEL_DIR\DEBUG_DIR\evfp.dll \sys\bin\evfp.dll</codeblock> <p>As an example, see the Integrator CM1136 base port, and specifically: <filepath>...\integrator\core\cm1136\rom\base_integrator1136.iby</filepath>  </p> <p>Note: </p> <ul>
+<li id="GUID-207C3F80-5B2A-5211-81F9-DD5DEBFC311F"><p>This is the default
+execution mode. </p> </li>
+<li id="GUID-8859B4F6-22B5-5912-B55A-F991118F10B9"><p>It is possible to switch
+between this execution mode and the <codeph>RunFast</codeph> execution mode. </p> </li>
+<li id="GUID-EC07181F-4191-56BB-B988-1C2EE36923DC"><p> <filepath>evfp.dll</filepath> is
+built using ARM's VFP support code and can only be built using the RVCT tool
+chain. </p> </li>
+</ul> </section>
+<section id="GUID-554CAA85-5448-55D1-9255-4EE00D4EAB90"><title>VFP-enabled
+floating port support libraries</title> <p>Symbian platform provides both
+the VFP version and the non-VFP version of the floating point support functions.
+You choose the VFP version when you build your ROM image by specifying the <codeph>VFPHELPERS</codeph> macro
+to <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">BUILDROM</xref>.
+This causes the ROM building tool chain to replace the following three DLLs: </p> <ul>
+<li id="GUID-57B3445D-F513-5F13-9C39-815D3E9C84BC"><p> <filepath>drtaeabi.dll</filepath>  </p> </li>
+<li id="GUID-F18160B6-00E6-5885-AAC1-4E903340B48C"><p> <filepath>dfpaeabi.dll</filepath>  </p> </li>
+<li id="GUID-E5EE051E-560F-585F-89FF-1B05CB3A0EAA"><p> <filepath>dfprvct2_2.dll</filepath>  </p> </li>
+</ul> <p>There are two ways to specify the <codeph>VFPHELPERS</codeph> macro: </p> <ol id="GUID-1B567E7A-8768-57AC-86AE-EEA6ED07E418">
+<li id="GUID-B61B4DF5-A9F7-52D4-BD44-49CF568F7327"><p>by adding the following
+line into the <filepath>header.iby</filepath> file for your port: </p> <codeblock id="GUID-9DD8C685-6CDC-524E-8BE8-B6709B8294BD" xml:space="preserve">#define VFPHELPERS</codeblock> <p>You
+use this technique to permanently include the VFP versions in your ROM image. </p> </li>
+<li id="GUID-DCC7728F-FE42-5776-8DAD-DED6F5436959"><p>by passing <codeph>VFPHELPERS</codeph> as
+a pre-processor argument using the <codeph>-D</codeph> option when invoking <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">BUILDROM</xref>, i.e. : </p> <p><userinput>BUILDROM
+-DVFPHELPERS ...</userinput> </p> <p>You use this technique if you only want
+to include the VFP versions for a specific ROM image, for example, when testing. </p> </li>
+</ol> <p>If you use the first technique, you can still provide non-VFP versions
+for a specific ROM image by passing <codeph>NOVFPHELPERS</codeph> as a pre-rpocessor
+argument using the <codeph>-D</codeph> option when invoking <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">BUILDROM</xref>,
+i.e. : </p> <codeblock id="GUID-90ACA126-BFED-53C1-9BE0-BBDDD202BBF0" xml:space="preserve">BUILDROM -DNOVFPHELPERS ...
+</codeblock> <p>In effect, you are overriding the definition in the <filepath>header.iby</filepath> file. </p> <p>For
+example, see the Integrator CM1136 base port, and specifically: <filepath>...\integrator\core\cm1136\rom\header.iby</filepath>  </p> </section>
+</conbody><related-links>
+<link href="GUID-7A3CEE5F-16FF-5204-97CC-31C932ACA732.dita"><linktext>Math Class
+Port Tutorial</linktext></link>
+<link href="GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8.dita#GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8/GUID-4DA41221-40B9-5BC7-B2C6-7C6EB4522508">
+<linktext>User-Side Hardware Abstraction</linktext></link>
+<link href="GUID-CBC1E46A-E254-5A01-86AE-F5EB6135E3E3.dita"><linktext>Vector Floating
+Point (VFP)</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-306A0B41-94CD-534A-B3BA-FAECB858E9A9.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-306A0B41-94CD-534A-B3BA-FAECB858E9A9" xml:lang="en"><title>Platform-Specific
+Functions</title><shortdesc>Explains how bootstrap functions are organised.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Platform-specific source code needs to implement a set of standard functions
+that are called by the generic source code. It also needs to provide a set
+of standard MMU permission and cache attribute definitions. </p>
+<p>Standard functions are organised in the following way: </p>
+<ul>
+<li id="GUID-C69F291E-398F-5ECD-AAFA-D7A0741BB706"><p>a set of public functions
+that the Symbian platform generic source links to directly </p> </li>
+<li id="GUID-5259C748-D1B7-5B84-BDA8-F2866BDB4B0D"><p>a set of functions that
+are contained in a table, known as the boot table. </p> </li>
+<li id="GUID-A0EA59AE-FD4E-5856-95B0-1560828D3A62"><p>a set of entries that
+define MMU and cache attributes to be used for standard memory and I/O areas;
+this set of entries is also contained in the boot table. </p> </li>
+</ul>
+<p>Refer to the Template bootstrap source code: <filepath>os/kernelhwsrv/bsptemplate/asspandvariant/template_variant/bootstrap/template.s</filepath> </p>
+<note>All bootstrap source code should be position independent.</note>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-30978E00-D244-44CD-8F4E-9676DF172A52.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-30978E00-D244-44CD-8F4E-9676DF172A52" xml:lang="en"><title>Driver-side
+Handling</title><shortdesc>This document describes how device drivers handle asynchronous
+requests.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Drivers generally implement the <xref href="GUID-9D910016-5611-30DD-A139-EE46705A4912.dita"><apiname>DoRequest()</apiname></xref> function
+in the LDD to handle the received asynchronous messages. </p>
+<p>The implementation reads the request type and other passed arguments, and
+initiates handling of the request appropriately. </p>
+<p>The return value of this function only indicates the status of the message
+reception to the driver. It does not actually indicate the request completion
+result. </p>
+<codeblock id="GUID-335BB3F8-7B2B-5FC4-A8D1-204E6B24FECD" xml:space="preserve">TInt DExDriverLogicalChannel::DoRequest(TInt aReqNo, TRequestStatus* aStatus,
+        TAny* a1, TAny* a2)
+    {
+    switch (aReqNo)
+        {
+        case RExDriverChannel::ERequestTransmitData:
+            // Call TransmitData function
+            r = TransmitData ((const TDesC8*)a1);
+            // The status object is stored 
+            // to be used when notifying the completion of the 
+            // request at a later point.
+            //
+            iTxDataStatus = aStatus;
+            break;
+        }
+    return r;
+    }</codeblock>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-3102F778-DD2F-4C87-A0DF-7FA44C9709D8.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-3102F778-DD2F-4C87-A0DF-7FA44C9709D8" xml:lang="en"><title>Multiple
+Client Support</title><shortdesc>This document describes how multiple clients can access a driver
+over a single logical channel.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>A single channel has a single handle which is shared by driver users. A
+driver can allow or prevent the sharing of a handle to a logical channel between
+multiple users. This policy is implemented by the <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita#GUID-A3CC1D95-4681-3349-A67C-F113A614041D/GUID-9E23019E-7383-371E-B63C-85500F6B653D"><apiname>DLogicalChannel::RequestUserHandle()</apiname></xref> function.
+The default implementation does not restrict sharing of the channel, but a
+driver can override the function to change this. </p>
+<p>In the following example, the driver ensures that only the intended clients
+can get the handle and access the driver. Any other client that tries to share
+the handle gets a <codeph>KErrAccessDenied</codeph> error. </p>
+<codeblock id="GUID-2FEB04B3-ABD3-58E4-BFDB-0AD947BA6E16" xml:space="preserve">TInt DExDriverLogicalChannel::RequestUserHandle(DThread* aThread,
+        TOwnerType aType)
+    {
+    // Handle should be provided only to the intended client. Any 
+    // other clients that try to get a handle to the driver should get an access 
+    // denied error.
+    if ( aType!=EOwnerThread || aThread!=iClient)
+        return KErrAccessDenied;
+    return KErrNone;
+    }</codeblock>
+<p> <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita#GUID-A3CC1D95-4681-3349-A67C-F113A614041D/GUID-9E23019E-7383-371E-B63C-85500F6B653D"><apiname>DLogicalChannel::RequestUserHandle()</apiname></xref> only restricts
+the user from sharing or duplicating an existing channel. It does not restrict
+another process from opening its own separate channel on the same device. </p>
+<p> <note> More than one user can access the driver at the same time. It is
+up to the driver to manage and provide correct and secure access to the driver. </note></p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-315DD62B-8669-471F-BDDC-BC4D700AEA60.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-315DD62B-8669-471F-BDDC-BC4D700AEA60" xml:lang="en"><title>Interrupt Client Interface Quick Start</title><shortdesc>Basic steps to use the client interface of the Interrupt
+platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Interrupt platform service provides an interface that allows
+clients to have access to interrupts.</p>
+<section id="GUID-CB30D2E1-BFD0-48F0-937B-B8D94FDE9CAE"><title>Basic
+steps</title><p>The following are the basic steps to use the Interrupt
+platform service:</p><ol>
+<li id="GUID-E2528165-7456-414C-AC3E-35A1CEFB46ED"><p>The <xref href="GUID-654A788A-526A-4C3F-838C-05B09F0D5445.dita">Interrupt Technology
+Guide</xref> describes the basic concepts of the Interrupt platform
+service.</p></li>
+<li id="GUID-51B81040-F4A9-455F-BF3F-69C38F58546E"><p>The <xref href="GUID-D0F5D40A-28D2-4A2E-9B40-180537E60F56.dita">Interrupt Client
+Interface Guide</xref> explains the client interface and how to use
+it.</p></li>
+<li id="GUID-16C85F67-9356-4BF2-83E2-291A89FD8AA9"><p>The <xref href="GUID-9B66387C-B6CF-41D9-BEFC-F79E30C70F52.dita">Interrupt Build Guide</xref> explains how to include the Interrupt platform service in a build.</p></li>
+<li id="GUID-B544C33B-A279-4B89-929C-7750C0FC2028"><p>The <xref href="GUID-2490DA46-A57B-4DFD-AA9C-2004D58486E3.dita">Interrupt Testing
+Guide</xref> explains how to test the Interrupt platform service.</p></li>
+</ol> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-31CE66F2-B36C-56ED-A399-BA9EFA179DED-master.png has changed
Binary file Adaptation/GUID-31CE66F2-B36C-56ED-A399-BA9EFA179DED_d0e75538_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-31FFA810-129A-4E35-A47F-C6D3C1C71D5E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-31FFA810-129A-4E35-A47F-C6D3C1C71D5E" xml:lang="en"><title>Register Access Tools Guide</title><shortdesc>Tools required for the Register Access platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There are no specific tools required to use or implement the Register
+Access platform service.</p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-32B82E5C-FD53-48E6-9ABC-88F82ACF71BC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,56 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-32B82E5C-FD53-48E6-9ABC-88F82ACF71BC" xml:lang="en"><title>The
+LDD Entry Point and Factory</title><shortdesc>This document describes how LDDs are created.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-A3C0C24F-BFE3-4126-A8C3-3CAEBDE28307">           <p>An LDD
+must define an entry point function using the macro <xref href="GUID-B5DA78FD-07CA-3C9F-9154-D29A04E5E1E7.dita"><apiname>DECLARE_STANDARD_LDD</apiname></xref>,
+or <xref href="GUID-38771B51-195D-3148-A462-277DA3696117.dita"><apiname>DECLARE_EXTENSION_LDD</apiname></xref> in the case of kernel extensions.
+This must create an LDD factory object derived from <xref href="GUID-7616AA05-83E6-3989-AB9D-11AE01245BEB.dita"><apiname>DLogicalDevice</apiname></xref>: </p> <codeblock id="GUID-4867DF18-9CCD-548F-AB08-25C168527BD8" xml:space="preserve">DECLARE_STANDARD_LDD()
+    {
+    return new DerivedLogicalDevice;
+    }</codeblock> <p>This factory object is created on the kernel heap. Its
+purpose is to create the logical channel, the object through which all client
+interaction with the driver will occur. </p> <p> <xref href="GUID-7616AA05-83E6-3989-AB9D-11AE01245BEB.dita"><apiname>DLogicalDevice</apiname></xref> is
+derived from <xref href="GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497.dita"><apiname>DObject</apiname></xref>, and is, therefore a reference-counting
+object. It also means that <codeph>DLogicalDevice</codeph> objects are given
+a name, as these objects are always subsequently found by name. The user-side
+specifies the name of the logical device through the first parameter in the
+user-side call to <xref href="GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066.dita#GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066/GUID-669AF44C-96BD-3CAB-95E7-DB2C5BEA00AF"><apiname>RBusLogicalChannel::DoCreate()</apiname></xref>. </p> <p>The
+file extension of a LDD DLL can be any permitted Symbian Platform name but,
+by convention, the LDD DLL has the extension <filepath>.LDD</filepath>. Device
+driver DLLs are polymorphic interface DLLs. When building LDDs, specify a
+target type of <i>ldd</i> in the <filepath>.mmp</filepath> file. </p> <p>An
+LDD is loaded by calling <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-AE0D51B7-7ADC-3C9F-ACAA-8F6D9EA0AEFA"><apiname>User::LoadLogicalDevice()</apiname></xref>. This
+static function: </p> <ul>
+<li id="GUID-774CC8D6-4E6C-54C6-B6A4-1409EEDD8965"><p>loads the DLL into RAM,
+if necessary </p> </li>
+<li id="GUID-A9D6846C-F13F-56B3-A7C5-0CC2021BFF93"><p>calls the exported function
+at ordinal 1 to create the factory object, the <codeph>DLogicalDevice</codeph> derived
+object </p> </li>
+<li id="GUID-50E53C2E-216A-592C-B0E6-4F8CA3D1B577"><p>places the factory object
+into the appropriate object container. </p> </li>
+</ul> <note> This only needs to be done once, not every time the driver is
+used. </note> <p>If an LDD needs to perform initialisation at boot time (before
+the driver is loaded by <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-AE0D51B7-7ADC-3C9F-ACAA-8F6D9EA0AEFA"><apiname>User::LoadLogicalDevice()</apiname></xref>) then
+specify the entry point macros <codeph>DECLARE_STANDARD_EXTENSION</codeph> and <codeph>DECLARE_EXTENSION_LDD</codeph>. </p><codeblock id="GUID-4F20539E-4BC6-5D37-858B-53FD27E3A91E" xml:space="preserve">DECLARE_STANDARD_EXTENSION()
+    {
+    // initialise code here
+    }
+
+DECLARE_EXTENSION_LDD()
+    {
+    return new DMyLogicalFactory;
+    }</codeblock><note><p>In order for the kernel to initialise the LDD extension
+at boot time then the <filepath>.oby</filepath> file must specify the <codeph>extension</codeph> keyword.
+Also note that initialisation of the extension will not load
+the LDD: this still has to be done through a call to <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-AE0D51B7-7ADC-3C9F-ACAA-8F6D9EA0AEFA"><apiname>User::LoadLogicalDevice()</apiname></xref>.</p></note></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-3335663A-BC11-556E-B5A6-F83622AE34C3.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-3335663A-BC11-556E-B5A6-F83622AE34C3" xml:lang="en"><title>Audio Driver Porting
+Implementation Tutorial</title><shortdesc>Describes the steps to implement a physical device driver (PDD)
+for the Sound Driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p id="GUID-C08202D0-5D57-5D29-B548-3BB17B9879D3"> The audio device driver
+implementation may provide for playback, recording, or both at the same time,
+but there are design considerations for each option. </p>
+</conbody><related-links>
+<link href="GUID-6D75968E-53CF-5436-8390-54CA12BCFDE9.dita#GUID-6D75968E-53CF-5436-8390-54CA12BCFDE9/GUID-C869F627-8218-5482-A04B-C6B74F62EFBF">
+<linktext>Concepts</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-33A7D8D4-84D6-56EA-8EAB-2A3A3ACABF77.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,299 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-33A7D8D4-84D6-56EA-8EAB-2A3A3ACABF77" xml:lang="en"><title>Reference</title><shortdesc>Provides a summary of related documentation for the MMC Controller
+to which you can refer. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p><b>API Reference </b></p>
+<section id="GUID-5D209B28-A43D-4637-A639-95011BE7D604"><title>Peripheral bus layer </title><table id="GUID-1F772B32-87D8-5DFB-AC7A-941066AF5997">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Item</b>  </p> </entry>
+<entry><p> <b>Header</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C122D579-BB08-3084-A30E-DC857D6E7282.dita"><apiname>DMediaChangeBase</apiname></xref>  </p> </entry>
+<entry><p> <filepath>pbus.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-8F9DCEAE-F4B4-3379-B4C5-0E368B2BA838.dita"><apiname>DPBusPowerHandler</apiname></xref>  </p> </entry>
+<entry><p> <filepath>pbus.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B4E66372-2654-3434-AFB7-844B0B8D2FC9.dita"><apiname>DPBusPrimaryMedia</apiname></xref>  </p> </entry>
+<entry><p> <filepath>pbusmedia.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A8B5FB5A-4709-3F29-B2CB-81FC5B0E7D63.dita"><apiname>DPBusPsuBase</apiname></xref>  </p> </entry>
+<entry><p> <filepath>pbus.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C988CAE6-9073-3851-A0B0-5479D1A34CFB.dita"><apiname>DPBusSocket </apiname></xref>  </p> </entry>
+<entry><p> <filepath>pbus.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-49F96729-2DDB-37E0-AE39-9BEF2B7FF7F9.dita"><apiname>TMediaState</apiname></xref>  </p> </entry>
+<entry><p> <filepath>pbus.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-33919ABC-150F-310A-9BB8-96B045E0381C.dita"><apiname>TPBusCallBack</apiname></xref>  </p> </entry>
+<entry><p> <filepath>pbus.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9871634-E5A6-3316-9170-ACEFEB6736A0.dita"><apiname>TPBusCallBackFn</apiname></xref>  </p> </entry>
+<entry><p> <filepath>pbus.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-4E466E4C-72CD-3C99-A997-821DE3B62053.dita"><apiname>TPBusIsr</apiname></xref>  </p> </entry>
+<entry><p> <filepath>pbus.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-E3BB783F-423F-352A-9B6E-FD23EC80AA8D.dita"><apiname>TPBusPsuInfo</apiname></xref>  </p> </entry>
+<entry><p> <filepath>pbus.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-CD00D507-CC86-33BE-91A7-FAF7EAFD4840.dita"><apiname>TPBusPsuState</apiname></xref>  </p> </entry>
+<entry><p> <filepath>pbus.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B02C7092-68A7-3F0C-BBAE-825ABD3347F5.dita"><apiname>TPBusPsuStatus</apiname></xref>  </p> </entry>
+<entry><p> <filepath>pbus.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-608738E1-20EF-35C0-91EC-32500176DD26.dita"><apiname>TPBusState</apiname></xref>  </p> </entry>
+<entry><p> <filepath>pbus.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6A387011-E104-3F65-A001-A9EA28C6F21C.dita"><apiname>TPBusType</apiname></xref>  </p> </entry>
+<entry><p> <filepath>pbus.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-EDEFD175-21D2-3BE0-9EEA-6B4705AC826F.dita"><apiname>TPsuVoltChkMethod</apiname></xref>  </p> </entry>
+<entry><p> <filepath>pbus.h</filepath>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-D95479F9-F297-4BD4-8E36-39EBDC938F80"><title>MultiMediaCard layer </title><table id="GUID-06CECB21-4C2C-535C-838A-7E146367696B">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Item</b>  </p> </entry>
+<entry><p> <b>Header</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-2F974AD8-551B-35F0-B72C-99122913714D.dita"><apiname>DMMCMediaChange</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B.dita"><apiname>DMMCPsu</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita"><apiname>DMMCSession</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-45B97680-1756-3559-8A2D-2F2E851AD6A7.dita"><apiname>DMMCSocket</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita"><apiname>DMMCStack</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C095E583-3E71-31F3-B092-627357D72958.dita"><apiname>SMF_BEGIN</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-11B9D102-4548-3321-8318-26E940273880.dita"><apiname>SMF_BPOINT</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-ACD776A5-5439-3BE9-8DD8-B537D8C2C637.dita"><apiname>SMF_CALL</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C1D65C79-F781-3E22-AA73-F75BA2516F6F.dita"><apiname>SMF_CALLMEWR</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-2B6FA032-F8F9-3205-9CBB-EFB96691ACC9.dita"><apiname>SMF_CALLMYS</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-3802119E-0FC0-3B7C-9582-21563EC9AF61.dita"><apiname>SMF_CALLWAIT</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C1089896-DD68-399C-BF34-2495C51A0CA1.dita"><apiname>SMF_END</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-2BA73A03-7379-394C-B9E8-4525316AF91F.dita"><apiname>SMF_EXIT</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-57CF6330-1EA6-36A9-B2A1-2BB360B1E7FD.dita"><apiname>SMF_EXITWAIT</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-BF735A08-6E69-374F-8052-EF6CA101A3C3.dita"><apiname>SMF_GOTONEXTS</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-AA215584-34D9-36DA-A05A-8A4DF4636D5E.dita"><apiname>SMF_GOTOS</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A143CA61-AA6B-3C5F-9E58-50BAF3786262.dita"><apiname>SMF_INVOKES</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A73CAEB2-2413-371E-A56F-2757C0723514.dita"><apiname>SMF_INVOKEWAITS</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6E9EF7EB-A9A2-3FA1-902D-188B4930927F.dita"><apiname>SMF_JUMP</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-85E63D6B-521B-309A-A1B1-18FDFCF626A0.dita"><apiname>SMF_JUMPWAIT</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-2BA7F4A7-ECB0-3839-809B-4C32D4F451BA.dita"><apiname>SMF_NEXTS</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B13D0665-AD49-348F-8795-67E8761B0BC8.dita"><apiname>SMF_RETURN</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-38811BD9-F27C-3408-A04F-053314A2CF84.dita"><apiname>SMF_STATE</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-94214574-2CCD-3BE4-ABD4-6A58328B29A2.dita"><apiname>SMF_WAIT</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-33FBF199-09B8-32C3-BAD6-92D277722DB3.dita"><apiname>SMF_WAITS</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-BC3F021B-CD08-36CE-8477-642BACE53762.dita"><apiname>TBusWidth</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-74BBF6F1-DF9A-3122-9BA8-A009F32B63B5.dita"><apiname>TCID</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C6858312-FC9A-34C9-B442-557F7558B5C4.dita"><apiname>TCSD</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-BE2D313C-D3E4-38C9-A21F-5519A3B5C8A7.dita"><apiname>TExtendedCSD</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita"><apiname>TMMCardControllerInterface</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmccd_ifc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-82760D77-8856-39BB-B360-FF16DB93AA6D.dita"><apiname>TMMCArgument</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C0E2780A-47B3-31A2-827C-AF89C1B65F2E.dita"><apiname>TMMCBusConfig</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-F59F1805-95FB-3BDD-97A5-4FD6048DE2E8.dita"><apiname>TMMCCallBack</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-32036692-8BA3-3AAF-9FD8-D135DFADAE77.dita"><apiname>TMMC</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-2E9FA98A-0C61-3E51-925B-522F5DDF94C1.dita"><apiname>TMMCCmdDirEnum</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A.dita"><apiname>TMMCCommandDesc</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-BC1D9C6B-05A0-3EE8-88C8-ECD4DD5B10E6.dita"><apiname>TMMCCommandEnum</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-08DD6323-F200-31D2-B9E3-F201BCE6A08A.dita"><apiname>TMMCCommandSpec</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-5EA269C1-C02D-30A3-AA1D-1551463534D6.dita"><apiname>TMMCErrTypedef.xml</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-3F9D89E8-44F0-35B3-9404-6CCAC79763E8.dita"><apiname>TMMCMachineInfo</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-1443A1D8-B06F-31A2-A1EB-4C8FB9FE06E6.dita"><apiname>TMMCMediaTypeEnum</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-75FF770B-07D1-3C07-9577-5A37841E53E7.dita"><apiname>TMMCStackConfig</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-022AC0FE-86EE-3908-A9F8-4A33D04A68A5.dita"><apiname>TMMCStateMachine</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-D1DEB293-0F98-320B-9344-01801A61C55F.dita"><apiname>TMMCStatus</apiname></xref>  </p> </entry>
+<entry><p> <filepath>mmc.h</filepath>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-98B8BA0B-1770-4341-8E86-7810D0168493"><title>State machine function list</title><p>This is a list of state
+machine functions defined for the MultiMediaCard controller. </p></section>
+<section id="GUID-BFA6C089-8CAF-4D2E-A081-7158A9EBF23F"><title>Top level state machine functions</title><ul>
+<li id="GUID-D6451E3E-F614-53B6-AC58-8396F9789106"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-F71A4421-2F9E-39FD-A352-97ECAAFE822D"><apiname>DMMCStack::CIMUpdateAcqSM()</apiname></xref>  </p> </li>
+<li id="GUID-1582529A-C8FF-55D5-A4D9-198814C16B44"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-D8D3CFDC-5292-3853-8618-5D3A21F5C4D7"><apiname>DMMCStack::CIMInitStackSM()</apiname></xref>  </p> </li>
+<li id="GUID-A7B1B0C5-788C-5F25-9957-B1CD883B563E"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-80F77083-1D61-3630-A7E6-285C4DEDDC5B"><apiname>DMMCStack::CIMCheckStackSM()</apiname></xref>  </p> </li>
+<li id="GUID-812F2F82-A586-5BAA-89A1-3523D670663D"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-80F77083-1D61-3630-A7E6-285C4DEDDC5B"><apiname>DMMCStack::CIMCheckStackSM()</apiname></xref>  </p> </li>
+<li id="GUID-CD098B84-9E9C-5176-844E-9EC2F2A702C9"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-E1DE7F50-49D2-389F-A3E1-224FFB998B10"><apiname>DMMCStack::NakedSessionSM()</apiname></xref>  </p> </li>
+<li id="GUID-9ABE6335-5850-5ED9-96B8-8DBFD37BFEE2"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-A00EF244-0926-3B4C-BD81-1B54416013C9"><apiname>DMMCStack::CIMSetupCardSM()</apiname></xref>  </p> </li>
+<li id="GUID-A2CC920C-11AF-516D-8CE7-2E47B886DF64"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-A3E6DCF7-3A62-3A7A-850F-9219473DDC9D"><apiname>DMMCStack::CIMReadWriteBlocksSM()</apiname></xref>  </p> </li>
+<li id="GUID-437309E1-0F40-51E9-8081-8662967677D4"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-3336A10D-6DE1-36C2-8A45-ECD3F373547B"><apiname>DMMCStack::CIMEraseSM()</apiname></xref>  </p> </li>
+<li id="GUID-B88B980F-BAAC-5555-BBCC-A36D6378B122"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-76D78D6B-0166-3BC2-86AD-17F963AA54FB"><apiname>DMMCStack::CIMReadWriteIOSM()</apiname></xref>  </p> </li>
+<li id="GUID-94B5B215-3551-529B-8046-D575FA4119BD"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-8924D5FB-EC47-3FD6-B93C-6E3C2B1D3FEE"><apiname>DMMCStack::NoSessionSM()</apiname></xref>  </p> </li>
+</ul></section>
+<section id="GUID-22CCBABD-F2B4-472F-9ED0-D53B86C18B72"><title>Child state machine functions</title><ul>
+<li id="GUID-1053D002-059B-5AED-BB1E-311C1F640595"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-A2A21774-EBE9-3012-9991-B8DE337BE66E"><apiname>DMMCStack::AcquireStackSM()</apiname></xref>  </p> </li>
+<li id="GUID-CC2B23B2-93B4-5607-8FCE-3C957A87F746"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-ECCAC37B-5EF9-3124-B43B-67084385EB53"><apiname>DMMCStack::AttachCardSM()</apiname></xref>  </p> </li>
+<li id="GUID-FD25E387-396B-5CE1-AEBD-D2881FEB9070"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-4A7CF5C1-5737-352A-8A04-A0B830459A9E"><apiname>DMMCStack::ExecCommandSM()</apiname></xref>  </p> </li>
+<li id="GUID-48CE9634-6CDF-5196-AC94-4A2D6FA05372"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-2F5A317A-7BB9-3161-8B96-5307C2A07383"><apiname>DMMCStack::IssueCommandCheckResponseSM()</apiname></xref>  </p> </li>
+<li id="GUID-881054E3-496A-5DF6-9101-444789E0DCD8"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-4DE26C94-B0C4-3FAD-BC1B-BCEA7EC464A1"><apiname>DMMCStack::PollGapTimerSM()</apiname></xref>  </p> </li>
+<li id="GUID-EAA73620-6F7C-542D-9152-F14658B7B860"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-337E5EC0-7C48-304A-A0B6-A1568099E389"><apiname>DMMCStack::RetryGapTimerSM()</apiname></xref>  </p> </li>
+<li id="GUID-7E979036-E118-55A8-974A-6E5795156D88"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-791BCA03-61F3-3C1C-BA2D-D633A94AF299"><apiname>DMMCStack::DoPowerUpSM()</apiname></xref>  </p> </li>
+<li id="GUID-A2477C62-63BA-5B38-9ACC-3304821DE051"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-7B91EF52-26E5-333C-A037-B142B492BCC4"><apiname>DMMCStack::InitClockOnSM()</apiname></xref>  </p> </li>
+<li id="GUID-4EE04B00-6428-515D-A3B4-93D468236CF3"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-F5BA3183-DC9F-3B79-8593-3F004F7CFD5E"><apiname>DMMCStack::ProgramTimerSM()</apiname></xref>  </p> </li>
+<li id="GUID-EE966207-B688-5C63-8690-15F35AAA0A58"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-A48C1C16-B465-3DDA-9C83-00DEB8D27B68"><apiname>DMMCStack::IssueMMCCommandSM()</apiname></xref>  </p> </li>
+</ul></section>
+<section id="GUID-196F9B98-B671-5D54-B78F-3A07F1F65216"><title>Engineering
+Specifications</title> <p>No specifications are published. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,331 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703" xml:lang="en"><title>Power Controller DPowerController Implementation Tutorial</title><shortdesc>This topic describes how to implement the <codeph>DPowerController</codeph> class to provide the main power controller functionality in a base
+port.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p><xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita"><apiname>DPowerController</apiname></xref> is defined as: </p>
+<codeblock id="GUID-95318C39-B205-557C-B1F3-75C1441E464A" xml:space="preserve">class DPowerController : public DBase
+    {
+public:
+    IMPORT_C DPowerController();
+    IMPORT_C void Register();
+    IMPORT_C void WakeupEvent();
+
+#ifndef __X86__
+    IMPORT_C TInt RegisterResourceController(DBase* aController, TInt aClientId);
+private:
+    struct SResourceControllerData
+        {
+        DBase* iResourceController;
+        TInt   iClientId;
+        } iResourceControllerData;
+#endif
+
+public:
+    volatile TPowerState    iTargetState;
+public:
+    virtual void CpuIdle() = 0;
+    virtual void EnableWakeupEvents() = 0;
+    virtual void DisableWakeupEvents() = 0;
+    virtual void AbsoluteTimerExpired() = 0;
+    virtual void PowerDown(TTimeK aWakeupTime) = 0;
+    };
+      </codeblock>
+<p>The first three functions are exported from the kernel, <filepath>EKERN.EXE</filepath>, while the other five pure virtual functions
+are implemented by your base port. You do not need to export any other
+functions. </p>
+<ul>
+<li id="GUID-2EEFEFF3-FCAF-526C-A11B-790A2A47AA9C"><p> <xref href="GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita#GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703/GUID-BCCDBA09-415D-5779-BCE5-CDEB2E1EF7D8">Initialising the power controller</xref>, </p> </li>
+<li id="GUID-CBB1EE9C-CD27-5417-973C-3BBED74715D6"><p> <xref href="GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita#GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703/GUID-DCD91EBA-CB0E-5EA9-84E0-8F8FED6FC91E">DPowerController::RegisterResourceController()</xref>, </p> </li>
+<li id="GUID-4E2D396D-E6FA-5658-830F-9F82D4A63AD1"><p> <xref href="GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita#GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703/GUID-5A0CAD08-AA12-56EE-B0A3-75548D1896C9">DPowerController::EnableWakeupEvents()</xref>, </p> </li>
+<li id="GUID-DB82BCE3-702A-51EB-ADE0-9434D59CD553"><p> <xref href="GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita#GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703/GUID-51D37A0C-AD46-52D5-A31C-CB3A8046CE84">DPowerController::AbsoluteTimerExpired()</xref>, </p> </li>
+<li id="GUID-77CCBFFE-037D-5B86-BF14-1BE87D38B47A"><p> <xref href="GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita#GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703/GUID-1F77C71C-D226-58BB-ABAE-43F958CC0C61">DPowerController::PowerDown()</xref>, </p> </li>
+<li id="GUID-8657D772-2338-588D-B074-832B06144D8B"><p> <xref href="GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita#GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703/GUID-E2A072D0-A67F-5E6D-81ED-CFD77B6ED4F1">CpuIdle()</xref>. </p> </li>
+</ul>
+<section id="GUID-BCCDBA09-415D-5779-BCE5-CDEB2E1EF7D8"><title>Initialising
+the power controller</title> <p>Typically, you implement your derived
+class in a power management kernel extension, which has the opportunity
+to perform initialisation before the system itself is fully initialised.
+This is done via the extension's DLL entry point. You use the <xref href="GUID-7964FC46-4641-3BDD-92C9-50FA22C3321A.dita"><apiname>DECLARE_STANDARD_EXTENSION()</apiname></xref> macro as a wrapper around
+your initialisation code. There are at least three things to do here: </p> <ul>
+<li id="GUID-25C66F1B-6B2F-5B3B-A827-410263EE22A4"><p>create an instance
+of your power controller object </p> </li>
+<li id="GUID-369A09EC-74D3-529A-AC05-0EFE0C4ABBF7"><p>register your
+power controller object with the Symbian platform power manager, by
+calling <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-F66D72D0-AA27-3BAF-8915-C6E8CC4E7CCF"><apiname>DPowerController::Register()</apiname></xref>. Your power
+controller cannot be used by the Symbian platform power manager until
+it has been registered. </p> </li>
+<li id="GUID-E4C7D934-AAB9-511B-93A4-125D5A5B248D"><p>if you intend
+to use a battery monitor, then you would create it and register it
+as the HAL handler to deal with <xref href="GUID-66A851A0-2A0C-3624-AEC1-22F6629FABF7.dita#GUID-66A851A0-2A0C-3624-AEC1-22F6629FABF7/GUID-227B4DCD-5D74-3AB7-8E09-64A04D88F094"><apiname>THalFunctionGroup::EHALGroupPower</apiname></xref> calls. See <xref href="GUID-65CDCA83-C726-5173-8E46-B8981D1D7B02.dita">Battery Monitor Implementation Tutorialc</xref> and <xref href="GUID-54042C84-6216-5930-9CBF-BAF635CECD4D.dita">Power HAL Handler
+Tutorial</xref> for more detail. </p> </li>
+</ul> <p>For example: </p> <codeblock id="GUID-1A909C4C-DCAF-54E3-B482-16918E33BF4F" xml:space="preserve">DECLARE_STANDARD_EXTENSION()
+    {
+    TInt r=KErrNoMemory;
+
+    // Create the power controller object, and register it.
+    DPowerController* pC = new DYourPowerController;
+    if !(pC)
+        {
+        return (r);
+        }
+        pC-&gt;Register();
+
+    // Create the battery monitor.
+    DBatteryMonitor* pM = new DYourBatteryMonitor;
+    if !(pM)
+        {
+        return(r);
+        }
+
+    r = KErrNone;
+    return(r);
+    }</codeblock> </section>
+<section id="GUID-DCD91EBA-CB0E-5EA9-84E0-8F8FED6FC91E"><title>DPowerController::RegisterResourceController()</title> <p>The function <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-42896B4D-9F77-3D91-82BD-50102A8F3DA4"><apiname>DPowerController::RegisterResourceController()</apiname></xref> allows the Resource Controller to register itself with the Power
+Controller. See <xref href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita#GUID-66FD040B-133E-57CF-80DD-9369F62709C6/GUID-08BFCAF4-9AF0-5999-A1C4-7BBD107C9354">registering with the resource controller</xref> in the PSL implementation
+document. </p> <p>To support idle power management the Power Controller's
+PSL must override <codeph>RegisterResourceController()</codeph> to
+include the registration of a list of resources whose states are of
+interest to idle power management. </p> <p><b>Idle power management</b> </p> <p>The Power Controller can assemble
+a list of resources whose state it is interested in from a NULL thread
+in an array of <xref href="GUID-586AF75A-8350-345D-ABF4-6542C8E75DED.dita"><apiname>SIdleResourceInfo</apiname></xref> structures. Each
+entry in the list contains the resource ID that the power controller
+must enter before registering with the PRM. The resource list should
+be created in the kernel heap or data section. </p> <p>The example
+below creates a buffer to capture the state of all static resources.
+The PRM captures the information using <xref href="GUID-46F2174F-0206-345B-8C5D-F8B5763652E0.dita#GUID-46F2174F-0206-345B-8C5D-F8B5763652E0/GUID-52DC308A-9DF1-3BDE-A905-A4DD3B692638"><apiname>DPowerResourceController::RegisterResourcesForIdle()</apiname></xref>. </p> <codeblock id="GUID-C6E907FD-094D-5412-8F81-FC02CDE8B411" xml:space="preserve">    ...
+//Allocate buffer for Idle resource management
+    NKern::ThreadEnterCS();
+    pBuf = HBuf::New(numResources * sizeof(SIdleResourceInfo)); 
+    NKern::ThreadLeaveCS();
+    if(!pBuf)
+        {
+           return KErrNoMemory;
+        }
+    SIdleResourceInfo* pI = (SIdleResourceInfo*)pBuf-&gt;Ptr();
+
+//Update resource ID
+    for(TUint c = 0; c &lt; numResources; c++)
+        {
+        pI[c].iResourceId = c+1; 
+        }
+    r = (iResourceControllerData.iResourceController)-&gt;RegisterResourcesForIdle(iResourceControllerData.iClientId, numResources, (TPtr*)pI);
+    ...</codeblock> <p>The first parameter passed to <codeph>RegisterResourcesForIdle()</codeph> is the client Id generated for the power controller this is the
+client ID passed by the PRM when calling <xref href="GUID-B2C466D1-0B65-3BB7-81B1-7297400E60C4.dita"><apiname>RegisterResourceController</apiname></xref>. </p> <p> <b>Note</b>: <codeph>RegisterResourcesForIdle()</codeph> is not exported and is only available for use by the Power Controller
+to register resources for idle power management. <b>Note</b>: <codeph>RegisterResourcesForIdle()</codeph> can only be called by the Power
+Controller once. </p> </section>
+<section id="GUID-5A0CAD08-AA12-56EE-B0A3-75548D1896C9"><title>DPowerController::EnableWakeupEvents()</title> <codeblock id="GUID-38714507-C38C-5787-997F-5D45F3A90357" xml:space="preserve">virtual void EnableWakeupEvents() = 0;</codeblock> <p>The Symbian Power Model defines 3 generic system-wide <xref href="GUID-113B3755-1797-5D1B-8E07-8A18F5FE1504.dita">power states</xref>: <i>Active</i>, <i>Standby</i> and <i>Off</i>, as defined in the <xref href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita">Symbian platform
+power model</xref>. </p> <p>Each of the system-wide low power states: <i>Standby</i> and <i>Off</i>, has a defined set of wake-up events.
+If a wake-up event occurs while the system is preparing to transition
+into one of these low power states, or when the system is in the <i>Standby</i> state, then this can result in the system moving back
+to the <i>Active</i> power state. Wake-up events may be different
+for different target power states. Wake-up events are platform-specific
+hardware events, and it is your base port that decides which events
+count as wake-up events. </p> <p><b>When is it called?</b> </p> <p> <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-0642129D-05F2-3AB0-B562-37A7BB7A275F"><apiname>DPowerController::EnableWakeupEvents()</apiname></xref> is called called by the <xref href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita#GUID-0C435514-EEC6-5660-BB5F-535790349632/GUID-330F07B2-BBDF-5675-B7D5-FF6B25DD03F4">power manager</xref> as a result of a user side call to <xref href="GUID-15D25C07-CFD2-32CE-AD22-E17D512D8E87.dita#GUID-15D25C07-CFD2-32CE-AD22-E17D512D8E87/GUID-C49C0A07-EAC7-32CB-956F-1FFEFF2FD326"><apiname>Power::EnableWakeupEvents()</apiname></xref>. The class <xref href="GUID-15D25C07-CFD2-32CE-AD22-E17D512D8E87.dita"><apiname>Power</apiname></xref> is the user side interface to the power manager, and is used by
+the user side entity that is responsible for moving the device into
+a low power state. </p> <p><b>Context</b> </p> <p>When the user side entity decides to move
+the device to a low power state, it sends a notification to all of
+the user side power domains registered with it, giving their applications
+a chance to save their data and state. However, before doing this,
+it calls <xref href="GUID-15D25C07-CFD2-32CE-AD22-E17D512D8E87.dita#GUID-15D25C07-CFD2-32CE-AD22-E17D512D8E87/GUID-C49C0A07-EAC7-32CB-956F-1FFEFF2FD326"><apiname>Power::EnableWakeupEvents()</apiname></xref>. It also calls <xref href="GUID-15D25C07-CFD2-32CE-AD22-E17D512D8E87.dita#GUID-15D25C07-CFD2-32CE-AD22-E17D512D8E87/GUID-6CFE19D9-249A-3305-8224-823D2FDB1859"><apiname>Power::RequestWakeupEventNotification()</apiname></xref> so that it can
+be informed of a wake-up event. If it is notified of a wake-up event,
+it can halt, and reverse the user side response to the power transition. </p> <fig id="GUID-ACC6E7E3-71E3-5553-B433-9017CB04513D">
+<image href="GUID-AEDBF425-6077-4C84-A698-508291671F2B_d0e27993_href.png" placement="inline"/>
+</fig> <p>Before calling <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-0642129D-05F2-3AB0-B562-37A7BB7A275F"><apiname>DPowerController::EnableWakeupEvents()</apiname></xref>, the power manager sets the <codeph>iTargetState</codeph> member
+of <codeph>DPowerController</codeph> to the applicable <xref href="GUID-87AB8B20-04EE-31D2-8F3D-EA904D05B8D0.dita"><apiname>TPowerState</apiname></xref>. This means that you can enable the appropriate set of wake-up events. </p> <p>Once the user side transition is complete, it calls <xref href="GUID-15D25C07-CFD2-32CE-AD22-E17D512D8E87.dita#GUID-15D25C07-CFD2-32CE-AD22-E17D512D8E87/GUID-7C6F3F0F-319B-3DEE-81BF-1EB5BB2EAB0A"><apiname>Power::PowerDown()</apiname></xref> in the user side interface to the <xref href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita#GUID-0C435514-EEC6-5660-BB5F-535790349632/GUID-330F07B2-BBDF-5675-B7D5-FF6B25DD03F4">power manager</xref>, which results in a call to <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-8AE99718-6B82-3920-9029-28C2041A3B10"><apiname>DPowerController::PowerDown()</apiname></xref> in the power controller. This starts the transition of all <xref href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita#GUID-0C435514-EEC6-5660-BB5F-535790349632/GUID-DC5F1ECD-CCA3-59FF-A2F1-A3DBD76CD458">power handlers</xref> to a low power state, a potentially long process.
+This means that the power controller needs the ability to detect wake-up
+events so that it can halt, and reverse the power transition. </p> <p><b>Implementation issues</b> </p> <p>There are three possibilities
+in dealing with wake-up events: </p> <ul>
+<li id="GUID-4243E6DD-C903-58DE-B125-38CEDB8B5269"><p>if wake-up events
+are not handled by specific peripheral drivers, you could set up the
+hardware so that wake-up events are recorded in a location accessible
+by the software. Prior to completing the system power transition,
+the Power controller would check the relevant hardware to see whether
+a wakeup event had occurred. On detecting a wake-up event it would
+tell the power manager by calling <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-C193F898-2C15-3C42-8353-14F00789BCDA"><apiname>DPowerController::WakeupEvent()</apiname></xref>. </p> </li>
+<li id="GUID-289B86C4-A578-5A42-A0DF-70A7BF3F440E"><p>if wake-up events
+are not handled by specific peripheral drivers, you could arrange
+for wake-up events to interrupt the CPU. The code that services those
+interrupts would tell the power manager by calling <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-FABDB7E2-DEC5-3EA9-8106-66C971C04AB7"><apiname>DPowerController::WakepEvent()</apiname></xref>. </p> </li>
+<li id="GUID-E51BAE55-0A81-5D1F-B509-096A7F2141EF"><p>if wakeup events
+are intercepted, serviced and cleared by peripheral drivers, then
+the following outline solution could be adopted: </p> <ul>
+<li id="GUID-5C942237-BBB2-5919-8578-B55BDAFAFC9F"><p>The power controller
+would need to publish a list of wake-up events, preferably as a bit
+mask, and export an API which peripheral drivers could use to notify
+the power controller that a wake-up event has occurred. The following
+interface class could be used for this purpose: </p> <codeblock id="GUID-084F7F46-66B6-5661-85AF-57D499250886" xml:space="preserve">class TPowerController
+    {
+public:
+    inline static void SetPowerControllerPointer(DPowerController* apPowerController)
+    { iPowerControllerPointer = apPowerController; }
+    IMPORT_C static void WakeupEventOccurred(TUint aWakeupEvent);
+    …        // other methods if required
+private:
+    DPowerController* iPowerControllerPointer;
+    };
+                      </codeblock> <p>The class would be implemented
+as part of the power management kernel extension and <codeph>SetPowerControllerPointer()</codeph> would be called when <xref href="GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita#GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703/GUID-BCCDBA09-415D-5779-BCE5-CDEB2E1EF7D8">initialising the power controller</xref>, but after creation of the
+power controller object. </p> <p>Those peripheral drivers that intercept
+wake-up events would need to link to the power controller DLL (i.e.
+the power management kernel extension). </p> <p>On the occurrence
+of a wake-up event, the peripheral driver software servicing that
+event would notify the power controller by calling <codeph>WakeupEventOccurred()</codeph>, specifying the appropriate wake-up event bit(s). </p> <p>You might
+implement <codeph>WakeupEventOccurred()</codeph> as follows: </p> <codeblock id="GUID-501ABA28-81B9-52C1-9842-003E1E389045" xml:space="preserve">EXPORT_C void TPowerController::WakeupEventOccurred(TUint aWakeupEvent)
+    {
+    if(iPowerControllerPointer-&gt;iWakeupEvents &amp; aWakeupEvent)
+        {
+        iPowerControllerPointer-&gt;WakeupEvent();
+        }
+    }</codeblock> <p>where <codeph>iWakeupEvents</codeph> is a data
+member defined in your <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita"><apiname>DPowerController</apiname></xref> -derived
+class that contains the bitmask representing the wake-up events. The
+bitmask groups wakeup events according to the target power state. </p> </li>
+</ul> </li>
+</ul> <p>When the peripheral driver powers down, it should leave the
+hardware that generates the wake-up event powered and enabled for
+detection. Thus, if a wake-up event of the type handled by this peripheral
+driver occurs, it will not be serviced in the normal way, but will
+be left pending until the power controller services it. </p> <p>When
+the power controller’s <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-8AE99718-6B82-3920-9029-28C2041A3B10"><apiname>DPowerController::PowerDown()</apiname></xref> function is called, the power controller must check the peripheral
+hardware directly to see whether the wakeup event has happened, or
+is happening right now, prior to transitioning the device to the target
+system-wide low power state. If the wake-up event is found to have
+happened then <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-8AE99718-6B82-3920-9029-28C2041A3B10"><apiname>DPowerController::PowerDown()</apiname></xref> would
+return immediately, instead of initiating the <xref href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita#GUID-0C435514-EEC6-5660-BB5F-535790349632/GUID-DC5F1ECD-CCA3-59FF-A2F1-A3DBD76CD458">power handlers</xref> power down of the peripheral drivers. </p> </section>
+<section id="GUID-51D37A0C-AD46-52D5-A31C-CB3A8046CE84"><title> DPowerController::AbsoluteTimerExpired()</title> <codeblock id="GUID-5EC61B73-DA37-51C8-963F-4E4169AC1BE7" xml:space="preserve">virtual void AbsoluteTimerExpired() = 0;</codeblock> <p><b>When is it called?</b> </p> <p> <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-C6F792DB-1EC0-33F4-8F82-AB3F7B44B061"><apiname>DPowerController::AbsoluteTimerExpired()</apiname></xref> is called by the <xref href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita#GUID-0C435514-EEC6-5660-BB5F-535790349632/GUID-330F07B2-BBDF-5675-B7D5-FF6B25DD03F4">power manager</xref> whenever an absolute timer expires. An absolute
+timer is one that is set to complete at a specific time, as queued
+by a call to <xref href="GUID-8A423EA2-4264-30C9-9579-0466994E6E88.dita#GUID-8A423EA2-4264-30C9-9579-0466994E6E88/GUID-3F302410-5CC2-3CCB-82F4-47E953E7A29B"><apiname>RTimer::At()</apiname></xref>. </p> <p><b>Implementation issues</b> </p> <p>If absolute timer expiration
+is one of your wake-up events, then your implementation of <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-C6F792DB-1EC0-33F4-8F82-AB3F7B44B061"><apiname>DPowerController::AbsoluteTimerExpired()</apiname></xref> should call <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-C193F898-2C15-3C42-8353-14F00789BCDA"><apiname>DPowerController::WakeupEvent()</apiname></xref> to notify the power manager
+that a wake-up event has happened. </p> <p>It is recommended that
+you track absolute timers. </p> </section>
+<section id="GUID-1F77C71C-D226-58BB-ABAE-43F958CC0C61"><title>DPowerController::PowerDown()</title> <codeblock id="GUID-AD394AD5-8E3E-5FE3-938E-639C4E5E9F79" xml:space="preserve">virtual void PowerDown(TTimeK aWakeupTime) = 0;</codeblock> <p><b>When is it called?</b> </p> <p> <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-8AE99718-6B82-3920-9029-28C2041A3B10"><apiname>DPowerController::PowerDown()</apiname></xref> is called by the <xref href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita#GUID-0C435514-EEC6-5660-BB5F-535790349632/GUID-330F07B2-BBDF-5675-B7D5-FF6B25DD03F4">power manager</xref> to move the device into one of the system-wide
+low power states: <i>Standby</i> or <i>Off</i>. </p> <p>Typically,
+this is a result of the user side entity that is responsible for moving
+the device into a low power state calling <xref href="GUID-15D25C07-CFD2-32CE-AD22-E17D512D8E87.dita#GUID-15D25C07-CFD2-32CE-AD22-E17D512D8E87/GUID-7C6F3F0F-319B-3DEE-81BF-1EB5BB2EAB0A"><apiname>Power::PowerDown()</apiname></xref> in the user side interface to the <xref href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita#GUID-0C435514-EEC6-5660-BB5F-535790349632/GUID-330F07B2-BBDF-5675-B7D5-FF6B25DD03F4">power manager</xref>. </p> <p>If <xref href="GUID-26621CA5-B686-53FB-AF3E-96CDD38C8520.dita">physical RAM defragmentation</xref> is implemented you may wish to include calls to <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-B4825007-E3DB-3559-9D58-637150EF3DB9"><apiname> TRamDefragRequest::DefragRam()</apiname></xref> within this function to enable defragmentation of RAM zones that
+can then be powered down. </p> <p><b>Context</b> </p> <p>The target state is defined by the value of
+the <codeph>iTargetState</codeph> member of <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita"><apiname>DPowerController</apiname></xref>, as set by the power manager. </p> <p><b>Implementation issues</b> </p> <p>Implementation depends on the
+target state: </p> <ul>
+<li id="GUID-0473B5C1-BEC0-5276-88C5-A4A8379A4621"><p>if the target
+state is <i>Standby</i>, as implied by a value of <xref href="GUID-87AB8B20-04EE-31D2-8F3D-EA904D05B8D0.dita#GUID-87AB8B20-04EE-31D2-8F3D-EA904D05B8D0/GUID-5604F598-8CBC-3A94-865F-CA58DA4492B0"><apiname>TPowerState::EPwStandby</apiname></xref> in <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-86A0C14F-B219-3E0B-BD5E-A2C20EEDBF64"><apiname>DPowerController::iTargetState</apiname></xref>, then the power
+controller should put the hardware into a state corresponding to the <i>Standby</i> state. </p> <p>If at least one wake-up event has been
+detected and recorded since the last call to <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-0642129D-05F2-3AB0-B562-37A7BB7A275F"><apiname>DPowerController::EnableWakeupEvents()</apiname></xref>, then <codeph>PowerDown()</codeph> should return immediately; otherwise,
+it should continue with the process of putting the device into <i>Standby</i>; execution of the function will halt, and can only continue,
+and return, when a wake-up event occurs. </p> </li>
+<li id="GUID-E38B9334-CFE4-5E91-9DD4-D7A0678AF344"><p>if the target
+state is <i>Off</i>, as implied by a value of <xref href="GUID-87AB8B20-04EE-31D2-8F3D-EA904D05B8D0.dita#GUID-87AB8B20-04EE-31D2-8F3D-EA904D05B8D0/GUID-0DAD6E93-BD08-3C90-BCE8-ADBFC2681227"><apiname>TPowerState::EPwOff</apiname></xref> in <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-86A0C14F-B219-3E0B-BD5E-A2C20EEDBF64"><apiname>DPowerController::iTargetState</apiname></xref>, then <codeph>PowerDown()</codeph> must <i>never</i> return. Typically, the power
+controller turns the device off, but can choose to perform other device-specific
+action such as a system reboot. </p> </li>
+</ul> <p>The <xref href="GUID-8C6E2996-24DE-3E59-927A-46D32290225E.dita"><apiname>TTimeK</apiname></xref> parameter passed to the function
+is a system time value. If non-zero, it specifies the time when the
+system should wakeup. The kernel calculates it as the time that the
+next absolute timer expires. Typically, your implementation will use
+the Real Time Clock module to generate an event at the specified time,
+and this will cause a return to the <i>Active</i> state. This implies
+that the base port should enable Real Time Clock event detection during <i>Standby</i>. </p> <p>The Symbian definition of the <i>Standby</i> state usually translates into the hardware manufacturer’s CPU “Standby”
+or “Sleep” modes of operation. Typically, the internal clocks associated
+with the core and some of the core peripherals, or their power supply,
+are suppressed, and their internal state is not preserved. In this
+case, the state of the core and core peripherals should be saved before
+going into <i>Standby</i> so that they can be restored when the system
+wakes-up. Note the following: </p> <ul>
+<li id="GUID-824D88FD-33FB-50DC-A904-F5F44BFBF90A"><p>for the core
+state, save the current mode, the banked registers for each mode,
+and the stack pointer for both the current mode and user mode </p> </li>
+<li id="GUID-E8CDFA98-E6F2-5D48-987F-E2591DAB242B"><p>for the core
+peripherals, save the state of the interrupt controller, the pin function
+controller, the bus state controller, and the clock controller </p> </li>
+<li id="GUID-90BEA663-F58C-5AD7-8578-353E5EFFBCCC"><p>for the MMU
+state, save the control register, the translation table base address,
+and the domain access control, if this is supported </p> </li>
+<li id="GUID-68AB9558-5CC7-573F-8A33-A38F16EAF304"><p>flush the data
+cache and drain the write buffer. </p> </li>
+</ul> <p>If all of this data is saved to a DRAM device, then this
+should be put into self refresh mode. </p> <p>Peripherals modules
+involved in the detection of wake-up events should be left powered. </p> <p>Tick timer events should be disabled, and the current count of
+this and any other system timers should be saved; relevant wake-up
+events should be left unmasked, and any others should be disabled. </p> </section>
+<section id="GUID-E2A072D0-A67F-5E6D-81ED-CFD77B6ED4F1"><title>DPowerController::CpuIdle()</title> <codeblock id="GUID-0E6F1B1D-F979-575B-BA3C-096CE4C0CA15" xml:space="preserve">virtual void CpuIdle()=0;</codeblock> <p><b>When is it called?</b> </p> <p> <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-473874CA-FC35-3EB2-BC23-A97D7176B833"><apiname>DPowerController::CpuIdle()</apiname></xref> is called whenever the Null thread is scheduled to run. This can
+happen as soon as the power model has been installed. It is the mechanism
+through which your base port can increase power savings when the system
+becomes inactive by moving the CPU or the system into a low power
+mode. </p> <p>If <xref href="GUID-26621CA5-B686-53FB-AF3E-96CDD38C8520.dita">physical RAM defragmentation</xref> is implemented you may wish to
+include calls to <xref href="GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262.dita#GUID-AE7E0A8E-1513-3F6B-A6D5-150084C4E262/GUID-B4825007-E3DB-3559-9D58-637150EF3DB9"><apiname> TRamDefragRequest::DefragRam()</apiname></xref> within this function to enable defragmentation while the device
+is idle. </p> <p><b>Implementation issues</b> </p> <p>The implementation can call
+the Variant or ASSP implementation of <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita#GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D/GUID-6F242C0C-2EFC-30EC-9A5E-A34C8D15E0D7"><apiname>Asic::Idle()</apiname></xref>. </p> <p>The idle state is usually implemented via a Wait-For-Interrupt
+type instruction that will usually suspend execution of the CPU, possibly
+triggering other ASIC power saving actions, and will resume execution
+when any unmasked interrupt occurs. </p> <p><b>Suppressing the system tick interrupt</b> </p> <p>To further increase
+power savings during CPU Idle, a base port can choose to suppress
+the system tick interrupt until the next nanokernel Timer (as implemented
+by <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita"><apiname>NTimer</apiname></xref>) is due to expire. Nanokernel timers
+are the basic timing service and all Symbian platform tick-based timers
+and time-of-day functions are derived from nanokernel timers. </p> <p>In EKA2, timing services rely on a hardware timer, which is programmed
+by the base port Variant code, to generate the system tick. We refer
+to this as the <i>system timer</i>. </p> <p>Typically, the platform-specific
+ASSP or Variant object has a pointer to the nanokernel timer queue,
+an <xref href="GUID-C54D99AA-FF6E-3023-8260-8F5A88FBFBE0.dita"><apiname>NTimerQ</apiname></xref> object. The number of ticks before the
+next <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita"><apiname>NTimer</apiname></xref> is due to expire can be found by calling <xref href="GUID-C54D99AA-FF6E-3023-8260-8F5A88FBFBE0.dita#GUID-C54D99AA-FF6E-3023-8260-8F5A88FBFBE0/GUID-69103F26-2C21-3ECA-9DB5-C31A41F6C238"><apiname>NTimerQ::IdleTime()</apiname></xref>. </p> <p>Before going into Idle mode, <codeph>CpuIdle()</codeph> disables the hardware timer used to generate the
+system tick (i.e. the system timer) for the number of ticks to be
+suppressed; i.e. the system timer is reset to go off and generate
+an interrupt only when the <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita"><apiname>NTimer</apiname></xref> expires. Note
+that the clock supply to the hardware timer must be left enabled. </p> <p>On returning from Idle mode, the software must examine the system
+timer and decide whether the <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita"><apiname>NTimer</apiname></xref> expiration
+was responsible for waking up the processor, or whether it was due
+to some other interrupt. </p> <p>If waking up was due to the <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita"><apiname>NTimer</apiname></xref>, the system timer must be reset to generate the
+system tick at the frequency desired, and the tick count, <xref href="GUID-C54D99AA-FF6E-3023-8260-8F5A88FBFBE0.dita#GUID-C54D99AA-FF6E-3023-8260-8F5A88FBFBE0/GUID-ACFDFE7C-19AE-3C81-9D38-3266A3A3EF1F"><apiname>NTimerQ::iMsCount</apiname></xref>, must be adjusted with the <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita"><apiname>NTimer</apiname></xref> expiration time. As the expiration time is always an integer multiple
+of the number of ticks, then the <xref href="GUID-C54D99AA-FF6E-3023-8260-8F5A88FBFBE0.dita#GUID-C54D99AA-FF6E-3023-8260-8F5A88FBFBE0/GUID-AA1EC86F-8A6E-340D-848F-A86554772A13"><apiname>NTimerQ::Advance()</apiname></xref> function can be used for this purpose. </p> <p>If waking up was
+due to another interrupt, then the software must read the system timer
+and calculate the time elapsed since going into Idle mode, and adjust
+the system tick count with the elapsed time (which could be a fractional
+number of ticks) and reprogram the system timer to continue generating
+the tick after the correct interval, as above. </p> <p>If the hardware
+timer that is used to generate the system ticks does not use a Compare-Match
+function, then some care has to be taken not to introduce skewing
+when manipulating the timer value directly. If the timer needs to
+be reloaded with the new value to give the next tick, then the software
+usually “spins”, waiting for the hardware timer to change, and then
+reloads it. This way the timer will always be reloaded on an edge
+of its internal clock. </p> <p><b>Waking up from “Sleep” modes with long wakeup latencies</b> </p> <p>Often, to further enhance power savings, the CPU and some peripherals
+are moved into a hardware “sleep” mode when <codeph>CpuIdle()</codeph> is called. This could be of long latency, and waking up could take
+longer than the system Tick period. There are two situations: </p> <ul>
+<li id="GUID-7484F7CB-C824-5752-9043-736E95D4405D"><p>if the wakeup
+time can be determined precisely, then <codeph>CpuIdle()</codeph> programs
+the system timer to bring the CPU back from the “Sleep“ mode at a
+time corresponding to the next <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita"><apiname>NTimer</apiname></xref> expiration
+(as a number of Ticks to suppress) <i>minus</i> the number of ticks
+it takes to wake up from that mode. On waking up on the timer, the
+System tick count should be adjusted with the total number of ticks
+suppressed, i.e. the count corresponding to the time of the <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita"><apiname>NTimer</apiname></xref> expiration. </p> </li>
+<li id="GUID-C0A9B2A2-D98D-50C0-B58A-4E84FCEC12E4"><p>If the wakeup
+time cannot be known deterministically, then the above scheme must
+be combined with another system to allow adjusting the system timer
+from the hardware Real Time Clock (RTC). </p> <p>Typically, the hardware
+RTC is clocked with a 1Hz clock, and can be programmed to interrupt
+the CPU on multiples of one second intervals. The clock supply to
+the RTC must be left enabled on going into "sleep" mode. </p> </li>
+</ul> <p>To guarantee that timed events occur when they are due, the
+CPU should only be allowed to go to into the long latency hardware
+“sleep” mode if the RTC can be guaranteed to complete a second tick
+before the CPU is due to wakeup. </p> <p>Note that if waking up from
+hardware “Sleep” mode takes a non-negligible amount of time, extreme
+care should be taken when deciding to move the platform into that
+mode. For example, if a receive request is pending on a data input
+device <i>and</i> the CPU reaches the Idle mode <i>and</i> the platform
+is transitioned into a “sleep” state <i>and</i> data arrives while
+it is still in that state, <i>then</i> there is a possibility that
+the system will not wake up on time to service the incoming data. </p> </section>
+<section id="GUID-4B613C67-3A12-4AD5-8842-6ED510A68746"><title>Validation</title> <p>The <filepath>e32test</filepath> programs <filepath>t_power</filepath>, and <filepath>t_timer</filepath> will put the system into standby
+and resume off a timer. </p> </section>
+</conbody><related-links>
+<link href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita"><linktext>Power
+Management</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-3574BE12-9DA9-573D-8545-3B073005A139.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-3574BE12-9DA9-573D-8545-3B073005A139" xml:lang="en"><title>Configuration:
+Timer Constants</title><shortdesc>Describes how to set the values of timer constants that change
+the behaviour of the Digitizer Driver. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The timing constants are defined near the beginning of the template port
+implementation of the platform specific layer in <filepath>...\template\template_variant\specific\xyin.cpp</filepath>. </p>
+<p>The values and their meaning are as follows: </p>
+<section id="GUID-C8EC7A1D-7597-57BB-ADE4-0EDFFEB323D0"><title>KInterSampleTime</title> <p>This
+constant determines the rate at which individual samples within a group are
+collected. </p> <p>A group of samples is collected when the pen is down, and,
+in the template port, this is handled by <codeph>DTemplateDigitiser::TakeSample()</codeph>. </p> <p>Once
+all the samples in a group have been collected, the function calls <xref href="GUID-4C26DF22-B715-30DA-BBF1-8C1CA3A729DB.dita#GUID-4C26DF22-B715-30DA-BBF1-8C1CA3A729DB/GUID-28D95B3F-EC80-3D13-A7F1-EDDC46469732"><apiname>Digitiser::RawSampleValid()</apiname></xref> in
+the platform independent layer, whose main purpose is to ensure the validity
+of the samples by checking the spread. If the samples appear valid, it averages
+the samples to obtain the current position. </p> <p>The setting of the timer
+constant depends on the sample resolution of the digitizer: </p> <ul>
+<li id="GUID-6D570D10-EDFB-5DFA-803E-E4808367D51B"><p>A high resolution can
+lead to more jitter between samples, and therefore more smoothing is required
+to obtain nice steady values. This argues for higher sampling rates, and a
+smaller value of <codeph>KInterSampleTime</codeph>. </p> </li>
+<li id="GUID-44E06F7A-8B7E-5EB5-98E2-131C3BEE75C7"><p>A low resolution means
+that there is very little variation between consecutive samples, and therefore
+fewer are required. This argues for lower sampling rates, and a larger value
+of <codeph>KInterSampleTime</codeph>. </p> </li>
+</ul> <p>Another consideration when setting this constant is the speed of
+the communications between the MPU and the digitizer. </p> <p>In the Symbian
+reference ports, this value varies between 1 and 3. </p> </section>
+<section id="GUID-587D0895-7B8D-5FA1-A2DE-2F346780BB78"><title>KPenDownDelayTime</title> <p>This
+value is used in the implementation of the <xref href="GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07.dita#GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07/GUID-D74C94E4-83AD-5BC0-B435-754E7D3FECA4">pen
+interrupt</xref> interrupt service routine (ISR). It represents a delay, measured
+in nano-kernel ticks, between a pen down event and the start of the collection
+of digitizer samples. </p> <p>The value is optional. Choose a value of 0 if
+no delay is required. Typically, a value of 2 is chosen. </p> </section>
+<section id="GUID-84FF861C-F916-5F57-BA6D-ACD5010B0790"><title>KInterGroupTime</title> <p>This
+value is used in <codeph>DTemplateDigitiser::WaitForPenUp()</codeph> and <codeph>DTemplateDigitiser::WaitForPenUpDebounce()</codeph>.
+After a group of samples has been collected, there is a delay, dictated by
+the value of this constant, before the collection for the next group begins. </p> <p>The
+inverse of the sum of <xref href="GUID-3574BE12-9DA9-573D-8545-3B073005A139.dita#GUID-3574BE12-9DA9-573D-8545-3B073005A139/GUID-C8EC7A1D-7597-57BB-ADE4-0EDFFEB323D0">KInterSampleTime</xref>,
+and <codeph>KInterGroupTime</codeph> will therefore determine the frequency
+at which groups of samples are taken. This, in turn, dictates how often pen
+movement events are issued, and, if no interrupt is used on pen up, how quickly
+this situation is ascertained. The constant is optional. Typically it is set
+at 1ms </p> <p>The delay is optional, a value of zero meaning that there is
+no delay. Typically, a value of 1 is chosen. </p> </section>
+<section id="GUID-9BFC5FDA-FC84-5B54-93AA-BED4035F2A59"><title>KPenUpDebounceTime</title> <p>This
+value is used in <codeph>DTemplateDigitiser::TakeSample()</codeph>. If, during
+sample collection, the pen goes up, then the digitizer will wait for this
+period of time before deciding whether the removal of the pen is momentary,
+or whether it is an intentional removal - this is also referred to as debounce. </p> <p>If,
+after the delay, the pen is still up, then a pen-up event is issued; otherwise
+the state of the digitizer reverts to collecting mode, resetting the sample
+buffer </p> <p>Typically, this value is set to around 30. </p> </section>
+<section id="GUID-EDA72AF2-460E-52F0-9EC7-634B7AC14D46"><title>KPenUpPollTime</title> <p>This
+value is used in <codeph>DTemplateDigitiser::TakeSample()</codeph>. </p> <p>If
+the pen is down when the system powers on, then the digitizer is sampled using
+this delay until the pen is up. </p> <p>Typically, this value is set at 30. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-360DEB3A-3E38-413A-9941-6C758BA01ADE.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,169 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-360DEB3A-3E38-413A-9941-6C758BA01ADE" xml:lang="en"><title>DSDIOSession
+Class Tutorial</title><shortdesc>Describes the DSDIOSession API class.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-286AF512-0B54-41BA-8F7A-6E67692046B2"><title>Description</title><p>This
+class is used for setting up a session to form specific SDIO specific command
+sequences. </p><p>The stages involved in initializing a session are as follows:</p><ol>
+<li id="GUID-C2FCE2E7-6F0C-4BF3-B191-A8F41EC7A8B3"><p>The session is first
+created with the required parameter values</p></li>
+<li id="GUID-24645335-A11F-4CA2-8767-82B0C23B8D96"><p>The session is placed
+on the stack.</p></li>
+<li id="GUID-DFCF8772-61B0-41C5-9EAC-27FB9F03C32D"><p>On completion of initialization,
+a callback is called.</p></li>
+</ol><p>It is intended that the <xref href="GUID-CC5352E2-DB21-393F-A7A4-108AA3684460.dita"><apiname>DSDIORegInterface</apiname></xref> class
+should be used for the majority of SDIO operations. This class should only
+be used in more complex scenarios, for example where the asynchronous nature
+of the stack could be an advantage. The same thing can also be achieved with
+the <xref href="GUID-CC5352E2-DB21-393F-A7A4-108AA3684460.dita"><apiname>DSDIORegInterface</apiname></xref> documented <xref href="GUID-2607CCFA-3D24-4716-A447-74304F861C44.dita">here</xref> .</p><p>Some
+functions have an auto-increment parameter. If the hardware function requires
+you to use the register as a pointer to an address, auto-increment automatically
+increments the register to point to the next address after each call. If the
+hardware function requires you to use the register as a FIFO, auto-increment
+should be disabled.</p><table id="GUID-CEA18E7B-CD1A-4527-911F-E26F5C44E3F3">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p>Header file</p></entry>
+<entry><p><filepath>sdio.h</filepath></p></entry>
+</row>
+<row>
+<entry><p>Source code file</p></entry>
+<entry><p><filepath>sdiosession.cpp</filepath></p></entry>
+</row>
+<row>
+<entry><p>Required libraries</p></entry>
+<entry><p>EPBUSSDIO</p></entry>
+</row>
+<row>
+<entry><p>Class declaration</p></entry>
+<entry><p><codeph>class DSDIOSession : public DSessionBase</codeph></p></entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-F102DD54-CAD1-4024-A2C6-45D214005760"><title>SetupCIMIoWrite()</title><p>The
+function declaration for the <xref href="GUID-A680A35C-7B13-3663-9502-A3ACD4362722.dita"><apiname>SetupCIMIoWrite()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C void SetupCIMIoWrite(TUint32 aAddr, TUint8 aWriteVal, TUint8* aReadDataP);</codeblock><p><b>Description</b></p><p>Set the session to transfer a single byte of
+data to the card, and optionally read the register after the write operation.</p><p><b>Parameters</b></p><table id="GUID-2F932886-E7EF-4A46-92A9-583F5A536381">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aAddr</codeph></p></entry>
+<entry><p>Address of the destination register.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8 aWriteVal</codeph></p></entry>
+<entry><p>The byte to be written</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8* aReadDataP</codeph></p></entry>
+<entry><p>Pointer to the start of the byte which is to be read into.</p><p>If
+this parameter is NULL, then a read-after-write operation is not performed.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><p>None</p></section>
+<section id="GUID-98F2E1F4-51FF-4A4B-851F-05064A6A5423"><title>SetupCIMIoRead()</title><p>The
+function declaration for the <xref href="GUID-B8663276-D651-30F7-961B-446D9266A9AD.dita"><apiname>SetupCIMIoRead()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C void SetupCIMIoRead(TUint32 aAddr, TUint8* aReadDataP);</codeblock><p><b>Description</b></p><p>Set the session to perform a read of a single
+byte of data from the card.</p><p><b>Parameters</b></p><table id="GUID-E4CCA254-4053-4775-A966-A51EE7548F8B">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aAddr</codeph></p></entry>
+<entry><p>Address of the source register.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8* aReadDataP</codeph></p></entry>
+<entry><p>Pointer to the byte which is to be read into.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><p>None</p></section>
+<section id="GUID-55F85DDD-E0A3-4718-8A79-9F1FF5CA2BBD"><title>SetupCIMIoWriteMultiple()</title><p>The
+function declaration for the <xref href="GUID-61195EA4-BA52-3B44-ACAD-56ACDCA0F5B3.dita"><apiname>SetupCIMIoWriteMultiple()</apiname></xref> method
+is:</p><codeblock xml:space="preserve">IMPORT_C void SetupCIMIoWriteMultiple(TUint32 aAddr, TUint32 aLen, TUint8* aDataP, TBool aInc);</codeblock><p><b>Description</b></p><p>Sets the session to perform a multi-byte (or multi-block) transfer
+of data to the card.</p><p><b>Parameters</b></p><table id="GUID-0888B150-DE56-459B-B469-8BE8E7DCB48D">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aAddr</codeph></p></entry>
+<entry><p>Address of the destination register.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint32 aLen</codeph></p></entry>
+<entry><p>The number of bytes to be transferred.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8* aDataP</codeph></p></entry>
+<entry><p>Pointer to the start of the source buffer.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TBool aInc</codeph></p></entry>
+<entry><p>Specifies whether the auto-increment feature is enabled or not.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><p>None</p></section>
+<section id="GUID-99F6C933-B8F1-4C88-A7D9-8AB21ACF85C3"><title>SetupCIMIoReadMultiple()</title><p>The
+function declaration for the <xref href="GUID-1F08ED19-FEB5-3822-9473-C36F6D3B0BAF.dita"><apiname>SetupCIMIoReadMultiple()</apiname></xref> method
+is:</p><codeblock xml:space="preserve">IMPORT_C void SetupCIMIoReadMultiple(TUint32 aAddr, TUint32 aLen, TUint8* aDataP, TBool aInc);</codeblock><p><b>Description</b></p><p>Sets the session to perform a multi-byte (or multi-block) transfer of
+data from the card.</p><p><b>Parameters</b></p><table id="GUID-641E988E-7B86-4536-B243-2D673C3BC9EF">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aAddr</codeph></p></entry>
+<entry><p>Address of the source register.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint32 aLen</codeph></p></entry>
+<entry><p>The number of bytes to be transferred.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8* aDataP</codeph></p></entry>
+<entry><p>Pointer to the start of the destination buffer.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TBool aInc</codeph></p></entry>
+<entry><p>Specifies whether the auto-increment feature is enabled or not.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><p>None</p></section>
+<section id="GUID-7769CF10-2C24-47B0-877B-6193C1F51F23"><title>SetupCIMIoModify()</title><p>The
+function declaration for the <xref href="GUID-3985761B-AE9D-3408-94DC-33689B77E209.dita"><apiname>SetupCIMIoModify()</apiname></xref> method
+is:</p><codeblock xml:space="preserve">IMPORT_C void SetupCIMIoModify(TUint32 aAddr, TUint8 aSet, TUint8 aClr, TUint8* aReadDataP);</codeblock><p><b>Description</b></p><p>Sets the session to perform a safe read-modify-write operation on a single
+byte of data on the card.</p><p><b>Parameters</b></p><table id="GUID-23EBA64A-F3B6-454C-BC46-F474CC14B990">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint32 aAddr</codeph></p></entry>
+<entry><p>Address of the destination register.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8 aSet</codeph></p></entry>
+<entry><p>A bitmask of the values to be set: pass 1 where the bit is to be
+set, otherwise pass 0.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8 aClr</codeph></p></entry>
+<entry><p>A bitmask of the values to be cleared: pass 1 where the bit is to
+be cleared, otherwise pass 0.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint8* aReadDataP</codeph></p></entry>
+<entry><p>If this value is not NULL, then the result of the modification is
+returned in this parameter.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><p>None</p></section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-365283F1-54B4-519A-81EC-9B5018896DDE-master.png has changed
Binary file Adaptation/GUID-365283F1-54B4-519A-81EC-9B5018896DDE_d0e35432_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-36CD752C-45FE-5BFE-A695-11DF085F301F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-36CD752C-45FE-5BFE-A695-11DF085F301F" xml:lang="en"><title>Debug
+Macros</title><shortdesc>Describes the macros that can be used to debug the bootstrap.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The macro have no effect in non-debug builds of the bootstrap, when <codeph>CFG_DebugBootRom</codeph> is
+FALSE. These macros do not modify any registers, but they may modify flags.
+See <xref href="GUID-2E4F8732-F253-5E0D-9A37-9476541E6004.dita">Platform-Specific
+Configuration Header</xref>. </p>
+<section id="GUID-F4EEC165-2D4D-40A7-AB7D-3CB6C6643A19"><title>PRINT</title><codeblock id="GUID-F8C872B4-0D57-5F4F-AE6D-E87264F7E30D" xml:space="preserve">PRINT text</codeblock><p>Sends
+the quoted text string <codeph>text</codeph> to the debug port. </p> </section>
+<section id="GUID-1194D16D-737B-48D9-A7C6-4928852943D9"><title>PRTLN</title><codeblock id="GUID-56763E7B-217E-5C5C-AF9D-303EAF36BD70" xml:space="preserve">PRTLN text</codeblock><p>Appends
+a new-line character to the quoted text string <codeph>text</codeph>, and
+sends the resulting text to the debug port. </p> </section>
+<section id="GUID-BE00E8CD-12DD-4D35-B5FF-FE417D7F3902"><title>DWORD</title><codeblock id="GUID-94DEABA8-4591-5321-9820-FA60E7F354B7" xml:space="preserve">DWORD reg, text</codeblock><p>Sends
+the quoted text string <codeph>text</codeph> to the debug port followed by
+the value of ARM general register <codeph>reg</codeph> as an 8 digit hexadecimal
+number followed by a new-line character. </p> </section>
+<section id="GUID-BE097999-2D84-4819-AF0B-6CAA7BCA44F5"><title>MEMDUMP</title><codeblock id="GUID-582327F5-CF6D-5339-A98C-498110BB16AC" xml:space="preserve">MEMDUMP base, len</codeblock><p>Dumps
+an area of memory of length <codeph>len</codeph> starting at <codeph>base</codeph>,
+specified in hexadecimal, and sends it to the debug port. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-3722B946-07CF-4AEA-B228-E50642D6B5BE.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,85 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-3722B946-07CF-4AEA-B228-E50642D6B5BE" xml:lang="en"><title>Register Access Implementation Guide</title><shortdesc>Describes the implementation of the Register Access platform
+service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>A ASSP hardware register is a physical interface to an item of
+hardware which contains values, such as bit fields, for controlling
+ASSP features.</p>
+<section id="GUID-514E76B0-009C-48D4-935C-FBE48FDD3631-GENID-1-2-1-10-1-5-1-8-1-1-9-1-4-1-3-2"><title>ASSP</title><p> An ASSP (Application Specific Standard Product) is a class of
+integrated circuit. Different ASSPs have different architectures and
+instructions sets. The <xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita"><apiname>AsspRegister</apiname></xref> class provides device driver writers with a simple interface to
+access ASSP registers. Hardware implementers must provide the specified
+functionality on a given platform and ASSP by writing the appropriate
+machine instructions. </p></section>
+<section id="GUID-DBEB025D-B457-493B-A052-274801C21B1E"><title>Pre-requisites</title><p>Before the implementing a register access implementation, the
+following must be decided:</p><ul>
+<li><p>The area in memory to which the registers are mapped. The start
+of this memory region is known as the base address.</p></li>
+<li><p>The location of each register in terms of an offset from the
+base address.</p></li>
+</ul><p>The above information will be present in a specific header
+file which is used by any device driver that uses this API. This header
+file also contains other information required to access the registers,
+such as:</p><ul>
+<li><p>constants for bit field offsets</p></li>
+<li><p>bit field values</p></li>
+</ul></section>
+<section id="GUID-CF41655A-5B14-47C4-811A-C9F9352B0688"><title>Implementation</title><p>To provide register access, hardware implementers need to implement
+the <xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita"><apiname>AsspRegister</apiname></xref> class. </p><p>Generic access to a register is provided in the form of three
+operations on a hardware register: read, write and modify. All these
+functions can be called in any context. </p><p>Symbian platform provides
+the class header and inline implementations of the 8, 16 and 32-bit
+wide functions. You must implement all the register modify functions
+and all functions to access 64-bit wide registers. You may also need
+to replace the inline 8, 16 and 32-bit wide register read and write
+functions if the ASSP contains write-only registers. </p> <p>You must
+implement these functions atomically so that there is no possibility
+of another thread or interrupt service routine accessing the contents
+of the register before the function returns. Where you cannot implement
+the function with a single machine instruction you must disable interrupts
+during the register operation (if you are working with a single core
+architecture) or wrap a spinlock around the register operation (if
+you are working with a multicore architecture). </p> <p>There are
+three cases in which you must enforce atomicity with interrupt disabled
+or use of spinlocks. </p> <ul>
+<li id="GUID-3D835089-4626-584F-9FB1-EBD9CBF7A8D0"><p>The modify operations
+involve reading the register, taking a local copy, changing the local
+copy and writing it back to the register and cannot be performed with
+a single machine instruction. </p> </li>
+<li id="GUID-939FFD27-60EB-5465-95B7-A3654FBB5941"><p>Operations on
+write-only registers involve maintaining a copy of the current contents
+of the register within the <xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita"><apiname>AsspRegister</apiname></xref> class. All write and modify operations therefore cannot be performed
+with a single machine instruction. </p> </li>
+<li id="GUID-26D38D30-DFF3-5DCD-8163-157A228C50D6"><p>Some architectures
+contain 64-bit registers. In this case, 64-bit operations involve
+at least two machine instructions. </p> </li>
+</ul><p>Baseport implementations of the Register Access platform service
+come in the form of a ASSP library (or DLL). To avoid the need for
+each device driver which uses the ASSP register class having to specify
+a baseport specific library file corresponding to the ASSP library,
+the name of the baseport specific library file should instead be included
+in a file used to define other variant specific settings such as the
+CPU core type, the memory model and the name of the variant. Each
+baseport will have a file called <filepath>variant.mmh</filepath>,
+where <codeph>variant</codeph> is the name of the baseport to be used.
+An example of this being used in a <filepath>variant.mmh</filepath> file is:</p><codeblock xml:space="preserve">#if defined(__USING_BASPORT__)
+library   VariantTarget(basport_name,assp_library)
+#endif
+</codeblock><note>baseport_name is the name of the variant and assp_library
+is the name of the ASSP specific library file.</note><p>In order to
+specify which baseport assp register set up is to be used in the client
+projects for this baseport, the following line is included in the
+MMP file of those projects</p><codeblock xml:space="preserve">#define __USING_BASEPORT___</codeblock></section>
+</conbody><related-links>
+<link href="http://developer.symbian.org/main/documentation/reference/s3/pdk/GUID-16AED228-539F-4BF7-A7FD-9A01FF1A9A84.html.dita">
+<linktext>SMP - Locking</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-372D2B88-2035-44A5-82CF-57FF131DDEBE.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE reference
+  PUBLIC "-//OASIS//DTD DITA Reference//EN" "reference.dtd">
+<reference id="GUID-372D2B88-2035-44A5-82CF-57FF131DDEBE" xml:lang="en"><title>Platform Service</title><shortdesc>A service that is intended to be used by any part of the
+OS.</shortdesc><prolog><metadata><keywords/></metadata></prolog><refbody>
+<section id="GUID-4597B788-2A72-4727-8FA1-34773E29AB9B"> 			 		</section>
+</refbody></reference>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-3773A78D-F491-52EB-AA1D-201636497F28.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-3773A78D-F491-52EB-AA1D-201636497F28" xml:lang="en"><title>Power Management
+Tutorials</title><shortdesc>This topic describes how to implement a power controller in a base
+port.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>A power controller is a kernel extension that manages the power management
+hardware of a phone, for example on-chip power management controllers and
+oscillators. </p>
+</conbody><related-links>
+<link href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita"><linktext>Power Management</linktext>
+</link>
+<link href="GUID-113B3755-1797-5D1B-8E07-8A18F5FE1504.dita"><linktext>Power States</linktext>
+</link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-37B8243E-027A-49D0-A896-27946DAC9052.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,114 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-37B8243E-027A-49D0-A896-27946DAC9052" xml:lang="en"><title>Baseport Template Tools Guide</title><shortdesc>Describes the tools required needed to implement and test
+the Baseport Template platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-BEE8A42D-5A75-4F2A-8B94-2FA43A9143A8"><title>Build
+tools</title>             <p>The following build tools are available: </p><table id="GUID-F7659F0C-0991-43D0-A077-2C0581A0BDBE">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry>Name</entry>
+<entry>Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">BUILDROM</xref></entry>
+<entry><codeph>BUILDROM</codeph> is a unified ROM building front end.
+It invokes <codeph>ROMBUILD</codeph> to build the ROM image and <codeph>ROFSBUILD</codeph> to build the ROFS image.</entry>
+</row>
+<row>
+<entry><xref href="GUID-003D2C5B-09DC-5BD1-AF45-A0FCB56F567B.dita">ROMBUILD</xref></entry>
+<entry><codeph>ROMBUILD</codeph> is the Symbian platform binary XIP
+(execute-in-place) ROM builder. It is normally invoked through <codeph>BUILDROM</codeph>.</entry>
+</row>
+<row>
+<entry><xref href="GUID-BF04B68E-7F77-5D99-A0F6-2842758EFD4D.dita">ROFSBUILD</xref></entry>
+<entry><codeph>ROFSBUILD</codeph> is the Symbian platform non-XIP
+ROFS builder. It is normally invoked through <codeph>BUILDROM</codeph>.</entry>
+</row>
+<row>
+<entry><xref href="http://developer.symbian.org/wiki/index.php/Build_Package/iMaker" scope="external">iMaker</xref></entry>
+<entry><codeph>iMaker</codeph> is a ROM-image creation tool that creates
+a flash image from a set of Symbian binary and data files. <codeph>iMaker</codeph> mainly functions on top of BUILDROM.</entry>
+</row>
+<row>
+<entry><xref href="GUID-922E4771-C1FD-5C88-9C11-57499684DB97.dita">SPITOOL</xref></entry>
+<entry><codeph>SPITOOL</codeph> is a utility tool to create static
+plug-in information (SPI) files.</entry>
+</row>
+<row>
+<entry><xref href="GUID-7AB0C7E2-8B7C-5CC3-BAA5-15AA59F31181.dita">InterpretSIS</xref></entry>
+<entry><codeph>InterpretSIS</codeph> is a command-line tool used to
+install SIS files. It can be invoked either through <codeph>BUILDROM</codeph> or directly.</entry>
+</row>
+<row>
+<entry><xref href="GUID-51C5DC6C-0CEE-5F44-8578-AEFBEF90FA4D.dita">READIMAGE</xref></entry>
+<entry><codeph>READIMAGE</codeph> is a command-line tool that provides
+readable data from a ROM, ROFS, or E32 image.</entry>
+</row>
+<row>
+<entry><xref href="GUID-CC04A14B-A839-5613-820D-F1E65EB2DF7F.dita">MAKSYM/MAKSYMROFS</xref></entry>
+<entry><codeph>MAKSYM/MAKSYMROFS</codeph> is a tool to create a readable
+symbol file listing the virtual addresses of the exported functions.</entry>
+</row>
+<row>
+<entry><xref href="GUID-9CF985F1-C100-5999-9410-58B7865A1E18.dita">Obey
+Files</xref></entry>
+<entry><codeph>OBEY</codeph> files are standard text files containing
+statements that are used to control the operation of the ROM building
+tools.</entry>
+</row>
+<row>
+<entry><xref href="http://developer.symbian.org/wiki/index.php/Raptor_Build_System" scope="external">Symbian Build System v2</xref></entry>
+<entry><codeph>SBSv2</codeph> is a tool for building Symbian platform
+and applications developed for Symbian platform. It helps you build
+a set of components, or the complete Symbian platform, on Windows
+and Linux platforms for the ARMv5, TOOLS2 and WINSCW target platforms.
+They also provide a reference to the file formats used as input to
+the build tools. For more information about SBSv2, see the Symbian
+Build System v2  documentation that is provided with the Platform
+Developer Toolkit. </entry>
+</row>
+</tbody>
+</tgroup>
+</table>         </section>
+<section id="GUID-565FDA0A-67BD-46D7-9673-D35B83EF09AC"><title>Emulators</title><p>The following emulators are available: </p><table id="GUID-AC6E5AC1-0344-4984-93CE-E721F35A6BFC">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry>Name</entry>
+<entry>Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="http://developer.symbian.org/wiki/index.php/Syborg_&amp;_QEMU" scope="external">QEMU</xref></entry>
+<entry><codeph>QEMU</codeph> is an open source emulator which can
+be used to run and debug a Symbian ROM image on a PC.</entry>
+</row>
+<row>
+<entry><xref href="http://developer.symbian.org/wiki/index.php/Syborg_&amp;_QEMU" scope="external">Syborg</xref></entry>
+<entry> <codeph>Syborg</codeph> is a Symbian baseport for use with
+QEMU.</entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+</conbody><related-links>
+<link href="GUID-0C84FD76-87B2-4AD1-B23A-2C5C8668BC4C.dita"><linktext>Base
+Porting Guide</linktext></link>
+<link href="GUID-57989FF8-5E8F-4C8A-9D38-169AFCA4C078.dita"><linktext>Baseport
+Template Implementation Guide</linktext></link>
+<link href="GUID-627FC480-AF4F-4B23-8671-6E0A0DABA0EF.dita"><linktext>Baseport
+Template Testing Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-388004AF-6F99-4BBB-A8E0-D75DC5B6790C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,134 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-388004AF-6F99-4BBB-A8E0-D75DC5B6790C" xml:lang="en"><title>Test
+Application</title><shortdesc>This document describes a simple application which is used to load
+a device driver and test its functionality.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-F3E3C80E-D74B-4846-A614-B69D653130CA">       <title>Testing
+device drivers</title>       <p>Drivers, apart from kernel extensions, are
+not automatically started by the Kernel, so they must be explicitly loaded
+by application. </p> <p>When testing an LDD-PDD model driver, it is a general
+practice to write a simple test application that loads the LDD and PDD by
+name, opens a logical channel, and calls the driver API to test the driver's
+functionality. </p> <p>The following shows a command line test application
+that does this: </p> <codeblock id="GUID-59C1DE97-3018-5B58-AF11-72A1F44B4C0F" xml:space="preserve">/** E32Main - Application, exe main entry point. */
+GLDEF_C TInt E32Main()
+    {
+    ...
+    // Load the PDD. This user API will load the PDD DLL by name 
+    // and also enable the loader to search for the PDD object 
+    // by name.
+    r = User::LoadPhysicalDevice(KExDriverPdd);
+
+    // PDD loading is considered successful, if either it is 
+    // loaded now or it is already loaded.
+    test((r==KErrNone)||(r==KErrAlreadyExists));
+
+    // Load the LDD. This user API loads the LDD DLL by name 
+    // and also enable the loader to search for the LDD object 
+    // by name.
+    r = User::LoadLogicalDevice(KExDriverLdd);
+
+    // LDD loading is considered successful, if either it is 
+    // loaded now or it is already loaded.
+    test((r==KErrNone)||(r==KErrAlreadyExists));
+    ...
+
+    // Get device capabilities
+    ...
+
+    // Open the device with reference to the driver name.    
+    r = device.Open(KDriverName);
+    if (r==KErrNone)
+        {
+        ... // do required operations
+        // Close the device. This handle is required only to 
+        // get any device related information from the LDD factory 
+        // object.
+        device.Close();
+        }
+
+    // RExDriverChannel is an RBusLogicalChannel derived class, which provides a user side 
+    // handle to a logical channel. It defines the driver interface.
+    RExDriverChannel ldd;
+
+    // Open the logical channel to the driver for unit 1. This is a 
+    // user-side wrapper function for the    
+    // RBusLogicalChannel::DoCreate() API. DoCreate() is 
+    // called in Open() for unit 1.
+    //
+    r = ldd.Open(KUnit1);
+    test(r==KErrNone);
+
+    // Call the driver API using the RExDriverChannel interface and 
+    // test for the functionality
+    ...
+
+    // Close the logical channel
+    ldd.Close();
+
+    // Free the logical device / LDD
+    r=User::FreeLogicalDevice (KDriverName);
+    test(r==KErrNone);
+
+    // Instead of directly using the PDD name, get the PDD 
+    // factory object name and append the extension name, to 
+    // unload the PDD.
+    TName pddName(KDriverName);
+    _LIT(KVariantExtension, ".pdd");
+    pddName.Append(KVariantExtension);
+
+    // Free the PDD, resulting in freeing the PDD factory object   
+    r=User::FreePhysicalDevice (pddName);
+    test(r==KErrNone);
+
+    ...
+    }</codeblock> <p>If the driver is a kernel extension, then the Kernel
+loads the driver when it boots, so an application does not need to load the
+driver explicitly. Applications simply open a channel to the driver and call
+the driver API as required. </p> <p>The <xref href="GUID-D16A6778-660E-302A-A3B5-DD98A088B7EC.dita"><apiname>RTest</apiname></xref> class provides
+macros and functions that can be used in test applications. It provides macros
+to validate a return value against an expected value, and to leave giving
+the line number where the error occurred. It also provides macros to print
+debug messages, to group the test sets, and so on. </p> <codeblock id="GUID-EB34D6B4-D9AC-5F47-BBEA-DBB04BBB5DEF" xml:space="preserve">// Create RTest object (test framework)
+LOCAL_D RTest test(_L("Tutorial Driver"));
+
+GLDEF_C TInt E32Main()
+    {
+    // Initialize the test object with a title    
+    test.Title();
+
+    // RTest::Starts() starts a set of tests
+    test.Start(_L("Load Physical Device"));
+    ...
+    // RTest::Next() starts a new set of tests
+    test.Next(_L("Open Channel"));
+    ...
+    // Test if a condition is true. If not, the application leaves 
+    // displaying the line number and error type
+    test(r==KErrNone)
+    ...
+    // Prints a string to the screen
+    test.Printf(_L(“&lt;display string %d&gt;”),r);
+    ...
+    // End the tests     
+    test.End();
+    }</codeblock> <p>The drivers developed and built can be tested on the
+target hardware. The debug or release versions of the driver are built into
+the ROM and downloaded to the target. This is done either by using a MMC card,
+USB, Serial or JTAG interface, as supported by the particular hardware board.
+Once the board is powered on or reset, Symbian platform boots and the text
+shell is displayed (assuming a text shell ROM image). To test an LDD-PDD driver,
+run the test application from the command line. </p> <p>If debug messages
+are enabled in the driver, by using <codeph>KTRACE</codeph> or <codeph>BTRACE</codeph>,
+the messages can be viewed on the LCD screen, or through a connected COM port,
+using the HyperTerminal application on a PC. </p>     </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-38FD682F-656B-48F7-A553-50BC4F1FB4BB.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE reference
+  PUBLIC "-//OASIS//DTD DITA Reference//EN" "reference.dtd">
+<reference id="GUID-38FD682F-656B-48F7-A553-50BC4F1FB4BB" xml:lang="en"><title>Base Port</title><shortdesc>The base code of the Symbian platform is structured so
+that generic code is separated from hardware-specific code. This means
+that porting Symbian to new hardware requires modification or creation
+of hardware-specific code only. This is what is known as a base port.</shortdesc><prolog><metadata><keywords/></metadata></prolog><refbody>
+<section id="GUID-96E1681F-C390-4744-9570-3F72198BC301"> 			 		</section>
+</refbody></reference>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-3A1BCF46-FFBB-4E4F-A73A-6E68254B23FF.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-3A1BCF46-FFBB-4E4F-A73A-6E68254B23FF" xml:lang="en"><title>SDIO
+Implementation Quick Start</title><shortdesc>Provides a collection of documents that describe SDIO (Secure Digital
+Input Output) implementation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The implementation guide describes how SDIO is included in a build of the
+Symbian platform. </p>
+<p><xref href="GUID-9BBDFF77-5E2C-4E13-BEB3-716CC80B3375.dita">SDIO Implementation
+Guide</xref></p>
+<p>The testing guide describes techniques that can be used for testing the
+SDIO functionality.</p>
+<p><xref href="GUID-2234BCF5-41CC-457A-BF1B-C4AB47931DB8.dita">SDIO Implementation
+Testing Guide</xref></p>
+<p>The tools guide describes the tools that can be used to test an implementation
+of SDIO.</p>
+<p><xref href="GUID-6B2221F2-A598-4677-A2D3-40FF27C7373F.dita">SDIO Implementation
+Tools Guide</xref></p>
+<p>The build guide describes how to include the SDIO adaptation in a ROM image.</p>
+<p><xref href="GUID-7E357DA2-67AD-403A-B4E1-7CB83E75136F.dita">SDIO Implementation
+Build Guide</xref></p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-3A30DA16-ECA8-5639-A9DC-6BE2AD55420B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-3A30DA16-ECA8-5639-A9DC-6BE2AD55420B" xml:lang="en"><title>I2C Technology Guide</title><shortdesc>This topic describes the Inter Integrated Circuit (I2C)
+bus technology. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-D58AC61D-AA0B-4F8C-A0B7-8762E9A4DD83"><title>Introduction</title> <p>The I2C is a serial bus technology invented by Philips. The I2C
+is a multi master serial interface used by the low power peripherals
+to exchange data. The I2C supports different modes of data transfer
+and three commonly used modes are: </p> <ul>
+<li id="GUID-F6E78BBF-D1D3-5947-A2CA-E33D31B38D67"><p> <i>Standard</i> mode supports 100Kbps data transfer </p> </li>
+<li id="GUID-FE480522-51A6-5A8B-99D3-1324E594220F"><p> <i>Fast</i> mode supports 400Kbps data transfer </p> </li>
+<li id="GUID-5A7AA88F-C3FF-55C1-B9E3-1FEBDF899DA8"><p> <i>High speed </i> mode supports 3.4Mbps data transfer </p> </li>
+</ul> </section>
+<section id="GUID-E820265D-FBF1-47CC-BE37-27CD9BD8BA61"><title>Architecture</title> <p>The I2C bus contains 2 bi-directional lines, a serial clock (SCL)
+and serial data (SDA) lines. In the I2C bus, more than one device
+could act as Master device. There can be only one master device active
+at a given time. The master device initiates the communication and
+slave responds to the master. The master and slave devices can be
+interchanged after a data <codeph>STOP</codeph> signal is sent from
+the master. The master device can address more than one slave at a
+time. </p> <fig id="GUID-2A0703D3-013C-59C6-86B1-98513D484586">
+<title>              I2C Bus            </title>
+<image href="GUID-B0FA9741-CB42-560F-A13E-78FAA57F7871_d0e93496_href.png" placement="inline"/>
+</fig> <p>The master device can read and write data to the slave device.
+The I2C bus uses 7 or 10 bit address. </p> </section>
+<section id="GUID-F0DEADCE-ED35-4822-BA73-6068CB2CAA98"><title>Features</title> <p>The features of the I2C bus are: </p> <ul>
+<li id="GUID-B63B7E4E-7C22-5AB3-803A-9B7E42B36A80"><p>the master device
+can send and receive data from the slave device </p> </li>
+<li id="GUID-9284798B-029F-52D0-ADEB-68726A430B5A"><p>the I2C bus
+uses 7 or 10 bit address </p> </li>
+<li id="GUID-9A9175F0-B6D9-52CA-818B-C9B028EE8DFE"><p>only uses 2
+bi-directional lines for communication </p> </li>
+<li id="GUID-B32C597E-1973-5F4B-8E2B-42C8E5696504"><p>multiple master
+device can be connected to the same bus </p> </li>
+</ul> </section>
+<section id="GUID-97A176BF-0300-4A1C-81D2-3FA5A4315456"><title>Communication</title> <p>The first byte from the master is used to address the slave device.
+In the first byte the master sends the address and read/write signal
+to the slave. There are three types of messages: </p> <ol id="GUID-4A10967B-8F72-5145-82F1-20C438B839D3">
+<li id="GUID-494BEC9B-22C6-535C-87C4-B9D5572F0F3C"><p>master just
+reads data from the slave </p> </li>
+<li id="GUID-B50B3F0A-35B1-528F-B2DD-9FF5709FAF1B"><p>master just
+writes data to the slave </p> </li>
+<li id="GUID-31A59E28-9677-535C-A5FB-990F40E53539"><p>master reads
+and writes data </p> </li>
+</ol> <p>The communication is initiated with a start signal and completed
+with a stop bit. In the third type of message the master starts the
+communication with a start signal with a read or write bit to the
+slave. The process continues until the master has completed the read
+and write tasks. The communication is terminated with a stop signal. </p> </section>
+<section id="GUID-64145C1A-25E6-4968-94B7-7E6A385C5F0F"><title>Typical
+Uses</title> <p>The typical uses of I2C bus are: </p> <ul>
+<li id="GUID-AF71E9EF-A299-5DAF-85FA-01C34DEE1425"><p>to read data
+from various flash devices like EEPROM and SDRAM </p> </li>
+<li id="GUID-E118CF39-8393-5476-8A61-CD36413EBF99"><p>to control LCD </p> </li>
+<li id="GUID-5B334072-676B-5516-93A8-626BDC44E132"><p>to read real
+time clock data </p> </li>
+</ul> </section>
+</conbody><related-links>
+<link href="http://www.nxp.com/acrobat/literature/9398/39340011.pdf.dita">
+<linktext>I2C bus specification v2-1 Jun 2000</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-3A625B23-354E-5CB4-98CF-FF53AD724FA0.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-3A625B23-354E-5CB4-98CF-FF53AD724FA0" xml:lang="en"><title>Dealing with Demand Paging</title><shortdesc>When demand paging is used, the contents of memory are
+available to a program when they are required (“on demand”). When
+the contents are no longer required, the RAM can be used for other
+content.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Demand paging is a change to how the kernel can use RAM from Symbian
+platform v9.3. This topic describes the possible results for base
+port. </p>
+<p>When demand paging is used, the contents of memory are available
+to a program when they are required - that is, 'on demand'. When the
+contents are no longer required, the RAM can be used for other content.
+In this way, the total RAM required to store content is less than
+if it were all permanently available. </p>
+<p>The Device Driver Guide provides <xref href="GUID-469EC7BB-8697-57FE-A487-016882A0BEA8.dita#GUID-469EC7BB-8697-57FE-A487-016882A0BEA8/GUID-E382AA71-8BB5-5567-8578-51598D3131FD">Suggested techniques for mitigating the effects of demand paging</xref> for writers of device drivers. These recommendations can result
+in a more ‘multithreaded’ base-port. This may have the following impact
+that needs to be considered: </p>
+<ul>
+<li id="GUID-DB6CC462-FB46-5D3B-8BAA-5B21FA06AF9D"><p>A base-port
+component may provide services to device drivers, exposing to them
+a shared resource; either hardware or software: </p> <ul>
+<li id="GUID-6B9E9433-EA19-54AE-B7A5-6E2C3341723B"><p>hardware - may
+be a hardware controller whose non-instantaneous operation, once initiated,
+cannot be disturbed until it completes </p> </li>
+<li id="GUID-92AD6E2B-34CC-59B4-8D52-FD739C3DD841"><p>software - may
+be a list of requests for services. </p> </li>
+</ul> </li>
+<li id="GUID-45F7D284-C216-5684-8C7B-2958C809B1BC"><p>A hardware component
+has a control interface that can be used by a number of drivers. Operations
+on the control interface although near instantaneous, are not atomic
+and cannot be interrupted. </p> </li>
+</ul>
+<p>In the case of the base-port component, when the state of a resource
+needs to be protected from the effects of pre-emption for a non-negligible
+period of time, the recommended approach is to use mutual exclusion,
+protecting the resource with a mutex: unless there is any chance that
+the same driver may trigger the same operation before the previous
+one completed. For example, when operations are non-blocking and happen
+in a context different from the initiator’s, a <xref href="GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953.dita"><apiname>NFastMutex</apiname></xref> should suffice. </p>
+<p>An example of the hardware component situation is a set-clear control
+interface, where a pair of registers (one containing the bits to be
+set, the other the bits to be cleared) have to be written to produce
+the desired change. If the operation is pre-empted after bits are
+set but before they are cleared for a desired final output, and a
+new set-clear operation is initiated, the final state of the interface
+may be undetermined. Pre-emption protection in this case is achieved
+by simply locking the Kernel using <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-7CBBF72B-4519-38DD-92CA-38AF636AFD8A"><apiname>NKern::Lock()</apiname></xref> before the operation starts and unlocking it with <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-A1A42137-906C-30F1-AF61-4F786FC372DE"><apiname>NKern::Unlock()</apiname></xref> after it completes. If the interface is to be used from an interrupt
+context disabling all interrupts is sufficient to protect against
+thread concurrency. </p>
+</conbody><related-links>
+<link href="GUID-90B5FDD9-7D59-5035-BF53-2B177655DCD6.dita"><linktext>Migration
+                Tutorial: Demand Paging and Internal MMC Cards</linktext>
+</link>
+<link href="GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3.dita"><linktext>Migration
+Tutorial: Demand                 Paging and Media Drivers</linktext>
+</link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-3A785F02-F4AA-432C-9331-8827029BB384.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-3A785F02-F4AA-432C-9331-8827029BB384" xml:lang="en"><title>Status
+Query</title><shortdesc>This document describes how the status of an asynchronous request
+is maintained and monitored.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>A <xref href="GUID-E0B34F3E-D4C4-3232-B8B1-7DB35B454646.dita"><apiname>TRequestStatus</apiname></xref> object is used to monitor the status
+and result of the asynchronous request. This object maintains the status of
+the request at various stages and finally contains the request result. The
+driver uses the status object when performing operations on the request such
+as cancelling, completing, or managing multiple similar requests. </p>
+<p>Initially, when the request is made, the Kernel changes the status to <xref href="GUID-B0778F54-C5DD-3307-A1E2-0DD339C4E4E7.dita"><apiname>KRequestPending</apiname></xref>.
+After completion of the request, the status is changed to <xref href="GUID-6AB86DE7-83FE-35AE-9528-AF9B3247E2D5.dita"><apiname>KRequestComplete</apiname></xref> to
+indicate request completion. It also contains the result of the request, which
+can indicate an error or failure of the request. <xref href="GUID-E0B34F3E-D4C4-3232-B8B1-7DB35B454646.dita#GUID-E0B34F3E-D4C4-3232-B8B1-7DB35B454646/GUID-43246976-3D7B-3B25-9C32-42E02E9ED674"><apiname>TRequestStatus::Int()</apiname></xref> returns
+the request result. </p>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-3AFE0D8B-FB9B-5355-A63B-FB71DD13E7D0-master.png has changed
Binary file Adaptation/GUID-3AFE0D8B-FB9B-5355-A63B-FB71DD13E7D0_d0e73917_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-3B6544CD-FA6E-5AB2-AA63-61186F52167D.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,231 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-3B6544CD-FA6E-5AB2-AA63-61186F52167D" xml:lang="en"><title>Controllable
+Power Resources</title><shortdesc>This topic explains how power resources were controlled in older
+releases of Symbian platform. For later releases see the Power Resource Manager
+documentation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This documentation is retained for reference for those working with hardware
+or software that is based on older versions of Symbian platform version (in
+particular old release 9.5). For later releases see the <xref href="GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9.dita">Porting
+the Power Resource Manager</xref> documentation.</p>
+<p>Controllable power resources are defined as being any device resource,
+such as voltages on power-lines or clocks, which can be independently enabled,
+disabled or modified under software control. </p>
+<p>The following hardware block diagram is an example of the way power resources
+might be arranged: </p>
+<fig id="GUID-41113C18-2C87-5DEA-9D05-31083F51269A">
+<title>Example power resource arrangement</title>
+<image href="GUID-622D6337-E60A-5252-8B2B-BA8232927453_d0e29152_href.png" placement="inline"/>
+</fig>
+<p>There is no default support or default implementation for controllable
+power resources in the generic layers of Symbian platform. They must be managed
+by the base port. </p>
+<p>We suggest that the management of controllable power resources (the resource
+manager) be implemented in the Variant DLL or the ASSP DLL. This allows the
+resource manager to be up and running by the time peripheral drivers, which
+might also be kernel extensions, are loaded. See the <xref href="GUID-984C2A0D-36BE-5A99-9D65-3F8791C669FF.dita#GUID-984C2A0D-36BE-5A99-9D65-3F8791C669FF/GUID-95C34114-F986-5428-9D40-5CF64429CDBD">ASSP/Variant Architecture</xref> and the <xref href="GUID-ECAC3FF3-CDB2-5153-AD76-90732BA83726.dita#GUID-ECAC3FF3-CDB2-5153-AD76-90732BA83726/GUID-F55D88DB-7DE1-5069-BAE7-A7FE3750D065">ASSP/Variant
+Tutorials</xref>. </p>
+<p>A suggested implementation has the instance of the <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita"><apiname>Asic</apiname></xref> derived
+class owning a pointer to the resource manager object. The interface class
+for the ASSP or Variant could then have an exported or an inline member function
+to return a pointer to this resource manager object. Peripheral drivers are
+expected to link against either the ASSP DLL, or the Variant DLL, or both. </p>
+<p>For example, for a device that has a Variant and an ASSP: </p>
+<codeblock id="GUID-049CEE21-944A-589A-9F1B-8F031D681198" xml:space="preserve">class MyVariant : public MyASSP
+    {
+public:
+    Init1();
+    Init3();
+    // Other mandatory Asic-derived member functions
+    ...
+public:
+    ResourceManager* myResMgrPtr;
+    ...
+    };
+      </codeblock>
+<p>where class <codeph>MyASSP</codeph> is derived from class <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita"><apiname>Asic</apiname></xref>. </p>
+<codeblock id="GUID-E8346FFB-1B0F-5482-9DF7-207B1B1948F8" xml:space="preserve">GLREF_D MyVariant TheVariant;</codeblock>
+<codeblock id="GUID-CEF1F0C7-62E4-52B1-9830-DBD32B2BE8CE" xml:space="preserve">class TMyVariant
+    {
+public:
+    inline static ResourceManager* ResourceManager()
+        {return(TheVariant.myResMgrPtr);}
+    // other exported methods
+    ...
+    };
+      </codeblock>
+<p>where <codeph>TMyvariant</codeph> is the Variant interface class, and <codeph>ResourceManager</codeph> is
+the resource manager class. </p>
+<p>The resource manager can be declared as a global object at the Variant
+(or ASSP) scope and can therefore be created when this component is first
+loaded. In this case, the <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita#GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D/GUID-FE55E398-7F08-384F-9E74-2CC2E45002B6"><apiname>Asic::Init3()</apiname></xref> function would
+initialise the <codeph>ResourceManager</codeph> object, and set up <codeph>myResMgrPtr</codeph>.
+Alternatively, if the Variant (or ASSP) were to need the resource manager
+up and running, then you would initialise <codeph>ResourceManager</codeph> in <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita#GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D/GUID-63F2135B-4264-3B3B-9B68-656A89BF7EE9"><apiname>Asic::Init1()</apiname></xref>. </p>
+<p>In this implementation, the Variant would export a header file(s) publishing
+a list of controllable power resources. </p>
+<section id="GUID-CC741BCC-D96E-4FB7-AA8C-7635D4131DE0"><title>Shared controllable
+power resources</title> <p>Some controllable power resources can be shared
+between groups of peripherals and therefore may require usage tracking. </p> <p>We
+recommend that shared power resources be represented by a class derived from <xref href="GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A.dita"><apiname>MPowerInput</apiname></xref>.
+This class offers the <codeph>Use()</codeph> and <codeph>Release()</codeph> interface
+that encapsulates resource counting behaviour. This mechanism should turn
+the resource on when the count becomes non-zero, and turn the resource off
+when the count becomes zero. </p> <p>We suggest that your <xref href="GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A.dita"><apiname>MPowerInput</apiname></xref> derived
+class defines and implements a <codeph>GetCount()</codeph> function that returns
+the usage count on the shared resource. </p> </section>
+<section id="GUID-37A4098A-5E44-5744-BCE1-CDC8B876E654"><title>A suggested
+implementation of a resource manager</title> <p>While we have implied that
+a resource manager is a single class, which we have called <codeph>ResourceManager</codeph>,
+the resource manager is a notional concept for controlling power resources. <i>Symbian
+neither mandates a format for a ResourceManager class, nor even its existence</i>.
+In practice, it may be more useful to embed resource manager functions and
+data in the Variant interface class (or the ASSP interface class, if appropriate). </p> <p>However,
+for the purpose of explaining what a resource manager can do, it is easier
+to assume that this behaviour is handled by a resource manager class. This
+is the outline definition of such a class. </p> <codeblock id="GUID-BB326270-B8C6-5398-AB36-FA50011004CA" xml:space="preserve">class ResourceManager
+    {
+public:    
+    void InitResources();                            // called by your Asic::Init3()/Asic::Init1()
+    void Modify(TUint aSetMask, TUint aClrMask);    // only 32 simple Resources can be managed
+    TBool GetResourceState(TUint aResBitMask);    // only 1 bit set on this mask, returns On/Off
+public:
+    (MPowerInput-derived) iSharedResource1;        // 1 per shared resource
+    (MPowerInput-derived) iSharedResource2;
+    ...
+    };
+      </codeblock> <p>The <codeph>InitResources()</codeph> function would
+do at least two things: </p> <ul>
+<li id="GUID-29FA1D5C-0691-5EB2-A45A-5925D5C58A56"><p>enable an appropriate
+set of simple resources at boot time </p> </li>
+<li id="GUID-6F0D4084-48E9-585B-857B-F67B7B453DC7"><p>initialise the shared
+power resource tracking objects, i.e. the instances of your <xref href="GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A.dita"><apiname>MPowerInput</apiname></xref> derived
+class(es). </p> </li>
+</ul> <p>The function would be called by the Variant or ASSP implementation
+of <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita#GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D/GUID-FE55E398-7F08-384F-9E74-2CC2E45002B6"><apiname>Asic::Init3()</apiname></xref> or <xref href="GUID-21641835-7103-374B-9FBB-FAB1875D59A5.dita"><apiname>Asic:Init1()</apiname></xref>. </p> <p>The <codeph>Modify()</codeph> function
+is an example of how to deal with power resources that are either on or off.
+The function would take bit masks, where a bit represents a separate controllable
+power resource. The first bit mask would represent the set of power resources
+to be turned on, while the second would represent the set of power resources
+to be turned off. This assumes that the function could behave synchronously.
+Drivers for peripherals that use a set of these controllable power resources,
+would call <codeph>Modify()</codeph> to turn the relevant controllable power
+resources on or off. </p> <p>As an example, the most common method of switching
+clock resources on or off is by setting and clearing bits in a hardware register.
+A base port could choose to implement common code for setting bits in registers. </p> <p>A
+shared power resource is further represented by a <xref href="GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A.dita"><apiname>MPowerInput</apiname></xref> derived
+class. The implementations of <xref href="GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A.dita#GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A/GUID-2BCA5312-43D9-3763-9636-3B2EB046D2C1"><apiname>MPowerInput::Use()</apiname></xref> and <xref href="GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A.dita#GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A/GUID-606ECD77-A5F7-3408-9B63-C68C0A7B73C6"><apiname>MPowerInput::Release()</apiname></xref> would
+call <codeph>Modify()</codeph> to turn on the shared resource when the usage
+count becomes non zero, or turn it off when the usage count reaches zero.
+Peripheral drivers would have access to shared resources, and also to the
+member functions of the <codeph>ResourceManager</codeph> class, through the
+ASSP or Variant Interface class function that returns a pointer to it. </p> <p>The
+resource manager, or its functions and members, could be offered as part of
+a power controller interface class, the <codeph>TPowerController</codeph> class
+suggested when we discussed the implementation of the <xref href="GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita">Power
+Controller</xref>'s <xref href="GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita#GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703/GUID-5A0CAD08-AA12-56EE-B0A3-75548D1896C9">EnableWakeupEvents()</xref> function.
+The class would provide an exported function that would give access to the
+resource manager. The resource manager class would be made part of the power
+controller kernel extension. Peripheral drivers needing access to shared power
+resources would then link to the power controller DLL. If the Variant or ASSP
+were also to need access to the resource manager, then the resource manager
+would have to be initialised much earlier in the kernel start-up sequence.
+In this case, we would suggest that the standard power controller kernel extension
+entry point defined by <xref href="GUID-7964FC46-4641-3BDD-92C9-50FA22C3321A.dita"><apiname>DECLARE_STANDARD_EXTENSION()</apiname></xref> be
+replaced with a custom entry point that might look like this: </p> <codeblock id="GUID-B5262624-C7B8-51E4-AE14-1D905DFC0A99" xml:space="preserve">GLDEF_C TInt KernelModuleEntry(TInt aReason)
+    {
+    if(aReason==KModuleEntryReasonVariantInit0)
+        {
+        ResourceManager* c = new ResourceManager ();    // create Resource Manager
+        return c ? KErrNone : KErrNoMemory;    
+        }
+    else if(aReason==KModuleEntryReasonExtensionInit0)
+        {
+        (create DPowerController and Battery Monitor and Power HAL handler)
+        }
+    return KErrNone;         // gets here from calling with KModuleEntryReasonExtensionInit1
+    }
+        </codeblock> <p>The Variant or ASSP would also need to link to the
+power controller DLL. </p> <p>The following base port software architecture
+could be applied to the power supply arrangement as illustrated in the hardware
+block diagram above (see the beginning of this section at <xref href="GUID-3B6544CD-FA6E-5AB2-AA63-61186F52167D.dita">Controllable
+Power Resources</xref>): </p> <fig id="GUID-309A6C5E-A347-5E04-B2C8-426A81755226">
+<title>Base port software architecture</title>
+<image href="GUID-EE2F64B2-A2E3-524F-8E04-68BE9AA9EA36_d0e29378_href.png" placement="inline"/>
+</fig> </section>
+<section id="GUID-C4C67612-C5CD-5D64-B257-259FD12443C9"><title>Multi-level,
+composite and asynchronous power resources</title> <p>Some power resources
+may have more than one operational level. For example, it is possible that
+an input clock to a peripheral can be operated at a nominal value corresponding
+to the fully active state, and may be lowered to another level corresponding
+to the power saving state. </p> <p>The same could apply to the input voltages
+that the peripheral can operate on. The control model suggested above for
+simple resources may not be appropriate. A suggested alternative would have
+these multi-Level resources implementing an interface that offers a public
+enumeration to cover all possible usage levels at which the resource can be
+used, and APIs such as: </p> <codeblock id="GUID-44492A89-C7DC-5C97-928C-549BEAD38161" xml:space="preserve">class MultiLevelResource
+    {
+    enum TResourceLevel
+        {
+        EOperationalLevel1,
+        EOperationalLevel2,
+        . . .
+        ELowPowerLevel1,
+        ELowPowerLevel2,
+        . . .
+        };
+    void UseToLevel();
+    void ReleaseToLevel();
+    TResourceLevel GetCurrentLevel();
+    . . . 
+    };</codeblock> <p>More importantly, it is possible that resources may
+have to be operated in combination with other resources. For example, some
+peripherals may have more than one input clock, and on transition between
+power states, these clocks may have to be changed simultaneously. </p> <p>If
+the resources to be actuated simultaneously are simple resources, then the
+model above with a <codeph>Modify()</codeph> call that takes a bit mask and
+allows more than one resource to be changed at a time may be appropriate.
+If the resources to be actuated are shared or multi-level, or have to be represented
+individually, then another interface will have to be defined to allow modifying
+more than one of them simultaneously. </p> <p>Modifying some resources may
+not be an instantaneous operation. For example, it may take a non-negligible
+amount of time to stabilise an input clock that has just been modified. </p> <p>The
+nature of EKA2 strongly discourages actively waiting (or “spinning”) inside
+drivers; instead it is suggested that the multithreading capabilities of EKA2
+kernel side code and the synchronisation mechanisms available be used to solve
+the problem of having the driver code having to wait for a resource to stabilise
+before proceeding with its use. </p> <p>As an example, let us assume that
+the multi-level resource mentioned above has a non-negligible delay associated
+with any level changes: </p> <ul>
+<li id="GUID-0549E815-BB6E-55C7-84DB-FB6A2ACA11AC"><p>If the length of time
+to wait for a power resource to stabilise is known, and is the order of a
+few milliseconds or less, or the driver executes on its unique kernel thread
+(not used by any other kernel-side code), then the best solution would be
+to sleep the driver thread, by calling <codeph>NKern::Sleep(aTime)</codeph> for
+the specified length of time after issuing a call to <codeph>UseToLevel()</codeph> (or <codeph>ReleaseToLevel()</codeph>). </p> </li>
+<li id="GUID-9F0FCB9F-2827-528A-B3D0-FEE6CF8470CD"><p>When the length of time
+to wait for a power resource to stabilise increases, then sleeping the driver
+thread may become a problem if the driver executes in a DFC queue used by
+other drivers, which is often the case. This is because blocking that thread
+means that no other drivers can run. Here, the best solution is for the driver
+to create another thread and DFC queue, by calling <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-B9D637A1-4EB9-39F7-8C5C-2C546994C4B8"><apiname>Kern::DfcQInit()</apiname></xref>,
+and whenever it needs to change the resource, queue a DFC on that queue, which
+will issue the calls to <codeph>UseToLevel()</codeph> (or <codeph>ReleaseToLevel()</codeph>)
+and then sleep the thread. </p> </li>
+<li id="GUID-C8472B27-FC27-5C72-B6C2-A0DA681EA3C6"><p>If the length of time
+to change a power resource cannot be known in advance, but the hardware provides
+an indication of completion of the change, for example, in the form of an
+interrupt, then the solution may involve the driver code waiting on a Fast
+Mutex, which is signalled by the completion event (in code belonging to the <codeph>MultiLevelResource</codeph> derived
+object). </p> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-3C34724F-B476-5329-B0B1-6D5A34294979.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-3C34724F-B476-5329-B0B1-6D5A34294979" xml:lang="en"><title>Interrupt
+Dispatcher Tutorial</title><shortdesc>Describes how to implement the Interrupt Dispatcher part
+of the ASSP/Variant.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/><related-links>
+<link href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita"><linktext>Interrupt
+Dispatcher</linktext></link>
+<link href="GUID-8FA1B2B0-5842-4D5D-BD61-C2D79B56ADC6.dita"><linktext>Interrupt
+Service Routines (ISR)</linktext></link>
+<link href="http://developer.symbian.org/wiki/index.php/Symbian_OS_Internals/6._Interrupts_and_Exceptions" scope="external"><linktext>Symbian OS Internals - Chapter 6 Interrupts
+and Exceptions</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-3CB74FE6-272E-4176-BC51-E36103CADB09-master.png has changed
Binary file Adaptation/GUID-3CB74FE6-272E-4176-BC51-E36103CADB09_d0e94075_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-3E85C075-436F-5D2E-B1F7-0C9EC6D382E3.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-3E85C075-436F-5D2E-B1F7-0C9EC6D382E3" xml:lang="en"><title>Source
+Code Organisation</title><shortdesc>Describes the platform-independent files of the bootstrap.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The generic files are stored in the <filepath>os/kernelhwsrv/kernel/eka/</filepath> directory. </p>
+<p>The files are: </p>
+<ul>
+<li id="GUID-BC07386A-D4FA-5F27-8289-DBA4E7BDD5DE"><p> <filepath>kernel/bootstrap.mke</filepath> -
+Generic part of the makefile, written for GNU make. Works for both ARM and
+X86 bootstrap builds. </p> </li>
+<li id="GUID-2DDE2253-4CD6-5AB9-97DD-CF513B14515E"><p> <filepath>include/e32rom.h</filepath> -
+C++ Header file describing the layout of the ROM header and the ROM file system. </p> </li>
+<li id="GUID-7E8A26BC-7E4F-57A2-92D3-890F26CF1C64"><p> <filepath>include/kernel/kernboot.h</filepath> -
+C++ Header file describing the interface between the bootstrap and the kernel,
+mainly the definition of super page fields. Applicable to both ARM and X86. </p> </li>
+<li id="GUID-7C536059-863A-5C1E-BFEC-0FF9570EAB4F"><p> <filepath>include/kernel/arm/bootcpu.inc</filepath> -
+Assembler include file giving CPU-specific definitions for ARM. </p> </li>
+<li id="GUID-FA30F09E-1A88-5C8F-A5BD-FF99E241EE25"><p> <filepath>include/kernel/arm/bootdefs.h</filepath> -
+C++ Header file containing some internal bootstrap definitions for ARM. </p> </li>
+<li id="GUID-F6C696D8-1860-56C1-A7EA-54CBAC959406"><p> <filepath>include/kernel/arm/bootmacro.inc</filepath> -
+Assembler include file containing some general-purpose macro definitions for
+ARM.</p> </li>
+<li id="GUID-137AC684-7714-5193-8747-F9A9614694B6"><p> <filepath>include/kernel/arm/bootstrap.lnk</filepath> -
+Linker script file for GNU linker; used when building ARM bootstrap using
+GNU tools. </p> </li>
+<li id="GUID-8E04B961-8B1A-546F-9EC5-B5CC1C90AC00"><p> <filepath>include/memmodel/epoc/&lt;model&gt;/arm/mmboot.h</filepath> -
+C++ Header file containing memory-model-specific definitions shared with bootstrap. </p> </li>
+<li id="GUID-255BDD64-F619-53B4-97AE-83EB1431CD1E"><p> <filepath>kernel/arm/bootcpu.s</filepath> -
+Source file containing routines which are specific to a particular ARM CPU
+rather than generic to all ARM CPUs.</p> </li>
+<li id="GUID-2C9EABF7-3C0E-526A-97A4-18EC69FEC45D"><p> <filepath>kernel/arm/bootutils.s</filepath> -
+Source file containing lots of useful subroutines such as memory copy, memory
+fill, generic MMU mapping code, generic memory allocator, and so on.</p> </li>
+<li id="GUID-E1250D93-DE7D-568D-8D35-F07221E50F62"><p> <filepath>kernel/arm/bootmain.s</filepath> -
+Source file containing top-level bootstrap code. </p> </li>
+</ul>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-3F0053A7-6EE2-5B59-81C2-27EC3CC7820A-master.png has changed
Binary file Adaptation/GUID-3F0053A7-6EE2-5B59-81C2-27EC3CC7820A_d0e9276_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-3F47E907-975A-5739-9B03-042CB90D675D.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-3F47E907-975A-5739-9B03-042CB90D675D" xml:lang="en"><title>Port Implementation
+Tutorial</title><shortdesc>Describes the steps to implement a port of the DMA Framework. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/><related-links>
+<link href="GUID-81C69779-27AE-55E0-ACCF-E4F3E6657427.dita"><linktext>Concepts</linktext>
+</link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-3FE9C184-1880-51E1-B045-3C2EA4BE204A-master.png has changed
Binary file Adaptation/GUID-3FE9C184-1880-51E1-B045-3C2EA4BE204A_d0e78117_href.png has changed
Binary file Adaptation/GUID-40880992-B177-4584-84B4-6F6CF096E423-master.png has changed
Binary file Adaptation/GUID-40880992-B177-4584-84B4-6F6CF096E423_d0e96877_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-40F2BC43-5022-5F4E-B445-56FEF43FEB8B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,71 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-40F2BC43-5022-5F4E-B445-56FEF43FEB8B" xml:lang="en"><title>Code
+Organization</title><shortdesc>Describes the MultiMediaCard Controller source code provided by
+Symbian platform</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-119E4B4A-03DB-5C79-AA97-14434E4BC2CA"><title>Platform independent
+layer</title> <p>The location of the source code and the header files for
+the <i>platform independent layer</i> of the <xref href="GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF.dita#GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF/GUID-50AB2022-B205-525B-83F9-0DE0275EC3EF">MultiMediaCard
+controller</xref>, i.e. the generic DLL, provided by Symbian platform called <filepath>epbusm.dll</filepath>,
+is as follows: </p> <table id="GUID-79C5EC28-39F2-566A-9B5D-3EADC8F0FF68">
+<tgroup cols="3"><colspec colname="col0"/><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p> </p> </entry>
+<entry><p> <b>Source location</b>  </p> </entry>
+<entry><p>Source files </p> </entry>
+</row>
+<row>
+<entry><p>Peripheral bus layer source code. </p> </entry>
+<entry><p> <filepath>...\e32\drivers\pbus\</filepath>  </p> </entry>
+<entry><ul>
+<li id="GUID-5B3ED907-1AB6-595B-B835-C5E3CFC1685F"><p> <filepath>spbus.cpp</filepath>  </p> </li>
+<li id="GUID-5F169AF7-270A-5CB5-9273-DD5014F508D8"><p> <filepath>pbusmedia.cpp</filepath>  </p> </li>
+</ul> </entry>
+</row>
+<row>
+<entry><p>Peripheral bus layer header files and inline functions. </p> </entry>
+<entry><p> <filepath>...\e32\include\drivers\</filepath>  </p> </entry>
+<entry><ul>
+<li id="GUID-D045781E-7586-5BD1-AEED-8C36C4D62D16"><p> <filepath>pbus.h</filepath>  </p> </li>
+<li id="GUID-F86AFC07-D180-5382-84B9-0E4973CA92E0"><p> <filepath>pbus.inl</filepath>  </p> </li>
+<li id="GUID-9B1814B4-1AEB-5917-8130-6146CF5009BF"><p> <filepath>pbusmedia.h</filepath>  </p> </li>
+</ul> </entry>
+</row>
+<row>
+<entry><p>MultiMediaCard layer source code. </p> </entry>
+<entry><p> <filepath>...\e32\drivers\pbus\mmc</filepath>  </p> </entry>
+<entry><ul>
+<li id="GUID-4772A3CE-E721-50FA-83E5-ECD31D50CAAA"><p> <filepath/>  </p> </li>
+<li id="GUID-05487506-9DAC-5033-ADCA-58DA75FC94F3"><p> <filepath>session.cpp</filepath>  </p> </li>
+<li id="GUID-CB1FA22B-50D6-599A-BE69-3EBBA19DB3DC"><p> <filepath>stack.cpp</filepath>  </p> </li>
+</ul> </entry>
+</row>
+<row>
+<entry><p>MultiMediaCard layer header files and inline functions. </p> </entry>
+<entry><p> <filepath>...\e32\include\drivers\</filepath>  </p> </entry>
+<entry><ul>
+<li id="GUID-BA815AF8-3CB3-5B01-8940-EF66D53C2CE5"><p> <filepath>mmc.h</filepath>  </p> </li>
+<li id="GUID-CFBD4DF0-3FFF-518D-8CEC-FA99804D7B72"><p> <filepath>mmc.inl</filepath>  </p> </li>
+<li id="GUID-5814CA3E-2274-5663-9005-CB78812C350E"><p> <filepath>mmc_ifc.h</filepath>  </p> </li>
+</ul> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-3E29AB5A-C48C-5C87-9008-CAFD370A7C65"><title>Platform specific
+layer</title> <p>The suggested location of the source code and the header
+files for the <i>platform specific layer</i> of the <xref href="GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF.dita#GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF/GUID-50AB2022-B205-525B-83F9-0DE0275EC3EF">MultiMediaCard controller</xref>, i.e. the variant DLL, provided by you,
+and usually called <filepath>epbusmv.dll</filepath>, is the variant specific
+directory. This is the directory <filepath>...\&lt;VAR&gt;\specific\</filepath>. </p> <p>How
+you organize source and header files within this directory is up to you. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-423537D5-2C8A-5C26-8D7B-60446E95F681.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,72 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-423537D5-2C8A-5C26-8D7B-60446E95F681" xml:lang="en"><title>Interrupt
+Layer Initialisation</title><shortdesc>This topic describes how to implement the <codeph>Asic::Init1()</codeph> and <codeph>Asic::Init3()</codeph> functions
+to initialise interrupts. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-78C26133-367A-44B4-832F-52299F1639BC"><title>In first phase
+initialisation</title> <p>During first phase initialisation of start-up, the
+kernel calls the ASSP's implementation of <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita#GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D/GUID-63F2135B-4264-3B3B-9B68-656A89BF7EE9"><apiname>Asic::Init1()</apiname></xref>.
+For the template reference board, where the ASSP is split into a common, ASSP
+layer and a device-specific (variant) layer, interrupt handling is initialised
+in the ASSP layer, specifically in <codeph>TemplateAssp::Init1()</codeph>,
+defined in <filepath>...\template_assp\template_assp_priv.h</filepath>, and
+implemented in <filepath>           ...\template_assp\assp.cpp</filepath>. </p> <p>Note
+that interrupts are <i>disabled</i> during first phase initialisation. </p> <p>Within
+your implementation of <codeph>Init1()</codeph>, do the following: </p> <ul>
+<li id="GUID-21B39DCF-EFF2-56EE-921C-600BAF6DEF2B"><p>Initialise <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-77E83634-BBF6-5190-9434-9FB700547CD0">the ISR table</xref>. </p> <p>It is useful to initialise the ISR table so
+that each interrupt is bound, by default, to the <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-9D98586F-AD1D-5C50-9AD8-F81D72135382">Spurious interrupts</xref> handler, with the 32-bit parameter taking the
+interrupt number. </p> <p>For example, </p> <codeblock id="GUID-9CCBD3F2-49EE-53CF-92D1-30AE7266EB16" xml:space="preserve">...
+const TInt KInterruptSourceCount = 32;
+SInterruptHandler IsrHandlers[KInterruptSourceCount];
+...
+
+for( TInt i = 0; i &lt; KInterruptSourceCount; ++i )
+    {
+    IsrHandlers[i].iIsr = SpuriousHandler;
+    IsrHandlers[i].iPtr = (TAny*)i;
+    }</codeblock> <p>where the spurious interrupt handler function might be
+implemented as: </p> <codeblock id="GUID-F9ED35A6-2473-5B8C-B8C8-D8EB75463192" xml:space="preserve">void SpuriousHandler(TAny* aId)
+    {
+       Kern::Fault("SpuriousInt", (TInt)aId);    // handle unexpected interrupt.
+    }
+</codeblock> <p>On the template reference board, the ISR table is initialised
+by <codeph>TemplateInterrupt::Init1()</codeph> in <filepath>...\template_assp\interrupts.cpp</filepath>,
+and this is called by <codeph>TemplateAssp::Init1()</codeph>. </p> </li>
+<li id="GUID-FBC1F518-7CC8-54FD-AD13-1C74C1C1E414"><p>Register the dispatcher
+functions. The Symbian platform kernel needs to know the location of the IRQ
+and FIQ dispatchers. It provides the two functions: <xref href="GUID-2A4186A4-DCE1-3726-9D6A-BBA2604FAAF5.dita#GUID-2A4186A4-DCE1-3726-9D6A-BBA2604FAAF5/GUID-7C0DD618-1FA4-39CD-BEE0-E7F5ED018C9C"><apiname>Arm::SetIrqHandler()</apiname></xref> and <xref href="GUID-2A4186A4-DCE1-3726-9D6A-BBA2604FAAF5.dita#GUID-2A4186A4-DCE1-3726-9D6A-BBA2604FAAF5/GUID-390FDCB3-53E7-303C-B6D7-CFBA214E8135"><apiname>Arm::SetFiqHandler()</apiname></xref>,
+which the Variant layer must call, passing the addresses of the IRQ and FIQ
+dispatchers. </p> <p>On the template reference board, the registration is
+done by <codeph>TemplateInterrupt::Init1()</codeph> in <filepath>...\template_assp\interrupts.cpp</filepath>. </p> <codeblock id="GUID-6A634065-4C51-5A84-9AF6-82654B7D54C6" xml:space="preserve">void TemplateInterrupt::Init1()
+    {
+     //
+     // need to hook the ARM IRQ and FIQ handlers as early as possible
+     // and disable and clear all interrupt sources
+     //
+     ... 
+     DisableAndClearAll();
+     Arm::SetIrqHandler((TLinAddr)TemplateInterrupt::IrqDispatch);
+     Arm::SetFiqHandler((TLinAddr)TemplateInterrupt::FiqDispatch);
+    }
+</codeblock> </li>
+<li id="GUID-F4D217AF-8B8D-56AB-8D09-2E70566FE5D2"><p>Bind any ISRs that handle
+chained or pseudo interrupts </p> </li>
+</ul> </section>
+<section id="GUID-7D6DACC3-FAD7-49C8-98DE-1024518E49AF"><title>In third phase
+initialisation</title> <p>During third phase initialisation of start-up, the
+kernel calls the ASSP's implementation of <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita#GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D/GUID-FE55E398-7F08-384F-9E74-2CC2E45002B6"><apiname>Asic::Init3()</apiname></xref>. </p> <p>Note
+that interrupts are <i>enabled</i> during third phase initialisation. </p> <p>Within
+your implementation of <codeph>Init3()</codeph>, if you need to, call <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-BB169E6E-D8F9-3762-899D-6DBA4B29CF87"><apiname>Interrupt::Enable()</apiname></xref> on
+any of the interrupt sources that are bound to a chained or pseudo ISR dispatcher.
+You don't need to do this if you are enabling and disabling the main interrupt
+on demand as the chained or pseudo-interrupts are enabled and disabled. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-42F8FA5A-BBE4-50DE-917E-D05755019FEC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,232 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-42F8FA5A-BBE4-50DE-917E-D05755019FEC" xml:lang="en"><title>Personality Layer Design</title><shortdesc>Provides some guidelines for the design of a personality
+layer for real time Applications for the Kernel.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-A0EC87BF-170D-46B4-AEFF-F21D7483149B"><title>Memory
+management</title> <p>The personality layer assumes that the RTA will
+run in a single flat address space in which there is neither protection
+between different parts of the application nor protection of any hardware
+or CPU resource from any part of the application. For example, any
+part of the application code can access any I/O port, and can disable
+interrupts. </p> <p>To get this behaviour under the Kernel Architecture
+2, the RTA must run in supervisor mode in the kernel address space.
+The obvious way to do this is to make the RTA together with the personality
+layer a kernel extension. This also ensures that it is started automatically
+early on in the boot process. </p> <p>In general the RTA will have
+its own memory management strategy and will not wish to use the standard
+Symbian platform memory management system. To achieve this, the personality
+layer will allocate a certain fixed amount of RAM for use by the real
+time application at boot time. For a telephony stack this will be
+around 128K - 256K. This can be done either by including it in the
+kernel extension's <filepath>.bss</filepath> section, or by making
+a one-time allocation on the kernel heap at boot time. Depending on
+the RTA requirements, the personality layer can manage this area of
+RAM (if the RTOS being emulated provides memory management primitives)
+or the RTA can manage it. </p> </section>
+<section id="GUID-FAA30849-282F-4E2D-ABDA-63E130A2D2FB"><title>Threads
+and mapping thread priorities</title> <p>A nanokernel thread will
+be used for each RTOS thread </p> <p>A priority mapping scheme will
+be required to map RTOS priorities, of which there are typically 64
+to 256 distinct values, to nanokernel priorities. As long as the RTA
+does not use more than 35 threads running simultaneously, which is
+usually the case, it should be possible to produce a mapping scheme
+that allows each thread to have a distinct priority, if needed. If
+this limit is exceeded, it will be necessary to fold some priorities
+together. </p> <p>Note that any attempt to increase the number of
+priorities supported by both the nanokernel and the Symbian platform
+kernel would be <i>prohibitively</i> expensive in terms of RAM usage. </p> </section>
+<section id="GUID-169604BD-A22A-5B56-8279-13F875AB4AB6"><title>Communication
+between Symbian platform and the RTOS Environments</title> <p>To allow
+the functionality of the RTA to be available to Symbian platform applications,
+it is necessary that a mechanism exist by which Symbian platform code
+and the RTA may communicate with each other. In practice this means: </p> <ul>
+<li id="GUID-DC8AF97D-EA8A-5852-96FF-CCA19D69F614"><p>it must be possible
+for a Symbian platform thread to cause an RTOS thread to be scheduled
+and vice-versa </p> </li>
+<li id="GUID-EF671D7A-28B6-505D-823C-5B51C378225E"><p>it must be possible
+for data to be transferred between Symbian platform and RTOS threads
+in both directions. </p> </li>
+</ul> <p>It will usually be possible for a Symbian platform thread
+to make standard personality layer calls (the same calls that RTOS
+threads would make) in order to cause an RTOS thread to be scheduled.
+This is because the nanokernel underlies both types of thread and
+most 'signal' type operations (i.e. those that make threads ready
+rather than blocking them) can be implemented using operations which
+make no reference to the calling thread, and which are therefore not
+sensitive to which type of thread they are called from. </p> <p>The
+standard personality layer calls will not work in the other direction,
+since it will not be possible for a Symbian platform thread to wait
+on a personality layer wait object. The most straightforward way for
+RTOS threads to trigger scheduling of a Symbian platform thread would
+be to enque a DFC on a queue operated by a Symbian platform thread.
+Another possibility would be for the Symbian platform thread to wait
+on a fast semaphore which could then be signalled by the RTOS thread.
+However the DFC method fits better with the way device drivers are
+generally written. A device driver will be necessary to mediate communication
+between Symbian platform user mode processes and the RTA since the
+latter runs kernel side. </p> <p>All data transfer between the two
+environments must occur kernel side. It will not be possible for any
+RTOS thread to access normal user side memory since the functions
+provided for doing so access parts of the <xref href="GUID-38D1534C-AA01-33AF-9937-CDD818A85F97.dita"><apiname>DThread</apiname></xref> structure representing the Symbian platform calling thread, for
+example to perform exception trapping. Some possibilities for the
+data transfer mechanism are: </p> <ul>
+<li id="GUID-96A247AA-BA1C-50E5-8400-5487DFF5991D"><p>A fairly common
+architecture for real time applications involves a fixed block size
+memory manager and message queues for inter-thread communication.
+The memory manager supports allocation and freeing of memory in constant
+time. The sending thread allocates a memory block, places data in
+it and posts it to the receiving thread's message queue. The receiving
+thread then processes the data and frees the memory block, or possibly
+passes the block to yet another thread. It would be a simple proposition
+to produce such a system in which the memory manager could be used
+by any thread. In that case a Symbian platform thread could pass messages
+to RTOS threads in the same way as other RTOS threads. Passing data
+back would involve a special type of message queue implemented in
+the personality layer. When a message was sent to a Symbian platform
+thread a DFC would be enqueued. That DFC would then process the message
+data and free the memory block as usual. This scheme combines the
+data transfer and scheduling aspects of communication. </p> </li>
+<li id="GUID-1D2B6085-7B3A-51EF-BFF6-865D4AF94E5A"><p>Any standard
+buffering arrangement could be used between the RTA and the device
+driver (e.g. circular buffers). Contention between threads could be
+prevented using nanokernel fast mutexes, on which any thread can wait,
+or by the simpler means of disabling preemption or disabling interrupts.
+It will also be possible for RTOS threads to make use of shared I/O
+buffers for transfer direct to user mode clients, provided that these
+buffers are set up by the Symbian platform device driver thread. This
+may be useful as a way to reduce copying overhead if bulk data transfer
+is necessary between the two domains. </p> </li>
+</ul> </section>
+<section id="GUID-09CC8168-50FD-49ED-8376-05C00C3243FA"><title>Synchronisation/communication
+primitives</title> <p>The nanokernel does not support most of the
+synchronisation and communication primitives provided by a standard
+RTOS. Any such primitives required by the RTA will have to be implemented
+in the personality layer. This means that the personality layer needs
+to define new types of object on which threads can wait. This in turn
+means that new nanokernel thread states (N-state) must be defined
+to signify that a thread is waiting on an object of the new type.
+In general, each new type of wait object requires an accompanying
+new nanokernel thread state. </p> <p><b>Blocking a thread on a wait object</b> </p> <p>To make a thread
+block on a new type of wait object, call the nanokernel function <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-72F2E4E0-B498-32D2-BB24-E79AC66EFDDB"><apiname>Kern::NanoBlock()</apiname></xref>, passing the maximum time for which the
+thread should block, the new N-state value, and a pointer to the wait
+object. </p> <p>Use the <codeph>TPriListLink</codeph> base class of <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita"><apiname>NThreadBase</apiname></xref> to attach the thread to a list of threads waiting
+on the object. Note that this must be done after calling <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-72F2E4E0-B498-32D2-BB24-E79AC66EFDDB"><apiname>Kern::NanoBlock()</apiname></xref>. As preemption is disabled before this
+function is called, a reschedule will not occur immediately, but will
+be deferred until preemption is reenabled. </p> <p id="GUID-5017FB0A-5C1E-5C88-9315-E12C12D9639F"><b>State handler</b> </p> <p>Every thread that can use a new type of wait object, must
+have a nanokernel state handler installed to handle operations on
+that thread when it is waiting on that wait object. A nanokernel state
+handler is a function that has the following signature: </p> <codeblock id="GUID-31E807F7-250B-552D-8480-5F282C151565" xml:space="preserve">void StateHandler(NThread* aThread, TInt aOp, TInt aParam);</codeblock> <ul>
+<li id="GUID-B8ECADB3-0345-56CB-8C7A-6D4E8CE15726"><p> <codeph> aThread</codeph> is a pointer to the thread involved. </p> </li>
+<li id="GUID-711957A1-4D01-5F8B-BF67-70EB8F39D20B"><p> <codeph> aOp</codeph> is one of the <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita#GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC/GUID-FF52640A-87C9-319B-B4C6-F6B860171229"><apiname>NThreadBase::NThreadOperation</apiname></xref> values
+that indicates which operation is being performed on the thread. </p> </li>
+<li id="GUID-FF54386A-D163-5F53-B230-296BE402C9E6"><p> <codeph> aParam</codeph> is a parameter that depends on <codeph>aOp</codeph>. </p> </li>
+</ul> <p>Note that the state handler is always called with preemption
+disabled. </p> <p>The possible values of <codeph>aOp</codeph> are: </p> <table id="GUID-F4372C47-F491-55E2-B06E-2C68628B5BC5">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>aOp</codeph> value </p> </entry>
+<entry><p>Description </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>ESuspend</codeph>  </p> </entry>
+<entry><p>Called if the thread is suspended while not in a critical
+section and not holding a fast mutex. Called in whichever context <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita#GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC/GUID-FF94D458-C2D0-3D20-ADD6-AAE68A3296C3"><apiname>NThreadBase::Suspend()</apiname></xref> is called from. </p> <p> <codeph>aParam</codeph> contains the requested suspension count. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EResume</codeph>  </p> </entry>
+<entry><p>Called if the thread is resumed while actually suspended,
+and the last suspension has been removed. Called in whichever context <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita#GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC/GUID-C0A6E734-7DE6-37B9-AAB2-A2A0E2664731"><apiname>NThreadBase::Resume()</apiname></xref> is called from. </p> <p> <codeph>aParam</codeph> contains no additional information. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EForceResume</codeph>  </p> </entry>
+<entry><p>Called if the thread has all suspensions cancelled while
+actually suspended. Called in whichever context <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita#GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC/GUID-BE92FBC3-A7D9-3576-A1A9-7BBA6EE64226"><apiname>NThreadBase::ForceResume()</apiname></xref> is called from. </p> <p> <codeph>aParam</codeph> contains no additional
+information. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>ERelease</codeph>  </p> </entry>
+<entry><p>Called if the thread is released from its wait. This call
+should make the thread ready if necessary. Called in whichever context <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita#GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC/GUID-1B24AC4E-C4A1-32AE-BC6E-DC3131116EF8"><apiname>NThreadBase::Release()</apiname></xref> was called from. </p> <p> <codeph>aParam</codeph> is the value passed into <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita#GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC/GUID-1B24AC4E-C4A1-32AE-BC6E-DC3131116EF8"><apiname>NThreadBase::Release()</apiname></xref> to be used as a return code. </p> <p>If <codeph>aParam</codeph> is
+non-negative, this indicates normal termination of the wait condition. </p> <p>If <codeph>aParam</codeph> is negative, it indicates early or
+abnormal termination of the wait; in this case the wait object should
+be rolled back as if the wait had never occurred. For example, a semaphore's
+count needs to be incremented if <codeph>aParam</codeph> is negative,
+since in that case the waiting thread never acquired the semaphore. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EChangePriority</codeph>  </p> </entry>
+<entry><p>Called if the thread's priority is changed. Called in whichever
+context <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita#GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC/GUID-A92E7B01-C1D0-3997-B3E1-2E54229FFA75"><apiname>NThreadBase::SetPriority()</apiname></xref> is called from.
+This function should set the <codeph>iPriority</codeph> field of the
+thread, after doing any necessary priority queue manipulations. </p> <p> <codeph>aParam</codeph> contains the new priority. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>ELeaveCS</codeph>  </p> </entry>
+<entry><p>Called in the context of the thread concerned if the thread
+calls <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-2C897BA5-2BD7-3ABA-9F2B-F0B1AC14D1AE"><apiname>NKern::ThreadLeaveCS()</apiname></xref> with an unknown <codeph>iCsFunction</codeph> that is negative but not equal to <codeph>ECsExitPending</codeph>. </p> <p>aParam contains the value of <codeph>iCsFunction</codeph>. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>ETimeout</codeph>  </p> </entry>
+<entry><p>Called if the thread's wait time-out expires and no time-out
+handler is defined for that thread. Called in the context of the nanokernel
+timer thread (DfcThread1). This should cancel the wait and arrange
+for an appropriate error code to be returned. The handler for this
+condition will usually do the same thing as the handler for <codeph>ERelease</codeph> with a parameter of <xref href="GUID-BAC2386E-8168-3CDB-9F9F-180319EF6920.dita"><apiname>KErrTimedOut</apiname></xref>. </p> <p> <codeph>aParam</codeph> contains no additional information. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>See the code in <filepath>...\e32\personality\example\...</filepath> for practical examples. </p> <p><b>Releasing the thread</b> </p> <p>When a thread's wait condition
+is resolved, the nanokernel function <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita#GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC/GUID-1B24AC4E-C4A1-32AE-BC6E-DC3131116EF8"><apiname>NThreadBase::Release()</apiname></xref> should be called. This takes a single <xref href="GUID-7A2A43EC-6125-3BFE-834B-23C37F7B40D5.dita"><apiname>TInt</apiname></xref> parameter. </p> <p>The parameter is usually <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref>, if the
+wait condition is resolved normally. A typical example is where the
+semaphore on which the thread is waiting, is signalled. A negative
+parameter value is used for an abnormal termination, and in this case,
+the wait object may need to be rolled back. </p> <p> <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita#GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC/GUID-1B24AC4E-C4A1-32AE-BC6E-DC3131116EF8"><apiname>NThreadBase::Release()</apiname></xref> should be called with preemption disabled. It performs the following
+actions: </p> <ul>
+<li id="GUID-6697024F-ED05-5C5A-A834-EA89402AE173"><p>sets the <codeph>NThreadBase::iWaitObj</codeph> field to NULL </p> </li>
+<li id="GUID-C1DF3120-4FD3-5B6C-90F8-6D8C7CAD0B88"><p>cancels the
+wait timer if it is still running </p> </li>
+<li id="GUID-6E346E2B-4F94-56FB-8372-8260BCC4CA8C"><p>stores the supplied
+return code in <codeph>NThreadBase::iReturnCode</codeph>  </p> </li>
+<li id="GUID-3AF577DB-41A9-553E-9EFD-6F0DA2FADCEA"><p>calls the <xref href="GUID-42F8FA5A-BBE4-50DE-917E-D05755019FEC.dita#GUID-42F8FA5A-BBE4-50DE-917E-D05755019FEC/GUID-5017FB0A-5C1E-5C88-9315-E12C12D9639F">state handler</xref> passing <codeph>ERelease</codeph> and the return
+code. If the return code is negative this should remove the thread
+from any wait queues and roll back the state of the wait object. In
+any case it should call <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita#GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC/GUID-82E43D79-721D-31A9-B9ED-1277F2300914"><apiname>NThreadBase::CheckSuspendThenReady()</apiname></xref> to make the thread ready again if necessary. </p> </li>
+</ul> </section>
+<section id="GUID-1FF1CFE8-41E3-4912-AE28-39D289442BB7"><title>Thread
+scheduling following a hardware interrupt</title> <p>Most RTOS allow
+interrupt service routines (ISRs) to perform operations such as semaphore
+signal, queue post, set event flag directly, usually using the same
+API as would be used in a thread context. The Kernel Architecture
+2 nanokernel does not allow this; ISRs can only queue an IDFC or DFC. </p> <p>The way to get round this limitation is to incorporate an IDFC
+into each personality layer wait object. The personality layer API
+involved then needs to check whether it is being invoked from an ISR
+or a thread and, in the first case, it queues the IDFC. It may need
+to save some other information for use by the IDFC, for example, it
+may need to maintain a list of messages queued from ISRs, a count
+of semaphore signals from ISRs or a bit mask of event flags set by
+ISRs. Checking for invocation from an ISR can be done either by using <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-9542588A-2920-3CB0-A2C0-A55FA6BC29A2"><apiname>NKern::CurrentContext()</apiname></xref>, or by checking the CPSR directly;
+if doing the latter note that any mode other than USR or SVC on the
+ARM counts as interrupt context. </p> <p>Hardware interrupts serviced
+by the RTA will need to conform to the same pattern as those serviced
+by Symbian platform extensions or device drivers. This means that
+the standard preamble must run before the actual service routine and
+the nanokernel interrupt postamble must run after the service routine
+to enable reschedules to occur if necessary. This can be done by calling <codeph>Interrupt::Bind()</codeph> as provided by the base port during RTA
+initialisation (possibly via a personality layer call if it must be
+called from C code). See also <xref href="GUID-3C34724F-B476-5329-B0B1-6D5A34294979.dita">Interrupt Dispatcher
+Tutorial</xref>. </p> </section>
+</conbody><related-links>
+<link href="GUID-2700AAC8-A034-5E7D-B0E0-26B49E68BB18.dita">
+<linktext>Personality Layer for Real                 Time Applications</linktext>
+</link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-431A08D4-46DD-5A9D-B2A4-3D58C9B1E9E7-master.png has changed
Binary file Adaptation/GUID-431A08D4-46DD-5A9D-B2A4-3D58C9B1E9E7_d0e18839_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-4353940E-C77B-4080-86AD-7DBE52B0A27B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-4353940E-C77B-4080-86AD-7DBE52B0A27B" xml:lang="en"><title>SDIO
+Interface Quick Start</title><shortdesc>Provides a collection of documents that describe the SDIO client
+interface API.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-C1E03E86-639B-4ECA-AC04-6EBC8C5E115B"><title>SDIO tutorials</title><p>The
+client interface guide describes the generic procedure for using SDIO in a
+kernel-side device driver.</p><xref href="GUID-12A4418A-9BC6-4BEB-993D-B55E61240A15.dita">SDIO
+Client Interface Guide</xref><p>The Bluetooth example describes a reference
+client driver using Bluetooth</p><xref href="GUID-53A6E46C-E961-47C7-A5FA-CB0B52266646.dita">SDIO
+BT Example</xref><p>The other tutorials describe the SDIO classes and commands
+in more detail</p><ul>
+<li><p><xref href="GUID-2607CCFA-3D24-4716-A447-74304F861C44.dita">DSDIOREGInterface
+Class Tutorial</xref></p></li>
+<li><p><xref href="GUID-360DEB3A-3E38-413A-9941-6C758BA01ADE.dita">DSDIOSession
+Class Tutorial</xref></p></li>
+<li><p><xref href="GUID-E1277A18-7201-4856-8712-067022F92123.dita">DSDIOStack Class
+Tutorial</xref></p></li>
+<li><p><xref href="GUID-BA3B42A2-141C-49D9-B513-1571C246C19B.dita">TSDIOCard Class
+Tutorial</xref></p></li>
+<li><p><xref href="GUID-C57086D7-7672-4A52-8634-D28B37AC6290.dita">TSDIOFunction
+Class Tutorial</xref></p></li>
+<li><p><xref href="GUID-535C66C9-8B45-4DF3-8404-8ED03ABB4799-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1.dita">TSDIOInterrupt
+Class Tutorial</xref></p></li>
+<li><p><xref href="GUID-BDF1F32B-796B-4D3D-9C91-43FF8E9DDAF9.dita">SDIO Commands
+Tutorial</xref></p></li>
+</ul></section>
+<section id="GUID-492FA86C-764B-437C-AC5F-7DDC4A360C15">             <title>Purpose</title> 
+           <p>SDIO is an input/output protocol used to communicate with SDIO
+(Secure Digital) cards and other media such as Bluetooth adapters and GPS
+receivers.</p>         </section>
+<section id="GUID-E135B9B1-1562-4DA4-9486-9C5FBAD70419"><title>Intended audience</title><p>This
+document is intended to be used by device driver writers. </p></section>
+<section id="GUID-E8E291CC-F338-411D-8B86-141B96C76D5B"><title>Architecture</title>Symbian
+platform implements SDIO as part of a larger framework involving SD cards,
+which are a type of MMC (multimedia) card. For this reason, to use SDIO in
+a device driver you will need to use classes representing SD and MMC cards
+and the associated communications stack even if you only want the basic I/O
+functionality. </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-43782364-0865-43D0-BC89-D63BA9912FB6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,174 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-43782364-0865-43D0-BC89-D63BA9912FB6" xml:lang="en"><title>Basic Management</title><shortdesc>This document describes how device drivers should manage shared
+chunks.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-A30FD089-100B-44A3-B174-A68C7BC00372"><title>Creation</title> <p>A
+shared chunk is created in kernel space. The user is given a handle to the
+shared chunk to access it, and can pass the handle to other process or other
+drivers. Chunks are represented by <xref href="GUID-85454082-6734-3F1D-983F-734D4C2AB12D.dita"><apiname>DChunk</apiname></xref> objects on the
+kernel side and by <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita"><apiname>RChunk</apiname></xref> on the user side. </p> <p>A shared
+chunk is created by using <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-F8D1FB29-7238-3438-951A-6F853C7CF817"><apiname>Kern::ChunkCreate()</apiname></xref>, which takes
+a <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita"><apiname>TChunkCreateInfo</apiname></xref> argument that sets the chunk properties. </p> <p>Chunk
+creation should be done in a critical section, created using <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-841D587C-E9E6-34EE-8ED0-E9A206F64379"><apiname>NKern::ThreadEnterCS()</apiname></xref> and <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-2C897BA5-2BD7-3ABA-9F2B-F0B1AC14D1AE"><apiname>NKern::ThreadLeaveCS()</apiname></xref>. The size of the chunk should be in multiples of MMU pages, which can be
+calculated using <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-B37D12CF-449A-3EC3-9C4F-854A35E98CE3"><apiname>Kern::RoundToSize(n)</apiname></xref>, where <varname>n</varname> is
+the actual size that needs to be rounded. </p> <codeblock id="GUID-5F307D2C-517B-505D-A8D3-A4820B612E53" xml:space="preserve">/**
+ Create a transmit shared chunk of specified size.
+ 
+ @param    aChunkSize
+         size of the chunk to be created
+             
+ @return    KErrNone on success, standard error code on failure
+ */    
+TInt DExUartPhysicalChannel::CreateTxChunk(TUint aChunkSize)
+    {
+    ...
+    // Round up the transmit chunk size to the page size. 
+    // Kern::RoundToPageSize() rounds up the argument to the size 
+    // of a MMU page. The size of one MMU page can be found out by 
+    // calling Kern::RoundToPageSize(1). 
+ 
+    size=Kern::RoundToPageSize(aChunkSize);
+        
+    // Thread must be in critical section 
+    NKern::ThreadEnterCS();
+    ...
+    // Create the chunk. Example is given in next code snippet
+    ...
+    // Commit the chunk. Example is given in following sections
+    ...
+    // Thread can leave the critical section 
+    NKern::ThreadLeaveCS();
+    }
+
+TInt DExUartPhysicalChannel::CreateTxChunk(TUint aChunkSize)
+    {
+    ...
+    NKern::ThreadLeaveCS(); // Enter the critical section
+        
+    // TChunkCreateInfo holds the parameters required to create a 
+    // chunk and is used by Kern::ChunkCreate()
+    TChunkCreateInfo info;
+    
+    // ESharedKernelMultiple specifies that a chunk which may be opened by 
+    // any number of user side processes
+    info.iType=TChunkCreateInfo::ESharedKernelMultiple;        
+    info.iMaxSize= size;        // Chunk size
+    
+    // This specifies the caching attributes for the chunk. It can 
+    // be no caching or fully caching (TMappingAttributes enum 
+    // type). If the MMU does not support the requested attributes,  
+    // then a lesser cached attribute will be used. The actual 
+    // value used is returned in aMapAttr of Kern::ChunkCreate() 
+    info.iMapAttr=EMapAttrFullyBlocking; // No Caching, suitable for DMA
+    
+    // Set to true if the chunk is to own its committed memory. 
+    // In this case all memory committed to the chunk will come 
+    // from the system's free pool and will be returned there when 
+    // the chunk is destroyed. If the chunk will be committed to 
+    // physical address, then EFalse can be set.
+    info.iOwnsMemory=ETrue;            // using RAM pages
+    
+    // As chunk destruction is asynchronous we can have 
+    // a DFC, if required, specifying a callback function to get 
+    // the chunk destroy notification exactly. This is used if any 
+    // follow up cleaning has to be done after chunk destruction.
+    info.iDestroyedDfc=NULL;    // No chunk destroy DFC.
+    
+    DChunk* chunk;
+    TUint32 mapAttr;
+    // Creates a chunk that can be shared between a user thread and a 
+    // kernel thread. This will be the initial step for a shared 
+    // chunk. Once created, the chunk owns a region of linear 
+    // address space of the requested size. This region is empty 
+    // (uncommitted) so before it can be used either RAM or I/O 
+    // devices must be mapped into it. This is achieved with the 
+    // Commit functions.
+    // Here iTxChunkKernAddr returns the linear address of the 
+    // chunk created.
+    //
+    TInt r=Kern::ChunkCreate(info,chunk,iTxChunkKernAddr, mapAttr);
+    if (r!=KErrNone)
+        {
+        // Thread can leave the critical section
+        NKern::ThreadLeaveCS();
+        return r;
+        }
+    ...
+    }</codeblock> </section>
+<section id="GUID-84D1C7D6-5EFE-4D88-BC87-1D8897693B8A"><title>Destruction</title> <p>To allow a chunk to be properly cleaned
+up, a driver should close the chunk when it is no longer required. When a
+chunk is closed, the reference count is decremented by one. The chunk gets
+destroyed when the reference count becomes zero. Closing the chunk should
+be done within a critical section. </p> <p>The destruction of the chunk happens
+asynchronously, and a notification of this can be requested. This is done
+using a DFC, by initialising <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita#GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4/GUID-F6394BC5-16A9-383B-8E5D-446FB3136762"><apiname>TChunkCreateInfo::iDestroyDfc()</apiname></xref> with
+the DFC object. </p> <codeblock id="GUID-14F48A69-FCDF-5D5A-A6C6-42E4D57CB497" xml:space="preserve">/**
+ Close the transmit chunk, that was already created. This is 
+ called while closing the logical channel
+ */
+void DExUartPhysicalChannel::CloseTxChunk()
+    {
+    // Thread must be in critical section
+    NKern::ThreadEnterCS();
+    
+    // Atomically get pointer to our chunk and NULL the iChunk 
+    // member. Nkern::SafeSwap() atomically replaces the word 
+    // referenced by aPtr with aNewValue, here NULL.
+    //
+ DChunk* chunk = (DChunk*)NKern::SafeSwap(NULL,(TAny*&amp;)iTxChunk);
+    
+    if (chunk)
+        {
+        // Close the chunk that was created. This should be 
+        // done in a critical section. This function decrements 
+        // a chunk's access count, and, if the count reaches 
+        // zero, the chunk is scheduled for destruction.
+        // ChunkClose() has to be called the same number of times 
+        // as chunk creation. A mismatch in this will result 
+        // in either a memory leak or a panic.
+        //
+        Kern::ChunkClose(chunk);
+        }
+    // Thread can leave the critical section    
+    NKern::ThreadLeaveCS();        
+    }</codeblock></section>
+<section id="GUID-2CCEB305-03D7-44A4-A489-3B00680383F9"><title>Mapping</title> <p>Shared chunks must be mapped to memory,
+which means that either RAM or an I/O device must be committed to a shared
+chunk before it can be used. This maps the chunk to a certain address. The
+memory can be physical contiguous RAM pages, an arbitrary set of RAM pages,
+a physical region, or a physical region with a list of physical addresses.
+The Kernel provides the following APIs for committing these types of memory: </p> <codeblock id="GUID-256A14F7-D9D8-528A-8E8A-C573A492F803" xml:space="preserve">// Commit RAM to a shared chunk. The memory pages to commit are 
+// obtained from the system's free pool
+TInt Kern::ChunkCommit(DChunk *aChunk, TInt aOffset, TInt aSize);
+
+// Commit RAM to a shared chunk. The memory pages to commit are 
+// obtained from the system's free pool and will have physically 
+// contiguous addresses. Used when TChunkCreateInfo::iOwnsMemory 
+// is ETrue
+TInt Kern::ChunkCommitContiguous(DChunk *aChunk, TInt aOffset, 
+                TInt aSize, TUint32 &amp;aPhysicalAddress);
+
+// Commit memory to a shared chunk. The physical region committed 
+// is that which starts at the supplied physical address. 
+// Typically, this region either represents memory mapped I/O, or 
+// RAM that was set aside for special use at system boot time. 
+// This is used when TChunkCreateInfo::iOwnsMemory is EFalse.
+TInt Kern::ChunkCommitPhysical(DChunk *aChunk, TInt aOffset, 
+                TInt aSize, TUint32 aPhysicalAddress);
+
+// Commit memory to a shared chunk. The physical region committed
+// is determined by the list of physical addresses supplied to 
+// this function
+TInt Kern::ChunkCommitPhysical(DChunk *aChunk, TInt aOffset, 
+        TInt aSize, const TUint32 *aPhysicalAddressList);
+</codeblock></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,467 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C" xml:lang="en"><title>Keyword reference (P-R)</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This page lists the keywords starting from P to R. </p>
+<section id="GUID-C95FF58E-B556-4B31-AC67-9B8FCB283D0F"><title>paged</title><codeblock xml:space="preserve">paged</codeblock><p><i>rombuild and rofsbuild</i></p><p>Use the <codeph>paged</codeph> keyword to specify that the executable
+is code paged.   If an executable is marked as code paged, the pages
+are loaded into the RAM on demand one page after another. This can
+reduce application startup time and memory usage. </p><p>This is the
+same as specifying the <codeph>pagedcode</codeph> keyword for an executable.</p></section>
+<section id="GUID-1314D06A-FA06-4D08-87FA-4B4927081127"><title>pagedcode</title><codeblock xml:space="preserve">pagedcode</codeblock><p><i>rombuild and rofsbuild</i></p><p>Same as <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-C95FF58E-B556-4B31-AC67-9B8FCB283D0F"><codeph>paged</codeph></xref>.</p></section>
+<section id="GUID-23A28BEA-1AF4-42B6-887F-60C7B0EE2DEC"><title>pageddata</title><codeblock xml:space="preserve">pageddata</codeblock><p><i>rombuild and rofsbuild</i></p><p>Use the <codeph>pageddata</codeph> keyword to specify that the
+executable is <xref href="http://developer.symbian.org/main/documentation/reference/s3/pdk/GUID-1391CDCC-9A09-54FB-BA7D-BC7A91DB2351.html" scope="external">data paged</xref>. This controls the paging of both
+heap and stacks for an executable. For more fine-grained control of
+memory usage, specify the paging of heap and stack data during the
+creation of new threads and processes. </p></section>
+<section id="GUID-ADB633E8-8DD1-514C-9560-A6A2429DA199"><title>pagingoverride</title> <codeblock id="GUID-B519894B-22BB-516A-A955-093ED800767B" xml:space="preserve">pagingoverride [NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED | DEFAULTPAGED]</codeblock> <p> <i>rombuild and rofsbuild</i>  </p> <p>This overrides the code
+and data paging settings for all the files, such as EXE and DLL in
+an OBY file. It takes a single argument, which can be one of the following: </p> <table id="GUID-CB22C2A3-68E8-51DD-9314-3ABC6AC71FE5">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<thead>
+<row>
+<entry>Argument</entry>
+<entry>Purpose</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p> <i>NOPAGING</i>  </p> </entry>
+<entry><p>To mark all executables as unpaged, irrespective of whether
+they are marked as paged or unpaged in the <filepath>MMP</filepath> file. </p> </entry>
+</row>
+<row>
+<entry><p> <i>ALWAYSPAGE</i>  </p> </entry>
+<entry><p>To mark all executables as paged, irrespective of whether
+they are marked as paged or unpaged in the <filepath>MMP</filepath> file. </p> </entry>
+</row>
+<row>
+<entry><p> <i>DEFAULTUNPAGED</i>  </p> </entry>
+<entry><p>All executables, which are not marked as paged or unpaged
+are marked as unpaged by default. </p> </entry>
+</row>
+<row>
+<entry><p> <i>DEFAULTPAGED</i>  </p> </entry>
+<entry><p>All executables, which are not marked as paged or unpaged
+are marked as paged by default. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>For example, the following entry in the Obey file marks
+all the executables as unpaged: </p> <codeblock id="GUID-A6794DD3-049A-5C5C-A68D-E54316DF30DD" xml:space="preserve">pagingoverride NOPAGING</codeblock> </section>
+<section id="GUID-29A1FB89-E364-5C90-99D3-92247B514810"><title>pagingpolicy</title> <codeblock id="GUID-AE92F332-CAF1-5BA7-918C-0BD8FE0F11C0" xml:space="preserve">pagingpolicy [NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED | DEFAULTPAGED]</codeblock> <p> <i>rombuild and rofsbuild</i>  </p> <p>This overrides the default
+settings for both code and data paging. It also overrides the settings
+from all the <xref href="GUID-85B33746-074D-5B54-ACF4-1B1620D48FF6.dita#GUID-85B33746-074D-5B54-ACF4-1B1620D48FF6/GUID-08CFF2B1-63CC-5358-AD13-B4152A83B640">previous levels</xref>. This keyword takes a single argument, which
+can be one of the possible values listed in <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-ADB633E8-8DD1-514C-9560-A6A2429DA199">pagingoverride</xref>. </p> <p>For example, the following entry in
+the Obey file instructs the loader not to page the executables in
+the default state: </p> <codeblock id="GUID-065D951C-4AD1-5DCB-A470-2B11D025D43F" xml:space="preserve">pagingpolicy NOPAGING</codeblock> </section>
+<section id="GUID-C3734F82-AAB3-438F-BE32-C3EF2C26B4FD"><title>payloaduid</title><p><codeblock xml:space="preserve">payloaduid = &lt;payloaduid&gt;</codeblock></p><p>Identifies
+the payload of the SMR partition. This field allows kernel consumers
+(such as HCR) at runtime to locate the memory regions that contain
+their data.</p></section>
+<section id="GUID-871843B7-9AB6-4BEC-92BD-4BB1D6E81B34"><title>payloadflags</title><p><codeblock xml:space="preserve">payloadflags = &lt;payloadflags&gt;</codeblock></p><p>Specifies the payload specific flags that are defined at runtime
+by the the payload provider tools or user and payload consumer. This
+field allows the provider to give metadata to the consumer of the
+payload.</p></section>
+<section id="GUID-705897FD-9EC4-5F54-9198-A93C5080B80E"><title>patchdata</title> <codeblock id="GUID-AC20808F-B7E1-5A92-8C61-94E3E93D0AC1" xml:space="preserve">patchdata &lt;binary_name&gt; @ &lt;symbolname&gt; &lt;newvalue&gt;
+</codeblock> <p> <i>BUILDROM only</i>  </p> <p>This keyword is introduced
+since Symbian OS v9.3, and it enables you to change the value of a
+constant that is exported by a binary while building the ROM image. </p> <p>This means that the value of the constant can be changed without
+rebuilding the binary. This is useful for quickly building ROM images
+with different values for the constant, allowing you to make comparisons
+in behaviour between the ROMs. This keyword must be placed before
+or after the binary that it patches in the <filepath>OBY</filepath> file. </p> <table id="GUID-AF61DE84-7208-52B6-A586-2493E4CDA6FC">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>&lt;binary_name&gt; </p> </entry>
+<entry><p>The name of the binary on the PC and not the name in the
+ROM image. </p> </entry>
+</row>
+<row>
+<entry><p>&lt;symbolname&gt; </p> </entry>
+<entry><p>The symbolic name of the constant exported by the binary. </p> </entry>
+</row>
+<row>
+<entry><p>&lt;newvalue&gt; </p> </entry>
+<entry><p>The replacement value. This can be specified either as an
+integer or as a hexadecimal value. </p> <p>It is assumed that the
+exported constant is an integer that is either 1 byte, 2 bytes or
+4 bytes in length, which means that the size of this replacement value
+must not exceed the capacity of the constant to represent it. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>For example, if a DLL named <filepath>dllA.dll</filepath> is created based on the header file <filepath>dllA.h</filepath> and
+source file <filepath>dllA.cpp</filepath>: </p> <codeblock id="GUID-D711F52C-2888-5AFA-AD38-F234CFC39A20" xml:space="preserve">//dllA.h
+IMPORT_C int bar();
+...
+</codeblock> <codeblock id="GUID-F5663D32-3ABC-5C08-8145-624459278F5C" xml:space="preserve">//dllA.cpp
+#include “dllA.h”
+EXPORT_C extern const unsigned int foo = 0x1234;
+EXPORT_C int bar ()
+    {
+    return foo;
+    ...
+    }
+</codeblock> <p>then an executable file can import this constant;
+for example: </p> <codeblock id="GUID-CB782D99-4860-59E3-8E0F-2A6078A7DF55" xml:space="preserve">#include &lt;e32cons.h&gt;
+#include &lt;e32base.h&gt;
+#include “dllA.h”
+...
+int importValue = bar();
+...
+</codeblock> <p>If you add the following statement to the <filepath>.oby</filepath> file to change the value of constant "foo" while
+building the ROM, then the actual value of <codeph>foo</codeph> accessed
+by the executable file is <codeph>0x100</codeph>, and not <codeph>0x1234</codeph> as specified when <filepath>DllA</filepath> was originally
+built. </p> <codeblock id="GUID-39DF91C3-AD49-5FCB-9825-3A6CE73F8B4C" xml:space="preserve">patchdata dllA @ foo 0x100</codeblock> <p> <b> Notes:</b>  </p> <ul>
+<li id="GUID-825461D9-E933-531C-AD97-398AE781105F"><p>The value of
+the constant in the source is not changed. It is only its value in
+the copy of the binary incorporated into the ROM image that is changed. </p> </li>
+<li id="GUID-0BAAF169-F04B-5E3C-B7E1-E66132034D4D"><p>Do not define
+a patchable constant (exported data) in the source file in which it
+is referred to, because the compiler may inline it. If a constant
+is inlined, it cannot be patched. Hence, the constant must be defined
+in a separate source file and must be referred to in other source
+files by using the <codeph>extern</codeph> qualifier. </p> </li>
+</ul> </section>
+<section id="GUID-19D81B5A-A13E-5468-B886-2EF65139C950"><title>patched</title> <codeblock id="GUID-3C8C1038-E677-5583-9E68-0BF6CADDB586" xml:space="preserve">patched</codeblock> <p> <i>rombuild only</i>  </p> <p>This is used when sectioning a
+ROM for language variants etc. If an executable is to be replaced,
+make it patched in the first section of the ROM and include a replacement
+in the top section of the ROM, after the <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-D31658A3-6346-5BBE-B79C-D274113C6120">section</xref> keyword. </p> <p>This keyword appears at the point
+in the obey file where the ROM is to be split. All files before this
+line appear in the first (constant) section and files after appear
+in the second (patch/language) section. </p> </section>
+<section id="GUID-1950C3F1-BB6A-5560-955B-41D8A62FF041"><title>platsecdiagnostics</title> <codeblock id="GUID-438A1C0E-6526-5907-A1A5-77FDE415B191" xml:space="preserve">platsecdiagnostics [on | off]</codeblock> <p> <i>rombuild only</i>  </p> <p>This is a keyword that affects
+Symbian platform security when building a ROM. </p> <p>It controls
+whether or not diagnostic messages are emitted when a capability or
+other platform security policy check fails. A diagnostic message takes
+the general form: </p> <codeblock id="GUID-5D417FA2-0C87-5D56-A9A7-24D13A3DDDE2" xml:space="preserve">*PlatSec* ERROR - xxxxx</codeblock> <p>if platform security is enforced </p> <codeblock id="GUID-0FD5A8AA-FCDB-539E-ACE4-1B8FFD1659D8" xml:space="preserve">*PlatSec* WARNING - xxxxx</codeblock> <p>if platform security is <i>NOT</i> enforced. </p> <p>The string
+xxxxx represents the text of the message that describes the capability
+being violated or the security policy check that is failing. </p> <ul>
+<li id="GUID-9D53B858-A308-597B-B2D9-D9FF3A2996CC"><p>Specify <codeph>on</codeph> to <i>enable</i> diagnostic messages to be emitted. </p> </li>
+<li id="GUID-EA18D791-E5C6-5B83-8B50-BD24A1292583"><p>Specify <codeph>off</codeph> to <i>disable</i> diagnostic messages from being emitted. </p> </li>
+<li id="GUID-3FAF9887-5C75-5892-B0A6-F85D75DC2188"><p>If neither <codeph>on</codeph> nor <codeph>off</codeph> is specified, then <codeph>on</codeph> is assumed as a default. </p> </li>
+</ul> </section>
+<section id="GUID-2644E195-4339-5809-ACA0-6B15244AA4AD"><title>platsecdisabledcaps</title> <codeblock id="GUID-9377A178-7A9D-5B48-8F6F-FB832180F483" xml:space="preserve">platsecdisabledcaps [+|-]cap1 [+|- cap2] [+|- cap3] ...[+|-capn]</codeblock> <p> <i>rombuild only</i>  </p> <p>This is a keyword that affects
+Symbian platform security when building a ROM. </p> <p>It allows capabilities
+to be added to, or removed from, all executables in the ROM image. </p> <p>Specify a list of capability names prefixed either by a <codeph>+</codeph> character or a <codeph>-</codeph> character. The first
+capability name in the list does not need to prefixed by either of
+these characters, but if it is omitted a <codeph>+</codeph> character
+is assumed. </p> <p>Capabilities preceded by a <codeph>+</codeph> character
+are added to all executables, while those preceded by a <codeph>-</codeph> character are removed from all executables. </p> <p>Any of the capabilities
+listed in the left hand column in the table below can be specified;
+follow the corresponding link in the right hand column for a description
+of that capability. Note that you can also use: </p> <codeblock id="GUID-D27E91F6-4522-5A78-AA36-5F21F6893B89" xml:space="preserve">+ALL</codeblock> <p>to add all capabilities, and </p> <codeblock id="GUID-005016EE-7B7C-5B92-98AF-12176CEBEEBF" xml:space="preserve">+NONE</codeblock> <p>to remove all capabilities. </p> <p>Note, however, that the combinations <codeph>-ALL</codeph> and <codeph>-NONE</codeph> are not permitted </p> <table id="GUID-60D9A9D6-420C-593E-A67B-FA10572DBC3D">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p><table id="GUID-F0A90295-7468-5559-BDF7-68E70E10EFCE">
+<tgroup cols="1"><colspec colname="col0"/>
+
+<tbody>
+<row>
+<entry>Capability</entry>
+</row>
+</tbody>
+</tgroup>
+</table> </p> </entry>
+<entry><p><table id="GUID-E1446E24-51B8-53CB-902F-5DB0EF66323D">
+<tgroup cols="1"><colspec colname="col0"/>
+
+<tbody>
+<row>
+<entry>TCapability Enum value</entry>
+</row>
+</tbody>
+</tgroup>
+</table> </p> </entry>
+</row>
+<row>
+<entry><p>TCB </p> </entry>
+<entry><p> <xref href="GUID-0C19208D-732F-3B2B-9B0F-81CB1CB56DFC.dita"><apiname>ECapabilityTCB</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>CommDD </p> </entry>
+<entry><p> <xref href="GUID-2714B609-120A-31C1-9415-235A2FEB9D9A.dita"><apiname>ECapabilityCommDD</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>PowerMgmt </p> </entry>
+<entry><p> <xref href="GUID-76F4383B-4EA5-391A-A271-A8F65ED77EC0.dita"><apiname>ECapabilityPowerMgmt</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>MultimediaDD </p> </entry>
+<entry><p> <xref href="GUID-48AA1686-C619-3C36-B4B5-6C5DE1F50B0A.dita"><apiname>ECapabilityMultimediaDD</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>ReadDeviceData </p> </entry>
+<entry><p> <xref href="GUID-1AC4E327-14CE-382D-AA1A-1A7EDBA1863E.dita"><apiname>ECapabilityReadDeviceData</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>WriteDeviceData </p> </entry>
+<entry><p> <xref href="GUID-C607209F-6FC5-31DE-8034-E5B799B857A8.dita"><apiname>ECapabilityWriteDeviceData</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>DRM </p> </entry>
+<entry><p> <xref href="GUID-C0EF5A59-F716-313A-911F-2D3D773DF597.dita"><apiname>ECapabilityDRM</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>TrustedUI </p> </entry>
+<entry><p> <xref href="GUID-AFB7AB40-B829-37B8-AAB1-7A6FAED9671B.dita"><apiname>ECapabilityTrustedUI</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>ProtServ </p> </entry>
+<entry><p> <xref href="GUID-200CA018-2CB3-3E4A-A505-085FAD2E3E8B.dita"><apiname>ECapabilityProtServ</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>DiskAdmin </p> </entry>
+<entry><p> <xref href="GUID-99D8A4E8-BC4F-39FF-A3DF-832CF0411629.dita"><apiname>ECapabilityDiskAdmin</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>NetworkControl </p> </entry>
+<entry><p> <xref href="GUID-4AFB561B-34D7-3570-A4C9-24B4952C787A.dita"><apiname>ECapabilityNetworkControl</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>AllFiles </p> </entry>
+<entry><p> <xref href="GUID-89631CF3-4AEE-3C2F-8AAE-5D9C3EB3B373.dita"><apiname>ECapabilityAllFiles</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>SwEvent </p> </entry>
+<entry><p> <xref href="GUID-369B6584-AB7F-3AA2-B912-E912D2BCBE98.dita"><apiname>ECapabilitySwEvent</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>NetworkServices </p> </entry>
+<entry><p> <xref href="GUID-07A09CBA-CB4E-3CBE-9FA3-930C455F3B0C.dita"><apiname>ECapabilityNetworkServices</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>LocalServices </p> </entry>
+<entry><p> <xref href="GUID-7D0E447B-EC32-355B-8BBF-F074A1B10D8A.dita"><apiname>ECapabilityLocalServices</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>ReadUserData </p> </entry>
+<entry><p> <xref href="GUID-4897D21D-5ACF-30A5-A38C-371A3983814D.dita"><apiname>ECapabilityReadUserData</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>WriteUserData </p> </entry>
+<entry><p> <xref href="GUID-8908E5F7-AC6A-333B-8F65-6DDC46798F48.dita"><apiname>ECapabilityWriteUserData</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p>Location </p> </entry>
+<entry><p> <xref href="GUID-1B530864-C77B-3CDE-B761-83C2EED44DB8.dita"><apiname>ECapabilityLocation</apiname></xref>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>For example: </p> <codeblock id="GUID-9EB9582E-7FD8-525D-872A-50B6E6D0AAE0" xml:space="preserve">PlatSecDisabledCaps LocalServices+ReadDeviceData+ReadUserData</codeblock> </section>
+<section id="GUID-275FDBE0-D0AA-5976-9886-B0D56C075C7F"><title>platsecenforcement</title> <codeblock id="GUID-CEAAB920-F6C4-5079-BD58-88ECC541D8D5" xml:space="preserve">platsecenforcement [on | off]</codeblock> <p> <i>rombuild only</i>  </p> <p>This is a keyword that affects
+Symbian platform security when building a ROM. </p> <p>It controls
+whether or not platform security is enforced. </p> <ul>
+<li id="GUID-E33ED82C-6870-59CE-8240-B60E4C5C33E9"><p>Specify <codeph>on</codeph> to <i>enable</i> platform security enforcement. If enforcement
+is enabled, and a capability or other platform security policy check
+fails, then the appropriate action for a failed platform security
+check occurs. </p> </li>
+<li id="GUID-35B93E8F-A341-5246-A400-FD501FE2F4C8"><p>Specify <codeph>off</codeph> to <i>disable</i> platform security enforcement. If
+enforcement is disabled, and a capability or other platform security
+policy check fails, then the system continues as though the original
+platform security check had in fact passed. </p> </li>
+<li id="GUID-DAEBBB42-DBF7-5821-B4E9-2FAC23057FEF"><p>If neither <codeph>on</codeph> nor <codeph>off</codeph> is specified, then <codeph>on</codeph> is assumed as a default. </p> </li>
+</ul> </section>
+<section id="GUID-83F419EE-9ECD-5B19-9B9E-11F2066E5C8D"><title>platsecenforcesysbin</title> <codeblock id="GUID-8913D68B-F934-5D8B-9095-1493770E060B" xml:space="preserve">platsecenforcesysbin [on | off]</codeblock> <p> <i>rombuild only</i>  </p> <p>This is a keyword that affects
+Symbian platform security when building a ROM. </p> <p>It controls
+whether or not to force the location of binary executables into the <filepath>\Sys\Bin\</filepath> directory. </p> <ul>
+<li id="GUID-C9712785-EC25-598A-AEAD-69197B032D7B"><p>Specifying <codeph>on</codeph> has the following effects: </p> <ul>
+<li id="GUID-DD14B43D-B1F1-5C39-9B05-176276664D73"><p> <codeph>rombuild</codeph> places all executables into <filepath>Z:\Sys\Bin\</filepath>, and
+overrides any file path specified in any of the <filepath>.IBY</filepath> files. </p> </li>
+<li id="GUID-3DF8A9CE-46E5-5125-B562-62F747346B01"><p>the loader only
+looks for files in the <filepath>\Sys\Bin\</filepath> directory and
+only loads files from the <filepath>\Sys\Bin\</filepath> directory.
+If a different path is specified this path is ignored and the <filepath>\Sys\Bin\</filepath> directory is searched. </p> </li>
+</ul> </li>
+<li id="GUID-4BEFDE6C-4E52-570A-9804-76A864AB501E"><p>Specifying <codeph>off</codeph> causes <codeph>rombuild</codeph> to place files according
+to the file path specified in the <filepath>.IBY</filepath> files
+and permits the loader to load files from any specified path. </p> </li>
+<li id="GUID-1860E5D0-B8C3-5FCB-A023-87DF6935B958"><p>If neither <codeph>on</codeph> nor <codeph>off</codeph> is specified, then <codeph>on</codeph> is assumed as a default. </p> </li>
+</ul> </section>
+<section id="GUID-B5EE7071-532B-591B-904B-93108A42D939"><title>platsecprocessisolation</title> <codeblock id="GUID-835546BD-69EB-5CBC-AB8C-B6CAC38A5193" xml:space="preserve">platsecprocessisolation [on | off]</codeblock> <p> <i>rombuild only</i>  </p> <p>This is a keyword that affects
+Symbian platform security when building a ROM. </p> <p>It controls
+whether or not insecure APIs inherited from EKA1 (Versions 8.1a, 8.0a,
+7.0s, and earlier) are to be disabled. These are APIs whose use is
+intended to be restricted. The kernel provides run-time checks for
+their correct usage. </p> <p>See the <xref href="GUID-DB441DFF-0075-5122-A2EB-A6EF76375D71.dita">list of APIs affected
+by the platsecprocessisolation keyword</xref>. </p> <ul>
+<li id="GUID-78A05AA6-49AC-54CF-AB53-6FEACBC2AB86"><p>Specify <codeph>on</codeph> to <i>disable</i> insecure APIs. Incorrect use of this
+set of restricted APIs results in diagnostic messages, if <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-1950C3F1-BB6A-5560-955B-41D8A62FF041">platsecdiagnostics</xref> is <codeph>on</codeph>, and raises panics
+or causes errors if <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-275FDBE0-D0AA-5976-9886-B0D56C075C7F">platsecenforcement</xref> is <codeph>on</codeph>. </p> </li>
+<li id="GUID-F1160335-4D72-5FEC-B1EF-02724A4F70C3"><p>Specify <codeph>off</codeph> to <i>allow</i> insecure APIs. </p> </li>
+<li id="GUID-9B48AE55-EBFA-587D-AB37-0C609D1066AC"><p>If neither <codeph>on</codeph> nor <codeph>off</codeph> is specified then <codeph>on</codeph> is assumed as a default. </p> </li>
+</ul> </section>
+<section id="PREFERREDPREFERREDROMBUILDONLYTHIS-0399C898"><title>preferred</title><codeblock xml:space="preserve">preferred</codeblock><p><i>rombuild only</i></p><p>This
+keyword specifies that the major version of the executable binary
+must be preferred over its minor versions.  The minor version specifies
+the revision of the executable. The major version enables you to identify
+whether two versions of an executable are compatible.  The two versions
+of an executable can be compatible only if they have same major version.</p><p>The executable's header stores minor and major versions of the
+executable. </p></section>
+<section id="GUID-D14ECB32-00DD-574B-9301-2EF11AE55BA5"><title>primary[[HWVD]]</title> <codeblock id="GUID-F15C440F-EBAB-55EE-B785-D345B5131A45" xml:space="preserve">primary[[HWVD]] = &lt;source-file&gt; &lt;destination-image-file&gt; [File-attribute-list] [Override-Attribute-list]</codeblock> <p> <i>rombuild only</i>  </p> <p>A standard executable file that
+is loaded directly, bypassing the file server. The Boot program loads
+and gives control to the primary; this is the Kernel. </p> <p>As with
+all standard executable files, this is loaded, relocated and stripped
+of its relocation information. </p> <p>Note that the <codeph>HWVD</codeph> is optional but, if specified, must be enclosed within square brackets. </p> </section>
+<section id="GUID-02DE8552-5FE0-52D4-8A82-A0B679E934AA"><title>priority</title> <codeblock id="GUID-AD178D79-3C2B-5E64-BFF3-9C8BB0B6A0A2" xml:space="preserve">priority = &lt;hex-number&gt; | &lt;priority-keyword&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Sets the priority of the process.
+The priority can be a hexadecimal number, or one of the keywords listed
+below. The keywords correspond to the associated priority value. </p> <table id="GUID-CA739D33-23F5-536F-B65D-DE43B699BEC1">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>Keyword </p> </entry>
+<entry><p>Process priority </p> </entry>
+</row>
+<row>
+<entry><p>low </p> </entry>
+<entry><p>EPriorityLow </p> </entry>
+</row>
+<row>
+<entry><p>background </p> </entry>
+<entry><p>EPriorityBackground </p> </entry>
+</row>
+<row>
+<entry><p>foreground </p> </entry>
+<entry><p>EPriorityForeground </p> </entry>
+</row>
+<row>
+<entry><p>high </p> </entry>
+<entry><p>EPriorityHigh </p> </entry>
+</row>
+<row>
+<entry><p>windowserver </p> </entry>
+<entry><p>EPriorityWindowServer </p> </entry>
+</row>
+<row>
+<entry><p>fileserver </p> </entry>
+<entry><p>EPriorityFileServer </p> </entry>
+</row>
+<row>
+<entry><p>realtimeserver </p> </entry>
+<entry><p>EPriorityRealTimeServer </p> </entry>
+</row>
+<row>
+<entry><p>supervisor </p> </entry>
+<entry><p>EPrioritySupervisor </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-39CDB129-CE41-4ACD-952E-72D9DDA61556"><title>process</title><codeblock xml:space="preserve">process = &lt;file path of process being attached&gt;</codeblock><p><i>rombuild only</i></p><p>This keyword specifies the process
+to which a DLL is attached.</p></section>
+<section id="GUID-E816D875-0CE6-5C0A-BB1A-93F9A3E2DE90"><title>reloc</title> <codeblock id="GUID-4533709F-6D95-59C0-90F2-DFE95BC6C7A1" xml:space="preserve">reloc = &lt;hex-address&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Overrides the default stack size
+for the executable. </p> </section>
+<section id="GUID-9724A786-4431-595F-8945-C29914D63A40"><title>rem</title> <codeblock id="GUID-9D98CF44-6DC6-5A74-8C71-5784C0CDEFA7" xml:space="preserve">rem &lt;comment&gt;</codeblock> <p> <i>rombuild and rofsbuild</i>  </p> <p>Defines a comment line.
+Text that appears after the rem keyword is interpreted as a comment. </p> </section>
+<section id="GUID-4584DD65-6861-5B2A-A4FB-B7F366DCE13A"><title>rename</title> <codeblock id="GUID-6A57E3F9-48D8-521F-A5AC-0CB6ADFB2F5F" xml:space="preserve">rename[[HWVD]]= &lt;existing-file&gt; &lt;destination-file&gt; [ full-attribute-list ]</codeblock> <p> <i>rombuild and rofsbuild</i>  </p> <p>Adding a file and then
+renaming it is equivalent to adding it directly at the rename destination.
+The existing and destination directories do not have to be the same. </p> </section>
+<section id="GUID-04CE5B92-FF2B-53BB-BC21-C66731B94CC1"><title>RIGHT_NOW</title> <codeblock id="GUID-292B46AF-28A6-5DC0-9F11-2A2B1747701C" xml:space="preserve">RIGHT_NOW</codeblock> <p> <i>BUILDROM only</i>  </p> <p>A pre-defined substitution. This
+is replaced with the exact time in the format <codeph>dd/mm/yy hh:mm:ss</codeph>  </p> <p>Note that there is no UNDEFINE facility, and substitutions
+are applied in an unspecified order. </p> </section>
+<section id="GUID-660AC1A4-948B-53AA-96F2-BFE48E478474"><title>rofsname</title> <codeblock id="GUID-B1A58F72-83B7-5BB0-9503-014849231AD0" xml:space="preserve">rofsname = &lt;filename&gt;</codeblock> <p> <i>rofsbuild only</i>  </p> <p>Defines the name of the core
+image. </p> </section>
+<section id="GUID-208C0FE4-DFC0-55C3-B6D7-F18C74F1A699"><title>rofssize</title> <codeblock id="GUID-46F9AD5E-9B59-5B21-A621-00116062A867" xml:space="preserve">rofssize = &lt;size in bytes&gt;</codeblock> <p> <i>rofsbuild only</i>  </p> <p>Specifies the maximum size of
+the core image, or the maximum size of the extension. </p> </section>
+<section id="GUID-C956A0A9-F8F0-5144-896C-1DBF32E76915"><title>romalign</title> <codeblock id="GUID-211623DD-B905-5CF2-98DD-E07FFA977C5B" xml:space="preserve">romalign = &lt;hex-alignment&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>The address alignment boundary
+for files in the ROM. </p> <p>This value should be greater than 4
+and a multiple of 4. The recommended value is 0x10. If no value is
+specified, <codeph>rombuild</codeph> defaults to using a value of
+0x1000. If the value specified is not a multiple of 4, it is rounded
+off. </p> </section>
+<section id="GUID-9841CB4D-D71F-53E8-AF0E-22B393ADF2CD"><title>ROMBUILD_OPTION</title> <codeblock id="GUID-CC19021A-0462-52FC-8461-07158AA23B28" xml:space="preserve">ROMBUILD_OPTION &lt;command-line-option&gt;</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Adds additional command line parameters
+to the eventual invocation of <xref href="GUID-003D2C5B-09DC-5BD1-AF45-A0FCB56F567B.dita">rombuild</xref>.
+It is primarily used to specify the <codeph>-no-header</codeph> option
+for platforms which don't want the 256-byte REPRO header. The <codeph>ROMBUILD_OPTION</codeph> keyword can be used multiple times if desired. </p> </section>
+<section id="GUID-D9A6B254-D76E-51C2-A943-FA360CDB3F0E"><title>romchecksum</title> <codeblock id="GUID-6FCDB34E-93C4-56A0-98D8-AF1BBE007B13" xml:space="preserve">romchecksum = &lt;32 bit hex-number&gt;</codeblock> <p> <i>rombuild and rofsbuild</i>  </p> <p>The checksum in the final
+ROM image is made using the following algorithm: </p> <p>checksum
+= romchecksum - sum of 32bit words in ROM image. </p> </section>
+<section id="GUID-C88976BA-6381-5DEB-830F-5ED63CB929FA"><title>ROM_IMAGE</title> <codeblock id="GUID-49013022-96F0-5A17-BA76-C582AAB7B57F" xml:space="preserve">ROM_IMAGE &lt;id&gt; &lt;name&gt; [size=&lt;rom max size&gt;] [xip | non-xip] [compress | no-compress] [extension]</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Defines a ROM image. </p> <p>This
+is a ROM configuration feature; up to 8 ROM images can be defined
+for a device. </p> <table id="GUID-393CADB8-1B1B-58EA-B368-E05B6F3A37D3">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>id</codeph>  </p> </entry>
+<entry><p>A value in the range 0..7 to identify the ROM image. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>name</codeph>  </p> </entry>
+<entry><p>A name suitable as a suffix for the ROM image, IBY and logs. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>non-xip</codeph>  </p> </entry>
+<entry><p>Specifies a non-XIP ROM. If not specified, a XIP ROM is
+the default </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>size = &lt;rom-max-size&gt;</codeph>  </p> </entry>
+<entry><p>Defines the maximum size of the ROM. Not required for XIP
+ROMs. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>compress</codeph>  </p> </entry>
+<entry><p>Compresses an XIP ROM. If not specified, no compression
+is the default behaviour. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>extension</codeph>  </p> </entry>
+<entry><p>Defines this image as an extension to the previous image. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>To mark a file for inclusion in a ROM it is prefixed with
+the keyword ROM_IMAGE. For example: </p> <codeblock id="GUID-52FA6075-B4D4-53D2-AECB-D5D72A2DB839" xml:space="preserve">ROM_IMAGE[2] data=\private\&lt;process SID&gt;\Apps\Calc\calc.INSTCOL_MBM \private\&lt;process SID&gt;\Apps\Calc\Calc.mbm</codeblock> <p>A Block of files can be included using '{' '}'
+braces, for example: </p> <codeblock id="GUID-E95D224C-EDA2-5BB4-A293-5E07F9142C74" xml:space="preserve">ROM_IMAGE[2]
+    {
+    #include "calc.iby"
+    #include "word.iby"
+    }
+      </codeblock> <p>File blocks can be nested, for example: </p> <codeblock id="GUID-7C33BDB8-A0B4-5A22-BC03-0FB2982CB249" xml:space="preserve">ROM_IMAGE[2]
+    {
+    #include "calc.iby"
+    ROM_IMAGE[0]
+        {
+        #include "word.iby"
+        }
+    #include "video.iby"
+    }
+      </codeblock> </section>
+<section id="GUID-6D4D4AF5-92E2-5E87-97D0-B5233E700287"><title>romlinearbase</title> <codeblock id="GUID-C9EA7FE3-CF87-52E4-9230-944D86463D13" xml:space="preserve">romlinearbase = &lt;hex-address&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>The virtual address of the start
+of ROM, in hex. </p> <p>This is the address at which the kernel expects
+to find the start of the ROM. The recommended value depends on the
+memory model: </p> <ul>
+<li id="GUID-4C4DAAF0-9FC6-5E2C-BF7C-832C453F4765"><p>For the Multiple
+Memory Model, typically used on ARMV6 based hardware platforms, the
+recommended value is 0x80000000. </p> </li>
+<li id="GUID-C9BADF29-5772-5C4C-8445-F78DBB3DA013"><p>For the Moving
+Memory Model, typically used on ARMV5 based hardware platforms, the
+recommended value is 0xF8000000. </p> </li>
+</ul> </section>
+<section id="GUID-29BEF45C-2361-5245-9184-0261B99B6FB1"><title>romname</title> <codeblock id="GUID-E6CCF8AD-B22B-5F89-852B-491B331A8ECA" xml:space="preserve">romname = &lt;rom-file-name&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>This is the name of the output
+file. It contains the ROM image that <codeph>rombuild</codeph> creates. </p> </section>
+<section id="GUID-2F1CEC9A-CC82-5029-9EC2-A03A491FEC09"><title>romnameeven</title> <codeblock id="GUID-F1C48F8F-A8E9-5861-A49F-E49C509D5339" xml:space="preserve">romnameeven = &lt;rom-file-name-even&gt;
+</codeblock> <p> <i>rombuild only</i>  </p> <p> <codeph>rombuild</codeph> can write two separate ROM images, one containing the odd bytes
+of the image and the other the even. This is done if this keyword
+and the <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-FB2E9BFF-B5B3-50D8-AFAD-F120D2007173">romnameodd</xref> keyword are used to specify the output filenames
+for the two half-images. A filename of "*" can be specified, which
+means use the file name specified on the <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-29BEF45C-2361-5245-9184-0261B99B6FB1">romname</xref> keyword and append <filepath>.even</filepath>. </p> </section>
+<section id="GUID-FB2E9BFF-B5B3-50D8-AFAD-F120D2007173"><title>romnameodd</title> <codeblock id="GUID-5D110E11-FFEC-5389-A0C4-FDCEB96BC190" xml:space="preserve">romnameodd = &lt;rom-file-name-odd&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p> <codeph>rombuild</codeph> can
+write two separate ROM images, one containing the odd bytes of the
+image and the other the even. This is done if this keyword and the <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-2F1CEC9A-CC82-5029-9EC2-A03A491FEC09">romnameeven</xref> keyword are used to specify the output filenames
+for the two half-images. A filename of "*" can be specified, which
+means use the file name specified on the <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-29BEF45C-2361-5245-9184-0261B99B6FB1">romname</xref> keyword and append <filepath>.odd</filepath>. </p> </section>
+<section id="GUID-4F40AAAE-A6CE-5492-99E3-95B0D74F3229"><title>romsize</title> <codeblock id="GUID-639E3B10-FBFC-5172-8C40-FA243B174B6E" xml:space="preserve">romsize = &lt;hex-size&gt;</codeblock><p> <i>rombuild and rofsbuild</i> </p><p>The size of the entire ROM,
+in hex, for example, <codeph>0x400000</codeph> for a 4MB ROM. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-44540C74-CD73-5D8E-A9E0-F90F46B4E7B1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,54 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-44540C74-CD73-5D8E-A9E0-F90F46B4E7B1" xml:lang="en"><title>Preventing
+And Recovering From Thrashing Tutorial</title><shortdesc>Describes how to reduce the chance of thrashing occurring in demand
+memory and how to recover from thrashing. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-B9C385CD-A155-52F9-9001-C219A9AD52DB"><title>Introduction</title> <p>Thrashing
+is a state where the vast majority of the processing time is spent paging
+memory in and out of the system and very little is spent useful work. If this
+situation persists, then the system performance rapidly becomes unacceptable
+and will appear to the user to have hung. </p> </section>
+<section id="GUID-D93027E5-EC83-431B-872C-17F81F5FD64B"><title>Background information</title><p>The following is useful background
+reading: </p><ul>
+<li><p> Thrashing </p></li>
+</ul> </section>
+<section id="GUID-6EAA97DD-B352-4C40-9A41-4F60F2A34A8B"><title>Thrashing features</title><p>When thrashing occurs the device
+will appear to do nothing or 'hang' for  period. Unlike a deadlock however,
+the device can recover from thrashing.</p> </section>
+<section id="GUID-6355035F-BBE3-4D33-8B02-76BA7B40AA0B"><title>Prevention of thrashing</title><p>The following can be used
+reduce the chance of thrashing: </p><ul>
+<li><p>Compress pages in memory to decrease the amount of memory that has
+to  be paged in and out </p></li>
+<li><p>Limit the maximum size of each process's paged memory to the minimum
+size of the paging cache </p></li>
+<li><p>Partition the page cache per-process and allocate pages to processes
+ based on the Working Set Size (WSS) of threads in that process</p></li>
+<li><p>Swap out the oldest pages in advance to free up memory to cope with
+spikes in paging demand</p></li>
+<li><p>Don't let threads steal pages from other threads </p></li>
+</ul> </section>
+<section id="GUID-5E119B58-E5C5-49AD-95B3-76DDDD4AF0CD"><title>Recovery from thrashing</title> <p>The possible courses of
+action to undertake, should thrashing occur, are : </p> <ul>
+<li id="GUID-50BE3032-DE49-575A-B2A8-20D12F387C86"><p>Reboot the device </p> </li>
+<li id="GUID-DFB20955-70DA-5403-BFDD-D45B50926E98"><p>Kill a thread </p> </li>
+<li id="GUID-DF970B70-A9BA-5532-A267-5920950F6F2A"><p>Decrease the number
+of paged threads running concurrently </p> </li>
+<li id="GUID-B849006B-66E7-5F31-8225-297235614AC4"><p>Pick one thread with
+a high page fault rate and stop other threads stealing pages from the thread's
+associated process </p> </li>
+<li id="GUID-0497BC30-7BCA-5E69-A835-722C80EA2680"><p>Prompt the user-side
+memory manager to close down applications. </p> </li>
+</ul> </section>
+</conbody><related-links>
+<link href="GUID-ACB79CEF-CA4D-5C96-AFCD-6AD7C7C26C53.dita"><linktext>Thrashing
+guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-450BF1D4-85D7-45D4-8893-57DA8F1640E9.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-450BF1D4-85D7-45D4-8893-57DA8F1640E9" xml:lang="en"><title>Baseport Template</title><shortdesc>Describes the Baseport Template platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-455ED16F-D288-42C9-AA7A-AE5822F7A5BC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-455ED16F-D288-42C9-AA7A-AE5822F7A5BC" xml:lang="en"><title>Time Quickstart</title><shortdesc>Provides a brief overview of the contents of the Time platform
+service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> Time platform service provides the state of the device
+(mobile). It is controlled by a state machine that is SSM. These states
+are defined by system state policies within a SSM plug-in and system
+state changes are triggered by system-wide property changes or external
+requests. </p>
+<section id="GUID-E019BE30-391D-4055-B244-CFFB62C37E46-GENID-1-2-1-10-1-5-1-10-1-1-4-1-3-2">         
+   <title>Concepts</title><ul>
+<li><p><xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita"><apiname>MRtcAdaptation</apiname></xref>: An SPI that allows customizing
+of the functionality of Real Time Clock (RTC) adaptation interface. </p></li>
+<li><p>Alarm Server: manages all alarms on the device and enables
+client UI applications to use the services provided by the Alarm Server.
+It relies on the Alarm UI to notify, which includes displaying and
+playing sounds. </p></li>
+<li><p>Alarm Client and Alarm Shared: are the static interface DLLs.
+Alarm client is the client side of the Alarm Server, which allows
+other components to interact with the Alarm Server. The Alarm Shared
+facilitates a common format shared across server and its clients for
+providing definition for an alarm. It consists of shared objects such
+as alarm class, IPC messages, repeat definitions, alarm states. </p></li>
+<li><p>System State Manager (SSM): manages the state of a device throughout
+its lifecycle. SSM extends the existing Generic Start-up Architecture
+(GSA) and also manages the system state and the system-wide property.</p></li>
+</ul></section>
+<section id="GUID-E019BE30-391D-4055-B244-CFFB62C37E46-GENID-1-2-1-10-1-5-1-10-1-1-4-1-3-3">         
+   <title>Key uses for hardware implementators</title>           
+ <ul>
+<li><p>Including session alarms</p></li>
+<li><p>Adding, updating and deleting alarms. </p></li>
+<li><p>Performing alarm category-based operations such as retrieval
+and deletion.</p></li>
+</ul>         </section>
+<section id="GUID-E019BE30-391D-4055-B244-CFFB62C37E46-GENID-1-2-1-10-1-5-1-10-1-1-4-1-3-4"><title>Key
+uses for device creators</title>             <ul>
+<li><p>Activating an alarm on a specific date.</p></li>
+</ul>         </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-4592D493-A47C-5622-8C03-F24FABB4381C-master.png has changed
Binary file Adaptation/GUID-4592D493-A47C-5622-8C03-F24FABB4381C_d0e19271_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-463915EE-25DB-4ABD-AA80-1C10CD242072.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-463915EE-25DB-4ABD-AA80-1C10CD242072" xml:lang="en"><title>Register Access Build Guide</title><shortdesc>Describes how to build the Register Access platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There are no specific build instructions for Register Access platform
+service. Register Access platform is a part of the ASSP layer. You
+should use the <xref href="GUID-003D2C5B-09DC-5BD1-AF45-A0FCB56F567B.dita">ROMBUILD</xref> commands to build the baseport.</p>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-465D1450-B1EF-568B-B518-34ACE8C1697C-master.png has changed
Binary file Adaptation/GUID-465D1450-B1EF-568B-B518-34ACE8C1697C_d0e9201_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-4804B6E0-9199-5F3E-984A-4B00B3984E45.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-4804B6E0-9199-5F3E-984A-4B00B3984E45" xml:lang="en"><title>Porting the
+Power Resource Manager</title><shortdesc>This tutorial describes the steps needed to successfully port the
+PRM for a particular device.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Power Resource Manager (PRM) is a framework for managing system power
+resources. This framework improves portability across different platforms
+and reduces device driver complexity. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-4862EA2E-6BFE-5E11-B527-7EBA94BB0EA2.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,116 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE task
+  PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
+<task id="GUID-4862EA2E-6BFE-5E11-B527-7EBA94BB0EA2" xml:lang="en"><title>OBY Tutorial </title><shortdesc>Describes the new demand paging keywords available to the
+OBY. file. </shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody>
+<context id="GUID-E46B9321-49E9-545D-B38B-CF2BB7AD8E19"><p><b>Introduction</b></p><p>The new keywords that are available in the OBY file are used
+to specify whether an object is paged, and if so what kind of demand
+paging it supports. </p><p>          With the addition of writable
+data paging, the list of paging modifiers is shown below:   </p><p><b>Procedure</b></p><p>          With the addition of writable data
+paging, the list of paging modifiers is shown below:   </p><table id="GUID-1DB56A5D-823B-4E26-80A3-C1362B309773">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><b>Keyword</b></p></entry>
+<entry><p><b>Behaviour on Symbian platform</b></p></entry>
+</row>
+<row>
+<entry><p>paged</p></entry>
+<entry><p> Enables code and data paging  </p></entry>
+</row>
+<row>
+<entry><p>unpaged</p></entry>
+<entry><p> Disables code and data paging</p></entry>
+</row>
+<row>
+<entry><p>pagedcode</p></entry>
+<entry><p> Enables code paging</p></entry>
+</row>
+<row>
+<entry><p> unpagedcode</p></entry>
+<entry><p>Disables code paging</p></entry>
+</row>
+<row>
+<entry><p>pageddata</p></entry>
+<entry><p>Enables data paging</p></entry>
+</row>
+<row>
+<entry><p>unpageddata</p></entry>
+<entry><p> Disables data paging</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p> These modifiers appear in OBY files at the end of statements
+relating to user-side ROM objects i.e. <codeph>'file=', 'dll=', 'data='
+and 'secondary='</codeph>statements). For example:  </p><codeblock xml:space="preserve">file=ABI_DIR\DEBUG_DIR\MyLibrary.dll \sys\bin\MyLibrary.dll unpaged</codeblock><p>The data paging keywords only make sense when applied to executable
+binary files.   </p><p>For an executable file, the use of one of the
+above keywords in the oby file will override the paging settings in
+the mmp file. However this will not be true, if the <codeph>pagingoverride</codeph>, <codeph>codepagingoverride</codeph> or <codeph>datapagingoverride</codeph> keywords are used in the MMP file, in the case of <codeph>nopaging</codeph>  or <codeph>alwayspage</codeph> .</p> </context>
+<result id="GUID-EA5E0DDD-4354-5DD4-89D2-462A0B0E8A81"><p>Executing
+the buildrom command builds with no errors or warnings. </p> </result>
+<example id="GUID-ED6203BD-3890-5F27-8BAA-AFE3B0FAA518"><title>OBY
+file example</title> <p>An example of an OBY file that uses the new
+demand paging keywords is given below: </p> <codeblock id="GUID-84F82A9B-8F29-5A58-A9C3-7DEB19D5B9ED" xml:space="preserve">// 
+// MyDPConfig.oby 
+//
+// The section below, is used to specify if XIP ROM paging is implemented.  
+#if !defined PAGED_ROM 
+#define PAGED_ROM 
+#endif
+ 
+// The sections below, is used to specify if code paging is implemented.
+#if !defined USE_CODE_PAGING 
+// Comment out the next line if code paging is wanted 
+#define USE_CODE_PAGING 
+#endif
+ 
+#if !defined CODE_PAGING_FROM_ROFS 
+// Comment out the next line if code paging from primary rofs is wanted 
+#define CODE_PAGING_FROM_ROFS 
+#endif 
+
+// The section below, is used to configure the writable data paging and to specify what the 
+// default paging behaviour is to be. 
+ROM_IMAGE[0] { 
+pagedrom 
+compress 
+//                 Min   Max   Young/Old 
+//                 Live  Live  Page 
+//                 Pages Pages Ratio 
+demandpagingconfig 256   512   3 
+pagingoverride defaultpaged
+
+// This section specifies what the default paging behaviour is to be for code paging. 
+#if defined USE_CODE_PAGING &amp;&amp; !defined USE_DATA_PAGING 
+codepagingpolicy defaultpaged 
+#endif 
+
+#if defined USE_DATA_PAGING 
+#if defined USE_CODE_PAGING 
+codepagingpolicy defaultpaged 
+#endif 
+
+datapagingpolicy defaultpaged 
+#endif 
+}
+
+#if defined CODE_PAGING_FROM_ROFS || defined USE_DATA_PAGING 
+ROM_IMAGE[1] { 
+pagingoverride defaultpaged 
+}
+#endif 
+
+// Now specify the files to be used
+file=ABI_DIR\DEBUG_DIR\MyLibrary.dll \sys\bin\MyLibrary.dll unpaged
+</codeblock> </example>
+<postreq id="GUID-5000ED29-DB7E-4855-965C-6B0C335A40C2"><p>The next step is to <xref href="GUID-6B9041F7-79A6-5CCA-9B4D-B8EF377FD378.dita">Build the writable
+data paging ROM</xref>  </p> </postreq>
+</taskbody></task>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-49379616-C235-598D-AE43-668998AD072B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,362 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-49379616-C235-598D-AE43-668998AD072B" xml:lang="en"><title>Process,
+Thread, Stack and Memory Attributes</title><shortdesc>Reference for users of the debug monitor tool to the attributes
+of Kernel objects and memory structure. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<ul>
+<li id="GUID-98737E3D-1A08-53ED-89C5-C0398E02C509"><p> <xref href="GUID-49379616-C235-598D-AE43-668998AD072B.dita#GUID-49379616-C235-598D-AE43-668998AD072B/GUID-4D7F6A1F-3120-5547-B027-344C08A01D83">Process and thread priorities</xref>  </p> </li>
+<li id="GUID-F08BDD05-90C3-544E-8C41-788A556F799F"><p> <xref href="GUID-49379616-C235-598D-AE43-668998AD072B.dita#GUID-49379616-C235-598D-AE43-668998AD072B/GUID-DDC45F0A-6B62-5EE6-9E42-D21F07BCF4B4">Thread state summary</xref>  </p> </li>
+<li id="GUID-5C39B7CB-D8B1-5DD4-BD62-76595A3B2EB4"><p> <xref href="GUID-49379616-C235-598D-AE43-668998AD072B.dita#GUID-49379616-C235-598D-AE43-668998AD072B/GUID-C6296C07-220E-5EB8-9E12-F7D63AB4B181">Thread and process exit information summary</xref>  </p> </li>
+<li id="GUID-4F26D9D7-D335-5332-899D-E4DA6D8F4819"><p> <xref href="GUID-49379616-C235-598D-AE43-668998AD072B.dita#GUID-49379616-C235-598D-AE43-668998AD072B/GUID-68CF9014-4922-56B9-9E53-AC5697F60E8E"> Critical threads and processes</xref>  </p> </li>
+<li id="GUID-528E13A3-7E35-5153-87D6-C25CD3E90B6E"><p> <xref href="GUID-49379616-C235-598D-AE43-668998AD072B.dita#GUID-49379616-C235-598D-AE43-668998AD072B/GUID-6530D514-A6CC-5AE9-AA97-C223B2189A09">Kernel calls and thread context</xref>  </p> </li>
+<li id="GUID-4D0AC539-A105-5D26-896C-E32A2863213B"><p> <xref href="GUID-49379616-C235-598D-AE43-668998AD072B.dita#GUID-49379616-C235-598D-AE43-668998AD072B/GUID-5A573FEB-A274-5C0F-A6B6-87D5BAD8A21C">Stacks</xref>  </p> </li>
+<li id="GUID-3A45E908-3D72-5871-9DEB-454F75A084BE"><p> <xref href="GUID-49379616-C235-598D-AE43-668998AD072B.dita#GUID-49379616-C235-598D-AE43-668998AD072B/GUID-E3F102A4-D187-5BC9-BE97-9F8447A5DB45">Virtual memory and run addresses</xref>  </p> </li>
+</ul>
+<section id="GUID-4D7F6A1F-3120-5547-B027-344C08A01D83"><title>Process and
+thread priorities</title> <p>Internally the scheduler always deals with nanokernel
+threads, <codeph>NThread</codeph> objects, and their associated priority between
+0 (lowest) and 63 (highest). In general, a thread with a higher priority that
+is ready to run will always run in preference to threads with a lower priority.
+The only exception is where a higher priority thread waits on a nanokernel
+fast mutex held by a lower priority thread. In this case, the higher priority
+thread will yield to the lower priority thread holding the mutex. </p> <p>A
+Symbian platform thread, a <codeph>DThread</codeph> object, has an embedded <codeph>NThread</codeph>,
+which enables it to be scheduled by the nanokernel. </p> <p>There are two
+ways of setting a priority for Symbian platform thread: </p> <ul>
+<li id="GUID-8568544D-49F4-5D52-8E38-28A09058FB04"><p>using the two-level
+priority scheme </p> </li>
+<li id="GUID-F3D2BAF8-9C95-59C3-A50E-150A7BDA4EE7"><p>using an absolute priority. </p> </li>
+</ul> <p><b>The
+two level priority scheme</b> </p> <p>In this scheme, a Symbian platform thread
+priority is relative to the priority of its owning process. By default, Symbian
+platform threads inherit the priority of their owning process when they are
+created. This priority can be raised or lowered relative to the process priority
+- this just sets the thread’s priority to the process priority plus or minus
+a specified priority weighting. If the priority of the process is changed,
+the priority of its threads will change relative to other threads in the system
+but will remain the same relative to each other. </p> <p>The default priority
+of a process is <codeph>EPriorityForgeround</codeph>, which is an absolute
+priority of 350. Threads by default are created with relative priority <codeph>EPriorityNormal</codeph> which
+sets them to the same priority as the owning process. The window server lowers
+the priority of background UI processes to <codeph>EPriorityBackground</codeph> (250). </p> <p>The
+NULL thread, also known as the idle thread, runs at priority 0, and means
+that it will only run when there are no other threads ready to run. </p> <p>Symbian
+platform thread priorities map onto <codeph>NThread</codeph> priorities in
+the range 1 to 31 as shown in the table below. </p> <table id="GUID-E61C3B76-B47D-5B9B-A469-A369D5AB4AFC">
+<tgroup cols="8"><colspec colname="col0"/><colspec colname="col1"/><colspec colname="col2"/><colspec colname="col3"/><colspec colname="col4"/><colspec colname="col5"/><colspec colname="col6"/><colspec colname="col7"/>
+<tbody>
+<row>
+<entry><p> <b>Thread priority</b>  </p> </entry>
+<entry><p>Idle </p> </entry>
+<entry><p>Much Less </p> </entry>
+<entry><p>Less </p> </entry>
+<entry><p>Normal </p> </entry>
+<entry><p>More </p> </entry>
+<entry><p>Much More </p> </entry>
+<entry><p>Real Time </p> </entry>
+</row>
+<row>
+<entry><p> <b>Process priority</b>  </p> </entry>
+<entry><p> </p> </entry>
+<entry><p> </p> </entry>
+<entry><p> </p> </entry>
+<entry><p> </p> </entry>
+<entry><p> </p> </entry>
+<entry><p> </p> </entry>
+<entry><p> </p> </entry>
+</row>
+<row>
+<entry><p>Low </p> </entry>
+<entry><p>1</p> </entry>
+<entry><p>1</p> </entry>
+<entry><p>2</p> </entry>
+<entry><p>3</p> </entry>
+<entry><p>4</p> </entry>
+<entry><p>5</p> </entry>
+<entry><p>22 </p> </entry>
+</row>
+<row>
+<entry><p>Background </p> </entry>
+<entry><p>3</p> </entry>
+<entry><p>5</p> </entry>
+<entry><p>6</p> </entry>
+<entry><p>7</p> </entry>
+<entry><p>8</p> </entry>
+<entry><p>9</p> </entry>
+<entry><p>22 </p> </entry>
+</row>
+<row>
+<entry><p>Foreground </p> </entry>
+<entry><p>3</p> </entry>
+<entry><p>10 </p> </entry>
+<entry><p>11 </p> </entry>
+<entry><p>12 </p> </entry>
+<entry><p>13 </p> </entry>
+<entry><p>14 </p> </entry>
+<entry><p>22 </p> </entry>
+</row>
+<row>
+<entry><p>High </p> </entry>
+<entry><p>3</p> </entry>
+<entry><p>17 </p> </entry>
+<entry><p>18 </p> </entry>
+<entry><p>19 </p> </entry>
+<entry><p>20 </p> </entry>
+<entry><p>22 </p> </entry>
+<entry><p>23 </p> </entry>
+</row>
+<row>
+<entry><p>SystemServer1 </p> </entry>
+<entry><p>9</p> </entry>
+<entry><p>15 </p> </entry>
+<entry><p>16 </p> </entry>
+<entry><p>21 </p> </entry>
+<entry><p>23 </p> </entry>
+<entry><p>25 </p> </entry>
+<entry><p>28 </p> </entry>
+</row>
+<row>
+<entry><p>SystemServer2 </p> </entry>
+<entry><p>9</p> </entry>
+<entry><p>15 </p> </entry>
+<entry><p>16 </p> </entry>
+<entry><p>21 </p> </entry>
+<entry><p>23 </p> </entry>
+<entry><p>25 </p> </entry>
+<entry><p>28 </p> </entry>
+</row>
+<row>
+<entry><p>SystemServer3 </p> </entry>
+<entry><p>9</p> </entry>
+<entry><p>15 </p> </entry>
+<entry><p>16 </p> </entry>
+<entry><p>21 </p> </entry>
+<entry><p>23 </p> </entry>
+<entry><p>25 </p> </entry>
+<entry><p>28 </p> </entry>
+</row>
+<row>
+<entry><p>RealTimeServer </p> </entry>
+<entry><p>18 </p> </entry>
+<entry><p>26 </p> </entry>
+<entry><p>27 </p> </entry>
+<entry><p>28 </p> </entry>
+<entry><p>29 </p> </entry>
+<entry><p>30 </p> </entry>
+<entry><p>31 </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>where: </p> <ul>
+<li id="GUID-4315CEE2-2717-5E8F-A8F7-885C621A95B6"><p>the process priority
+values are defined by the internal Symbian platform enum <codeph>TProcPriority</codeph>,
+defined in <filepath>...\e32\include\kernel\kern_priv.h</filepath>. The symbols
+in the table correspond to the symbols in the enum. </p> </li>
+<li id="GUID-89D0D7FA-4B17-5753-898A-26C1B20EE59B"><p>the thread priority
+values are defined by the internal Symbian platform enum <codeph>TThrdPriority</codeph>,
+defined in <filepath>...\e32\include\kernel\kern_priv.h</filepath>. The symbols
+in the table correspond to the symbols in the enum. </p> </li>
+</ul> <p><b>Absolute
+priority scheme</b> </p> <p>It is possible to set an absolute priority that
+is not relative to the process priority; it is not affected by changes in
+the process priority. </p> </section>
+<section id="GUID-DDC45F0A-6B62-5EE6-9E42-D21F07BCF4B4"><title>Thread state
+summary</title> <p>This is a brief summary about nanokernel thread states
+and Symbian platform thread states. </p> <p><b>Nanokernel
+thread states</b> </p> <p>The state of a nanokernel thread is referred to
+as the NState (or N-state). This is to disambiguate it from any other state,
+such as the state of a Symbian platform thread (referred to as the MState
+or M-state). </p> <p>The states of a nanokernel thread are defined by the
+values of the <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita#GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC/GUID-2184305D-18EF-3322-9276-20F8A4253455"><apiname>NThreadBase::NThreadState</apiname></xref> enumeration. </p> <p><b>Symbian platform thread states</b> </p> <p>The state of a Symbian platform
+thread is referred to as the MState (or M_state). This is in addition to the
+nanokernel N-state, and tracks threads waiting on Symbian platform synchronization
+objects. The <codeph>DThread</codeph> class representing a Symbian platform
+thread is internal to Symbian, but the following table defines its possible
+states. The values in the left-hand column are the enumerators of the internal
+enumeration <codeph>DThread::TThreadState</codeph>. </p> <table id="GUID-C6ACF17D-2E18-5FCB-9383-BAE57D8F420F">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>ECreated</codeph>  </p> </entry>
+<entry><p>The initial state of all Symbian platform threads. It is a transient
+state; the thread starts in this state when the <codeph>DThread</codeph> object
+is created, and stays in that state until it is ready to be resumed, typically
+when DLL linkage and memory allocation is complete. At this point, the state
+will change to <codeph>EReady</codeph>. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EDead</codeph>  </p> </entry>
+<entry><p>This is the final state of a Symbian platform thread. A thread enters
+this state when it reaches the end of its exit handler, just before the nanokernel
+terminates it. In effect, the thread has exited but has not yet been deleted. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EReady</codeph>  </p> </entry>
+<entry><p>This indicates that the thread is not waiting on, or attached to
+any Symbian platform kernel wait object. It does not necessarily imply that
+the thread is actually ready to run - this is indicated by the N-state. For
+example, a thread that is explicitly suspended or waiting on a nanokernel
+wait object (generally a fast semaphore) still has a READY M-state provided
+that it is not attached to any Symbian platform wait object. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EWaitSemaphore</codeph>  </p> </entry>
+<entry><p>This indicates that the thread is currently blocked waiting for
+a Symbian platform semaphore, and is enqueued on the semaphore’s wait queue.
+The thread’s <codeph>DThread::iWaitObj</codeph> field points to the semaphore. </p> <p>For
+example, this is the case if the thread calls <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-50223158-D05D-33FE-A3DD-FFA9E2F464FF"><apiname>User::WaitForRequest()</apiname></xref> or <xref href="GUID-AED27A76-3645-3A04-B80D-10473D9C5A27.dita#GUID-AED27A76-3645-3A04-B80D-10473D9C5A27/GUID-68F18434-4758-33BA-9959-1F92A50651A2"><apiname>RSemaphore::Wait()</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EWaitSemaphoreSuspended</codeph>  </p> </entry>
+<entry><p>This indicates that the thread has been explicitly suspended after
+blocking on a Symbian platform semaphore, and is enqueued on the semaphore’s
+suspended queue. The thread’s <codeph>DThread::iWaitObj</codeph> field points
+to the semaphore. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EWaitMutex</codeph>  </p> </entry>
+<entry><p>This indicates that the thread is currently blocked waiting for
+a Symbian platform mutex, and is enqueued on the mutex wait queue. The thread’s <codeph>DThread::iWaitObj</codeph> field
+points to the mutex. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EWaitMutexSuspended</codeph>  </p> </entry>
+<entry><p>This indicates that the thread has been explicitly suspended after
+blocking on a Symbian platform mutex, and is enqueued on the mutex suspended
+queue. The thread’s <codeph>DThread::iWaitObj</codeph> field points to the
+mutex. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EHoldMutexPending</codeph>  </p> </entry>
+<entry><p>This indicates that the thread has been woken up from the EWaitMutex
+state but has not yet claimed the mutex. The thread is enqueued on the mutex
+pending queue and the thread’s <codeph>DThread::iWaitObj</codeph> field points
+to the mutex. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EWaitCondVar</codeph>  </p> </entry>
+<entry><p>This indicates that the thread is waiting on a condition variable. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EWaitCondVarSuspended</codeph>  </p> </entry>
+<entry><p>This indicates that the thread is suspended while waiting on a condition
+variable. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-C6296C07-220E-5EB8-9E12-F7D63AB4B181"><title>Thread and
+process exit information summary</title> <p>User threads and processes have
+“exit information”. When a thread or process terminates the reason for the
+termination is found in the exit information. For example, a panic will store
+the panic category and reason in the exit information. Exit information has
+three parts: the exit type, exit reason and exit category. </p> <p>Exit type
+is defined by the <xref href="GUID-0296BFC6-7F7C-3259-AF21-7E9B5C304B24.dita"><apiname>TExitType</apiname></xref> enum. </p> <p>When a thread
+or process is created, its exit type is set to 3. An exit type of 3 indicates
+that the thread is still active, though not necessarily running. If the thread
+terminates for any reason, then the exit type is changed to reflect the cause
+of the exit. </p> <p>Once the thread or process has exited, the exit reason
+and exit type fields will contain useful information. The contents depends
+on the type of exit. </p> <p>Note that if the main thread in a process exits,
+then the process will exit with the same exit information as the thread. </p> <p><b>Exit category: Terminate</b> </p> <p>if <xref href="GUID-B0E661BC-4058-3256-B9C3-5A4FD52F6DE5.dita#GUID-B0E661BC-4058-3256-B9C3-5A4FD52F6DE5/GUID-CE11A762-AF52-3122-86C8-C2F362AEF764"><apiname>RThread::Terminate()</apiname></xref> or <xref href="GUID-9DD1EA2B-DC59-315C-8E9C-CE6D9461B695.dita#GUID-9DD1EA2B-DC59-315C-8E9C-CE6D9461B695/GUID-3DD41FD4-F389-340F-8E18-8FDEBC953251"><apiname>RProcess::Terminate()</apiname></xref> is
+called, then the exit category is <codeph>Terminate</codeph>, and the exit
+reason is the value of the <codeph>aReason</codeph> argument passed to these
+functions. </p> <p><b>Exit
+category: Kill</b> </p> <p>If <xref href="GUID-B0E661BC-4058-3256-B9C3-5A4FD52F6DE5.dita#GUID-B0E661BC-4058-3256-B9C3-5A4FD52F6DE5/GUID-1F717486-784A-32B9-A048-EE4F2450F8C8"><apiname>RThread::Kill()</apiname></xref> or <xref href="GUID-9DD1EA2B-DC59-315C-8E9C-CE6D9461B695.dita#GUID-9DD1EA2B-DC59-315C-8E9C-CE6D9461B695/GUID-8E87D3AE-E3F0-34DD-98C6-71B0D0D55FB8"><apiname>RProcess::Kill()</apiname></xref> is
+called, then the exit category is <codeph>Kill</codeph>, and the exit reason
+is the value of the <codeph>aReason</codeph> argument passed to these functions. </p> <p><b>Exit category: panic</b> </p> <p>If a thread panics, then the exit category
+is <codeph>panic</codeph>, and the exit reason is the panic number. For example
+a USER-19 panic would give the following exit information: </p> <codeblock id="GUID-ACC94269-E06E-5C7F-ACAF-74764FE21A0F" xml:space="preserve">exit type = 2
+exit category = “USER”
+exit reason = 19
+</codeblock> </section>
+<section id="GUID-68CF9014-4922-56B9-9E53-AC5697F60E8E"><title> Critical threads
+and processes</title> <p>Marking a thread or process as “system critical”
+means that it is an integral and essential part of the system, for example,
+the file server. In effect the thread or process is being declared necessary
+for correct functioning of the device. If a system critical thread exits or
+panics then the device will reboot; during development it will enter the debug
+monitor. A thread can be set as process critical, which means that if it panics
+the process will be panicked. </p> </section>
+<section id="GUID-6530D514-A6CC-5AE9-AA97-C223B2189A09"><title> Kernel calls
+and thread context</title> <p>When a user thread makes a call into any kernel
+code, the kernel code continues to run in the context of the user thread.
+This applies to device driver code. </p> <p>The stack is swapped to a kernel-side
+stack and the permissions of the thread are increased to kernel privilege,
+but otherwise the user thread is still running. Each thread has a small kernel
+stack used to handle kernel calls – it would be dangerous to continue using
+the normal thread stack in case it overflows. Some calls are handled in this
+state, others – typically device drivers – will post a message to a kernel
+side thread to carry out the request. </p> </section>
+<section id="GUID-5A573FEB-A274-5C0F-A6B6-87D5BAD8A21C"><title>Stacks</title> <p>When
+a process is created, a chunk is allocated to hold the process executable's <codeph>.data</codeph> section
+(initialised data) and <codeph>.bss</codeph> section (zero filled data). Sufficient
+space (default 2Mb) is also reserved as user-side stack space for threads
+that run in that process. </p> <p>By default, each thread is allocated 8k
+of user-side stack space. A guard of 8k is also allocated. </p> <p>The stack
+area follows the <codeph>.data</codeph> and <codeph>.bss</codeph> sections,
+and each thread's user side stack follows. On ARM processors the stack is
+descending, so that as items are added to the stack, the stack pointer is
+decremented. This means that if the stack overflows, the stack pointer points
+into the guard area and causes a processor exception, with the result that
+the kernel panics the thread. </p> <fig id="GUID-C87444AA-A8DC-5A5C-B2E6-B15FA69B6CE1">
+<image href="GUID-DD0DA06D-4180-54F1-8807-A7BF31D6A1F1_d0e70450_href.png" placement="inline"/>
+</fig> <p>Return addresses are stored by pushing them on to the stack so at
+any point you can trace through the stack looking at the saved return addresses
+to see the chain of function calls up to the present function. </p> <p>The
+size of the user-side stack space has an indirect effect on the number of
+threads that a process can have. There are other factors involved, but this
+is an important one. The limit is a consequence of the fact that a process
+can have a maximum of 16 chunks. This means that if threads within a process
+can share a heap (allocated from a single chunk), then it is possible to have
+a maximum of 128 threads per process [2Mb/(8K + 8K)]. More threads may be
+possible if you allow only 4K of stack per thread. </p> <p>Apart from the
+kernel stack attached to each thread, the kernel also maintains stacks that
+are used during processing of interrupts, exceptions and certain CPU states.
+Interrupts and exceptions can occur at any time, with the system in any state,
+and it would be dangerous to allow them to use the current stack which may
+not even be valid or may overflow and panic the kernel. The kernel stacks
+are guaranteed to be large enough for all interrupt and exception processing. </p> </section>
+<section id="GUID-E3F102A4-D187-5BC9-BE97-9F8447A5DB45"><title>Virtual memory
+and run addresses</title> <p>Symbian platform devices have an MMU which is
+used to map the addresses seen by running code to real addresses of memory
+and I/O. The MMU in effect creates a virtual memory map, allowing scattered
+blocks of RAM to appear contiguous, or for a section of memory to appear at
+different addresses in different processes, or not at all. </p> <p>Symbian
+platform uses the MMU to provide memory protection between processes, to allow
+sharing of memory, efficient allocation of RAM and to make all processes “see”
+the same memory layout. Three different memory models are supported by Symbian
+platform on ARM CPUs: </p> <ul>
+<li id="GUID-456A3D12-E1E0-5289-B5EB-2E3A47F07684"><p>moving model: this is
+the model familiar from EKA1 where processes are moved to a run-address in
+low memory when executing and moved back to a home-address in high memory
+when not running. </p> </li>
+<li id="GUID-3A5BCC68-7BAC-58B8-9727-54A880A7CED3"><p>direct model: this is
+used when the CPU does not have an MMU, or is emulating a system without an
+MMU. Not normally used, but occasionally useful for development boards </p> </li>
+<li id="GUID-7CB07322-B33E-5723-975C-6D2442B924F9"><p>multiple model: only
+supported in ARM architecture V6 and above, each process has its own set of
+MMU tables. A context switch changes the current MMU table to the new thread’s
+table, instead of moving memory about in a single table as with moving model. </p> </li>
+</ul> <p><b>Fixed
+processes</b> </p> <p>For ARM architectures with a virtually-tagged cache,
+fixed processes avoid the need to flush the cache on context switches by keeping
+all the code and data at a fixed address. This implies that there can only
+ever be one instance of each fixed process because the data chunk address
+cannot be changed. </p> <p>Important servers such as the file server and window
+server are fixed. </p> <p>There is no limit to the number of fixed processes
+that can be supported. The kernel will attempt to use ARM domains for fixed
+process protection, but there are a limited number of domains so when they
+are exhausted normal MMU techniques will be used. Domains are slightly faster
+in a context switch but this is negligible compared to the real purpose of
+the fixed process in avoiding the cache flush. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-4993AF8E-28C3-54BA-8D27-D86E05D39CFD.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,61 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-4993AF8E-28C3-54BA-8D27-D86E05D39CFD" xml:lang="en"><title>Crash
+Logger Technology</title><shortdesc>The Crash Logger contains a logger program that stores system state
+information when a crash occurs, and a reader application that can be used
+later to get this information</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-060E1937-9BB9-5A81-A1FA-7EAEA04B9DEF"><title>The
+crash logger</title> <p>When the kernel crashes, control is handed to the
+crash logger. It tries to read as much state information as it can reasonably
+find, and dumps it to a pre-reserved location in permanent storage flash storage). </p> <p>Support
+exists for dumping information to <i>nor</i> flash and <i>nand</i> flash.
+The crash logger must have its own drivers to do this, as it cannot be assumed
+that any specific part of the kernel is operating correctly in these circumstances.
+These drivers are essentially simplified versions of the standard drivers. </p> <p>All
+monitoring functionality, crash logging and crash debugging is placed in kernel
+extensions. Functionality can be enabled or disabled by placing the appropriate
+kernel extensions into ROM at ROM build time. </p> <p>To support both crash
+logging and debugging without duplicating code, a common module, <filepath>exmoncommon.dll</filepath>,
+has been created. This extension contains all of the generic monitoring code,
+and supports features such as dumping registers, thread stacks and object
+containers and is responsible for registering with the kernel’s crash monitor
+entry point: </p> <codeblock id="GUID-F1EF54CF-614D-5459-ABA1-07F5E9D3969E" xml:space="preserve">Epoc::SetMonitorEntryPoint()</codeblock> <p>This
+extension must be placed in ROM before either of the two monitoring extensions,
+as they both rely on its functionality. As <filepath>exmoncommon.dll</filepath> depends
+on the underlying memory model, it is built from the Variant. </p> <p>After
+the common monitoring code registers itself with the kernel, further debugging
+extensions may register with the common code. These extensions are called
+when the kernel fails, in the order that they register. The maximum number
+of extensions currently supported is nine though only two- the interactive
+debugger, and the non-interactive crash logger are provided. However, this
+is an arbitrary limit set by the macro definition <codeblock xml:space="preserve">MONITOR_MAXCOUNT</codeblock> in
+the file <filepath>E32\include\kernel\monitor.h</filepath>, and can be increased
+given sensible use cases. </p> <ul>
+<li id="GUID-75C55DE2-982C-59E2-8A93-43457B687165"><p> <filepath>exmondebug.dll</filepath> is
+the traditional interactive debugger. </p> </li>
+<li id="GUID-12933627-FEBC-5D1A-9573-81F15FEDA328"><p> <filepath>exmonlog.dll</filepath> is
+the crash logger. </p> </li>
+</ul> <p>These DLLs are also built from the Variant. In the case of the crash
+logger, two separate <filepath>.mmp</filepath> files exist: </p> <ul>
+<li id="GUID-88D7A132-143A-519A-8645-FAA11D484FC7"><p>one for NAND flash,
+building <filepath>exmonlognand.dll</filepath>  </p> </li>
+<li id="GUID-EE02A14E-9E19-516D-93F9-B6590736D71C"><p>one for NOR flash, building <filepath>exmonlognor.dll</filepath>  </p> </li>
+</ul> <p>The rombuild scripts ensure that the crash logger for only one type
+of flash is placed into the ROM, and named as <filepath>exmonlog.dll</filepath>. </p> </section>
+<section id="GUID-7CAFA8C9-597C-5F20-AB15-22FFC7EFA203"><title>The crash reader</title> <p>At
+the next system boot, the crash reader application uses the normal system
+flash drivers to read the crash log from the reserved non-filesystem (non-uservisible)
+flash area, and to write it into the user-visible file system. </p> <p>The
+output file from the crash reader is a text file, or a compressed <filepath>GZIP-compatible</filepath> file. </p> <p>The
+crash reader application is called <filepath>crashread.exe</filepath>, which
+is built from <filepath>e32utils\crashread\crashread.mmp</filepath>. </p> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-4A2E212E-BC1B-5965-9A62-6309CC7CAAAB-master.png has changed
Binary file Adaptation/GUID-4A2E212E-BC1B-5965-9A62-6309CC7CAAAB_d0e61647_href.png has changed
Binary file Adaptation/GUID-4A2E212E-BC1B-5965-9A62-6309CC7CAAAB_d0e65116_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-4A910E9F-E881-51D7-A84A-CBC6AC343FD1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-4A910E9F-E881-51D7-A84A-CBC6AC343FD1" xml:lang="en"><title>Level
+2 Cache Macros</title><shortdesc>Describes the macros that define if the phone uses Level 2 cache.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The macros are used in the platform-specific configuration header file, <filepath>config.inc</filepath>,
+described in <xref href="GUID-2E4F8732-F253-5E0D-9A37-9476541E6004.dita">Platform-Specific
+Configuration Header</xref>. </p>
+<section id="GUID-B821E97C-BC53-4953-BE7D-12EC6DFD1A83"><title>CFG_HasL210Cache</title><codeblock id="GUID-46EB45BD-AF86-5501-B617-E9BC051B09A9" xml:space="preserve">CFG_HasL210Cache</codeblock><p>Includes
+support for the L210 cache in the bootstrap. </p> </section>
+<section id="GUID-9FAABE37-46B9-4821-8D2B-63C9168F71A3"><title>CFG_HasL220Cache</title><codeblock id="GUID-6D6C1D4C-5083-5C21-97B8-149B5378D4CF" xml:space="preserve">CFG_HasL220Cache</codeblock><p>Includes
+support for the L220 cache in the bootstrap. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-4AEF7595-17C0-513E-9568-B212E6194388.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,163 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-4AEF7595-17C0-513E-9568-B212E6194388" xml:lang="en"><title>Record
+operation</title><shortdesc>Describes the operation of the Sound Driver for sound recording.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-0722033C-4BC0-45D0-B980-C1FC680BBF70"><title>Client functions</title> <p>Many aspects regarding the way
+that the Sound Driver recording operates are similar to the way it handles
+playback. One difference is how the memory location in the <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita">Shared
+Chunks</xref> for the transfer is determined. In play requests, the client
+specifies the source location in the chunk for the transfer having arranged
+for the data to be loaded there prior to the request. For record requests,
+the client just requests a buffers worth of record data and allows the driver
+to decide which buffer to use for the request. </p> <p>The driver commences
+recording when the client issues the first <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-D96D7433-6CB5-3368-8B51-C19731C474AF"><apiname>RSoundSc::RecordData()</apiname></xref> request.
+However, unlike playback operation, once recording has commenced, the driver
+continues to record data into its available record buffers until it is told
+to stop. To stop the driver capturing record data, the client must either
+issue <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-16C40CF6-C84D-3901-8527-EA66842E0AAC"><apiname>RSoundSc::Pause()</apiname></xref> to temporarily suspend recording, <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-4B53ED55-EC95-35B3-B9D6-A24EF70D81F9"><apiname>RSoundSc::CancelRecordData()</apiname></xref> to
+terminate record operation, or close the driver channel altogether. </p> <p>The
+client specifies the number and size of the record buffers available to the
+driver within the shared chunk by calling either <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-1978D84C-6E2A-39C0-AF5F-17C85E5B25B4"><apiname>RSoundSc::SetBufferChunkCreate()</apiname></xref>,
+to create a buffer, or <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-46096E39-A530-3644-91F0-0B97AC3C6580"><apiname>RSoundSc::SetBufferChunkOpen()</apiname></xref> to
+open an existing buffer. </p> <p>When the driver starts recording, all the
+buffers in the shared chunk are empty, and the driver can use all of these
+available buffers. They are filled one by one, and if the client is slow to
+request the recorded data, then once the driver has filled all of the available
+empty buffers, it is forced to discard the earliest one filled and re-use
+this to continue recording data. </p> <p>Each time the client requests a buffers
+worth of recorded data with <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-D96D7433-6CB5-3368-8B51-C19731C474AF"><apiname>RSoundSc::RecordData()</apiname></xref>, it
+is given the earliest one filled. This buffer is now said to be in-use and
+unavailable to the driver for capturing. This buffer remains in-use until
+it is freed by the client with a call of <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-26F7C97B-D06A-32BE-90B3-2E6918BF3F4D"><apiname>RSoundSc::ReleaseBuffer()</apiname></xref>. </p> <p>When
+buffers are in use by the client the number of buffers available to the driver
+for capture is reduced. If the client is slow to release buffers and the number
+of available buffers falls to two then further <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-D96D7433-6CB5-3368-8B51-C19731C474AF"><apiname>RSoundSc::RecordData()</apiname></xref> requests
+fail with <codeph>KErrInUse</codeph> until the client has freed some buffers.
+The driver always needs a working set of at least two buffers in order to
+achieve uninterrupted data capture. The driver always has a current buffer
+which is actively being filled and another queued in advance. If the client
+fails to take buffers at full speed then they are discarded by the driver. </p><p><note> The
+driver does not slow down if it runs out of empty buffers. </note></p> <p><b>Buffers</b> </p> <p>The driver maintains three buffer lists: </p> <ul>
+<li id="GUID-D0B884B5-3687-5CB9-B732-1B028F0008A8"><p>free list </p> </li>
+<li id="GUID-3A3FAAA7-72C2-5A35-9F4D-3824966D3D52"><p>completed list </p> </li>
+<li id="GUID-E571D299-99C5-51D1-832E-55A88533B365"><p>in-use list. </p> </li>
+</ul> <p>A record buffer can only exist in one of these lists at any time.
+The free list contains buffers that are empty and not in use by the client.
+Once a buffer has been filled with record data it is moved into the completed
+buffer list. Here the buffer remains until it is passed back to the client
+in response to a record request. When a client is using the buffer it is deemed
+as in-use and is moved to the <i>in-use</i> list. Each time the client successfully
+calls <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-26F7C97B-D06A-32BE-90B3-2E6918BF3F4D"><apiname>RSoundSc::ReleaseBuffer()</apiname></xref> to free up a buffer then
+the driver moves this from the in-use list to the free list. </p> <p>The driver
+also maintains two record buffers which are excluded from any of the three
+lists. </p> <ul>
+<li id="GUID-3EB509DB-F35F-51E7-AAD9-8A25EEDAE604"><p>the current buffer,
+the one actively being filled with record data </p> </li>
+<li id="GUID-E109F4E5-998D-5B19-AE82-A913BBF4CED3"><p>the next buffer which
+becomes the active buffer once the current buffer is filled </p> </li>
+</ul> <p>During recording there may be DMA requests pending for both the current
+buffer and the next buffers. </p> <fig id="GUID-FBF47E94-8334-55D3-9AC0-FDAF1F9960B1">
+<title>                 The record buffer cycle               </title>
+<desc><p>The numbers one to five show the buffer cycle under normal operation,
+while the letters A to C show error induced operation. </p> </desc>
+<image href="GUID-1A92047A-3C1D-5B4C-949B-98D770F5F530_d0e32642_href.png" placement="inline"/>
+</fig> <p>When recording commences, the driver removes two buffers from the
+free list making one the current buffer and the other the next buffer (4 and
+5). </p> <p>When the current buffer is set as filled, the LDD normally adds
+this to the completed list (1). If a record error has occurred while recording
+to this buffer and it is only partially filled, or even empty then the buffer
+is still added to the completed list, as the client needs to be informed of
+the error (1). The only exception is in handling record pause, where a record
+buffer ends up being completed with no error and with no data added. In this
+case the buffer is added straight into the free list (A). </p> <p>Having added
+the current buffer to one of these lists, the driver moves the next buffer
+to the current buffer (5) and then obtains a new next buffer (4). In normal
+operation this comes from the free list but if the client is slow, this list
+may be empty and the buffer is taken from the completed list (B). This is
+a buffer overflow situation which is reported to the client as a response
+to its next <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-D96D7433-6CB5-3368-8B51-C19731C474AF"><apiname>RSoundSc::RecordData()</apiname></xref> request as <codeph>KErrOverFlow</codeph>. </p> <p>Whenever
+a buffer is filled, the driver checks if there is a record request pending
+(1). Similarly, when the driver processes a new record request it checks if
+a filled buffer is already available. In either case, if a request can be
+completed to the client then the earliest buffer completed is returned. If
+this buffer was filled successfully then it added to the in-use list (2).
+However, if an error occurred whilst filling the buffer then it is returned
+straight to the free list instead (C). </p> <p>Each time the client successfully
+calls <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-26F7C97B-D06A-32BE-90B3-2E6918BF3F4D"><apiname>RSoundSc::ReleaseBuffer()</apiname></xref> to free up a buffer then
+the driver moves this from the in-use list to the free list (3). </p> </section>
+<section id="GUID-548515F6-403D-4C99-AAA3-027C7D303C73"><title>Audio recording</title> <p><b>RecordData()</b> </p> <p>If
+the driver is not already recording data then the first <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-D96D7433-6CB5-3368-8B51-C19731C474AF"><apiname>RSoundSc::RecordData()</apiname></xref> request
+is handled in the context of the driver DFC thread, as access to the audio
+hardware is required to enable record operation. However, for efficiency,
+subsequent record requests from the client are handled entirely in the context
+of the calling thread, as access to the audio hardware is not required to
+handle the request. The driver only has to check whether there is a filled
+record buffer already available. If there is then the driver completes the
+request straight away. If not, the driver saves the details of the request
+until a filled buffer does become available. </p> <p>Returning to the case
+of a record request where the driver is not already in the process of recording
+data, the LDD first checks whether the client has specified or supplied a
+shared chunk to the driver channel and has set the audio configuration and
+record level. If the buffer configuration has not been specified then the
+driver cannot proceed and returns <codeph>KErrNotReady</codeph>. If the audio
+configuration or record level has not been specified then the LDD applies
+default settings to the audio hardware device for each instead by calling
+the functions <xref href="GUID-E1C67F8D-1A83-36B3-A451-22F496A659C6.dita#GUID-E1C67F8D-1A83-36B3-A451-22F496A659C6/GUID-23CEDA72-E161-30C4-B8D7-DBDCBC5B9C63"><apiname>DSoundSc::SetConfig()</apiname></xref> and <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-D893A29B-1A4B-35AF-876B-84D74B7E783C"><apiname>DSoundScPdd::SetVolume()</apiname></xref> on
+the PDD. </p> <p><b>StartTransfer()</b> </p> <p>Depending
+on the mapping attributes of the shared chunk, the LDD may now need to purge
+the region of the record chunk concerned. Next the LDD calls <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-54D3CC19-0C00-3FFA-BD1A-62618D36EB20"><apiname>DSoundScPdd::StartTransfer()</apiname></xref> on
+the PDD to allow it to prepare the audio hardware device for record data transfer. </p> <p><b>TransferData()</b> </p> <p>The LDD may need to break down the record buffer
+into memory fragments. These specify a physically contiguous region and are
+manageable by the PDD as a single transfer. The LDD queues as many transfer
+fragments of the current buffer on the PDD as it can accept with a call to <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-8C79D09B-317A-3D8E-B9C2-474812F17529"><apiname>DSoundScPdd::TransferData()</apiname></xref> for
+each fragment. If all fragments from the current buffer are accepted by the
+PDD then the LDD tries to queue fragments from the next buffer. As with playback,
+to support uninterrupted transfer of audio data the PDD must be able to accept
+multiple fragments simultaneously. As long as the LDD has transfer fragments
+still to queue, it continues to call <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-8C79D09B-317A-3D8E-B9C2-474812F17529"><apiname>DSoundScPdd::TransferData()</apiname></xref> until
+the PDD signals that it has temporarily reached its capacity by returning <codeph>KErrNotReady</codeph>. </p> <p><b>RecordCallBack()</b> </p> <p>Each time the PDD completes the transfer
+of a fragment from a record buffer, it must signal this event back to the
+LDD by calling the function <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita#GUID-5807543D-A30F-3EB9-8F28-91A623B0D484/GUID-9112E399-DC3C-334F-BE16-B5F42216F903"><apiname>DSoundScLdd::RecordCallBack()</apiname></xref>.
+This must always be called in the context of the driver DFC thread. In executing <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita#GUID-5807543D-A30F-3EB9-8F28-91A623B0D484/GUID-434E378F-0C48-39D9-8FB8-9831A1F704C0"><apiname>DSoundScLdd::RecordCallback()</apiname></xref>,
+the LDD checks whether the entire transfer for the current buffer is now complete.
+If so, depending on the mapping attributes of the shared chunk, the LDD may
+need to purge the region of the record client. The LDD attempts to queue further
+fragments on the PDD, by calling <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-8C79D09B-317A-3D8E-B9C2-474812F17529"><apiname>DSoundScPdd::TransferData()</apiname></xref>,
+which should now have the capability to accept more transfers. So, the PDD
+should be written to handle calls to <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-8C79D09B-317A-3D8E-B9C2-474812F17529"><apiname>DSoundScPdd::TransferData()</apiname></xref> within
+its call back to <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita#GUID-5807543D-A30F-3EB9-8F28-91A623B0D484/GUID-434E378F-0C48-39D9-8FB8-9831A1F704C0"><apiname>DSoundScLdd::RecordCallback()</apiname></xref>. </p> </section>
+<section id="GUID-7B5CF9A4-8527-4C76-96CD-C03F861AF3BF"><title>Pause and resume audio recording</title> <p>The client can
+temporarily halt the progress of audio record at any time by issuing <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita#GUID-5807543D-A30F-3EB9-8F28-91A623B0D484/GUID-D912620F-9C51-3AFC-8A59-31AF9455AC4A"><apiname>DSoundScLdd::Pause()</apiname></xref>.
+To configure the audio hardware device to halt recording, the LDD calls <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-0608766F-2645-3E28-B804-BD4B953DB5FF"><apiname>DSoundScPdd::PauseTransfer()</apiname></xref> on
+the PDD. This time, any active transfer should be aborted by the PDD. If a
+recording is halted the PDD must signal this event with a single call of the
+LDD function <xref href="GUID-3731902C-9C34-3FAE-8F82-9F9493C2C2E7.dita#GUID-3731902C-9C34-3FAE-8F82-9F9493C2C2E7/GUID-73F74080-6219-3D9A-BA56-735A17A9ABA0"><apiname>DSOundScLdd::RecordCallback()</apiname></xref>, which reports
+back any partial data already received. In this case, if transfer is resumed
+later, the LDD issues a new <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-8C79D09B-317A-3D8E-B9C2-474812F17529"><apiname>DSoundScPdd::TransferData()</apiname></xref> request
+to commence data transfer after calling <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-C692BF61-FA3D-3B85-BCC6-1248C9C7D9BF"><apiname>DSoundScPdd::ResumeTransfer()</apiname></xref>.
+As access to the hardware is required in both cases, pause and resume are
+handled in the context of the driver DFC thread. </p> </section>
+<section id="GUID-BA951968-290F-4DA5-842A-2004664B1139"><title>Error handling during recording</title> <p>If the PDD reports
+an error when setting up the audio hardware device for recording then the
+LDD immediately completes the first record request back to the client returning
+the error value as the result. It will not restart record data transfer unless
+it receives a further record request from the client. </p> <p>If the PDD reports
+an error when commencing the transfer of a record fragment or as the result
+of the transfer of a record fragment, then the LDD ceases transfer to that
+record buffer and instead reports the error back to the client. The error
+is returned in response to the record request which corresponds with that
+buffer. </p> <p>Unexpected errors from the PDD are returned to the LDD via
+the functions <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-8C79D09B-317A-3D8E-B9C2-474812F17529"><apiname>DSoundScPdd::TransferData()</apiname></xref> and <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita#GUID-5807543D-A30F-3EB9-8F28-91A623B0D484/GUID-434E378F-0C48-39D9-8FB8-9831A1F704C0"><apiname>DSoundScLdd::RecordCallback()</apiname></xref>. </p> <p>The
+LDD does not try to cancel the transfer of other fragments for the same buffer
+that are already queued on the PDD, but it ignores their outcome. However,
+the LDD does try to carry on with the transfer to other available record buffers. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-4AFDA3FF-38D1-5EFE-B18A-E3EAAA52EB75.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-4AFDA3FF-38D1-5EFE-B18A-E3EAAA52EB75" xml:lang="en"><title>Flash
+Guide</title><shortdesc> Flash memory is a class of memory that can retain its contents
+even after the power has been switched off.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-71F0C83A-D03C-5CF7-9395-C7BD746B25A8"><title>Introduction</title> <p>Unlike
+ROM, the data in Flash memory can be changed by an application. </p> </section>
+<section id="GUID-97937125-353C-4043-B430-0327E214C87B"><title>Flash memory features</title> <p>  Features of Flash memory
+are:</p><ul>
+<li><p> Writing and erasing of memory has to be undertaken in blocks of memory</p></li>
+<li><p> Memory contents are retained until erased (regardless of whether the
+power has been turned on/off). </p></li>
+</ul></section>
+<section id="GUID-70642797-8164-462D-9542-05E8CB343629"><title>Flash memory limitations</title> <p>The following are limitations
+of FLASH memory: </p><ul>
+<li><p>There are a finite number of erase-write cycles (usually 100,000).</p></li>
+<li><p>NAND Flash cannot be executed in place. Instead the contents have to
+be loaded into RAM and then executed. </p></li>
+</ul></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-4C4515EA-A5DD-56B4-94B0-EE48D66013F7.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-4C4515EA-A5DD-56B4-94B0-EE48D66013F7" xml:lang="en"><title>Read Data from USB using Shared Chunks </title><shortdesc>This tutorial describes how to read shared chunk data from
+a USB connection. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-0197C58A-668F-4C8F-966B-A41F31F41A7A"><title>Read data</title> <p>To read data from the host to
+the device (<codeph>Out</codeph>) call the function <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-4BE585C8-89BF-31D6-865D-85F6C7CBF88B"><apiname>RDevUsbcScClient::ReadDataNotify()</apiname></xref> to make a request to wait for data in the specified buffer and wait
+for it to complete. </p> <p>If the buffer already has data in it,
+it will return immediately with the code <codeph>KErrCompletion</codeph>. If there is no data in the buffer an asynchronous request is set
+up that will complete when data is available. <b>Note</b>: check the
+return code before attempting to wait for the request to complete. </p> <codeblock id="GUID-655AFB03-5EC8-5CA5-A15B-8DFC33126026" xml:space="preserve">TUsbcScHdrEndpointRecord* epInfo;
+TRequestStatus status;
+
+TUsbcScChunkHeader chunkHeader(gChunk);
+    
+chunkHeader.GetBuffer(0, 2, epInfo);  
+TInt outBuffNum = epInfo-&gt;iBufferNo;
+
+r = gPort.ReadDataNotify(outBuffNum,status);</codeblock> <p>The first
+parameter required by <codeph>ReadDataNotify()</codeph> is the endpoint
+buffer number. The endpoint buffer number can be found in the alternate
+setting table in the chunk header. The location of the buffer can
+be found by looking at the buffer offset table, which is also in the
+chunk header. </p> <p>When the request has completed, process the
+data in the buffer that was read from the driver. </p> <p>The transfer
+buffer for an IN endpoint is always pointed to by the <codeph>iTail</codeph> member of the endpoint buffer struct <xref href="GUID-8A844723-82FA-3BB8-B6AD-4E5FC6B5431B.dita"><apiname>SUsbcScBufferHeader</apiname></xref>. When finished processing the current chunk move <codeph>iTail</codeph> to point to the next transfer buffer. </p> <codeblock id="GUID-FA53E100-1C6F-5252-9FC3-586EF4467EC6" xml:space="preserve">iTransfer = (TUsbcScTransferHeader*) (iHeader-&gt;iTail + iBase);
+... // Process data
+iHeader-&gt;iTail = iTransfer-&gt;iNext;</codeblock> <p>If there is no more
+data to be read then close the channel and unload the driver. </p> </section>
+<section id="GUID-F015D0C6-0325-45CA-A6FD-2E6E1D7FB78D"><title>Next steps</title> <p>When you have finished reading
+and writing <xref href="GUID-BE73CFE6-D48D-5B92-AF49-E2D967ADF0EC.dita">Close and Unload the Driver</xref>. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-4C5DB74E-41A5-53CB-A053-CBBEADD31AFF.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-4C5DB74E-41A5-53CB-A053-CBBEADD31AFF" xml:lang="en"><title>Architecture</title><shortdesc>Describes the architecture of the DMA Framework.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The following diagram shows the main parts of the architecture: </p>
+<fig id="GUID-E25AE30D-8EC9-530F-BD3C-FF4D6E5B9049">
+<image href="GUID-AC7830F9-C3FB-5117-B851-1D106AE400D4_d0e10568_href.png" placement="inline"/>
+</fig>
+<p>The DMA Framework is implemented as a single DLL, which is split into two
+layers: </p>
+<ul>
+<li id="GUID-FE402AA7-2E91-56F2-9424-7ADCB30E5D43"><p>a platform independent
+layer that implements the behaviour that is common to all hardware </p> </li>
+<li id="GUID-3EB73B07-D1BF-5D05-957D-6DB8A3F3D4F2"><p>a platform specific
+layer that implements the behaviour that is specific to a particular platform. </p> </li>
+</ul>
+<p>The DLL is called <filepath>dma.dll</filepath>, and is implemented as a
+kernel extension, which means that it is loaded very early during system initialisation. </p>
+<p>The platform specific layer interfaces to the DMA controller hardware via
+the I/O port constants and functions exposed by the ASSP DLL and/or Variant
+DLL. </p>
+<p>The clients of the DMA Framework are physical device drivers (PDD). </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-4C8E40EE-8CC9-4737-A28E-A18E89356718.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-4C8E40EE-8CC9-4737-A28E-A18E89356718" xml:lang="en"><title>Time</title><shortdesc>Describes the Time platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
Binary file Adaptation/GUID-4CB3C746-606F-4533-8BBB-4A1254A74772-master.png has changed
Binary file Adaptation/GUID-4CB3C746-606F-4533-8BBB-4A1254A74772_d0e94716_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-4DAC39E0-2EC2-40F7-9AEF-4FDA09F1A151.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-4DAC39E0-2EC2-40F7-9AEF-4FDA09F1A151" xml:lang="en"><title>Asynchronous
+Requests</title><shortdesc>This document discusses the use of asynchronous requests by device
+drivers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>An asynchronous request is typically used to start an operation on a device
+that completes at a later point of time. It returns immediately after starting
+the operation on the device or making a request to the driver. The user side
+thread is not blocked and can continue with other operations, including issuing
+other requests (synchronous or asynchronous). </p>
+<p>A driver lists the available asynchronous request types in an enumeration. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-4E3C086B-25BE-4DAC-9E21-CFC4F8B792A5.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,121 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-4E3C086B-25BE-4DAC-9E21-CFC4F8B792A5" xml:lang="en"><title>DMA Technology Guide</title><shortdesc>Describes the Direct Memory Access framework.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-E987EF55-27CE-4EC2-B250-2C3D7C36CAF9"><title>Purpose</title><p>The DMA framework provides a generic simple interface for the
+clients to access DMA resources in a device. The primary clients are
+device drivers that will use the DMA framework to set up DMA transfers.
+A device can have more than one DMA controller (DMAC). </p></section>
+<section id="GUID-7607CC80-0FA0-4FC2-897A-C4AB6B6C74FC"><title>Architectural
+concepts</title><p>The key concepts related to DMA framework are:</p><fig id="GUID-ECCF1F57-DBD0-4653-A631-F8972E24DECF">
+<title>DMA Framework</title>
+<image href="GUID-10FE825A-4383-4A10-A507-58577BB230FB_d0e89974_href.png" placement="inline"/>
+</fig><dl>
+<dlentry>
+<dt>DMA Client</dt>
+<dd><p>A device driver or a kernel object that needs to use the resources
+of the DMA framework. On the Symbian platform, the Physical Device
+Drivers are the primary clients of the DMA framework. </p></dd>
+</dlentry>
+<dlentry>
+<dt>DMA Platform Service API</dt>
+<dd><p>The generic interface to provide DMA services to the clients.</p></dd>
+</dlentry>
+<dlentry>
+<dt>DMA Import Library</dt>
+<dd><p>The DMA clients link against the <filepath>dma.lib</filepath> file.</p></dd>
+</dlentry>
+<dlentry>
+<dt>DMA Platform-Independent Layer (PIL)</dt>
+<dd><p>The platform-independent layer contains the generic framework
+independent from the hardware.</p></dd>
+</dlentry>
+<dlentry>
+<dt>DMA Platform-Specific Layer (PSL)</dt>
+<dd><p>The platform-specific layer is specific to the baseport and
+the hardware used.</p></dd>
+</dlentry>
+<dlentry>
+<dt>DMA Controller (DMAC)</dt>
+<dd><p>The DMAC is the DMA hardware implementation. The number of
+DMAC in the implementation of the DMA Framework depends on the hardware.
+The DMAC is a peripheral to the CPU and is programmed to control data
+transfers without using the CPU. </p></dd>
+</dlentry>
+</dl></section>
+<section id="GUID-CAC0FE8F-A338-4B0E-92ED-7A1D1FD52C24"><title>DMA
+functionality</title><p>The key concepts related to functionality
+provided by the DMA framework are:</p><dl>
+<dlentry>
+<dt>Scatter/Gather Mode</dt>
+<dd><p>Some DMA controllers transfer data using scatter/gather mode.
+In this mode, the operating system creates a DMA descriptor with source
+and destination memory addresses and the configuration. The source
+and destination data can be a list of scattered memory blocks. The
+DMA controller uses this configuration to perform the data transfer.</p></dd>
+</dlentry>
+<dlentry>
+<dt>DMA Descriptors</dt>
+<dd><p>The data structure used by the DMA framework to store the configuration
+of the data transfer. These will store details such as source address,
+destination address, number of bytes and pointer to the next descriptor,
+when the DMA is used to transfer disjoint blocks of data. This structure
+is defined in the platform specific layer. The descriptors are always
+used to store the configuration even if the DMA controller does not
+support scatter/gather mode. When the scatter/gather mode is not supported
+by the DMAC, the descriptors used to store the configuration are called
+as pseudo-descriptors.</p></dd>
+</dlentry>
+<dlentry>
+<dt>Descriptor Headers</dt>
+<dd><p>The descriptor headers are used to store additional information
+about the descriptors. The descriptors are accessed using the descriptor
+headers which contain the pointer to the descriptor.</p></dd>
+</dlentry>
+<dlentry>
+<dt>Transfer Request</dt>
+<dd><p>The device drivers configure and initialize a data transfer
+using the class <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita"><apiname>DDmaRequest</apiname></xref>. The data can be transferred
+between:<ul>
+<li><p>memory to memory</p></li>
+<li><p>memory to peripheral</p></li>
+<li><p>peripheral to memory</p></li>
+</ul>The transfer request stores the callback function of the clients.
+The callback function is used to notify the success or failure of
+a data transfer.</p></dd>
+</dlentry>
+<dlentry>
+<dt>DMA Channel</dt>
+<dd><p>The object which represents a single hardware, logical or a
+virtual channel. In the DMA platform service API, each DMA channel
+is referred to by a 32-bit value called a cookie. Each DMA transfer
+is in the form of a description header and its associated DMA descriptor.
+The queue of transfer requests (both being transferred and pending)
+consists of a linked list of the DMA headers. </p></dd>
+</dlentry>
+<dlentry>
+<dt>DMA Channel Allocator</dt>
+<dd><p>The channel manager controls the opening and closing of DMA
+channels. The channel manager functions are defined in the platform
+independent layer and implemented in the platform specific layer. </p></dd>
+</dlentry>
+</dl></section>
+<section id="GUID-F64155FC-5245-447F-88E7-C642EDEB2CEE"><title>Typical
+Uses</title><p>The typical use cases of a DMA framework are:</p><ul>
+<li><p>programmable data transfer between hardware peripherals and
+memory buffers</p></li>
+<li><p>programmable data transfer of block of data between different
+regions of memory</p></li>
+</ul></section>
+</conbody><related-links>
+<link href="http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.ddi0424b/index.html.dita">
+<linktext>ARM DMA Controller Reference Manual</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-4E6520E8-4BF1-55D1-B643-81B8D2816D1D-master.png has changed
Binary file Adaptation/GUID-4E6520E8-4BF1-55D1-B643-81B8D2816D1D_d0e5246_href.png has changed
Binary file Adaptation/GUID-4FDD1F7B-1A4E-5389-A0A4-22727CD42B5B-master.png has changed
Binary file Adaptation/GUID-4FDD1F7B-1A4E-5389-A0A4-22727CD42B5B_d0e9110_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-50217E69-F4A9-4B9F-8608-419783046A1E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-50217E69-F4A9-4B9F-8608-419783046A1E" xml:lang="en"><title>Register Access Quick Start Guide</title><shortdesc>Register Access is used to read/write/modify values on
+only the ASSP hardware.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Register Access platform service is used by many of the other
+platform services for either reading values from or setting the configuration
+of hardware in the device.</p>
+<section id="GUID-04B0F9F2-A800-4FE0-A0E3-AB20B09039A7"><title>Getting
+started</title><ul>
+<li><p>The <xref href="GUID-A25FFD79-0797-43EC-8975-8C23E7E539C4.dita">Register Access Technology Guide</xref> describes the key concepts
+of the Register Access platform service.</p></li>
+<li><p>The <xref href="GUID-DB55C1A0-2901-4661-B6B1-3B61BF6FF4FA.dita">Register Access Client Interface Guide</xref> describes the Register
+Access platform service API and its use by device drivers. </p></li>
+<li><p>The <xref href="GUID-07E0DEC0-A749-4B14-9E73-3AF8ACD28BC6.dita">Register Access Implementation</xref> section describes the implementation
+of the Register Access PSL.</p></li>
+<li><p>The <xref href="GUID-463915EE-25DB-4ABD-AA80-1C10CD242072.dita">Register Access Build Guide</xref> describes how to include the Register
+Access platform service in a ROM image.</p></li>
+<li><p>The <xref href="GUID-31FFA810-129A-4E35-A47F-C6D3C1C71D5E.dita">Register Access Tools Guide</xref> describes the tools that are specific
+to the Register Access platform service.</p></li>
+<li><p>The <xref href="GUID-C34DFF54-87C5-47F6-B0AE-3B066DC7F5A0.dita">Register Access Testing Guide</xref> explains how to test the functionality
+of the Register Access platform service.</p></li>
+</ul></section>
+<section id="GUID-EAB1F5D0-D340-4578-8ECB-E325440261EC-GENID-1-2-1-10-1-5-1-8-1-1-5-1-3-3"><title>Users</title><p>Since this platform service is used by many of the other platform
+services, it is of interest to both device driver developers and hardware
+implementors.</p><fig id="GUID-0651B065-C442-45C1-A45B-E7946CCE6430">
+<title>AsspRegister class diagram</title>
+<image href="GUID-F55A0CB4-0AB6-4DE3-9DFA-FBCB7131BB3A_d0e98263_href.png" placement="inline"/>
+</fig></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,722 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10" xml:lang="en"><title>Shared
+Chunks</title><shortdesc>A shared chunk is a mechanism that kernel-side code uses to share
+memory buffers safely with user-side code. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>A shared chunk is a mechanism that kernel-side code can use to share memory
+buffers safely with user-side code. This topic describes this concept, and
+explains how to use the shared chunk APIs. </p>
+<ul>
+<li id="GUID-2D439828-C4DB-5D0F-83EF-46EDD9D2C2CF"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-F09BAE7B-805F-5CF1-8C9A-AD23C50026AD">What are shared chunks?</xref>  </p> </li>
+<li id="GUID-EE669369-2315-5EB3-A4EF-CF1778DF4432"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-FBFA1B23-C6CA-5E9A-A461-E4822EB9E76F">Creating a shared chunk</xref>  </p> </li>
+<li id="GUID-0BE8F408-05E8-5F1A-987A-E35CD8D92703"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-D55514EA-D218-52F2-807B-78D58E99D810">Opening a handle to the shared chunk for user-side access</xref>  </p> </li>
+<li id="GUID-5A0B2A6A-169F-5158-B554-A346C34C16D7"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-F63A506B-1573-5F6A-B0C7-CEE5BF1FAD72">Discarding a handle</xref>  </p> </li>
+<li id="GUID-9ED0C21B-5B51-5E38-B77F-96E879E9A053"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-86446948-6012-59B9-8411-BF0E98DC7D3A">Closing and destroying a shared chunk</xref>  </p> </li>
+<li id="GUID-9E297A46-9C63-59C2-A515-1AB8F3BD09BA"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-6D3AAC95-E52B-5E78-B57E-0433ECF14C3A">Committing memory</xref>  </p> </li>
+<li id="GUID-BF5A0349-1DD7-5266-9F86-1DC3F73CC2CC"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-E9630D2D-794B-5AB1-8980-0927E040C0C5">Passing data from user-side code to another device driver</xref>  </p> </li>
+<li id="GUID-EA0A1F4A-DB1D-55F8-8EB1-C3E139AA9B47"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-4C374CF0-0680-5A27-94E7-BB0FD75413AF">Passing data between user-side code</xref>  </p> </li>
+<li id="GUID-A0448628-461A-52F9-A2D4-DE3863005966"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-A8FF0519-9FDC-53D5-8BD6-A3AEA6BFDD46">Direct peripheral access to shared chunks</xref>  </p> </li>
+<li id="GUID-C6A46B05-12C8-5459-ABD7-0BD173E36580"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-D8E298EA-A4CD-5501-B5F1-B8F0EE93CE84"> Example code</xref>  </p> <ul>
+<li id="GUID-B17ECEF5-920C-516C-80D1-15AFD3FAA282"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-D284D6D0-400D-53D2-9A43-05CEE28DFDC4">Example: Creating a shared chunk</xref>  </p> </li>
+<li id="GUID-75FB5604-6468-502B-A005-38D81DE03588"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-6501F90A-5330-5BC9-A991-A3BECCCA6CDD">Example: Opening a handle to the shared chunk for user-side access</xref>  </p> </li>
+<li id="GUID-FF092178-84C4-5996-85C2-6B9E111EFFD6"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-062C405B-B10F-54A8-8F61-418CAE6019D8">Example: Using a DFC to notify destruction of chunk</xref>  </p> </li>
+<li id="GUID-02D42EFC-B20B-5E34-B555-657DC5DFB748"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-97BF15A2-E74A-51DE-B003-16E1DFF8964E">Example: Committing memory</xref>  </p> </li>
+</ul> </li>
+</ul>
+<p>You may find it useful to refer to the general sections : <xref href="GUID-8D80AA51-5108-5D4B-B6B9-7FA47570AB89.dita">Device
+Driver Concepts</xref> and <xref href="GUID-4A402DAD-99D3-595E-87FD-AAB5A970D6CC.dita">Device
+Driver Framework</xref>. </p>
+<section id="GUID-F09BAE7B-805F-5CF1-8C9A-AD23C50026AD"><title>What are shared
+chunks?</title> <p>A shared chunk is a mechanism that kernel-side code uses
+to share memory buffers safely with user-side code. References to kernel-side
+code always mean device driver code. </p> <p>The main points to note about
+shared chunks are: </p> <ul>
+<li id="GUID-9B4BC2DE-59AD-50F9-AF37-4966D741741A"><p>They can be created
+and destroyed only by device drivers. It is typical behaviour for user-side
+code, which in this context we refer to as the <i>client</i> of the device
+driver, to pass a request to the device driver for a handle to a shared chunk.
+This causes the device driver to open a handle to the chunk and return the
+handle <i>value</i> to the client. Successful handle creation also causes
+the chunk's memory to be mapped into the address space of the process to which
+the client's thread belongs. Note, however, that the driver dictates <i>when</i> the
+chunk needs to be created, and <i>when</i> memory needs to be committed. </p> </li>
+<li id="GUID-B5D39B0E-150A-56E8-A396-EDDC36D3061B"><p>Like all kernel-side
+objects, a shared chunk is reference counted. This means that it remains in
+existence for as long as the reference count is greater than zero. Once all
+opened references to the shared chunk have been <i>closed</i>, regardless
+of whether the references are user-side or kernel-side, it is destroyed. </p> </li>
+<li id="GUID-348564CB-647F-5658-9DDC-5E0B022B7644"><p>User-side code that
+has gained access to a shared chunk from one device driver can pass this to
+a second device driver. The second device driver must <i>open</i> the chunk
+before it can be used. </p> </li>
+<li id="GUID-8496E32C-48C7-5778-B886-0F63C6EF7ED6"><p>More than one user-side
+application can access the data in a shared chunk. A handle to a shared chunk
+can be passed from one process to another using standard handle passing mechanisms.
+In practice, handles are almost always passed in a client-server context via
+inter process communication (IPC). </p> </li>
+<li id="GUID-8F0AAFD5-661A-5569-AABF-C88287DF836B"><p>Processes that share
+the data inside a chunk should communicate the location of that data as an
+offset from the start of the chunk, and <i>not</i> as an absolute address.
+The shared chunk may appear at different addresses in the address spaces of
+different user processes. </p> </li>
+</ul> </section>
+<section id="GUID-FBFA1B23-C6CA-5E9A-A461-E4822EB9E76F"><title>Creating a
+shared chunk</title> <p>A shared chunk can be created only by code running
+on the kernel-side. This means that it is the device driver's responsibility
+to create a chunk that is to be shared by user-side code. There is <i>no user-side
+API</i> that allows user-side code to create shared chunks. </p> <p>The device
+driver creates a shared chunk using the <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-F8D1FB29-7238-3438-951A-6F853C7CF817"><apiname>Kern::ChunkCreate()</apiname></xref> function.
+It passes to this function a <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita"><apiname>TChunkCreateInfo</apiname></xref> object containing
+the required attributes for that chunk. The most important attribute is the <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita#GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4/GUID-B00A3693-50B6-3A84-89E0-B06D9ABE82ED"><apiname>TChunkCreateInfo::ESharedKernelMultiple</apiname></xref> attribute
+that states that a shared chunk is to be created. </p> <p>Chunks are reference
+counted kernel objects. When the chunk is created, the reference count is
+set to one. </p> <p>See <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-D284D6D0-400D-53D2-9A43-05CEE28DFDC4">Example:
+Creating a shared chunk</xref>. </p> </section>
+<section id="GUID-D55514EA-D218-52F2-807B-78D58E99D810"><title>Opening a handle
+to the shared chunk for user-side access</title> <p>Before user-side code
+can access the memory in a shared chunk, the device driver must create a handle
+to the chunk and then pass the value back to the user-side. It does this by
+calling the <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-BA56B205-60D8-326E-8340-3F78CCEA3DD1"><apiname>Kern::MakeHandleAndOpen()</apiname></xref> function, passing
+the information: </p> <ul>
+<li id="GUID-178CFDE6-BBB0-5A37-A680-13F4E0463248"><p>a pointer to the user-side
+code's thread (or NULL if referring to the current thread) </p> </li>
+<li id="GUID-7A39F8FA-B7E8-5E27-BA07-D1CA6179B8BF"><p>a pointer to the shared
+chunk </p> </li>
+</ul> <p>Typically, the device driver does this in response to a request from
+the user-side. <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-BA56B205-60D8-326E-8340-3F78CCEA3DD1"><apiname>Kern::MakeHandleAndOpen()</apiname></xref> also maps the
+chunk's memory into the address space of the user-side code's thread. </p> <p>If
+the creation of the handle is successful, the device driver returns the handle <i>value</i> back
+to the user-side. The user-side code then assigns the value to an <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita"><apiname>RChunk</apiname></xref> object
+using one of <codeph>RChunk</codeph>'s base class functions: </p> <ul>
+<li id="GUID-091419E2-3BA4-5821-8138-A1047A6070BF"><p> <xref href="GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB.dita#GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB/GUID-C7E88CD7-A32B-3585-9D8B-3A0726947690"><apiname>RHandleBase::SetHandle()</apiname></xref>  </p> </li>
+<li id="GUID-7974DC49-8CDA-5660-9C8D-709D1FDCA478"><p> <xref href="GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB.dita#GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB/GUID-9AEAD2B5-4531-3157-839C-CBAECBFCF069"><apiname>RHandleBase::SetReturnedHandle()</apiname></xref>  </p> </li>
+</ul> <p>The user-side code uses <xref href="GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB.dita#GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB/GUID-9AEAD2B5-4531-3157-839C-CBAECBFCF069"><apiname>RHandleBase::SetReturnedHandle()</apiname></xref> if
+the device driver returns either a positive handle value or a negative error
+code. A negative error code means that handle creation has failed. </p> <p>Opening
+a handle to a shared chunk increases the reference count by one. </p> <p>See <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-6501F90A-5330-5BC9-A991-A3BECCCA6CDD">Example:
+Opening a handle to the shared chunk for user-side access</xref>. </p> </section>
+<section id="GUID-F63A506B-1573-5F6A-B0C7-CEE5BF1FAD72"><title>Closing a handle</title> <p>After
+it has been opened, a device driver may need to perform further operations
+before the handle can be returned to the user-side. If these operations fail,
+the device driver code may want to unwind the processing it has done, including
+discarding the handle it has just created. It does this using the function <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-71A20F01-5E5F-3B27-92BA-3B3BF7D578C9"><apiname>Kern::CloseHandle()</apiname></xref>. </p> <p>This
+reverses the operation performed by <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-BA56B205-60D8-326E-8340-3F78CCEA3DD1"><apiname>Kern::MakeHandleAndOpen()</apiname></xref>. </p> </section>
+<section id="GUID-86446948-6012-59B9-8411-BF0E98DC7D3A"><title>Closing and
+destroying a shared chunk</title> <p>There is no explicit method for deleting
+or destroying shared chunks. Instead, because chunks are reference counted
+kernel objects, a device driver can use the function <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-480F655A-5B93-3E8A-8964-3A04682C3CCF"><apiname>Kern::ChunkClose()</apiname></xref>.
+This function decrements a chunk's access count, and, if the count reaches
+zero, the chunk is scheduled for destruction. </p> <p>The chunk is not be
+destroyed immediately. Instead it is done asynchronously. If the device driver
+needs to know when the chunk has been destroyed, it must specify a DFC (Deferred
+Function Call) at the time the chunk is created. The device driver specifies
+the DFC through the <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita#GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4/GUID-58271733-146A-3ECB-91AC-C38BD2ADC9A0"><apiname>TChunkCreateInfo::iDestroyedDfc</apiname></xref> member.
+The DFC is queued to run only when the chunk has finally been destroyed. At
+this point it is guaranteed that the memory mapped by the chunk can no longer
+be accessed by any code. This is useful in cases where chunks are used to
+map I/O devices or other special memory, and the program managing these needs
+to know when they are free to be reused. </p> <p> <b> Note:</b> For each call
+to <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-F8D1FB29-7238-3438-951A-6F853C7CF817"><apiname>Kern::ChunkCreate()</apiname></xref> and <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-DAEE47C8-40ED-3F95-9EE9-29033FC5A8D3"><apiname>Kern::OpenSharedChunk()</apiname></xref> there
+should be <i>exactly one</i> call to <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-480F655A-5B93-3E8A-8964-3A04682C3CCF"><apiname>Kern::ChunkClose()</apiname></xref>.
+Calling <codeph>Close()</codeph> too few times can cause memory leaks. Calling <codeph>Close()</codeph> too
+many times can cause the chunk to be destroyed while a program is still trying
+to access the memory, which causes an application panic for user code and
+a system crash for kernel code. </p> </section>
+<section id="GUID-6D3AAC95-E52B-5E78-B57E-0433ECF14C3A"><title>Committing
+memory</title> <p>After a shared chunk has been created it owns a region of
+contiguous virtual addresses. This region is empty, which means that it is
+not mapped to any physical RAM or memory mapped I/O devices. </p> <p>Before
+the chunk can be used, the virtual memory must be mapped to real physical
+memory. This is known as <i>committing</i> memory. </p> <p><b>Committing RAM
+from the system free memory pool</b> </p> <p>You can commit RAM taken from
+the system free memory pool using the following ways: </p> <ul>
+<li id="GUID-7E755F49-D5E6-538C-9CE1-947310DD94A7"><p>by committing an arbitrary
+set of pages. Use the function <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-9FCD7C2A-5192-3B99-8ACF-2802C1A3FAA1"><apiname>Kern::ChunkCommit()</apiname></xref>. </p> </li>
+<li id="GUID-738B8FF3-5848-54F9-B872-179317BE9B4B"><p>by committing a set
+of pages with physically contiguous addresses. Use the function <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-E1B88A30-6572-3E0B-B6BB-ED4359D7A5FD"><apiname>Kern::ChunkCommitContiguous()</apiname></xref>. </p> </li>
+</ul> <p><b>Committing specified physical addresses</b> </p> <p>You can commit
+specific physical addresses, but only if you set the data member <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita#GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4/GUID-106850A0-5498-387F-AF70-F9D04EB6318D"><apiname>TChunkCreateInfo::iOwnsMemory</apiname></xref> to <xref href="GUID-A759CA2D-8327-348F-9337-4886E619D920.dita"><apiname>EFalse</apiname></xref> when
+you create the shared chunk - see <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-FBFA1B23-C6CA-5E9A-A461-E4822EB9E76F">Creating
+a shared chunk</xref>. </p> <p>You can use the following ways to do this: </p> <ul>
+<li id="GUID-2DCE4AB8-A5CF-536C-8FC1-414755AAC894"><p>by committing a region
+of contiguous addresses. Use the function <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-F3A3D9F5-5885-38B2-9711-1DF99C36F62D"><apiname>Kern::ChunkCommitPhysical()</apiname></xref> with
+the signature: </p> <codeblock id="GUID-E159781F-7B60-5A2B-A8EE-3BB6B9CEADBB" xml:space="preserve">TInt Kern::ChunkCommitPhysical(DChunk*, TInt, TInt, TUint32)</codeblock> </li>
+<li id="GUID-5CC4AB75-BF24-5C86-B87B-CA4CDFF6ED5E"><p>by committing an arbitrary
+set of physical pages. Use the function <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-F3A3D9F5-5885-38B2-9711-1DF99C36F62D"><apiname>Kern::ChunkCommitPhysical()</apiname></xref> with
+the signature: </p> <codeblock id="GUID-321BD1CC-95D4-5539-9C24-187944AA9D90" xml:space="preserve">TInt Kern::ChunkCommitPhysical(DChunk*, TInt, TInt, const TUint32*)</codeblock> </li>
+</ul> <p>Note: the same physical memory can be committed to two different <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita"><apiname>RChunk</apiname></xref> s
+or shared chunks at the same time, where each <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita"><apiname>RChunk</apiname></xref> has
+a different owner, as long as your turn OFF the caches. </p> </section>
+<section id="GUID-E9630D2D-794B-5AB1-8980-0927E040C0C5"><title>Passing data
+from user-side code to another device driver</title> <p>User-side code that
+has access to a shared chunk from one device driver may want to use this when
+it communicates with another device driver. To enable this, the second device
+driver needs to gain access to the chunk and the addresses used by the memory
+it represents. </p> <p>The second driver must open a handle on the shared
+chunk before any of its code can safely access the memory represented by that
+chunk. Once it has done this, the reference counted nature of chunks means
+that the chunk, and the memory it represents, remains accessible until the
+chunk is closed. </p> <p>The general pattern is: </p> <ul>
+<li id="GUID-03CA36B3-E327-5632-BAC4-80386B6EADC5"><p>the first device driver
+creates the shared chunk. </p> <p>See <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-FBFA1B23-C6CA-5E9A-A461-E4822EB9E76F">Creating
+a shared chunk</xref>. </p> </li>
+<li id="GUID-510CA2F2-B9D5-5342-8739-566EBC0BAAC9"><p>the user-side gets the
+handle <i>value</i> from the first device driver and calls <codeph>SetHandle()</codeph> or <codeph>SetReturnedHandle()</codeph> on
+an <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita"><apiname>RChunk</apiname></xref> object [the functions are members of <codeph>RChunk</codeph>'s
+base class <xref href="GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB.dita"><apiname>RHandleBase</apiname></xref> (see <xref href="GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB.dita#GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB/GUID-C7E88CD7-A32B-3585-9D8B-3A0726947690"><apiname>RHandleBase::SetHandle()</apiname></xref> and <xref href="GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB.dita#GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB/GUID-9AEAD2B5-4531-3157-839C-CBAECBFCF069"><apiname>RHandleBase::SetReturnedHandle()</apiname></xref>]. </p> <p>See <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-D55514EA-D218-52F2-807B-78D58E99D810">Opening
+a handle to the shared chunk for user-side access</xref>. </p> </li>
+<li id="GUID-3FFCE699-19F1-5A35-BEE6-96FB706EC16F"><p>the user-side passes
+the handle <i>value</i> to the second device driver. This value is obtained
+by calling <codeph>Handle()</codeph> on the <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita"><apiname>RChunk</apiname></xref> object.
+[the function is a member of <codeph>RChunk</codeph>'s base class <xref href="GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB.dita"><apiname>RHandleBase</apiname></xref> (see <xref href="GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB.dita#GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB/GUID-5B4C908D-AA34-3F1A-8170-77C4C1F829F0"><apiname>RHandleBase::Handle()</apiname></xref>]. </p> </li>
+<li id="GUID-8337612F-E476-52BC-8A4F-39099DD0F351"><p>the second device driver
+calls the variant of <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-DAEE47C8-40ED-3F95-9EE9-29033FC5A8D3"><apiname>Kern::OpenSharedChunk()</apiname></xref> with the signature: </p> <codeblock id="GUID-9B2095EE-14E9-5E05-8CD4-67DCB62E3583" xml:space="preserve">DChunk* Kern::OpenSharedChunk(DThread*,TInt,TBool)</codeblock> <p>to
+open a handle to the shared chunk. </p> <p> <b> Note:</b> there are situations
+where the second device driver cannot use this variant of <codeph>Kern::OpenSharedChunk()</codeph> because: </p> <ul>
+<li id="GUID-FDAE7AC0-17AF-5EF8-BEE1-9B58A97B4283"><p>The user-side application
+may have obtained data by using a library API that uses shared chunks internally,
+but which only presents a descriptor based API to the user application. For
+example, an image conversion library may perform JPEG decoding using a DSP,
+which puts its output into a shared chunk, but that library supplies the user
+application with only a descriptor for the decoded data, not a chunk handle. </p> </li>
+<li id="GUID-45844589-86D5-5FB8-AEA7-D5586DA45E87"><p>The communication channel
+between the user-side application and the device driver supports descriptor
+based APIs only, and does not have an API specifically for shared chunks.
+The API items presented by the File Server are an example of this situation. </p> </li>
+</ul> <p>The second device driver will only have the address and size of the
+data (usually a descriptor). If the driver needs to optimise the case where
+it knows that this data resides in a shared chunk, it can use the variant
+of <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-DAEE47C8-40ED-3F95-9EE9-29033FC5A8D3"><apiname>Kern::OpenSharedChunk()</apiname></xref> with the signature: </p> <codeblock id="GUID-8CCA35C1-ABBE-5C9D-ABB9-0233E074A14F" xml:space="preserve">DChunk* Kern::OpenSharedChunk(DThread*,const TAny*,TBool,TInt&amp;)</codeblock> <p>to
+speculatively open the chunk. </p> </li>
+</ul> <p><b>Getting the virtual address of data in a shared chunk </b> </p> <p>Before
+device driver code can access a shared chunk that is has opened, it must get
+the address of the data within it. Typically, user-side code will pass offset
+and size values to the driver. The driver converts this information into an
+address, using the function <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-626CCD99-63D8-322A-A807-9DB96523C82D"><apiname>Kern::ChunkAddress()</apiname></xref>. </p> <p><b>Getting
+the physical address of data in a shared chunk </b> </p> <p>Device driver
+code can get the physical address of a region within a shared chunk from the
+offset into the chunk and a size value. This is useful for DMA or any other
+task that needs a physical address. Use the function <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-79F110C1-2764-34B5-857B-6C0012D2049D"><apiname>Kern::ChunkPhysicalAddress()</apiname></xref> to
+do this. </p> <p><b>Getting chunk attributes and checking for uncommitted
+memory </b> </p> <p>As a shared chunk may contain uncommitted regions of memory
+(gaps), it is important that these gaps are detected. Any attempt to access
+a bad address causes an exception. You can use the function <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-79F110C1-2764-34B5-857B-6C0012D2049D"><apiname>Kern::ChunkPhysicalAddress()</apiname></xref> to
+check for uncommitted regions of memory. </p> </section>
+<section id="GUID-4C374CF0-0680-5A27-94E7-BB0FD75413AF"><title>Passing data
+between user-side code</title> <p>User-side code can access data in a shared
+chunk once it has opened a handle on that chunk. Handles can be passed between
+user processes using the various handle passing functions. This most common
+scenario is via client-server Inter Process Communication (IPC). </p> <p><b>Passing
+a handle from client to server </b> </p> <p>The client passes the handle to
+the shared chunk as one of the four arguments in a <xref href="GUID-4AD02F14-1142-372F-9D11-224595932034.dita"><apiname>TIpcArgs</apiname></xref> object.
+The server opens this using the <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita#GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07/GUID-BE5915FF-4C43-30D8-A6E3-45C33973CD9D"><apiname>RChunk::Open()</apiname></xref> variant
+with the signature: </p> <codeblock id="GUID-0AFB6DCA-A689-55CD-8B51-18E001822855" xml:space="preserve">RChunk::Open(RMessagePtr2 aMessage,TInt aParam,TBool isReadOnly, TOwnerType aType)
+</codeblock> <p><b>Passing a handle from server to client </b> </p> <p>The
+server completes the client message using the chunk handle: </p> <codeblock id="GUID-8CBBC765-9623-508D-8761-A123A4697C7C" xml:space="preserve">RMessagePtr2::Complete(RHandleBase aHandle)</codeblock> <p>The
+client then assigns the returned handle value to an <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita"><apiname>RChunk</apiname></xref> by
+calling: </p> <codeblock id="GUID-EC9CE7E0-20B2-5315-9770-0860A3C429DA" xml:space="preserve">RChunk::SetReturnedHandle(TInt aHandleOrError)</codeblock> <p> <b> Note:</b>  </p> <ul>
+<li id="GUID-B32E3982-9AC8-531E-9109-3CA77F75D4F4"><p>Processes that share
+data within shared chunks must specify the address of that data as an <i>offset</i> from
+the start of the chunk, and not as an absolute address. This is because the
+chunk may appear at different addresses in the address spaces of different
+user processes. </p> </li>
+<li id="GUID-BD87DA45-3279-522C-BF23-552A40DFB8FD"><p>Once a chunk is no longer
+needed for data sharing, user applications should close the handle they have
+on it. If they do not, the memory mapped by the chunk can never be freed. </p> </li>
+</ul> <p>See <xref href="GUID-6047DB3F-DC92-51DF-9EEB-00E79E890B54.dita">Using
+Client/Server</xref>. </p> </section>
+<section id="GUID-A8FF0519-9FDC-53D5-8BD6-A3AEA6BFDD46"><title>Direct peripheral
+access to shared chunks</title> <p>When DMA or any other hardware device accesses
+the physical memory represented by a shared chunk, the contents of CPU memory
+cache(s) must be synchronised with that memory. Use these functions for this
+purpose: </p> <ul>
+<li id="GUID-F1BB9CD1-2D18-5B85-B2DC-C3189C2A82CB"><p> <xref href="GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F.dita#GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F/GUID-5F08DEAA-1237-32DE-AE41-CE7B18230972"><apiname>Cache::SyncMemoryBeforeDmaWrite()</apiname></xref>  </p> </li>
+<li id="GUID-89FE8A8C-BD27-5A9C-A429-7600CDF2CD76"><p> <xref href="GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F.dita#GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F/GUID-3FF3C567-C1BD-3D4E-97E1-B036456A374E"><apiname>Cache::SyncMemoryBeforeDmaRead()</apiname></xref>  </p> </li>
+</ul> <p> <b> Note:</b> both these functions take a <xref href="GUID-F58A1C0D-1B36-37EA-8012-1C74B2D12CAD.dita"><apiname>TUint32</apiname></xref> type
+parameter, identified in the function signatures as <codeph>TUint32 aMapAttr</codeph>.
+This is the same <codeph>TUint32</codeph> value set on return from calls to
+either <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-79F110C1-2764-34B5-857B-6C0012D2049D"><apiname>Kern::ChunkPhysicalAddress()</apiname></xref> or <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-F8D1FB29-7238-3438-951A-6F853C7CF817"><apiname>Kern::ChunkCreate()</apiname></xref>. </p> </section>
+<section id="GUID-D8E298EA-A4CD-5501-B5F1-B8F0EE93CE84"><title>Example code</title> <p>This
+section contains code snippets that show shared chunks in use. Most of the
+code is intended to be part of a device driver. A few snippets show user-side
+code and the interaction with device driver code. </p> <ul>
+<li id="GUID-F2F06E9B-4832-5E05-B392-EC0B89CC2813"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-D284D6D0-400D-53D2-9A43-05CEE28DFDC4">Example: Creating a shared chunk</xref>  </p> </li>
+<li id="GUID-9807283B-B66D-59BE-A6E3-6A9E0A62021D"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-6501F90A-5330-5BC9-A991-A3BECCCA6CDD">Example: Opening a handle to the shared chunk for user-side access</xref>  </p> </li>
+<li id="GUID-3C59E7E6-FA0C-5487-BEC8-FCA4BBE2524F"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-062C405B-B10F-54A8-8F61-418CAE6019D8">Example: using a DFC to notify destruction of chunk</xref>  </p> </li>
+<li id="GUID-9FF13AA3-5847-5574-8B0F-81123EB446BE"><p> <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-97BF15A2-E74A-51DE-B003-16E1DFF8964E">Example: committing memory</xref>  </p> </li>
+</ul> <p id="GUID-D284D6D0-400D-53D2-9A43-05CEE28DFDC4"><b>Example: Creating
+a shared chunk</b> </p> <p>This code snippet shows how a device driver creates
+a shared chunk. The class <codeph>DMyDevice</codeph> has been given responsibility
+for creating the chunk: </p> <codeblock id="GUID-FD2DE166-0516-529A-BD0E-8A872968A67A" xml:space="preserve">/**
+The device or other object making use of shared chunks
+*/
+class DMyDevice
+    {
+    ...
+    TInt CreateChunk();
+    void CloseChunk();
+private:
+    void ChunkDestroyed();
+private:
+    TBool iMemoryInUse;
+    DChunk* iChunk
+    TUint32 iChunkMapAttr;
+    TLinAddr iChunkKernelAddr;
+    ...
+    }</codeblock> <codeblock id="GUID-40DB5E59-11DC-5FC5-B36A-6766132C9A65" xml:space="preserve">/*
+Address and size of our device's memory
+*/
+const TPhysAddr KMyDeviceAddress = 0xc1000000;  // Physical address
+const TInt KMyDeviceMemorySize = 0x10000;
+
+/**
+Create a chunk which maps our device's memory
+*/
+TInt DMyDevice::CreateChunk()
+    {
+    // Check if our device's memory is already in use
+    if(iMemoryInUse)
+        {
+        // Wait for short while (200ms) in case chunk is being deleted
+        NKern::Sleep(NKern::TimerTicks(200));
+        // Check again
+        if(iMemoryInUse)
+            {
+            // Another part of the system is probably still using our memory, so...
+            return KErrInUse;
+            }
+        }
+
+    // Enter critical section so we can't die and leak the objects we are creating
+    // I.e. the TChunkCleanup and DChunk (Shared Chunk)
+    NKern::ThreadEnterCS();
+
+    // Create chunk cleanup object
+    TChunkCleanup* cleanup = new iChunkCleanup(this);
+    if(!cleanup)
+        {
+        NKern::ThreadLeaveCS();
+        return KErrNoMemory;
+        }
+
+    // Create the chunk
+    TChunkCreateInfo info;
+    info.iType         = TChunkCreateInfo::ESharedKernelMultiple;
+    info.iMaxSize      = KMyDeviceMemorySize;
+    info.iMapAttr      = EMapAttrFullyBlocking; // No caching
+    info.iOwnsMemory   = EFalse; // We'll be using our own devices memory
+    info.iDestroyedDfc = cleanup;
+    DChunk* chunk;
+    TInt r = Kern::ChunkCreate(info, chunk, iChunkKernelAddr, iChunkMapAttr);
+    if(r!=KErrNone)
+        {
+        delete cleanup;
+        NKern::ThreadLeaveCS();
+        return r;
+        }
+
+    // Map our device's memory into the chunk (at offset 0)
+
+    r = Kern::ChunkCommitPhysical(chunk,0,KMyDeviceMemorySize,KMyDeviceAddress);
+    if(r!=KErrNone)
+        {
+        // Commit failed so tidy-up...
+
+        // We, can't delete 'cleanup' because it is now owned by the chunk and will
+        // get run when the chunk is destroyed. Instead, we have to Cancel it, which
+        // prevents it from doing anything when it does run.
+        cleanup-&gt;Cancel()
+        // Close chunk, which will then get deleted at some point
+        Kern::ChunkClose(chunk);
+        }
+    else
+        {
+        // Commit succeeded so flag memory in use and store chunk pointer
+        iMemoryInUse = ETrue;
+        iChunk = chunk;
+        }
+
+    // Can leave critical section now that we have saved pointers to created objects
+    NKern::ThreadLeaveCS();
+
+    return r;
+    }
+
+/**
+Close the chunk which maps our device's memory
+*/
+TInt DMyDevice::CloseChunk()
+    {
+    // Enter critical section so we can't die whilst owning the chunk pointer
+    NKern::ThreadEnterCS();
+
+    // Atomically get pointer to our chunk and NULL the iChunk member
+    DChunk* chunk = (DChunk*)NKern::SafeSwap(NULL,(TAny*&amp;)iChunk);
+
+    // Close chunk
+    if(chunk)
+       Kern::CloseChunk(chunk);
+
+    // Can leave critical section now
+    NKern::ThreadLeaveCS();
+    }
+</codeblock> <p><b>Implementation notes </b> </p> <ul>
+<li id="GUID-A587088F-889D-58F7-973D-AD6C471B43E2"><p>a <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita"><apiname>TChunkCreateInfo</apiname></xref> object
+is created, populated and passed to <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-F8D1FB29-7238-3438-951A-6F853C7CF817"><apiname>Kern::ChunkCreate()</apiname></xref>.
+This is information that Symbian platform needs to create the chunk. To create
+a <i>shared</i> chunk, <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita#GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4/GUID-4384AF76-CECE-3B86-BE92-375C1DEA36DA"><apiname>TChunkCreateInfo::iType</apiname></xref> must be
+set to <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita#GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4/GUID-B00A3693-50B6-3A84-89E0-B06D9ABE82ED"><apiname>TChunkCreateInfo::ESharedKernelMultiple</apiname></xref>. </p> </li>
+<li id="GUID-F2EB6952-CAFA-5CB0-BB86-3C77C46C9EEA"><p>If the device architecture
+allowed the device driver function <codeph>DMyDevice::CreateChunk()</codeph> to
+be called in a re-entrant manner, you would need to protect this code using
+a mutex. Such a situation might arise when a logical channel is shared between
+two threads, or two logical channels are created on the same device. There
+may also be other cases where a mutex is needed. </p> <p>See also: </p> <ul>
+<li id="GUID-B5A971C3-B630-5944-851C-86D4285D3C90"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-F5B59A23-48E0-5596-B589-10DD2549F124">The Symbian platform mutex</xref>  </p> </li>
+<li id="GUID-0618C6AD-DB19-50A6-979B-D2D7C7CA0413"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-FEBBDA4F-412E-3AE5-9098-8E2F6BF3E969"><apiname>Kern::MutexCreate()</apiname></xref>  </p> </li>
+<li id="GUID-7FA55315-7403-5CAD-9E84-73A7F8D3DF3A"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-1F0C28A8-9E9A-3AA3-A441-BA8406B3A06A"><apiname>Kern::MutexWait()</apiname></xref>  </p> </li>
+<li id="GUID-3DC20F30-767F-5D3F-8013-2976AB6B2991"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-B8080F86-1342-31EA-9A28-205354CA0CB9"><apiname>Kern::MutexSignal()</apiname></xref>  </p> </li>
+</ul> </li>
+<li id="GUID-A68113CF-C792-59A7-94C3-D2214E065CF6"><p>The line: </p> <codeblock id="GUID-519F054D-429E-5B64-B8FA-34F48E85E1B9" xml:space="preserve">info.iDestroyedDfc = cleanup;</codeblock> <p>in
+the function <codeph>DMyDevice::CreateChunk()</codeph> and code following
+the comment </p> <codeblock id="GUID-C1FCC780-1BD1-5E29-9089-B59434804335" xml:space="preserve">// Create chunk cleanup object</codeblock> <p>sets
+the DFC that runs when the shared chunk is finally closed. See <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-062C405B-B10F-54A8-8F61-418CAE6019D8">Example: using a DFC to notify destruction of chunk</xref> for the DFC code
+itself. </p> </li>
+</ul> <p id="GUID-6501F90A-5330-5BC9-A991-A3BECCCA6CDD"><b>Example: Opening
+a handle to the shared chunk for user-side access</b> </p> <p>These code snippets
+show user-side code making a request to a device driver to open handles on
+two shared chunks. </p> <p>The code snippets assume that the chunks have already
+been created. </p> <p><b>User-side</b> </p> <p>The user-side interface to
+a device driver is always a class derived from <xref href="GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066.dita"><apiname>RBusLogicalChannel</apiname></xref>,
+and is provided by the device driver. Here, this is the <codeph>RMyDevice</codeph> class.
+In real code, the class would offer much more functionality, but only the
+relevant function members and data members are shown: </p> <codeblock id="GUID-CB639C9A-900F-5344-B50F-7DC190D714EB" xml:space="preserve">/**
+Client (user-side) interface to the device driver.
+*/
+class RMyDevice : public RBusLogicalChannel
+    {
+    ...
+public:
+    TInt OpenIoChunks(RChunk&amp; aInputChunk,RChunk&amp; aOutputChunk);
+    ... 
+private:
+    /** Structure to hold information about the i/o buffers */
+    class TIoChunkInfo
+        {
+    public:
+        TInt iInputChunkHandle;
+        TInt iOutputChunkHandle;
+        };
+    // Kernel-side channel class is a friend...
+    friend class DMyDeviceChannel; 
+    ...
+    };
+</codeblock> <p>You call the function <codeph>OpenIoChunks()</codeph> to: </p> <ul>
+<li id="GUID-46625099-EA5D-519C-A9F3-BC6AD97AB41A"><p>issue a request to the
+driver to create handles to two chunks </p> </li>
+<li id="GUID-BAA515D0-FA3A-5D6B-807C-5B562E8B9387"><p>get handles to those
+shared chunks so that they can be accessed by user-side code. </p> </li>
+</ul> <codeblock id="GUID-42B88530-E7A7-5F5D-A9D4-2026E3E4F3E4" xml:space="preserve">TInt RMyDevice::OpenIoChunks(RChunk&amp; aInputChunk,RChunk&amp; aOutputChunk)
+    {
+    // Send request to driver to create chunk handles.
+    TIoChunkInfo info;
+    TInt r=DoControl(EOpenIoChunks,(TAny*)&amp;info);
+    // Set the handles for the chunks
+    aInputChunk.SetHandle(info.iInputChunkHandle);
+    aOutputChunk.SetHandle(info.iOutputChunkHandle);
+
+    return r;
+    }
+</codeblock> <p><b>Implementation notes </b> </p> <ul>
+<li id="GUID-3758237B-4806-5852-835C-1288F368BBEE"><p>The request is passed
+to the driver as a synchronous call; it calls the base class function <xref href="GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066.dita#GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066/GUID-D774DE92-6431-374A-A1F6-1C7045BD4FE5"><apiname>RBusLogicalChannel::DoControl()</apiname></xref>.
+This means that the call does not return until the driver has created (or
+failed to create) the handles to the shared chunks. The call is synchronous
+because the creation of the handles does not depend on the hardware controlled
+by the driver, so there should be minimal delay in its execution. </p> </li>
+<li id="GUID-F8E261B0-D768-5157-B6FA-6B51B6829E47"><p>The driver returns the
+handle <i>numbers</i> in the <codeph>TIoChunkInfo</codeph> object; specifically
+in its <codeph>iInputChunkHandle</codeph> and <codeph>iOutputChunkHandle</codeph> data
+members. </p> <p>To access the shared chunks, user-side code needs handles
+to them. Handles to chunks are <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita"><apiname>RChunk</apiname></xref> objects. </p> <p>The
+final step is to set the returned handle <i>numbers</i> into the <codeph>RChunk</codeph> objects
+by calling <codeph>SetHandle()</codeph>. This function is provided by <codeph>RChunk</codeph>'s
+base class <xref href="GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB.dita"><apiname>RHandleBase</apiname></xref>. </p> <p>See <xref href="GUID-2EAAE194-FAE1-5545-A678-72973E9B72A7.dita">handles</xref> for
+background information. </p> </li>
+<li id="GUID-57FFB715-A05B-5E0D-8354-094018C5AEE5"><p>In this example the
+return value from <xref href="GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066.dita#GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066/GUID-D774DE92-6431-374A-A1F6-1C7045BD4FE5"><apiname>RBusLogicalChannel::DoControl()</apiname></xref> is not
+checked. In practice you need to do so. </p> </li>
+</ul> <fig id="GUID-2D81B150-2273-5474-9E33-2C7CE236FAD8">
+<title>Shared chunks implementation</title>
+<image href="GUID-52B8098A-7695-5EA6-B58F-D730A445C583_d0e77443_href.png" placement="inline"/>
+</fig> <p><b> Device driver (kernel) side </b> </p> <p>This is example code
+snippet shows the device driver side handling of the request made by the user-side
+to open handles on two shared chunks. </p> <p>The request is handled by the <codeph>OpenIoChunks()</codeph> function
+in the device driver's logical channel. The logical channel is represented
+by a class derived from <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita"><apiname>DLogicalChannelBase</apiname></xref>. In this example,
+this is the <codeph>DMyDeviceChannel</codeph> class. </p> <p>Details of how
+a user-side call to <codeph>RMyDevice::OpenIoChunks()</codeph> results in
+a call to the driver's <codeph>DMyDeviceChannel::OpenIoChunks()</codeph> function
+are not shown. <xref href="GUID-0956CE5E-C02B-5EEE-890A-5E8E84A8D9A1.dita#GUID-0956CE5E-C02B-5EEE-890A-5E8E84A8D9A1/GUID-AB757BD9-80A4-53DE-82D8-D9BE8A252C9F">Passing
+requests from user-side to kernel-side</xref> in <xref href="GUID-0956CE5E-C02B-5EEE-890A-5E8E84A8D9A1.dita">The
+Logical Channel</xref> explains the principles. </p> <codeblock id="GUID-B55DA6B8-A38F-5ED6-A415-DBB027D30870" xml:space="preserve">/**
+  Kernel-side Logical Channel for 'MyDevice'
+*/
+class DMyDeviceChannel : public DLogicalChannelBase
+    {
+    ...
+private:
+    TInt OpenIoChunks(RMyDevice::TIoChunkInfo* aIoChunkInfoForClient);
+private:
+    DChunk* iInputChunk;
+    TInt iInputChunkSize;
+    DChunk* iOutputChunk;
+    TInt iOutputChunkSize;
+    ...
+    };
+</codeblock> <p>The following code snippet is the implementation of <codeph>DMyDeviceChannel::OpenIoChunks()</codeph>. </p> <codeblock id="GUID-E344116F-8C10-5226-9547-5F0ABD16D831" xml:space="preserve">/**
+  Called by logical channel to service a client request for i/o chunk handles
+*/
+TInt DMyDeviceChannel::OpenIoChunks(RMyDevice::TIoChunkInfo* aIoChunkInfo)
+    {
+    // Local info structure we will fill in
+    RMyDevice::TIoChunkInfo info;
+
+    // Need to be in critical section whilst creating handles
+    NKern::ThreadEnterCS();
+
+    // Make handle to iInputChunk for current thread
+    TInt r = Kern::MakeHandleAndOpen(NULL, iInputChunk); 
+    // r = +ve value for a handle, -ve value is error code
+    if(r&gt;=0) 
+        {
+        // Store InputChunk handle
+        info.iInputChunkHandle = r;
+
+        // Make handle to iOutputChunk for current thread
+        r = Kern::MakeHandleAndOpen(NULL, iOutputChunk); 
+        // r = +ve value for a handle, -ve value is error code
+        if(r&gt;=0) 
+            {
+            // Store OutputChunk handle
+            info.iOutputChunkHandle = r;
+            // Signal we succeeded...
+            r = KErrNone;
+            }
+        else
+            {
+            // Error, so cleanup the handle we created for iInputChunk
+            Kern::CloseHandle(NULL,info.iInputChunkHandle);
+            }
+        }
+
+    // Leave critical section before writing info to client because throwing an
+    // exception whilst in a critical section is fatal to the system.
+    NKern::ThreadLeaveCS();
+
+    // If error, zero contents of info structure.
+    // (Zero is usually a safe value to return on error for most data types,
+    // and for object handles this is same as KNullHandle)
+    if(r!=KErrNone)
+        memclr(&amp;info,sizeof(info));
+
+    // Write info to client memory
+    kumemput32(aIoChunkInfo,&amp;info,sizeof(info));
+
+    return r;
+    }
+</codeblock> <p><b>Implementation notes </b> </p> <ul>
+<li id="GUID-396C4C6F-C6ED-5796-8B68-13A2E25FF365"><p>The function calls <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-BA56B205-60D8-326E-8340-3F78CCEA3DD1"><apiname>Kern::MakeHandleAndOpen()</apiname></xref> twice,
+once for each shared chunk. A NULL value is passed as the first parameter
+in both calls to this function instead of an explicit <codeph>DThread</codeph> object.
+This creates the handles for the current thread. Although this code is running
+in kernel mode, the context remains the user thread. </p> </li>
+<li id="GUID-B0D3721A-A5A8-5A17-A402-C84A087DC921"><p>The first handle created
+is closed if the second handle cannot be created: </p> <codeblock id="GUID-8B73E41A-8BEF-503A-8A22-13F2258BC380" xml:space="preserve">if(r&gt;=0) 
+            {
+            ...
+            }
+        else
+            {
+            // Error, so cleanup the handle we created for iInputChunk
+            Kern::CloseHandle(NULL,info.iInputChunkHandle);
+            }</codeblock> </li>
+<li id="GUID-396AE759-ACC8-5F7E-AF36-37A7A2BDB855"><p>The handle values are
+written back into the <codeph>TIoChunkInfo</codeph> structure using the <xref href="GUID-D141C3C4-F2F6-37DF-BDF6-63DDE9052FA0.dita"><apiname>kumemput32()</apiname></xref> function.
+See the EKA2 references in <xref href="GUID-F46B87B7-97A9-530B-BAC4-EF1DB9C91E39.dita#GUID-F46B87B7-97A9-530B-BAC4-EF1DB9C91E39/GUID-4A7BCB91-C58B-597F-85B6-74463BE9BC04">Accessing
+User Memory</xref> in <xref href="GUID-F46B87B7-97A9-530B-BAC4-EF1DB9C91E39.dita">Migration
+Tutorial: EKA1 Device Driver to Kernel Architecture 2</xref>. </p> </li>
+</ul> <p id="GUID-062C405B-B10F-54A8-8F61-418CAE6019D8"><b>Example: Using
+a DFC to notify destruction of a chunk</b> </p> <p>This set of code snippets
+shows how to set up a DFC that notifies a device driver when a shared chunk
+has finally been destroyed. </p> <codeblock id="GUID-F75EE51B-EC55-57C1-B2C6-D68D44B34069" xml:space="preserve">/**
+Example class suitable for use as a 'Chunk Destroyed DFC' when
+creating Shared Chunks with Kern::ChunkCreate()
+*/
+class TChunkCleanup : private TDfc
+    {
+public:
+    TChunkCleanup(DMyDevice* aDevice);
+    void Cancel();
+private:
+    static void ChunkDestroyed(TChunkCleanup* aSelf);
+private:
+    DMyDevice* iDevice;
+    };
+
+/**
+Contruct a Shared Chunk cleanup object which will signal the specified device
+when a chunk is destroyed.
+*/
+TChunkCleanup::TChunkCleanup(DMyDevice* aDevice)
+    : TDfc((TDfcFn)TChunkCleanup::ChunkDestroyed,this,Kern::SvMsgQue(),0)
+    , iDevice(aDevice)
+    {}
+
+/**
+Cancel the action of the cleanup object.
+*/
+void TChunkCleanup::Cancel()
+    {
+    // Clear iDevice which means that when the DFC gets queued on chunk destruction
+    // our ChunkDestroyed method will do nothing other than cleanup itself.
+    iDevice = NULL;
+    }
+
+/**
+Callback function called when the DFC runs, i.e. when a chunk is destroyed.
+*/
+void TChunkCleanup::ChunkDestroyed(TChunkCleanup* aSelf)
+    {
+    DMyDevice* device = aSelf-&gt;iDevice;
+    // If we haven't been Cancelled...
+    if(device)
+        {
+        // Perform any cleanup action required. In this example we call a method
+        // on 'MyDevice' which encapsulates this.
+        device-&gt;ChunkDestroyed();
+        }
+
+    // We've finished so now delete ourself
+    delete aSelf;
+    }
+</codeblock> <p><b>Implementation notes </b> </p> <ul>
+<li id="GUID-3387037D-9BBC-5A07-A180-FC2DAB6F6503"><p>The DFC is an item of
+information that is passed to <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-F8D1FB29-7238-3438-951A-6F853C7CF817"><apiname>Kern::ChunkCreate()</apiname></xref> when
+the shared chunk is created. See <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita#GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10/GUID-D284D6D0-400D-53D2-9A43-05CEE28DFDC4">Example:
+Creating a shared chunk</xref> to see how the two sets of code connect. </p> </li>
+<li id="GUID-CB5AE321-CF79-543D-9CA2-DDF1B0B115EC"><p>Ensure that the code
+implementing this DFC is still loaded when the DFC runs. As you cannot know
+when a chunk will be destroyed, the code should reside in a kernel extension. </p> </li>
+</ul> <p id="GUID-97BF15A2-E74A-51DE-B003-16E1DFF8964E"><b>Example: committing
+memory</b> </p> <p>This code snippet shows how memory is committed. It is
+based on the implementation of the class <codeph>DBuffers</codeph>, which
+represents a group of buffers hosted by a single chunk. </p> <codeblock id="GUID-9768851E-648B-501D-9AA5-1922EB428EEC" xml:space="preserve">/**
+  Class representing a group of buffers in the same chunk
+*/
+class DBuffers
+    {
+public:
+    DBuffers();
+    ~DBuffers();
+    TInt Create(TInt aBufferSize,TInt aNumBuffers);
+public:
+    DChunk* iChunk;             /**&lt; The chunk containing the buffers. */
+    TLinAddr iChunkKernelAddr;  /**&lt; Address of chunk start in kernel process */
+    TUint32 iChunkMapAttr;      /**&lt; MMU mapping attributes used for chunk */
+    TInt iBufferSize;           /**&lt; Size of each buffer in bytes */
+    TInt iOffsetToFirstBuffer;  /**&lt; Offset within chunk of the first buffer */
+    TInt iOffsetBetweenBuffers; /**&lt; Offset in bytes between consecutive buffers */
+    };</codeblock> <codeblock id="GUID-CBC59647-DEA3-52AC-B7BD-BF15F29BB0E7" xml:space="preserve">/** Constructor */
+DBuffers::DBuffers()
+    : iChunk(NULL)
+    {}
+
+/** Destructor */
+DBuffers::~DBuffers()
+    {
+    if(iChunk) Kern::ChunkClose(iChunk);
+    }
+
+/**
+  Create the chunk and commit memory for all the buffers.
+  @param aBuffserSize Size in bytes of each buffer
+  @param aNumBuffers Number of buffers to create
+*/
+TInt DBuffers::Create(TInt aBufferSize,TInt aNumBuffers)
+    {
+    // Round buffer size up to MMU page size
+    aBufferSize = Kern::RoundToPageSize(aBufferSize);
+    iBufferSize = aBufferSize;
+
+    // Size of one MMU page
+    TInt pageSize = Kern::RoundToPageSize(1);
+
+    // We will space our buffers with one empty MMU page between each.
+    // This helps detect buffer overflows...
+
+    // First buffer starts one MMU page into chunk
+    iOffsetToFirstBuffer = pageSize; 
+
+    // Each buffer will be spaced apart by this much
+    iOffsetBetweenBuffers = aBufferSize+pageSize;
+
+    // Calculate chunk size
+    TUint64 chunkSize = TUint64(iOffsetBetweenBuffers)*aNumBuffers+pageSize;
+
+    // Check size is sensible
+    if(chunkSize&gt;(TUint64)KMaxTInt)
+        return KErrNoMemory;  // Need more than 2GB of memory!
+
+    // Enter critical section whilst creating objects
+    NKern::ThreadEnterCS();
+
+    // Create the chunk
+    TChunkCreateInfo info;
+    info.iType         = TChunkCreateInfo::ESharedKernelMultiple;
+    info.iMaxSize      = (TInt)chunkSize;
+    info.iMapAttr      = EMapAttrCachedMax; // Full caching
+    info.iOwnsMemory   = ETrue; // Use memory from system's free pool
+    info.iDestroyedDfc = NULL;
+    TInt r = Kern::ChunkCreate(info, iChunk, iChunkKernelAddr, iChunkMapAttr);
+    if(r==KErrNone)
+        {
+        // Commit memory for each buffer...
+
+        TInt offset = iOffsetToFirstBuffer; // Offset within chunk for first buffer
+
+        // Repeat for each buffer required...
+        while(aNumBuffers--)
+            {
+            // Commit memory at 'offset' within chunk
+            r = Kern::ChunkCommit(iChunk,offset,aBufferSize);
+            if(r!=KErrNone)
+                break;
+
+            // Move 'offset' on to next buffer
+            offset += iOffsetBetweenBuffers;
+            }
+
+        if(r!=KErrNone)
+            {
+            // On error, throw away the chunk we have created
+            Kern::ChunkClose(iChunk);
+            iChunk = NULL; // To indicate that 'this' doesn't have any valid buffers
+            }
+        }
+
+    // Finished
+    NKern::ThreadLeaveCS();
+    return r;
+    }
+</codeblock> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-51C5DC6C-0CEE-5F44-8578-AEFBEF90FA4D.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,226 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-51C5DC6C-0CEE-5F44-8578-AEFBEF90FA4D" xml:lang="en"><title>READIMAGE</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>READIMAGE is a command-line tool that provides readable data from
+a ROM, ROFS, or E32 image. It can also generate an IBY file from a
+SIS file which can be used to generate a data drive image. </p>
+<section id="GUID-EB948089-0609-58A1-A87E-5B13B0DF1FE7"><title>Command
+syntax</title> <p>Run the following command to use the READIMAGE tool: </p> <p><userinput>readimage [options] &lt;image filename&gt; or &lt;SIS
+filename&gt;</userinput> </p> <p>where: </p> <ul>
+<li id="GUID-396A2825-6CD1-5E0D-8E2E-40424D57CBBE"><p> <codeph>&lt;image
+filename&gt;</codeph> is an input <filepath>image</filepath> file </p> </li>
+<li id="GUID-6AB4C51E-F213-5755-BFF7-1416AC024D06"><p> <codeph> &lt;sis
+filename&gt;</codeph> is an input <filepath>.sis</filepath> file. </p> </li>
+</ul> <p><b>Reading ROM, ROFS and E32 images</b> </p> <p>Run the following
+command to read a ROM, ROFS, or E32 image: </p> <p><userinput>readimage
+options &lt;ROM/ROFS/E32 imagefile&gt;</userinput> </p> <p>The command
+line options are as follows: </p> <table id="GUID-A89CDF05-C34B-5091-96B8-F34F503B102B">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<thead>
+<row>
+<entry>Options</entry>
+<entry>Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p> <codeph>-o</codeph>  </p> </entry>
+<entry><p>Indicates output file name. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-d</codeph>  </p> </entry>
+<entry><p>Displays header information about the input image. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-s</codeph>  </p> </entry>
+<entry><p>Displays the directory structure of the input image. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-v</codeph>  </p> </entry>
+<entry><p>Displays image headers and the directory structure of the
+input image. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-e</codeph>  </p> </entry>
+<entry><p>Displays the E32 image from the input ROM or ROFS image. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-h</codeph>  </p> </entry>
+<entry><p>Displays help information. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-z &lt;path&gt;</codeph>  </p> </entry>
+<entry><p>Extracts all files from the given image to the specified
+location. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-l &lt;logfile name&gt;</codeph>  </p> </entry>
+<entry><p>Logs the image contents in a file. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-x &lt;pattern&gt;</codeph>  </p> </entry>
+<entry><p>Extracts a single or a set of files from a ROM or ROFS image
+into the current directory. The pattern contains set of file names.
+For more information about <codeph>&lt;pattern&gt;</codeph>, see <xref href="GUID-C0D7E049-635B-5089-9C2F-55BE2481A77E.dita#GUID-C0D7E049-635B-5089-9C2F-55BE2481A77E/GUID-5ABC32C0-2D45-5A38-81A8-409B1E191007">Extracting a set of files</xref>. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-r</codeph>  </p> </entry>
+<entry><p>Recursively extracts the files from ROM or ROFS image. This
+option is always used with the <codeph>-x</codeph> option. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p> <b>Note</b>: Options are not case-sensitive. READIMAGE
+reports an error if an argument is not passed for the -x or -z option. </p> <p> <b><i>Extracting one file</i></b>  </p> <p>The command below
+extracts all the files from <filepath>sample.img</filepath> to the <filepath>C:\test</filepath> location. </p> <p><userinput>readimage -z C:\test\
+sample.img</userinput> </p> <p> <b><i>Extracting a set of files with
+wildcard ?</i></b>  </p> <p>The READIMAGE tool provides the -x option
+to extract one or more files from a ROM or ROFS image, based on a
+pattern that matches the name of the file. A question mark(?) indicates
+to match one instance of any character in a file name, within the
+directory. </p> <p>The command below extracts all the <filepath>.exe </filepath> files from the <filepath>\sys\bin</filepath> directory present in
+the <filepath>sample.img</filepath> file, whose file name consists
+of two characters. </p> <p><userinput>readimage -x \sys\bin\??.exe
+sample.img </userinput> </p> <p> <b><i>Extracting a set of files with
+wildcard *</i></b>  </p> <p>The READIMAGE tool provides the -x option
+to extract one or more files from a ROM or ROFS image, based on a
+pattern that matches the name of the file. A star sign(*) indicates
+to match zero or more instances of any character in a file name, within
+the directory. </p> <p>The command below extracts all the <filepath>.exe</filepath> files from the \sys\bin directory present in the <filepath>sample.img</filepath> file, into the current directory. </p> <p><userinput>readimage -x \sys\bin\*.exe sample.img</userinput> </p> <p>The command
+below extracts all the <filepath>.exe</filepath> files from the \sys\bin
+directory present in the <filepath>sample.img</filepath> file, into
+the C:\test location. </p> <p><userinput>readimage -x \sys\bin\*.exe
+-z C:\test sample.img</userinput> </p> <p>The command below extracts
+all the .dll files from the \sys\bin\ directory and its sub-directories
+present in the sample.img file, into the current directory. </p> <p><userinput>readimage -x \sys\bin\*.dll -r sample.img</userinput> </p> <p><b>Generating an IBY file from a SIS file</b> </p> <p>Run the
+following command to generate an <filepath>.iby</filepath> file from
+a <filepath>.sis</filepath> file: </p> <p><userinput>readimage -sis2iby
+[-tmpdir &lt;path&gt; -outdir &lt;path&gt;] &lt;sisfile&gt;</userinput> </p> <p>The following command-line options are supported when generating
+an <filepath>.iby</filepath> file from a <filepath>.sis</filepath> file: </p> <table id="GUID-5033FF35-0597-54EF-BDCC-46D66591F629">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<thead>
+<row>
+<entry>Options</entry>
+<entry>Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p> <codeph>&lt;sisfile&gt;</codeph>  </p> </entry>
+<entry><p>Input <filepath>.sis</filepath> file. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> -sis2iby</codeph>  </p> </entry>
+<entry><p>Used to generate <filepath>.iby</filepath> file for the
+given <filepath>.sis</filepath> file. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> -tmpdir &lt;path&gt;</codeph>  </p> </entry>
+<entry><p>Extracts contents of the <filepath>.sis</filepath> file
+to the specified directory. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-outdir &lt;path&gt;</codeph>  </p> </entry>
+<entry><p>Generates <filepath>.iby</filepath> file in the specified
+directory. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>To generate an <filepath>.iby</filepath> file from the
+given <filepath>.sis</filepath> file, READIMAGE performs the steps
+as follows: </p> <ol id="GUID-6E427F6F-712F-51F5-B6B5-B9B4970017A1">
+<li id="GUID-459AE7C1-B254-5FD6-A574-306F847AD989"><p>Reports an error
+if the <filepath>.sis</filepath> file is invalid or missing. </p> </li>
+<li id="GUID-09E38B54-F6AD-5323-AD7D-FA1F5DCA58B2"><p>Extracts the
+contents of the <filepath>.sis</filepath> file into a specified directory,
+or the current directory if the path is not specified. A <filepath>.pkg</filepath> script file is extracted from the sis file. </p> </li>
+<li id="GUID-A1E4B1C5-1507-5809-B41C-4C26E12F77E8"><p>Creates an <filepath>.iby</filepath> file in the specified directory or the current directory
+based on the <filepath>.pkg</filepath> file. </p> </li>
+</ol> <p>The <filepath>.sis</filepath> file is created using the package
+(PKG) script file. A <filepath>.pkg</filepath> file is a text file
+containing statements that define the information needed by the installation
+(<filepath>.sis</filepath> ) file creation utility, MAKESIS. </p> <p>For more information about creating <filepath>.sis</filepath> file,
+see <xref href="GUID-4BDC9F63-83A1-53A5-91A0-B092AA821755.dita">MakeSIS</xref> Installation file generator syntax. For more information on the
+.pkg file format, see <xref href="GUID-6D6C54E2-66DA-5626-A75D-5597469D5BE0.dita">PKG File</xref> in
+the <xref href="GUID-2FC268F3-5EC2-40DB-B3EA-0E2D5C6EFCAD.dita">Symbian
+C++ Developer Library</xref>. </p> <p>READIMAGE extracts the <filepath>.pkg</filepath> file from the <filepath>.sis</filepath> file. It
+then uses the <filepath>.pkg</filepath> file as input to generate
+the <filepath>.iby</filepath> file. </p> <p><b><i>Languages and Package-header
+section</i></b> </p> <p>The details of Languages and Package-header
+sections are written in the <filepath>.iby</filepath> file as comments. </p> <ul>
+<li id="GUID-6998D038-C11F-5A1A-ABC8-8967438444AC"><p> <filepath>.pkg</filepath> file </p> <codeblock id="GUID-C35E5D70-C347-55C9-8612-C875D67380A0" xml:space="preserve">&amp;EN
+# {"HelloWorld application"}, (0xe8000091), 1, 0, 0, TYPE=SA</codeblock> </li>
+<li id="GUID-3B4C9642-0774-5B1F-B5F2-4F7A6B001B6A"><p> <filepath>.iby</filepath> file </p> <codeblock id="GUID-EE292E70-9E4D-53E8-AF9D-0633DE89AE87" xml:space="preserve">// Generated IBY file for the package file: \dump\hwapp\hwapp.pkg
+// Languages: EN
+// Header: "HelloWorld application" (0xe8000091)</codeblock> </li>
+</ul> <p><b><i>Install-file section</i></b> </p> <p>In the Install-file
+section, the standard installation files, which are specified with
+the installation option <codeph>FF</codeph>, are written using the <codeph>FILE</codeph> or <codeph>DATA OBEY</codeph> file keywords. The <codeph>File</codeph> keyword is used if the file is an E32 image, Otherwise,
+the <codeph>Data</codeph> keyword is used. </p> <ul>
+<li id="GUID-466E2C48-C6A1-5AAA-9315-125FC9C4D9F0"><p> <filepath>.pkg</filepath> file </p> <codeblock id="GUID-5FF15257-A248-533A-BBED-5D517F1CB988" xml:space="preserve">"file0" - "!:\sys\bin\HelloWorld.exe", FF, VR
+"file1" - "!:\private\&lt;process SID&gt;\Apps\AGENDA\Ericsson.txt", FF, VR</codeblock> </li>
+<li id="GUID-FE0C0E53-65E7-55FB-A7A0-D268EE74A53B"><p> <filepath>.iby</filepath> file </p> <codeblock id="GUID-3BC88477-86B8-5019-B87D-BABDE6BB60F0" xml:space="preserve">file = "\test\dump\hwapp\file0" "\sys\bin\HelloWorld.exe"
+data = "\test\dump\hwapp\sis0\file1" "\private\&lt;process SID&gt;\Apps\AGENDA\Ericsson.txt"</codeblock> </li>
+</ul> <p><b><i>Embedded-SIS section</i></b> </p> <p>The details of
+the Embedded-SIS section are written using <codeph>#include</codeph> pre-processor directive. </p> <ul>
+<li id="GUID-1674C791-9BEF-5E21-90E9-04B4D7EEEFAB"><p> <filepath>.pkg</filepath> file </p> <codeblock id="GUID-0EED436A-74BF-5AC8-84EA-3325E2057F52" xml:space="preserve">@"sis0.sis", (0x101f7771)
+@"sis1.sis", (0x101f7773)</codeblock> </li>
+<li id="GUID-235D1AD1-2DE1-5414-97A7-2C6A4B6FDAA3"><p> <filepath>.iby</filepath> file </p> <codeblock id="GUID-DF10E57A-DE34-5914-A6B9-1D723F19DF4B" xml:space="preserve">#include "sis0.sis"
+#include "sis1.sis"</codeblock> </li>
+</ul> <p><b><i>Conditions-block section</i></b> </p> <p>In the Conditions-block
+section, the IF statements are written using the <codeph>#if - #else
+- #endif</codeph> pre-processor directive block. </p> <p>The condition-primitives
+and the functions in the <filepath>.pkg</filepath> file are written
+as pre-processor macros. </p> <p>The relational and logical operator
+keywords are written using the appropriate operators. </p> <ul>
+<li id="GUID-CD902082-FC13-5B1E-A316-2D0B289D9ECA"><p> <filepath>.pkg</filepath> file </p> <codeblock id="GUID-C21BA23D-3D71-56E0-8F6D-5A3448403D07" xml:space="preserve">;Display 2 options to the user
+! ({"Option1", "Option1"}, {"Option2", "Option2"})
+;Conditional installation
+IF option1
+    "file0" - "!:\private\10000005\import\InstTest\option1.txt";
+ENDIF
+IF option2
+    "file0" - "!:\private\10000005\import\InstTest\option2.txt";
+ENDIF
+;Conditional installation
+IF (MANUFACTURER) = (1)
+    "file1" - "!:\sys\bin\HelloWorld.exe"
+ELSEIF (MANUFACTURER) = (4)
+    "file1" - "!:\sys\bin\HelloWorld1.exe"
+ELSE
+    "file1" - "!:\sys\bin\HelloWorld2.exe"
+ENDIF
+    
+</codeblock> </li>
+<li id="GUID-723E919D-4A09-5923-99EC-5B1BBD7D1C08"><p> <filepath>.iby</filepath> file </p> <codeblock id="GUID-A7D26F78-0287-52F9-B1DC-13AD7EEF9594" xml:space="preserve">//Install Options: "OPTION1" "OPTION1" "OPTION2" "OPTION2"
+#if defined (option1)
+    data = "s:\test\hwapp\file0"
+"\private\10000005\import\InstTest\option1.txt";
+#endif
+#if defined (option2)
+    data = "s:\test\hwapp\file0"
+"\private\10000005\import\InstTest\option2.txt";
+#endif
+
+#if (MANUFACTURER) = (1)
+    file = "s:\test\hwapp\file1" "\sys\bin\HelloWorld.exe"
+#elseif (MANUFACTURER) = (4)
+    file = "s:\test\hwapp\file1" "\sys\bin\HelloWorld1.exe"
+#else
+    file = "s:\test\hwapp\file1" "\sys\bin\HelloWorld2.exe"
+#endif</codeblock> </li>
+</ul> <p> <b>Note:</b> Using the <filepath>.iby</filepath> file with
+the condition-block statements for the creation of ROM and ROFS images
+needs appropriate macro definitions. For the preceding examples, the
+macros are defined as follows: </p> <codeblock id="GUID-B79B1372-3B2D-5A7E-9A7C-568302CC7D3F" xml:space="preserve">#define option1 //selecting option1 block
+#define MANUFACTURER 4 //selecting second conditional block</codeblock> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-52583CC7-483E-54B5-8094-F0F61BD46B7F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,105 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-52583CC7-483E-54B5-8094-F0F61BD46B7F" xml:lang="en"><title>Configuration: Attribute Definition Files</title><shortdesc>Describes the format of configuration files.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The attributes that can be used on a device are defined in two
+configuration files. . </p>
+<section id="GUID-8648B87A-B712-5458-850A-FDF318669FE3"><title>Config.hcf
+file</title> <p>The purpose of this file, <filepath>config.hcf</filepath>, is to define the <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-174A663C-3943-5D36-B507-D97A687C168C">attributes</xref> that have meaning on this hardware. It specifies
+whether attributes: </p> <ul>
+<li id="GUID-F47EC58A-2E93-5D57-ADD8-F2D7B440F555"><p>are read-only </p> </li>
+<li id="GUID-F8BEB68C-3D90-5517-80D5-AC7B2EA6FDEC"><p>can be read
+and written </p> </li>
+<li id="GUID-9FFE7AE2-32FF-5B30-8458-728A08F5EBC7"><p>are simply stored
+by the HAL - the non-derived attributes </p> </li>
+<li id="GUID-BE8EB94D-ED03-5066-A8AE-DC0294A828D9"><p>require calls
+to other components to obtain or set their values - the derived attributes. </p> </li>
+</ul> <p>The file must be created in the <filepath>...\Variant\hal\...</filepath> directory. </p> <p>Note that: </p> <ul>
+<li id="GUID-46D60900-655F-5DEC-AED2-5AC7F3D5C32A"><p> <i>all</i> supported
+attributes must have an entry in the Config file <filepath>config.hcf</filepath>  </p> </li>
+<li id="GUID-0A474EFD-E146-5D65-AD22-54FE50FA7E68"><p> <i>all</i> non-derived
+attributes also need an entry in the<xref href="GUID-52583CC7-483E-54B5-8094-F0F61BD46B7F.dita#GUID-52583CC7-483E-54B5-8094-F0F61BD46B7F/GUID-3514023A-9CB6-578F-9928-FD0971B81BEF">Values file</xref> <filepath>values.hda</filepath>. </p> </li>
+</ul> <p>The build system uses the Perl script <filepath>halcfg.pl</filepath> to convert text information in the Config file into a C++ source
+file before the C++ compiler is invoked. The generated binary maps
+to the data members defined in the <codeph>HalInternal</codeph> class. <i>Note that this class is internal to Symbian</i>. </p> <p>After initial
+implementation, any changes to the files will be picked up by the
+supplied makefile, <filepath>...\hal\config.mke</filepath>. The necessary
+changes are made to the generated <filepath>config.cpp</filepath> file
+when the HAL is built. </p> <p>Any additional functions must be added
+to the implementation file by hand, e.g. in a file called <filepath>imp.cpp</filepath>. However, this would be unusual because all likely
+functions are already implemented in <filepath>...\hal\src\userhal.cpp</filepath>. </p> <p>The config file consists of a number of lines of text in
+the form: </p> <codeblock id="GUID-837B7F2C-E2CB-5DB6-97D5-AA009C335DA7" xml:space="preserve">&lt;attrib&gt; [:&lt;prop1&gt;, &lt;prop2&gt;, ...] = &lt;implementation&gt;</codeblock> <p>where the pair of square brackets indicates optional items. </p> <p><b>&lt;attrib&gt;</b> </p> <p>This is one of the values of the enumeration <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-1959915A-BA99-3F94-AFD4-FD1AA540BFBF"><apiname>HALData::TAttribute</apiname></xref> in the source file <filepath>...\hal\inc\hal_data.h</filepath>  </p> <p><b>&lt;prop1&gt;, &lt;prop2&gt;,...</b> </p> <p>These are optional property
+specifications defined by the enumeration <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-F1E5A60F-FB3C-387A-9055-BC5478ADB815"><apiname>HALData::TAttributeProperty</apiname></xref> in the source file <filepath>...\hal\inc\hal_data.h</filepath>.
+Where more than one property is specified, they are separated by commas.
+If specified, the initial colon is required. Currently, only the two
+properties <xref href="GUID-59379CFA-F4FD-36B0-855F-A9528B3458B4.dita"><apiname>EValid</apiname></xref> and <xref href="GUID-490A3E37-17DB-3702-9E8C-FD3F555A3080.dita"><apiname>ESettable</apiname></xref> are defined. Note that any substring which is not ambiguous within
+the enumerated type is acceptable; matching is not case sensitive. </p> <p>The property <xref href="GUID-59379CFA-F4FD-36B0-855F-A9528B3458B4.dita"><apiname>EValid</apiname></xref> is defined implicitly
+for all attributes that appear in the Config file. It indicates that
+the attribute is meaningful on this platform. Attributes that do not
+appear in the Config file do not have this property, and calls to <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-573C49D6-7763-37AE-B2B2-4C8FB1327E21"><apiname>HAL::Get()</apiname></xref> or <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-9454F1B2-D525-3D6D-A872-C6457CACD4FC"><apiname>HAL::Set()</apiname></xref> which refer
+to those attributes return <xref href="GUID-F89DA3F0-2A48-3F9B-8F08-29350E92D0E4.dita"><apiname>KErrNotSupported</apiname></xref>. </p> <p>The property <xref href="GUID-490A3E37-17DB-3702-9E8C-FD3F555A3080.dita"><apiname>ESettable</apiname></xref>, means that an attribute
+is modifiable. Calls to <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-9454F1B2-D525-3D6D-A872-C6457CACD4FC"><apiname>HAL::Set()</apiname></xref> for attributes
+without this property return <xref href="GUID-F89DA3F0-2A48-3F9B-8F08-29350E92D0E4.dita"><apiname>KErrNotSupported</apiname></xref>. </p> <p><b>&lt;implementation&gt;</b> </p> <p>Defines whether an <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-174A663C-3943-5D36-B507-D97A687C168C">attribute</xref> is derived. It can be: </p> <ul>
+<li id="GUID-F9FE0364-512E-5348-B50D-041DD54DD5F3"><p>0, which means
+that the specified attribute is not derived, but is just a constant
+stored by the HAL. </p> </li>
+<li id="GUID-C078572B-3E53-571E-8B2F-04516D3D7C9D"><p>the name of
+a function used to implement <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-573C49D6-7763-37AE-B2B2-4C8FB1327E21"><apiname>HAL::Get()</apiname></xref> and <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-9454F1B2-D525-3D6D-A872-C6457CACD4FC"><apiname>HAL::Set()</apiname></xref> for that specified attribute. </p> </li>
+</ul> <p><b>Comments</b> </p> <p>The order in which attributes are defined
+is not important. Comments may be included by starting a line with
+//. A comment <i>must</i> be on its own line and cannot be appended
+to an attribute specification. </p> </section>
+<section id="GUID-3514023A-9CB6-578F-9928-FD0971B81BEF"><title>Values.hda
+file</title> <p>The purpose of this file, <filepath>values.hda</filepath>, is to specify the initial values of the non-derived <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-174A663C-3943-5D36-B507-D97A687C168C">attributes</xref>, those attributes which are simply stored in, and
+retrieved from, the HAL. It must be created in the <filepath>...\variant\hal\...</filepath> directory. </p> <p>The build system uses the Perl script <filepath>halcfg.pl</filepath> to convert text information in the Values file
+into a C++ source file before the C++ compiler is invoked. </p> <p>After initial implementation, any changes to the file will be picked
+up by the supplied makefile, <filepath>...\hal\config.mke</filepath>. The necessary changes are made to the generated <filepath>values.cpp</filepath> file when the HAL is built. </p> <p>Any additional functions must
+be added to the implementation file by hand, e.g. in a file called <filepath>imp.cpp</filepath>. However, this would be unusual because all likely
+functions are already implemented in <filepath>...\hal\src\userhal.cpp</filepath>. </p> <p>The values file consists of a number of lines of text in
+the form: </p> <codeblock id="GUID-2BD2A5EA-376A-5B7A-BF2F-7DDFEC9F39EC" xml:space="preserve">&lt;attrib&gt; = &lt;value&gt;</codeblock> <p><b>&lt;attrib&gt;</b> </p> <p>This is one of the values of the enumeration <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-1959915A-BA99-3F94-AFD4-FD1AA540BFBF"><apiname>HALData::TAttribute</apiname></xref> defined in the header file <filepath>...\hal\inc\hal_data.h</filepath>. </p> <p><b>&lt;value&gt;</b> </p> <p>This is the initial value of the attribute.
+It may be specified in various ways, but depends on the attribute,
+and may be one of the following: </p> <ul>
+<li id="GUID-5C0A1713-DC06-58F1-988C-CD8EB4F774A2"><p>a decimal integer
+constant </p> </li>
+<li id="GUID-1D5479D3-AA7D-587E-89CF-F2ACF4E222AE"><p>a hexadecimal
+integer constant, by prepending <codeph>0x</codeph>  </p> </li>
+<li id="GUID-FD6C4845-8D85-54F3-AB82-D4A92D09CB8D"><p>an enumerated
+value for those attributes that have a corresponding enumeration in <filepath>...\hal\inc\hal_data.h</filepath>. Note that any substring which
+is not ambiguous within the enumerated type is acceptable; matching
+is not case sensitive. For example, <codeph>intel</codeph> would be
+an acceptable abbreviation for <codeph>EManufacturer_Intel</codeph> in the enumeration <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-FF91E5FE-CD00-3D2F-AE88-F601611F9A55"><apiname>HALData::TManufacturer</apiname></xref>. </p> </li>
+<li id="GUID-912B02EB-A3A7-5EA0-B350-1637D5D62EFD"><p> <codeph>bit1
++ bit2 + ... + bitn</codeph>, for those attributes with corresponding
+bitmask enumerations in <filepath>...\hal\inc\hal_data.h</filepath>, and declared with the <codeph>bitmask</codeph> pseudo-keyword. <codeph>bit1</codeph>, <codeph>bit2</codeph> etc. are values of the enumeration.
+Any substring which is not ambiguous within the bitmask type is acceptable
+and matching is not case sensitive. </p> </li>
+</ul> <p><b>Comments</b> </p> <p>The order in which attributes are defined
+is not important. Comments may be included by starting a line with
+//. A comment <i>must</i> be on its own line and cannot be appended
+to an attribute specification. </p><p><note> Attributes <xref href="GUID-81DC05E0-DEF1-3A67-B0D5-C5B65FC42E9C.dita"><apiname>EMachineUid</apiname></xref> and <xref href="GUID-641E454C-59AD-39C4-8BC6-A9A86042A77B.dita"><apiname>EManufacturer</apiname></xref> should be allocated UID values
+in the normal way. These values should be placed in the values file
+and in product specific header files, not in <filepath>...\hal\inc\hal_data.h</filepath></note>.</p> <codeblock xml:space="preserve"> </codeblock> </section>
+<section id="GUID-A939F6FD-F3AD-4445-BF25-B2DC26369F91"><title>Example
+of a non-derived attribute</title> <p>A line similar to the following
+in the <filepath>values.hda</filepath> file defines the machine Uid
+to the HAL, and shows how a value is paired to an attribute. </p> <codeblock id="GUID-15C4C6A7-10F2-5782-96CE-3A66C074683E" xml:space="preserve">EMachineUid= 0x1000a682</codeblock> <p>A line similar to the following in the <filepath>config.hcf</filepath> file indicates that the value is not derived but is simply stored
+by the HAL. </p> <codeblock id="GUID-2E744820-D5A6-50E1-8449-F8FE69F92796" xml:space="preserve">EMachineUid= 0</codeblock> </section>
+<section id="GUID-B8778DDA-DDC5-46D5-B668-D8B788AE23C9"><title>Example
+(1) of a derived attribute</title> <p>The following line in the <filepath>config.hcf</filepath> file shows how to configure the API for the
+display contrast. This states that the display contrast is settable,
+and that the function to do this is called <codeph>ProcessDisplayContrast</codeph>. </p> <codeblock id="GUID-BC43C02A-4436-5BFF-AA35-BF3D2F33AE3C" xml:space="preserve">EDisplayContrast : set = ProcessDisplayContrast</codeblock> </section>
+<section id="GUID-83AF21A8-517D-442F-B621-1921A2A8C40E"><title>Example
+(2) of a derived attribute</title> <p>The following lines in the <filepath>config.hcf</filepath> file shows how to configure the API for the
+display size. </p> <codeblock id="GUID-ACD86D8C-887C-5B32-813A-6E468DE46E74" xml:space="preserve">EDisplayXPixels=ProcessDisplayCurrentModeInfo
+EDisplayYPixels=ProcessDisplayCurrentModeInfo</codeblock> <p>This
+is read only information, so the entries do not contain the "set"
+keyword. The values are derived via the API function <codeph>ProcessDisplayCurrentModeInfo</codeph>, and there is no corresponding entry in <filepath>values.hda</filepath>. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-52702561-DA37-5381-BA0D-76D9A41B2760.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,274 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-52702561-DA37-5381-BA0D-76D9A41B2760" xml:lang="en"><title>ROFSBUILD Obey File Structure</title><shortdesc>A <codeph>ROFSBUILD</codeph> obey file consists of a number
+of sections, each defining a ROFS image.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>A ROFS image is used to store code that is not part of the Core
+OS section. The File Server uses ROFS (the Read-Only File System)
+to access this, and ROFS uses a Media Driver to read the data from
+the NAND Flash device and to load this into RAM for access or execution.
+The Composite File System combines this media area with the Core OS
+media area and presents the two as a single read-only drive <filepath>Z:</filepath>. </p>
+<p>A ROFS image contain the following main sections: </p>
+<ul>
+<li id="GUID-D75AAEF2-C4CB-505B-8241-4B4004B64888"><p>a <codeph>CoreImage</codeph> section that specifies the existing core image to be used as the
+base for generating the extension image. </p> </li>
+<li id="GUID-47DDE7A8-725A-58D0-9FCB-B26C016FC1D3"><p>an <codeph>ExtensionRomSection</codeph> that defines the ROM image that extends the core image. </p> </li>
+</ul>
+<p>The structure is defined as: </p>
+<codeblock id="GUID-9A1B02AB-D374-5F38-8059-194716683578" xml:space="preserve">ObeyFile : CoreImageStatement [ ExtensionRomSection ]</codeblock>
+<codeblock id="GUID-938C40C7-7F1A-5045-8CAD-A32854825C58" xml:space="preserve">CoreImage : coreimage = &lt;CoreImageFileName&gt;</codeblock>
+<codeblock id="GUID-09B9C238-E6C9-5FB7-A4C9-AC7489F2F085" xml:space="preserve">ExtensionRomSection : ObeyStatementList</codeblock>
+<codeblock id="GUID-EDD5A97A-32F4-598C-97D9-5AA7D7285A4E" xml:space="preserve">ObeyStatementList : ObeyStatement | ObeyStatement ObeyStatementList
+ObeyStatement : RomStatement | FileStatement</codeblock>
+<ul>
+<li id="GUID-F8D61C60-EC9F-586D-BD44-E3F3A4D2E146"><p>See <xref href="GUID-52702561-DA37-5381-BA0D-76D9A41B2760.dita#GUID-52702561-DA37-5381-BA0D-76D9A41B2760/GUID-558A26ED-F79A-5DDB-AD5C-63204D6C565A">RomStatement</xref>  </p> </li>
+<li id="GUID-848AC4AD-FC40-5BF4-9FCE-62FC730FE194"><p>See <xref href="GUID-52702561-DA37-5381-BA0D-76D9A41B2760.dita#GUID-52702561-DA37-5381-BA0D-76D9A41B2760/GUID-37B07648-CCE5-5523-83EE-E5A65FBE3864">FileStatement</xref>  </p> </li>
+<li id="GUID-BD262DE4-F923-5FB9-9EC8-367F01301C91"><p>See <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-2322ABCF-3771-5965-8FBE-6AE58240ED2D">coreimage</xref> keyword </p> </li>
+</ul>
+<section id="GUID-558A26ED-F79A-5DDB-AD5C-63204D6C565A"><title>RomStatement</title> <p>A <codeph>RofsStatement</codeph> is one of the following: </p> <table id="GUID-CADF73E6-545A-56E9-A63B-0B61758C3973">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-BEB026CF-0136-545D-9348-78A8C559EBB1">autosize</xref> = </p> </entry>
+<entry><p> <codeph>&lt;block-size&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-1E15B489-2FF4-5C14-90B2-0EE66CBB7F7F">extensionrofs</xref>  </p> </entry>
+<entry><p> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-7780C1D5-92C0-58D1-9953-7231A760546E">extensionrofsname</xref> = </p> </entry>
+<entry><p> <codeph>&lt;filename&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-A71135A8-C6A6-50DB-8081-8CCD5B6AC0CB">externaltool</xref> = </p> </entry>
+<entry><p> <codeph>&lt;toolname&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-660AC1A4-948B-53AA-96F2-BFE48E478474">rofsname</xref> = </p> </entry>
+<entry><p> <codeph>&lt;filename&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-208C0FE4-DFC0-55C3-B6D7-F18C74F1A699">rofsize</xref> = </p> </entry>
+<entry><p> <codeph>&lt;size-in-bytes&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-6CD93289-02BF-57B9-8BD4-CFC0FF1EB3E0"> version</xref> = </p> </entry>
+<entry><p> <codeph>[ &lt;major&gt; ] [ .&lt;minor&gt; ] [ (&lt;build&gt;) 
+                 ]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-4F40AAAE-A6CE-5492-99E3-95B0D74F3229">romsize</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-size&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-D9A6B254-D76E-51C2-A943-FA360CDB3F0E">romchecksum</xref> = </p> </entry>
+<entry><p> <codeph>&lt;base-checksum&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-39410510-6C93-5203-8577-5C4D1520517F">time</xref> = </p> </entry>
+<entry><p> <codeph>dd/mm/yyyy hh:mm:ss</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-31DD609C-5C70-5626-B892-5FD7BA63B640">trace</xref> = </p> </entry>
+<entry><p> <codeph>&lt;32bit-hex-number&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-ADB633E8-8DD1-514C-9560-A6A2429DA199">pagingoverride</xref>  </p> </entry>
+<entry><p> <codeph>[NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED |     
+             DEFAULTPAGED]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-29A1FB89-E364-5C90-99D3-92247B514810">pagingpolicy</xref>  </p> </entry>
+<entry><p> <codeph>[NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED |     
+             DEFAULTPAGED]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-705897FD-9EC4-5F54-9198-A93C5080B80E">patchdata</xref> = </p> </entry>
+<entry><p> <codeph>&lt;DLLname&gt;@&lt;symbolname&gt; &lt;newvalue&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-9F070479-77D7-57E0-B142-64B3A23BBB1F">codepagingpolicy</xref></entry>
+<entry><p><codeph>[NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED | DEFAULTPAGED]</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-7DAC5804-0A03-5098-836A-2DB2CDB6F5D4">datapagingpolicy</xref></entry>
+<entry><p><codeph>[NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED | DEFAULTPAGED]</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-20A2663B-FE05-5E0A-ACF9-669EDDC8317C">codepagingoverride</xref></entry>
+<entry><p><codeph>[NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED | DEFAULTPAGED]</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-DF3AEED2-A9D0-5176-B4E5-63F73262BE07">datapagingoverride</xref></entry>
+<entry><p><codeph>[NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED | DEFAULTPAGED]</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-F15BB2C7-6773-5636-B329-4789AFEC809C">dataimagename</xref> = </entry>
+<entry><p><codeph>&lt;image name&gt;</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-3C7B6900-5190-540B-8B17-F0BCE7FCB1DB">dataimagefilesystem</xref> = </entry>
+<entry><p><codeph>&lt;FAT16 | FAT32&gt;</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-C0E3CB31-93F9-548F-BAD1-54D04F719504">dataimagesize</xref> =</entry>
+<entry><p><codeph>&lt;size in bytes&gt;</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-169AE2D3-6382-5262-A763-E68B1678967F">volume </xref> =</entry>
+<entry><p><codeph>&lt;volume label&gt;</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-908AECD2-5F98-55B9-BFFF-E25D7AA90D50">sectorsize</xref> =</entry>
+<entry><p><codeph>&lt;size in bytes&gt;</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-1D289928-36B0-55D6-A061-7D01C6E5802A">fattable</xref> =</entry>
+<entry><p><codeph>&lt;number of FAT tables&gt;</codeph></p></entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-37B07648-CCE5-5523-83EE-E5A65FBE3864"><title>FileStatement</title> <codeblock id="GUID-0A6EF9A1-C253-553E-8B78-83A1EFF94B9C" xml:space="preserve">FileStatement : FileSpecificationStatement | ControlStatement | RomDirectoryStatement</codeblock> <p>A <codeph>ControlStatement</codeph> is one of the following: </p> <table id="GUID-2B45E748-A43C-57C0-9A1D-223B3CA3DC45">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-9724A786-4431-595F-8945-C29914D63A40">rem</xref>  </p> </entry>
+<entry><p> <codeph>&lt;comments&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-0D56F068-91DE-50C8-94FF-9744B5E5B3E6">stop</xref>  </p> </entry>
+<entry><p> </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>A <codeph>FileSpecificationStatement</codeph> is one of
+the following: </p> <table id="GUID-8A824C20-75D5-5B24-A40D-7B4A2E149744">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-23851F44-7FAC-5B99-8D15-44099A61A4E4">data[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;Source-file&gt; &lt;destination-file&gt; [</codeph> <xref href="GUID-52702561-DA37-5381-BA0D-76D9A41B2760.dita#GUID-52702561-DA37-5381-BA0D-76D9A41B2760/GUID-BDFAA694-A9E4-540A-9F76-9192DEA5D91A">FileAttributeList</xref> <codeph>]</codeph> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-ECDEA52A-1357-5173-AA80-4E34A83A4511">file[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;Source-file&gt; &lt;destination-file&gt; [</codeph> <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-723EAEB3-3D76-513D-B010-49C40E3113BC">FileAttributeList</xref>] [<xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-D77A83B7-71A9-5473-8E11-63D5B5470C2E">OverrideAttributeList</xref> <codeph>]                   [paged |
+unpaged]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-B9B523ED-4D61-5EBF-9EFC-C47F8FA78C80">filecompress[[HWVD]]</xref> = </p></entry>
+<entry><p><codeph>&lt;source-file&gt; &lt;destination-image-file&gt; [<xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-723EAEB3-3D76-513D-B010-49C40E3113BC">FileAttributeList</xref>][<xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-D77A83B7-71A9-5473-8E11-63D5B5470C2E">OverrideAttributeList</xref>]</codeph></p></entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-9CAD6F80-7817-56E6-BB06-DB70B0A1EBF1">fileuncompress[[HWVD]] </xref> = </p></entry>
+<entry><p><codeph>&lt;source-file&gt; &lt;destination-image-file&gt; [<xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-723EAEB3-3D76-513D-B010-49C40E3113BC">FileAttributeList</xref>][<xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-D77A83B7-71A9-5473-8E11-63D5B5470C2E">OverrideAttributeList</xref>]</codeph></p></entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>A <codeph>RomDirectoryStatement</codeph> is one of the
+following: </p> <table id="GUID-694F3A85-F64E-513A-853C-2755D7DDAC19">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-0A8E6B07-1C40-55DD-A2D8-122E62A285F1">hide[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;existing-file&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-7CE887E7-C2C3-5F87-AB40-AFA571A68A23">alias[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;existing-file&gt; &lt;destination-file&gt;      
+            [</codeph> <xref href="GUID-52702561-DA37-5381-BA0D-76D9A41B2760.dita#GUID-52702561-DA37-5381-BA0D-76D9A41B2760/GUID-BDFAA694-A9E4-540A-9F76-9192DEA5D91A">FileAttributeList</xref> <codeph>]</codeph> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-4584DD65-6861-5B2A-A4FB-B7F366DCE13A">rename[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;existing-file&gt; &lt;destination-file&gt; [</codeph> <xref href="GUID-52702561-DA37-5381-BA0D-76D9A41B2760.dita#GUID-52702561-DA37-5381-BA0D-76D9A41B2760/GUID-BDFAA694-A9E4-540A-9F76-9192DEA5D91A">FileAttributeList</xref> <codeph>]</codeph> </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-BDFAA694-A9E4-540A-9F76-9192DEA5D91A"><title>FileAttributeList</title> <codeblock id="GUID-C7F5805D-5039-58CB-9870-099BB5A6CC02" xml:space="preserve">FileAttributeList : FileAttribute | FileAttribute  FileAttributeList</codeblock> <p>A <codeph>FileAttribute</codeph> is one of the following: </p> <table id="GUID-D5B8B5AA-0F1C-5C40-AB8E-FCA60B3DCAD3">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-19D49CB3-C180-5F32-9488-63C71A3D5991">attrib</xref> = </p> </entry>
+<entry><p> <codeph>[ s | S ][ h | H ][ r | R | w | W ] | hide</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-1374D944-1C79-5C23-B972-1B0BABA09450">exattrib</xref> = </p> </entry>
+<entry><p> <codeph>U</codeph>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-18A03082-87E0-4543-A241-38A4435B57F6"><title>OverrideAttributeList</title><p><codeblock xml:space="preserve">OverrideAttributeList : OverrideAttribute | OverrideAttribute  OverrideAttributeList</codeblock></p><p>An <codeph>overrideAttribute</codeph> is one of the following:</p><table id="GUID-CE4D5A2E-D2B9-54DF-A365-958FA62FA13B-GENID-1-2-1-8-1-1-6-1-1-11-1-5-1-3-13-4">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-03F5D906-B29F-4375-9EA4-BDEEFE53645F">capability</xref> =</entry>
+<entry><p><codeph>&lt;capability&gt;</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-C95FF58E-B556-4B31-AC67-9B8FCB283D0F">paged</xref></entry>
+<entry/>
+</row>
+<row>
+<entry><xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-AE7F4574-69AD-4817-A15D-A4560BA210D6">unpaged</xref></entry>
+<entry/>
+</row>
+<row>
+<entry><xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-1314D06A-FA06-4D08-87FA-4B4927081127">pagedcode</xref></entry>
+<entry/>
+</row>
+<row>
+<entry><xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-6423A7D6-1129-49A1-882E-64C5182A197F">unpagedcode</xref></entry>
+<entry/>
+</row>
+<row>
+<entry><xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-23A28BEA-1AF4-42B6-887F-60C7B0EE2DEC">pageddata</xref></entry>
+<entry/>
+</row>
+<row>
+<entry><xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-F6B182CA-4042-4E03-8718-893423913EB8">unpageddata</xref></entry>
+<entry/>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-205BE385-1937-5034-9DBE-51D1A276326A">stack</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-size&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-250AC57D-0430-5DBD-B04E-99A874E42256">heapmin</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-size&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-DDB9FC14-73FF-5D99-963E-C289D3091FD1">heapmax</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-size&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-02DE8552-5FE0-52D4-8A82-A0B679E934AA">priority</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-number&gt; | &lt;keyword&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-A53DC5BA-7531-53F4-9117-4F26D372F212">uid1</xref> = </p> </entry>
+<entry><p> <codeph>&lt;uid value&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-342B6CA5-8508-5673-900F-9CF331F5AC79">uid2</xref> = </p> </entry>
+<entry><p> <codeph>&lt;uid value&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-6F5B7223-A8E2-51EC-B950-79426DB0AAB4">uid3</xref> = </p> </entry>
+<entry><p> <codeph>&lt;uid value&gt;</codeph>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-529757E6-ABF2-5C5C-A995-7DED6D298F52.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,76 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-529757E6-ABF2-5C5C-A995-7DED6D298F52" xml:lang="en"><title>Design</title><shortdesc>This topic describes how to design the USB client controller
+for different types of USB hardware.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>On most hardware platforms, the variant is split into a common,
+or ASSP, layer and a device specific, or variant, layer; for example,
+the Symbian port for the template board is split into a core layer
+for the ASSP (in <filepath>...\template_assp\...</filepath>) and code
+specific to the template board (in <filepath>...\template_variant\...</filepath>). </p>
+<p>On some hardware configurations, the USB platform-specific layer
+functionality is not only dependent on the USB device controller (in
+the ASSP) but also on the variant. As an example, the USB cable connection/disconnection
+notification mechanism is not defined in the USB specification. This
+means that some USB device controllers have a mechanism for detecting
+the status of a cable connection that is internal to the ASSP, while
+for other controllers the mechanism is variant specific, and requires
+software support in the variant layer. </p>
+<p>In the template example port, the ASSP layer is implemented by
+the <codeph>TemplateAssp</codeph> class defined in <filepath>...\template_assp\template_assp_priv.h</filepath>. This class defines a number of pure virtual functions that act
+as the interface to the cable connection status mechanism. </p>
+<codeblock id="GUID-4E7ED63E-5383-53D8-AC79-29AE307B1FED" xml:space="preserve">class TemplateAssp : public Asic
+    {
+
+    ...
+  /**
+     * USB client controller - Some example functions for the case that USB cable detection and
+     * UDC connect/disconnect functionality are part of the variant.
+     * Pure virtual functions called by the USB PSL, to be implemented by the variant (derived class).
+     * If this functionality is part of the ASSP then these functions can be removed and calls to them
+     * in the PSL (./pa_usbc.cpp) replaced by the appropriate internal operations.
+     */
+    virtual TBool UsbClientConnectorDetectable()=0;
+    virtual TBool UsbClientConnectorInserted()=0;
+    virtual TInt RegisterUsbClientConnectorCallback(TInt (*aCallback)(TAny*), TAny* aPtr)=0;
+    virtual void UnregisterUsbClientConnectorCallback()=0;
+    virtual TBool UsbSoftwareConnectable()=0;
+    virtual TInt UsbConnect()=0;
+    virtual TInt UsbDisconnect()=0;
+</codeblock>
+<p>In the template example port, the variant layer is implemented
+by the <codeph>Template</codeph> class defined in <filepath>...\template_variant\inc\variant.h</filepath>. The variant layer provides the implementation for these USB pure
+virtual functions. </p>
+<codeblock id="GUID-D697E009-5C21-5C7A-A31A-7A526413655E" xml:space="preserve">NONSHARABLE_CLASS(Template) : public TemplateAssp
+    {
+
+    ...
+     /**
+     * USB client controller - Some example functions for the case that USB cable detection and
+     * UDC connect/disconnect functionality are part of the variant.
+     * These virtual functions are called by the USB PSL (pa_usbc.cpp).
+     * If this functionality is part of the ASSP then these functions can be removed as calls to them
+     * in the PSL will have been replaced by the appropriate internal operations.
+     */
+    virtual TBool UsbClientConnectorDetectable();
+    virtual TBool UsbClientConnectorInserted();
+    virtual TInt RegisterUsbClientConnectorCallback(TInt (*aCallback)(TAny*), TAny* aPtr);
+    virtual void UnregisterUsbClientConnectorCallback();
+    virtual TBool UsbSoftwareConnectable();
+    virtual TInt UsbConnect();
+    virtual TInt UsbDisconnect();
+</codeblock>
+<p>The implementation for these functions can be found in <filepath>...\template_variant\specific\variant.cpp</filepath>. </p>
+<p>The USB port also needs interrupt handling code to deal with USB
+external interrupts. See the <xref href="GUID-3C34724F-B476-5329-B0B1-6D5A34294979.dita">Interrupt Dispatcher
+Tutorial</xref> for details about how to do this. </p>
+<note>This may be done by others as a specialist porting activity. </note>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-52B8098A-7695-5EA6-B58F-D730A445C583-master.png has changed
Binary file Adaptation/GUID-52B8098A-7695-5EA6-B58F-D730A445C583_d0e77443_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-535C66C9-8B45-4DF3-8404-8ED03ABB4799-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-11-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-535C66C9-8B45-4DF3-8404-8ED03ABB4799-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-11-1" xml:lang="en"><title>TSDIOInterrupt
+Class Tutorial</title><shortdesc>Describes the TSDIOInterrupt API class.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-26C82435-8FB9-422E-B6D0-302CB1E4B5F5-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-11-1-3-1"><title>Description</title><p>The <xref href="GUID-5A5218D4-E8AD-322F-BE5B-597137623B3F.dita"><apiname>TSDIOInterrupt</apiname></xref> class
+provides the client with the ability to enable, disable, bind and unbind to
+an SDIO interrupt. There is no Clear() method provided as it is the responsibility
+of the client device driver to clear the appropriate interrupt through its <xref href="GUID-CC5352E2-DB21-393F-A7A4-108AA3684460.dita"><apiname>DSDIORegInterface</apiname></xref> class
+documented <xref href="GUID-2607CCFA-3D24-4716-A447-74304F861C44.dita">here</xref>.</p><table id="GUID-8047BB14-2519-4421-B6BD-41B078CAC404-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-11-1-3-1-3">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p>Header file</p></entry>
+<entry><p><filepath>interrupt.h</filepath></p></entry>
+</row>
+<row>
+<entry><p>Source code file</p></entry>
+<entry><p><filepath>interrupt.cpp</filepath></p></entry>
+</row>
+<row>
+<entry><p>Required libraries</p></entry>
+<entry><p>epbussdio.lib</p></entry>
+</row>
+<row>
+<entry><p>Class declaration</p></entry>
+<entry><p><codeph>class TSDIOInterrupt</codeph></p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-ACEDEF93-FD3F-4F19-9641-36F4FAC8FE66-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-11-1-3-2"><title>Bind()</title><p>The
+function declaration for the <xref href="GUID-8DAB6465-BCDE-35FE-8C31-861C13A34526.dita"><apiname>Bind()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt Bind(TSDIOIsr aIsr, TAny* aPtr);</codeblock><p><b>Description</b></p><p>Binds the <xref href="GUID-5E00A59F-9316-3522-B152-EA8F8BC429B3.dita"><apiname>TSDIOIsr</apiname></xref> callback to the function's interrupt.
+Once bound, the interrupt should be enabled for the function by a call to
+Enable().</p><p><b>Parameters</b></p><p><table id="GUID-8F76FE85-D8EF-4FBF-974F-CB5CD7FF76FB-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-11-1-3-2-7-1">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TSDIOIsr aIsr</codeph></p></entry>
+<entry>The ISR used to handle the function's interrupt.</entry>
+</row>
+<row>
+<entry><p><codeph>TAny* aPtr</codeph></p></entry>
+<entry>User defined data for use within the ISR.</entry>
+</row>
+</tbody>
+</tgroup>
+</table></p><p><b>Return value</b></p><p><codeph>KErrNone</codeph> if successful, <codeph>KErrAlreadyExists</codeph> if
+an ISR already bound to the function's interrupt, or a standard Symbian platform
+error code.</p></section>
+<section id="GUID-ACEDEF93-FD3F-4F19-9641-36F4FAC8FE66-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-11-1-3-3"><title>Unbind()</title><p>The
+function declaration for the <xref href="GUID-EAED145E-E4BE-3A0F-BC25-78E1FC13FB55.dita"><apiname>Unbind()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt Unbind();</codeblock><p><b>Description</b></p><p>Unbinds
+the callback from the interrupt controller, replacing the callback with a
+dummy handler.</p><p><b>Parameters</b></p><p>None.</p><p><b>Return value</b></p><p><codeph>KErrNone</codeph> if
+successful, otherwise a standard Symbian platform error code.</p></section>
+<section id="GUID-ACEDEF93-FD3F-4F19-9641-36F4FAC8FE66-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-11-1-3-4"><title>Enable()</title><p>The
+function declaration for the <xref href="GUID-1B8F9258-D611-39DC-B0A7-8BB634915752.dita"><apiname>Enable()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt Enable();</codeblock><p><b>Description</b></p><p>Enables
+the function's interrupt by setting the appropriate IEN bit in the CCCR. Note
+that this only unmasks the global function interrupt. It is the responsibility
+ of the client to perform any function-specific interrupt enabling that may
+be required.</p><p><b>Parameters</b></p><p>None.</p><p><b>Return value</b></p><p><codeph>KErrNone</codeph> if
+successful, otherwise a standard Symbian platform error code.</p></section>
+<section id="GUID-ACEDEF93-FD3F-4F19-9641-36F4FAC8FE66-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-11-1-3-5"><title>Disable()</title><p>The
+function declaration for the <xref href="GUID-229B7E6B-EF06-3C54-8D92-F1075B04D585.dita"><apiname>Disable()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt Disable();</codeblock><p><b>Description</b></p><p>Disables the function's interrupt by clearing the appropriate IEN bit in
+the CCCR.  Note that this only masks the global function interrupt. It is
+the responsibility  of the client to perform any function-specific interrupt
+disabling that may be required.</p><p><b>Parameters</b></p><p>None.</p><p><b>return
+value</b></p><p><codeph>KErrNone</codeph> if successful, otherwise a standard
+Symbian platform error code.</p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-535C66C9-8B45-4DF3-8404-8ED03ABB4799-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-535C66C9-8B45-4DF3-8404-8ED03ABB4799-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1" xml:lang="en"><title>TSDIOInterrupt
+Class Tutorial</title><shortdesc>Describes the TSDIOInterrupt API class.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-26C82435-8FB9-422E-B6D0-302CB1E4B5F5-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1-3-1"><title>Description</title><p>The <xref href="GUID-5A5218D4-E8AD-322F-BE5B-597137623B3F.dita"><apiname>TSDIOInterrupt</apiname></xref> class
+provides the client with the ability to enable, disable, bind and unbind to
+an SDIO interrupt. There is no Clear() method provided as it is the responsibility
+of the client device driver to clear the appropriate interrupt through its <xref href="GUID-CC5352E2-DB21-393F-A7A4-108AA3684460.dita"><apiname>DSDIORegInterface</apiname></xref> class
+documented <xref href="GUID-2607CCFA-3D24-4716-A447-74304F861C44.dita">here</xref>.</p><table id="GUID-8047BB14-2519-4421-B6BD-41B078CAC404-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1-3-1-3">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p>Header file</p></entry>
+<entry><p><filepath>interrupt.h</filepath></p></entry>
+</row>
+<row>
+<entry><p>Source code file</p></entry>
+<entry><p><filepath>interrupt.cpp</filepath></p></entry>
+</row>
+<row>
+<entry><p>Required libraries</p></entry>
+<entry><p>epbussdio.lib</p></entry>
+</row>
+<row>
+<entry><p>Class declaration</p></entry>
+<entry><p><codeph>class TSDIOInterrupt</codeph></p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-ACEDEF93-FD3F-4F19-9641-36F4FAC8FE66-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1-3-2"><title>Bind()</title><p>The
+function declaration for the <xref href="GUID-8DAB6465-BCDE-35FE-8C31-861C13A34526.dita"><apiname>Bind()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt Bind(TSDIOIsr aIsr, TAny* aPtr);</codeblock><p><b>Description</b></p><p>Binds the <xref href="GUID-5E00A59F-9316-3522-B152-EA8F8BC429B3.dita"><apiname>TSDIOIsr</apiname></xref> callback to the function's interrupt.
+Once bound, the interrupt should be enabled for the function by a call to
+Enable().</p><p><b>Parameters</b></p><p><table id="GUID-8F76FE85-D8EF-4FBF-974F-CB5CD7FF76FB-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1-3-2-7-1">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TSDIOIsr aIsr</codeph></p></entry>
+<entry>The ISR used to handle the function's interrupt.</entry>
+</row>
+<row>
+<entry><p><codeph>TAny* aPtr</codeph></p></entry>
+<entry>User defined data for use within the ISR.</entry>
+</row>
+</tbody>
+</tgroup>
+</table></p><p><b>Return value</b></p><p><codeph>KErrNone</codeph> if successful, <codeph>KErrAlreadyExists</codeph> if
+an ISR already bound to the function's interrupt, or a standard Symbian platform
+error code.</p></section>
+<section id="GUID-ACEDEF93-FD3F-4F19-9641-36F4FAC8FE66-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1-3-3"><title>Unbind()</title><p>The
+function declaration for the <xref href="GUID-EAED145E-E4BE-3A0F-BC25-78E1FC13FB55.dita"><apiname>Unbind()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt Unbind();</codeblock><p><b>Description</b></p><p>Unbinds
+the callback from the interrupt controller, replacing the callback with a
+dummy handler.</p><p><b>Parameters</b></p><p>None.</p><p><b>Return value</b></p><p><codeph>KErrNone</codeph> if
+successful, otherwise a standard Symbian platform error code.</p></section>
+<section id="GUID-ACEDEF93-FD3F-4F19-9641-36F4FAC8FE66-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1-3-4"><title>Enable()</title><p>The
+function declaration for the <xref href="GUID-1B8F9258-D611-39DC-B0A7-8BB634915752.dita"><apiname>Enable()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt Enable();</codeblock><p><b>Description</b></p><p>Enables
+the function's interrupt by setting the appropriate IEN bit in the CCCR. Note
+that this only unmasks the global function interrupt. It is the responsibility
+ of the client to perform any function-specific interrupt enabling that may
+be required.</p><p><b>Parameters</b></p><p>None.</p><p><b>Return value</b></p><p><codeph>KErrNone</codeph> if
+successful, otherwise a standard Symbian platform error code.</p></section>
+<section id="GUID-ACEDEF93-FD3F-4F19-9641-36F4FAC8FE66-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1-3-5"><title>Disable()</title><p>The
+function declaration for the <xref href="GUID-229B7E6B-EF06-3C54-8D92-F1075B04D585.dita"><apiname>Disable()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt Disable();</codeblock><p><b>Description</b></p><p>Disables the function's interrupt by clearing the appropriate IEN bit in
+the CCCR.  Note that this only masks the global function interrupt. It is
+the responsibility  of the client to perform any function-specific interrupt
+disabling that may be required.</p><p><b>Parameters</b></p><p>None.</p><p><b>return
+value</b></p><p><codeph>KErrNone</codeph> if successful, otherwise a standard
+Symbian platform error code.</p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-535E5C2A-DCFD-4BCB-B26B-11E88BDB8A8A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,295 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-535E5C2A-DCFD-4BCB-B26B-11E88BDB8A8A" xml:lang="en"><title>TDmac Derived Class Implementation</title><shortdesc>Implementing the hardware-specific DMA controller.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> class is part of the PIL. It is a
+container for the DMA controller's channels, descriptors and descriptor
+headers. It also defines virtual functions for operations that require
+a PSL implementation.</p>
+<p>You need to derive <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> for each distinct type
+of DMA controller on your device, and implement these virtual functions.</p>
+<p><table id="GUID-2AB9BEBC-9C41-4CAC-A222-24083FAD5F2B">
+<tgroup cols="3"><colspec colname="col1"/><colspec colname="COLSPEC1" colwidth="1.00*"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">Function</entry>
+<entry valign="top">Mandatory/Conditional</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-E0617B44-6C99-3327-9E20-2975E465AA8C.dita"><apiname>Transfer()</apiname></xref></entry>
+<entry>Mandatory</entry>
+<entry>For single buffer and scatter/gather, this starts the DMA transfer.
+For double buffer, this prepares the next fragment to transfer while
+a current transfer is in operation</entry>
+</row>
+<row>
+<entry><xref href="GUID-267716ED-F59A-35FB-89CC-FB82540FEA79.dita"><apiname>StopTransfer()</apiname></xref></entry>
+<entry>Mandatory</entry>
+<entry>Stop the specified channel synchronously. Must not return to
+the PSL implementation until the channel has stopped.</entry>
+</row>
+<row>
+<entry><xref href="GUID-ACF1D126-591B-3A84-9F53-94370B1BFA7B.dita"><apiname>IsIdle()</apiname></xref></entry>
+<entry>Mandatory</entry>
+<entry>Returns <codeph>ETrue</codeph> if specified channel is idle,
+otherwise <codeph>EFalse</codeph></entry>
+</row>
+<row>
+<entry><xref href="GUID-D8ECA8CE-7F7C-356D-9C9F-4BD37ED2618C.dita"><apiname>MaxTransferSize()</apiname></xref></entry>
+<entry>Optional</entry>
+<entry>Takes the parameters and evaluates the maximum transfer size
+in bytes.</entry>
+</row>
+<row>
+<entry><xref href="GUID-F6CBDDF7-A9C1-3534-9F5E-5B4FC77E888B.dita"><apiname>MemAlignMask()</apiname></xref></entry>
+<entry>Optional</entry>
+<entry><i>This applies to DMA v1 only.</i></entry>
+</row>
+<row>
+<entry><xref href="GUID-AA9217AF-EF1C-3010-AA7E-A4D3FCA14B30.dita"><apiname>InitHwDes()</apiname></xref></entry>
+<entry>Optional</entry>
+<entry>For scatter-gather, initialise the array of memory areas and
+set up the first block of data to be transferred.</entry>
+</row>
+<row>
+<entry><xref href="GUID-DCEFF8BA-BC74-3DA4-88CC-6A2C2E928BFE.dita"><apiname>ChainHwDes()</apiname></xref></entry>
+<entry>Optional</entry>
+<entry>For scatter-gather, add additional blocks of data to transfer
+to the list of memory areas.</entry>
+</row>
+<row>
+<entry><xref href="GUID-7076A78C-24F8-36B0-8FC2-F4DA8AB6DC14.dita"><apiname>AppendHwDes()</apiname></xref></entry>
+<entry>Optional</entry>
+<entry>For scatter-gather, add to the array of memory areas while
+the transfer is active. This is used in particular for streaming data
+where new descriptors can be added to the end of the chain while data
+earlier in the train is being transferred. E.g. video streaming.</entry>
+</row>
+<row>
+<entry><xref href="GUID-9D519453-8CA5-3200-8E9A-BB1599C25CE9.dita"><apiname>UnlinkHwDes()</apiname></xref></entry>
+<entry>Optional</entry>
+<entry>For scatter-gather, remove items from the array of memory areas.</entry>
+</row>
+<row>
+<entry><xref href="GUID-5569F5DA-D5FD-3368-99E4-F9AE6E1A7752.dita"><apiname>FailNext()</apiname></xref></entry>
+<entry>Optional</entry>
+<entry>For a sequence of memory transfers, tell the next one to fail. </entry>
+</row>
+<row>
+<entry><xref href="GUID-ED81D339-84D6-3811-AC39-184D6AC723C0.dita"><apiname>MissNextInterrupts()</apiname></xref></entry>
+<entry>Optional</entry>
+<entry>DMA transfers start on the next interrupt, but sometimes you
+want to skip the next interrupt for synchronisation or other reasons.</entry>
+</row>
+<row>
+<entry><xref href="GUID-93A3F01A-3489-37E5-921C-5EA5228545AA.dita"><apiname>Extension()</apiname></xref></entry>
+<entry>Optional</entry>
+<entry>Pass a command from the application/client down to the DMA
+chipset. Hardware dependent.</entry>
+</row>
+</tbody>
+</tgroup>
+</table></p>
+<section id="GUID-525949BF-21B1-40DA-888E-D05B204BC382"><title>Implement
+the mandatory controller virtual functions</title> <p>The <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> class contains several pure virtual functions that
+must be implemented by the PSL implementation: </p><ul>
+<li id="GUID-5FE89E59-2C8F-417E-AC84-77C8F20EA2E7"><xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-81921A9D-41F5-34BC-B882-60CC4CD807FB"><apiname>TDmac::Transfer()</apiname></xref></li>
+<li id="GUID-1D62C97A-5DC6-4BEE-B3EC-9120808FBFD6"><xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-B738D1B9-80FA-334D-ABEB-DFFF093E0B9D"><apiname>TDmac::StopTransfer()</apiname></xref></li>
+<li id="GUID-1708E632-4C79-4274-9363-4528095342A6"><xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-7422834D-CE6B-32DB-A040-7762A8BAB7D7"><apiname>TDmac::IsIdle()</apiname></xref></li>
+</ul> <p>These functions start and stop transfers on a DMA channel
+and are the main interface between the PIL and the PSL. The implementation
+of these functions depends on the hardware available for performing
+DMA, and on the characteristics used to specify a DMA transfer: </p><ul>
+<li id="GUID-93F00482-7DB7-4D0B-9BBC-62D0DEDFC669">the source and
+destination addresses </li>
+<li id="GUID-2BF651D7-261B-4B70-A281-07C14C0837D0">the burst size </li>
+<li id="GUID-638B0F70-6595-4B8C-8B46-22023B5AAF12">the maximum transfer
+size </li>
+<li id="GUID-879FE6AA-0D3E-4BAD-AB32-C3F6B4CB6758">the transfer width,
+i.e. number of bits per memory access </li>
+<li id="GUID-FD9A86D2-2BE6-4600-B0EF-54CCC2854D5D">the memory alignment
+and endianness. </li>
+</ul> <p>The DMA Framework manages the transfer descriptors according
+to the descriptor parameter passed into the <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> constructor by the derived class constructor; the descriptor parameter
+is a <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-BBD2153C-4B41-357C-9299-D710930AFCBE"><apiname>TDmac::SCreateInfo</apiname></xref> structure. The per-request
+transfer parameters are passed into the descriptors for each request
+issued by a driver. </p></section>
+<section id="GUID-9D4B491F-2E42-407F-BC99-E1F32AE6549E"><title>The
+transfer function: Transfer()</title> <p>This function initiates a
+previously constructed request on a specific channel. This is the
+template implementation: </p> <codeblock xml:space="preserve">
+void TTemplateDmac::Transfer(const TDmaChannel&amp; aChannel, const SDmaDesHdr&amp; aHdr)
+//
+// Initiates a (previously constructed) request on a specific channel.
+//
+    {
+    const TUint8 i = static_cast&amp;&lt;TUint8&amp;&gt;(aChannel.PslId());
+    TDmaDesc* pD = HdrToHwDes(aHdr);
+
+    __KTRACE_OPT(KDMA, Kern::Printf("&amp;&gt;TTemplateDmac::Transfer channel=%d des=0x%08X", i, pD));
+
+    // Load the first descriptor address into the DMAC and start it
+    // by setting the RUN bit.
+    (void) *pD, (void) i;
+
+    }
+</codeblock> </section>
+<section id="GUID-56D77E64-1AD3-4F17-AD26-562AEB97DC56"><title>The
+stop transfer function: StopTransfer()</title> <p>This is the template
+implementation: </p> <codeblock xml:space="preserve">void TTemplateDmac::StopTransfer(const TDmaChannel&amp; aChannel)
+//
+// Stops a running channel.
+//
+    {
+    const TUint8 i = static_cast&amp;&lt;TUint8&amp;&gt;(aChannel.PslId());
+
+    __KTRACE_OPT(KDMA, Kern::Printf("&amp;&gt;TTemplateDmac::StopTransfer channel=%d", i));
+
+    }
+</codeblock></section>
+<section id="GUID-C2427406-8F3A-407D-8D3D-9B3040542054"><title>The
+function: IsIdle()</title> <p><xref href="GUID-ACF1D126-591B-3A84-9F53-94370B1BFA7B.dita"><apiname>IsIdle()</apiname></xref> returns
+the state of a given channel. This is the template implementation: </p> <codeblock xml:space="preserve">TBool TTemplateDmac::IsIdle(const TDmaChannel&amp; aChannel)
+//
+// Returns the state of a given channel.
+//
+    {
+    const TUint8 i = static_cast&amp;&lt;TUint8&amp;&gt;(aChannel.PslId());
+
+    __KTRACE_OPT(KDMA, Kern::Printf("&amp;&gt;TTemplateDmac::IsIdle channel=%d", i));
+
+    return ETrue;
+    }
+</codeblock> </section>
+<section id="GUID-A385DE6A-E267-4F0C-A0AC-A85316706D68"><title>Implement
+the non-mandatory controller virtual functions</title> <p>The following
+auxiliary functions are used to implement the scatter-gather transfer
+mode behavior by creating and manipulating the linked list of transfer
+fragment headers that describe a given scatter-gather transaction.
+They are called by the <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> base class functions
+when the instance of the <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> derived class reports
+itself as being capable of scatter-gather operations. </p> <ul>
+<li id="GUID-8CFB839A-A2A2-47C5-A75A-062CE205FB0A"><xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-90AC3E58-E589-3F91-85F7-16A4ADFFFA69"><apiname>TDmac::InitHwDes()</apiname></xref></li>
+<li id="GUID-58BDB319-0A8D-4C1B-8C75-6C9E119D26DF"><xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-05021B05-75DE-3F75-92C6-8B9445EB86D3"><apiname>TDmac::ChainHwDes()</apiname></xref></li>
+<li id="GUID-2998E58B-2A02-4A66-87F5-A87F1915F47C"><xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-AFCDDA16-991D-3BDA-B90B-87BCAFF66E5C"><apiname>TDmac::AppendHwDes()</apiname></xref></li>
+</ul></section>
+<section id="GUID-4B1544BB-A3BC-4938-8832-FCD86C647953"><title>First
+scatter-gather support function: InitHwDes()</title> <p>This is a
+function for creating a scatter-gather list. From the information
+in the passed-in request, the function sets up the descriptor with
+that fragment's: </p><ul>
+<li id="GUID-A585C7E8-0C14-4F62-BB6B-C34FB4DEC0D1">source and destination
+address </li>
+<li id="GUID-5A58FD8F-BC32-48B9-BFA3-B376E4BD2ACC">size </li>
+<li id="GUID-C5BC6402-011F-497A-B3C2-C3AB5F29E1C7">driver/DMA controller
+specific transfer parameters: memory/peripheral, burst size, transfer
+width. </li>
+</ul> <p>This is the template implementation: </p> <codeblock xml:space="preserve">void TTemplateDmac::InitHwDes(const SDmaDesHdr&amp; aHdr, TUint32 aSrc, TUint32 aDest, TInt aCount,
+                              TUint aFlags, TUint32 aPslInfo, TUint32 /*aCookie*/)
+//
+// Sets up (from a passed in request) the descriptor with that fragment's source and destination address,
+// the fragment size, and the (driver/DMA controller) specific transfer parameters (mem/peripheral,
+// burst size, transfer width).
+//
+    {
+    TDmaDesc* pD = HdrToHwDes(aHdr);
+
+    __KTRACE_OPT(KDMA, Kern::Printf("TTemplateDmac::InitHwDes 0x%08X", pD));
+
+    // Unaligned descriptor? Error in generic layer!
+    __DMA_ASSERTD(IsHwDesAligned(pD));
+
+    pD-&amp;&gt;iSrcAddr = (aFlags &amp; KDmaPhysAddrSrc) ? aSrc : Epoc::LinearToPhysical(aSrc);
+    pD-&amp;&gt;iDestAddr = (aFlags &amp; KDmaPhysAddrDest) ? aDest : Epoc::LinearToPhysical(aDest);
+    pD-&amp;&gt;iCmd = DcmdReg(aCount, aFlags, aPslInfo);
+    pD-&amp;&gt;iDescAddr = TDmaDesc::KStopBitMask;
+    }
+</codeblock> </section>
+<section id="GUID-FAAE402C-959D-40CD-B208-C5AB9E495CAB"><title>Second
+scatter-gather support function: ChainHwDes()</title> <p>If the framework
+needs to fragment the client’s request, either because of the transfer
+size or because the memory is not a single contiguous block, then
+the framework calls this function. It chains hardware descriptors
+together by setting the next pointer of the original descriptor to
+the physical address of the descriptor to be chained. It assumes that
+the DMAC channel is quiescent when called. </p> <p>This is the template
+implementation: </p> <codeblock xml:space="preserve">void TTemplateDmac::ChainHwDes(const SDmaDesHdr&amp; aHdr, const SDmaDesHdr&amp; aNextHdr)
+//
+// Chains hardware descriptors together by setting the next pointer of the original descriptor
+// to the physical address of the descriptor to be chained.
+//
+    {
+    TDmaDesc* pD = HdrToHwDes(aHdr);
+    TDmaDesc* pN = HdrToHwDes(aNextHdr);
+
+    __KTRACE_OPT(KDMA, Kern::Printf("TTemplateDmac::ChainHwDes des=0x%08X next des=0x%08X", pD, pN));
+
+    // Unaligned descriptor? Error in generic layer!
+    __DMA_ASSERTD(IsHwDesAligned(pD) &amp;&amp; IsHwDesAligned(pN));
+
+    pD-&amp;&gt;iDescAddr = DesLinToPhys(pN);
+    }
+</codeblock></section>
+<section id="GUID-60013038-5A06-4926-A7F4-68D6FBA79ABC"><title>Third
+scatter-gather support function: AppendHwDes() </title> <p>This function
+is called by the <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> base class when a driver
+request is called for a channel that is still active, i.e. where the
+intent is to provide data streaming so that the target device is constantly
+provided with data; for example, an audio device playing a track.
+In this case, the function provided by the derived class must: </p> <ul>
+<li id="GUID-484E794E-A446-4AFD-8956-D072C6B5EC81">stop the DMAC to
+prevent any corruption of the scatter-gather list while appending
+the new fragment descriptor </li>
+<li id="GUID-2D05CB0A-450A-45DF-8736-E406CFC1C6A2">append the new
+descriptor </li>
+<li id="GUID-E638DFC8-8078-4D5A-AC78-1A06B01DDBE5">re-enable the channel,
+ideally before the target has detected the gap in service. </li>
+</ul> <p>This is the template implementation: </p> <codeblock xml:space="preserve">void TTemplateDmac::AppendHwDes(const TDmaChannel&amp; aChannel, const SDmaDesHdr&amp; aLastHdr,
+                                const SDmaDesHdr&amp; aNewHdr)
+//
+// Appends a descriptor to the chain while the channel is running.
+//
+    {
+    const TUint8 i = static_cast&amp;&lt;TUint8&amp;&gt;(aChannel.PslId());
+
+    TDmaDesc* pL = HdrToHwDes(aLastHdr);
+    TDmaDesc* pN = HdrToHwDes(aNewHdr);
+
+    __KTRACE_OPT(KDMA, Kern::Printf("&amp;&gt;TTemplateDmac::AppendHwDes channel=%d last des=0x%08X new des=0x%08X",
+                                    i, pL, pN));
+    // Unaligned descriptor? Error in generic layer!
+    __DMA_ASSERTD(IsHwDesAligned(pL) &amp;&amp; IsHwDesAligned(pN));
+
+    TPhysAddr newPhys = DesLinToPhys(pN);
+
+    const TInt irq = NKern::DisableAllInterrupts();
+    StopTransfer(aChannel);
+
+    pL-&amp;&gt;iDescAddr = newPhys;
+    const TTemplateSgChannel&amp; channel = static_cast&amp;&lt;const TTemplateSgChannel&amp;&amp;&gt;(aChannel);
+    TDmaDesc* pD = channel.iTmpDes;
+
+    (void) *pD, (void) i;
+
+    NKern::RestoreInterrupts(irq);
+
+    __KTRACE_OPT(KDMA, Kern::Printf("&amp;&lt;TTemplateDmac::AppendHwDes"));
+    }
+</codeblock></section>
+</conbody><related-links>
+<link href="GUID-4E3C086B-25BE-4DAC-9E21-CFC4F8B792A5.dita"><linktext>DMA
+Technology Guide</linktext></link>
+<link href="GUID-95A33491-17AC-4F12-948E-A1352ADDA483.dita"><linktext>DMA
+Implementation Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-53649311-4465-48B5-8D07-A65515950040.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-53649311-4465-48B5-8D07-A65515950040" xml:lang="en"><title>Data
+Transfer across Memory Boundaries</title><shortdesc>This document describes how to read from and write to user-side
+memory from a kernel thread context or a user thread.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>When a driver reads or writes data from or to a user-side program, the
+data must be copied between user address space and Kernel address space. The
+Kernel provides a number of APIs that allow this to be done safely. The API
+to use depends on whether the request is serviced in a user thread context,
+or in a Kernel thread context. </p>
+<section id="GUID-646C4340-6AC9-4152-9447-806B0AF53E32">       <title>From
+kernel space</title>       <p>To read and write data to the user space from
+a kernel thread context, use Kernel APIs such as <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-C505206F-F54F-3760-BA7D-2DB52AB4E0B3"><apiname>Kern::ThreadDesRead()</apiname></xref>, <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-904A42A8-8077-3FC6-BEF2-29619F079842"><apiname>Kern::ThreadRawRead()</apiname></xref>, <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-FA321582-6D75-37A1-8DAB-D50638F76593"><apiname>Kern::ThreadDesWrite()</apiname></xref>, and <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-182C88F4-326C-376E-9FBE-889E3CB9B68A"><apiname>Kern::ThreadRawWrite()</apiname></xref>. The data can be handled
+as descriptors or as raw memory. </p> <p>The Kernel also provides other APIs
+to safely read the information about a descriptor in another thread's address
+space. <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-22DD7D90-B4B5-3450-82BF-C3CC3A43430A"><apiname>Kern::ThreadGetDesInfo()</apiname></xref> returns the length, maximum
+length, and a pointer to the descriptor's buffer. The length and maximum length
+can also be obtained specifically by using <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-1DE210A5-B7A2-3F52-9003-439CA3DD4715"><apiname>Kern::ThreadGetDesLength()</apiname></xref> and <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-A5E20DB7-9DB4-350C-B636-95E2148DCC6F"><apiname>Kern::ThreadGetDesMaxLength()</apiname></xref>. </p> <codeblock id="GUID-640AEF03-EEC7-5E87-B4E2-C0AF09B08255" xml:space="preserve">TInt DExDriverLogicalChannel::DoControl(TInt aFunction, TAny* a1, TAny* /*a2*/)
+    {
+    ...
+    // To read the buffer descriptors from user space
+    r=Kern::ThreadDesRead(iClient,a1,iTxBuffer,0,0);
+    ...
+    // To write the buffer descriptors to user space
+    r=Kern::ThreadDesWrite(iClient,(TDes8*)a1,iRxBuffer,0);
+    ...
+    }</codeblock> <codeblock id="GUID-50FAEB14-8660-5AC8-9DD9-B33F77E1E529" xml:space="preserve">// Read the descriptor maximum length from the user thread (iClient)  
+// using the kernel API Kern::ThreadGetDesMaxLength(). This API 
+// gets the maximum length of a descriptor in another thread's 
+// address space. Kern::ThreadGetDesInfo() can also be used to 
+// get length, maximum length and pointer to the descriptor's 
+// buffer.
+//
+iCount=Kern::ThreadGetDesMaxLength(iClient,aData);</codeblock>     </section>
+<section id="GUID-7D3C7D57-0F76-4686-8AE6-C254CCC4A778"><p><b>From user space</b> </p> <p>When
+executing a read or write operation in the context of a user thread, use the
+following APIs: </p> <ul>
+<li id="GUID-69D74013-8670-58C2-A92D-68E0227EE266"><p> <xref href="GUID-B56A34CD-E5B5-3E3E-A2EE-3BC9D248B210.dita"><apiname>kumemget()</apiname></xref>  </p> </li>
+<li id="GUID-F686EE32-C1C4-5229-A7DD-D1F19430DF92"><p> <xref href="GUID-C7AB0391-99D5-31A2-91D4-A7F195546FC3.dita"><apiname> kumemput()</apiname></xref>  </p> </li>
+<li id="GUID-97147CB8-CEE1-5919-8491-D0E06B2BDC40"><p> <xref href="GUID-F5136CAF-B66F-388D-A610-D0153CAF7E23.dita"><apiname> umemget()</apiname></xref>  </p> </li>
+<li id="GUID-DD8A639B-161D-524F-BFD5-7C46A3D39900"><p> <xref href="GUID-371860F0-36BF-340D-BEF6-1763EF9874AE.dita"><apiname> umemput()</apiname></xref>  </p> </li>
+</ul> <p>Kernel APIs are also available to do copy operations using descriptors: </p> <ul>
+<li id="GUID-1958BA33-0D05-5757-9331-19AF2C3DF294"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-D7CE1BF2-F1B8-30E9-9D34-7BDDA39C1B0C"><apiname>Kern::KUDesGet()</apiname></xref>  </p> </li>
+<li id="GUID-AA5A7A0F-5053-5ED5-8BEA-C88822D1BB66"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-8B62DE20-357F-3499-9F2E-FAD4B18C34D6"><apiname>Kern::KUDesPut()</apiname></xref>  </p> </li>
+<li id="GUID-4E139680-6D2A-5A1F-A312-44473C90A356"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-F9B70C06-0611-3EA8-9C9C-553B77347D36"><apiname>Kern::KUDesInfo()</apiname></xref>  </p> </li>
+<li id="GUID-D1004AD8-FA86-50C5-A3B0-7861A5939D89"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-CE3887C0-9DBD-3A36-AF53-FE4192352500"><apiname>Kern::KUdesSetLength()</apiname></xref>  </p> </li>
+</ul> <p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-15287E72-897C-3F34-9C0A-E9C555456FDF"><apiname>Kern::InfoCopy()</apiname></xref> can be used to copy a descriptor
+safely in a way that enables forward and backward compatibility. It is typically
+used for copying capability packages. </p> <codeblock id="GUID-C2936EA7-98C1-5328-833D-F418298EFA09" xml:space="preserve">void DExDriverLogicalDevice::GetCaps(TDes8&amp; aCaps) const
+    {
+    // device capabilities are packaged to a buffer
+    TPckgBuf&lt;RExDriver::TUartCaps&gt; caps;
+    caps().iVersion=iVersion;
+    // Copy the device capabilities to the user thread using the 
+    // Kernel API
+    Kern::InfoCopy(aCaps,caps);
+    }</codeblock></section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-5392507E-45FF-4B20-B257-E58E23685295-master.png has changed
Binary file Adaptation/GUID-5392507E-45FF-4B20-B257-E58E23685295_d0e410_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-53944506-5CA2-52BA-8D5A-9EE72092612B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-53944506-5CA2-52BA-8D5A-9EE72092612B" xml:lang="en"><title>Bootstrap</title><shortdesc>Describes what is the bootstrap and how to implement it for a specific
+platform.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The bootstrap is a program that the phone runs after a hardware reset.
+The task of the bootstrap is to prepare a basic environment for the kernel
+to run. If the phone uses NAND Flash, then the NAND Flash Core Loader loads
+and starts the bootstrap.</p>
+<p>Symbian platform divides the bootstrap into a platform-independent layer
+that can be used with any ARM device, and a platform-specific layer that you
+must implement when you create a new phone. </p>
+</conbody><related-links>
+<link href="GUID-775B5858-4358-5195-B580-7C16AE4981C3.dita"><linktext>Flash Translation
+Layer Technology </linktext></link>
+<link href="GUID-80698E62-E310-59CA-A524-5CF44C437BE4.dita"><linktext>Base Starter</linktext>
+</link>
+<link href="GUID-A3449F37-89BB-5208-8FD5-F4DF73F7E71A.dita"><linktext>System Startup
+Overview</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-54042C84-6216-5930-9CBF-BAF635CECD4D.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-54042C84-6216-5930-9CBF-BAF635CECD4D" xml:lang="en"><title>Power
+HAL Handler Tutorial</title><shortdesc>User-side programs can get and set a number of system attributes
+about power using the <codeph>HAL</codeph> interface. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The base port must provide and register a HAL handler to handle these attributes. </p>
+<p>The power attributes are in the <xref href="GUID-FB85CE22-DDFF-37E6-A6CE-7F70A994D371.dita"><apiname>EHalGroupPower</apiname></xref> HAL group.
+The handler provides a kernel-side implementation to deal with the user-side
+calls to <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-573C49D6-7763-37AE-B2B2-4C8FB1327E21"><apiname>HAL::Get()</apiname></xref> and <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-9454F1B2-D525-3D6D-A872-C6457CACD4FC"><apiname>HAL::Set()</apiname></xref> when
+one of the following parameters is passed: </p>
+<ul>
+<li id="GUID-9AEBA9C2-BF3C-541D-BFD0-4E610DBE80A3"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-7344DA81-987E-351E-9F91-7AA78C3FA033"><apiname>HALData::EPowerGood</apiname></xref>  </p> </li>
+<li id="GUID-5F3A4C2B-941F-5D57-8B43-EC451D840854"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-C7DDA0E9-5882-3988-8747-AA790AC31E05"><apiname>HALData::EPowerBatteryStatus</apiname></xref>  </p> </li>
+<li id="GUID-0D50D9CD-8AE9-5831-8E80-EE8B5230907D"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-6A6650DE-67C1-3E1E-AFC7-CA7ADCED621D"><apiname>HALData::EAccessoryPower</apiname></xref>  </p> </li>
+<li id="GUID-06A8A38B-3F3F-5B41-B79F-57CD49ABC382"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-5800E3AA-61A7-33B1-BBAE-6E4D826373AB"><apiname>HALData::EPowerBackup</apiname></xref>  </p> </li>
+<li id="GUID-77277657-3765-531B-8E19-8D2E11BAA558"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-C6E1EDDD-06C4-3A4D-9C93-67316D6C4823"><apiname>HALData::EPowerBackupStatus</apiname></xref>  </p> </li>
+<li id="GUID-9179DF67-5AFC-5C98-ACFD-391035A32756"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-435EB49C-8821-37DD-8D13-46158B6261BD"><apiname>HALData::EPowerExternal</apiname></xref>  </p> </li>
+<li id="GUID-E10E8676-5DB4-5045-9BDC-DF280695A4C6"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-079CD0A7-6C36-3A05-8EFA-51FDD649C657"><apiname>HALData::EPenDisplayOn</apiname></xref>  </p> </li>
+<li id="GUID-81581675-F4E7-517C-BF25-22CDCC87E787"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-A0F07710-1C15-3B7F-8D45-02D9E40A2514"><apiname>HALData::ECaseSwitchDisplayOn</apiname></xref>  </p> </li>
+<li id="GUID-D9DC5061-371E-5B89-8CA5-93FA99B7827A"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-148D0CDF-6CEC-33BD-876A-CA93D0C702B3"><apiname>HALData::ECaseSwitchDisplayOff</apiname></xref>  </p> </li>
+</ul>
+<p>A typical application will have a user side monitor that periodically calls <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-573C49D6-7763-37AE-B2B2-4C8FB1327E21"><apiname>HAL::Get()</apiname></xref>,
+passing <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-C7DDA0E9-5882-3988-8747-AA790AC31E05"><apiname>HALData::EPowerBatteryStatus</apiname></xref> to get the charge
+level of the battery. </p>
+<p>Typically, the handler is implemented as part of a <xref href="GUID-3E6D44FE-787B-3D9E-899C-8BAA7DDCBC5C.dita"><apiname>DPowerHal</apiname></xref> derived
+object, which is created by the entry point of the base port power kernel
+extension. The object is, therefore, part of the power controller kernel extension. </p>
+<section id="GUID-292B08F7-9BE6-4D85-A70E-A063D300195F"><title>Implementation
+notes</title> <ul>
+<li id="GUID-A69AD521-6B9C-565F-944F-125774283041"><p>The <xref href="GUID-3E6D44FE-787B-3D9E-899C-8BAA7DDCBC5C.dita"><apiname>DPowerHal</apiname></xref> derived
+object constructor must register with the power manager by calling <codeph>Register()</codeph>. </p> </li>
+<li id="GUID-5E2558D9-DB44-554A-8A18-33D161E568D2"><p>If there is some power-related
+data that can be accessed via the HAL component and that persists through
+power cycles (On/Off), it should be initialised here. Typically the <codeph>TOnOffInfoV1</codeph> data
+member of the Variant-specific <codeph>TActualMachineConfig</codeph> (usually
+found in <filepath>mconf.h</filepath> file under the platform directory) contains
+some of that persistent data. </p> </li>
+<li id="GUID-07E132AF-0F18-5578-A74C-C87618F98678"><p>The handler itself is
+the function <codeph>PowerHalFunction()</codeph>, and must be fully implemented
+in the base port. </p> </li>
+<li id="GUID-EEB6EB2D-8E99-5EFF-B2C6-4C73E6D39852"><p>The kernel hooks up
+the handler to service the HAL functions at boot-time. </p> </li>
+<li id="GUID-6C2DE544-5447-5786-8F0C-A065E0C1A59A"><p>The power Hal functions
+that the Handler can handle are enumerated by <xref href="GUID-105D7978-FFAD-3868-BE6A-8A9746A82D70.dita"><apiname>TPowerHalFunction</apiname></xref>.
+Not all of these functions need to be handled. If not handled, the kernel
+returns <codeph>KErrNotSupported</codeph> when the HAL function is called
+with the relevant parameter. It is left to the base port to decide which functions
+are relevant. </p> </li>
+</ul> </section>
+</conbody><related-links>
+<link href="GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8.dita#GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8/GUID-4DA41221-40B9-5BC7-B2C6-7C6EB4522508">
+<linktext>User-Side Hardware Abstraction</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-552530EB-1287-542D-AED3-125387B485C1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-552530EB-1287-542D-AED3-125387B485C1" xml:lang="en"><title>Architecture</title><shortdesc>Describes the architecture of the Digitizer Driver. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The architecture has two layers: </p>
+<table id="GUID-66F9A575-14A6-5F98-9166-CF5F5B03BF67">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>A platform-independent layer that: </p> </entry>
+<entry><ul>
+<li id="GUID-1F3AAAB4-181C-54EF-83AA-CEBE00590934"><p>processes digitiser
+samples </p> </li>
+<li id="GUID-F8D8BC65-0D80-5D5A-9F87-B8C34FEE70A2"><p>issues pen movement
+events to the kernel </p> </li>
+<li id="GUID-75A10183-BFCE-5D3D-B167-6D884EED335F"><p>maintains a buffer of
+digitiser readings </p> </li>
+</ul> <p>This layer implements behaviour that can be expected to be the same
+across all platforms. </p> <p> <i>Symbian provides this.</i>  </p> </entry>
+</row>
+<row>
+<entry><p>A platform specific layer that is responsible for: </p> </entry>
+<entry><ul>
+<li id="GUID-5D268750-7FF8-527F-B670-02A2605F610E"><p>the conversion between
+screen and digitiser coordinates </p> </li>
+<li id="GUID-65D85059-ED68-5AEF-BA1C-8255D5AAADC1"><p>the implementation of
+low level calibration </p> </li>
+<li id="GUID-98D55CC6-946B-5396-A518-65AF137684D3"><p>the gathering of raw
+digitiser data samples </p> </li>
+<li id="GUID-6E3D68AF-4EF8-50CA-90EA-814820C15ACA"><p>power management. </p> </li>
+</ul> <p>This layer implements behaviour that can vary between platforms and
+therefore needs to be implemented by the port. </p> <p>The bulk of the effort
+here is the definition and implementation of a class derived from the Symbian
+defined <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita"><apiname>DDigitiser</apiname></xref> class; the derived class implements
+the pure virtual functions defined by <codeph>DDigitiser</codeph>. </p> <p> <i>You
+provide this.</i>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table>
+<p>The template port provides a framework for implementing the platform specific
+part of the digitiser. The diagram below shows the overall relationship: </p>
+<fig id="GUID-25F301AD-9B05-51BF-A96B-C99AB5B2D2E4">
+<image href="GUID-904C9C5A-5FDB-5978-88CF-E30D6C0DBB61_d0e8869_href.png" placement="inline"/>
+</fig>
+<p>The standard Symbian platform ports all follow the same general pattern,
+including the H2. However, the H2 board implementation has two levels in its
+platform specific layer (an ASSP and a variant layer) and uses different source
+file names (e.g. <filepath>digitizer.cpp</filepath>), but, nevertheless, the
+same general pattern applies. </p>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-5686E787-537F-5B32-B719-34EF5B7F0D37-master.png has changed
Binary file Adaptation/GUID-5686E787-537F-5B32-B719-34EF5B7F0D37_d0e18814_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-57989FF8-5E8F-4C8A-9D38-169AFCA4C078.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,116 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-57989FF8-5E8F-4C8A-9D38-169AFCA4C078" xml:lang="en"><title>Baseport Template Implementation Guide</title><shortdesc>Describes the use of the Baseport Template in porting Symbian
+platform.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-36D13F9C-CD44-4153-A195-CCFB4EBFAD90-GENID-1-2-1-10-1-5-1-4-1-1-6-1-3-1-3-1"><title>General
+procedure</title>             <p>The Baseport Template is a minimal
+baseport for the Symbian platform that implements the basic functionality
+of a baseport without supplying any hardware specific code. It provides
+a skeleton of a working baseport, which base porters can modify in
+accordance with the instructions in the comments. Porting involves
+abstraction from hardware and must be performed in a set sequence
+(for example, the abstraction in the drivers depends on previous abstraction
+in HAL which depends on previous abstraction in ASIC and so on). Many
+of the header files are not in the Baseport Template files but are
+held elsewhere in the code base, for example,<filepath> ..\e32\include\kernel\arm\</filepath></p>         </section>
+<section id="GUID-36D13F9C-CD44-4153-A195-CCFB4EBFAD90-GENID-1-2-1-10-1-5-1-4-1-1-6-1-3-1-3-2"><title>File
+structure</title>             <p>The files which make up the Baseport
+Template are divided between two directories, ASSP and Variant containing
+two classes of the same names. This division represents a fundamental
+feature of the kernel architecture which you are recommended to retain
+in your implementation of the port. The baseport involves implementing
+functions to run on the target hardware, but it is useful to distinguish
+between functionality specific to the CPU (ARM etc) and functionality
+specific to peripherals with their own processors. ASSP functions
+must be implemented in accordance with the device hardware, while
+Variant functions correspond to off chip peripherals. The distinction
+is not absolutely mandatory (it is possible just to provide a Variant
+layer) but strongly recommended and assumed in many other areas of
+the porting process.</p><p>A port with an ASSP/Variant architecture
+is implemented with two C++ classes and two <filepath>.mpp</filepath> files.</p><ul>
+<li><p><filepath>...\template_assp\assp.cpp</filepath></p></li>
+<li><p><filepath>...\template_assp\katemplate.mmp</filepath></p></li>
+<li><p><filepath>...\template_variant\specific\variant.cpp</filepath></p></li>
+<li><p><filepath>...\template_variant\vtemplate.mmp</filepath></p></li>
+</ul><p>For more information see the Base Porting Guide.</p>     
+   </section>
+<section id="GUID-36D13F9C-CD44-4153-A195-CCFB4EBFAD90-GENID-1-2-1-10-1-5-1-4-1-1-6-1-3-1-3-3"><title>Bootstrap</title>             <p>The bootstrap is the code that runs after a hardware
+reset, to initialize the basic system services that enable the kernel
+to run. Parts of it must be written in assembler (either GNU or ARM)
+and are specific to the device hardware, while others are written
+in C++ and are automatically translated into assembler. Bootstrap
+is implemented as the <filepath>bootstrap/template.s</filepath> file.</p><p>This is supplied as an example only: implementation is entirely
+dependent on the target hardware.</p><p>For more information see the <xref href="GUID-0C84FD76-87B2-4AD1-B23A-2C5C8668BC4C.dita">Base Porting Guide</xref>.</p>         </section>
+<section id="GUID-36D13F9C-CD44-4153-A195-CCFB4EBFAD90-GENID-1-2-1-10-1-5-1-4-1-1-6-1-3-1-3-4"><title>Interrupt
+dispatcher</title>             <p>The Symbian platform is a real time
+interrupt driven operating system. To port it you need to determine
+the number and function of the interrupts in your port and implement
+the interrupt dispatcher to handle them. Interrupt service routines
+(ISRs) are held in an array of class <xref href="GUID-2C9B6510-D045-3FA1-AD65-B544E30D34C7.dita"><apiname>SInterruptHandler</apiname></xref> as a member of the <xref href="GUID-5E593C59-BA22-3B70-AAFB-BFE19E22538A.dita"><apiname>TemplateInterrupt</apiname></xref> class defined
+in <filepath>template_assp_priv.h</filepath>. ISRs are associated
+with individual interrupt sources defined in the ASSP layer by functions
+of the Interrupt class such as <xref href="GUID-8DAB6465-BCDE-35FE-8C31-861C13A34526.dita"><apiname>Bind()</apiname></xref> and <xref href="GUID-EAED145E-E4BE-3A0F-BC25-78E1FC13FB55.dita"><apiname>Unbind()</apiname></xref>.</p><ul>
+<li><p><filepath>...\template_assp\template_assp_priv.h</filepath></p></li>
+<li><p><filepath>...\template_assp\interrupts.cpp</filepath></p></li>
+</ul> <p>For more information see the <xref href="GUID-0C84FD76-87B2-4AD1-B23A-2C5C8668BC4C.dita">Base Porting Guide</xref>.</p>        </section>
+<section id="GUID-36D13F9C-CD44-4153-A195-CCFB4EBFAD90-GENID-1-2-1-10-1-5-1-4-1-1-6-1-3-1-3-5">         
+   <title>ASIC</title>             <p>The <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita"><apiname>Asic</apiname></xref> class
+contains initialization functions which must be called early in the
+boot process. <xref href="GUID-E73C682E-5824-3C9C-9F98-D99D57473584.dita"><apiname>ASSP</apiname></xref> is derived from <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita"><apiname>Asic</apiname></xref> and <xref href="GUID-E769B916-E743-3955-B897-07B6DA1C7D1E.dita"><apiname>Variant</apiname></xref> from the ASSP derivation.</p><ul>
+<li><p><filepath>...\template_assp\template_assp.h</filepath></p></li>
+<li><p><filepath>...\template_assp\template_assp.cpp</filepath></p></li>
+</ul> <p>For more information see the <xref href="GUID-0C84FD76-87B2-4AD1-B23A-2C5C8668BC4C.dita">Base Porting Guide</xref>.</p>        </section>
+<section id="GUID-36D13F9C-CD44-4153-A195-CCFB4EBFAD90-GENID-1-2-1-10-1-5-1-4-1-1-6-1-3-1-3-6">         
+   <title>HAL</title>             <p>The <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita"><apiname>HAL</apiname></xref> class
+abstracts items of hardware specific functionality. You must implement
+functions to get and set hardware specific attributes in accordance
+with the hardware used on the target device. The attributes are defined
+in <filepath>config.hcf</filepath> and <filepath>values.hda</filepath> configuration files.</p><ul>
+<li><p><filepath>...\template_variant\hal\config.hcf</filepath></p></li>
+<li><p><filepath>...\template_variant\hal\values.hda</filepath></p></li>
+</ul><p>The attributes are modified by get and set functions called
+HAL handlers defined in the relevant hardware drivers.</p><p>For more
+information see the <xref href="GUID-0C84FD76-87B2-4AD1-B23A-2C5C8668BC4C.dita">Base Porting Guide</xref>.</p>         </section>
+<section id="GUID-36D13F9C-CD44-4153-A195-CCFB4EBFAD90-GENID-1-2-1-10-1-5-1-4-1-1-6-1-3-1-3-7">         
+   <title>Drivers</title>             <p>The rest of the work involves
+porting drivers. A typical implementation would include these drivers:</p><ul>
+<li><p>DMA Framework <ul>
+<li><p><filepath>...\template_assp\dmapsl.cpp</filepath></p></li>
+<li><p><filepath>...\template_assp\dma.mpp</filepath></p></li>
+</ul></p></li>
+<li>Digitizer Driver <p><ul>
+<li><p><filepath>...\template_variant\specific\xyin.cpp</filepath></p></li>
+<li><p><filepath>...\template_variant\exxytemplate.mmp</filepath></p></li>
+</ul></p></li>
+<li>Keyboard Driver <p><ul>
+<li><p><filepath>...\template_variant\exkey_inttemplate.mmp</filepath></p></li>
+<li><p><filepath>...\template_variant\specific\keyboard_interrupt.cpp</filepath></p></li>
+</ul></p></li>
+<li>LCD Extension <p><ul>
+<li><p><filepath>...\template_variant\specific\lcd.cpp</filepath></p></li>
+<li><p><filepath>...\template_variant\exlcdtemplate.mmp</filepath></p></li>
+</ul></p></li>
+<li>Serial Port Driver <p><ul>
+<li><p><filepath>...\template_variant\specific\uart.cpp</filepath></p></li>
+<li><p><filepath>...\template_variant\datxtemplate.mmp</filepath></p></li>
+</ul></p></li>
+<li>Sound Driver <p><ul>
+<li><p><filepath>...\template\template_variant\specific\soundsc_rx.cpp</filepath> </p></li>
+<li><p><filepath>...\template\template_variant\specific\soundsc_tx.cpp</filepath> </p></li>
+<li><p><filepath>...\template\template_variant\soundsctemplate.mmp</filepath> </p></li>
+</ul></p></li>
+<li>USB Client Driver Technology<p><ul>
+<li><p><filepath>...\template_assp\pa_usbc.cpp</filepath></p></li>
+<li><p><filepath>...\template_assp\usbcc.mmp</filepath></p></li>
+</ul></p></li>
+</ul>         </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-583F70B4-5C8C-54FA-A869-E6F073DE1FD6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-583F70B4-5C8C-54FA-A869-E6F073DE1FD6" xml:lang="en"><title>Interrupt::Enable()
+and Interrupt::Disable()</title><shortdesc>The functions <codeph>Interrupt::Enable()</codeph> and <codeph>Interrupt::Disable()</codeph> are
+used by device drivers to enable and disable the interrupt source in the interrupt
+controller hardware. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p/>
+<p>An <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-8E58F4C9-0290-55E0-A4FD-B6C2361BE205">Interrupt
+ID</xref> is passed to the functions to identify the interrupt source. All
+requests for enabling and disabling interrupts should go to these functions
+in the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita"><apiname>Interrupt</apiname></xref> class so that device drivers should never
+need to know where the interrupt is actually implemented. The general rule
+is that the interrupt ID is tagged in some way to allow these functions to
+decide whether the interrupt refers to the ASSP layer or to the Variant layer.
+These functions are implemented in the ASSP layer. </p>
+<p>The implementation of these functions is completely dependent on the interrupt
+hardware. In the template port, <codeph>Interrupt::Enable()</codeph> is implemented
+in <filepath>...\template_assp\interrupts.cpp</filepath>. The relevant part
+is: </p>
+<codeblock id="GUID-8A99386B-5681-5ABA-B4BB-735DF2C2695A" xml:space="preserve">EXPORT_C TInt Interrupt::Enable(TInt anId)
+    {
+     __KTRACE_OPT(KEXTENSION,Kern::Printf("Interrupt::Enable id=%d",anId));
+     TInt r=KErrNone;
+     // if ID indicates a chained interrupt, call variant...
+     if (anId&lt;0 &amp;&amp; ((((TUint)anId)&gt;&gt;16)&amp;0x7fff)&lt;(TUint)KNumTemplateInts)
+         r=TemplateAssp::Variant-&gt;InterruptEnable(anId);
+     else if ((TUint)anId&gt;=(TUint)KNumTemplateInts)
+         r=KErrArgument;
+     else if (TemplateInterrupt::Handlers[anId].iIsr==TemplateInterrupt::Spurious)
+         r=KErrNotReady;
+     else
+         {
+         //
+         // TO DO: (mandatory)
+         //
+         // Enable the corresponding Hardware Interrupt source
+         //
+         }
+     return r;
+    }
+          </codeblock>
+<p>Interrupts that 'belong' to the Variant Layer are passed to that layer
+through the call to: </p>
+<codeblock id="GUID-05C36364-3912-5EEE-B851-82803A731950" xml:space="preserve">r =TemplateAssp::Variant-&gt;InterruptEnable(anId);</codeblock>
+<p> <codeph>Interrupt::Disable()</codeph> follows the same general pattern. </p>
+<p>The Variant layer equivalent of this function, <codeph>Template::InterruptEnable()</codeph>,
+in <filepath>...\template_variant\specific\variant.cpp</filepath>, also follows
+the same pattern. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-58AA7257-0951-42AB-9B6E-AAF63343FEFA-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-5-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,88 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-58AA7257-0951-42AB-9B6E-AAF63343FEFA-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-5-1" xml:lang="en"><title>DMA Channel Operations</title><shortdesc>Describes how a device driver should open and close a DMA
+channel.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-C4241738-D4C3-4171-87B2-5EDFFACE4002-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-5-1-3-1"><title>Open</title><p>To use a DMA channel it has to be opened. <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-514BA285-3563-3C24-A067-F360098A6ADF"><apiname>TDmaChannel::Open()</apiname></xref> must be called to open the channel, and the required information
+provided in a <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-6B973278-8BE7-3CE5-97D8-60E8D3F4D473"><apiname>TDmaChannel::SCreateInfo</apiname></xref> structure.
+The actual DMA channel selection is done by the hardware specific
+layer. </p> <codeblock id="GUID-A1CA8DBA-1378-502B-8CC8-6D83F13DD151-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-5-1-3-1-3" xml:space="preserve">/**
+ Initializes the DMA for transmit. This function does all the 
+ required generic initialization to use the DMA framework. This 
+ function does not have any variant specific initialization. 
+    
+ @return     KErrNone on success, else standard error code on failure
+ */
+TInt DExDriverUartTxDma::Init()
+    {
+    ...
+
+    // Initialize the channel information to select and configure the DMA     
+    // channel
+    TDmaChannel::SCreateInfo info;
+    info.iCookie = (TUint);
+    info.iDesCount = 1; // For single buffered transfers
+    info.iDfcPriority = 4; // Set the priority of this DFC for DMA
+    info.iDfcQ = iUartComm-&gt;DfcQ(); // DFCQ onto which this request
+ // has to be queued    
+
+    // DMA channel has to be opened before doing any operations on 
+    // the channel. TDmaChannel::Open() opens the DMA channel as 
+    // set by info passed and selected by the hardware-specific layer. 
+   
+    r = TDmaChannel::Open(info, iTxDmaChannel);
+    if (r!=KErrNone)
+        {
+        return r;
+        }
+    ...
+    }</codeblock> </section>
+<section id="GUID-5E09A55C-A2B9-4E02-9BCF-F23558357B70-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-5-1-3-2"><title>Close</title> <p>A DMA channel has to be closed after completing all the DMA operations.
+This releases the DMA channel for other resources and peripherals.
+To close a previously opened channel, the channel should be idle,
+with no pending requests. So, before closing, call <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-0A98D2DC-2A61-3FBD-AB7A-623FE926A183"><apiname>TDmaChannel::CancelAll()</apiname></xref>, which cancels the current request and any pending DMA requests.
+This should then be followed by closing the channel using <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-8204AFBD-2A60-372E-B626-35BD19851FF7"><apiname>TDmaChannel::Close()</apiname></xref>. </p> <codeblock id="GUID-4BA5CDD2-6BD3-5179-89B8-7337ED5809AA-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-5-1-3-2-3" xml:space="preserve">/**
+ Destructor. Deinitializes the member variables, cancels any 
+ requests, closes the channel, deletes the DMA requests, frees the 
+ hardware chunks allocated.
+ */    
+
+DExDriverUartTxDma::~DExDriverUarttxDma()
+    {
+    ...
+    // if DMA channel is existing, cancel all requests on it.    
+    //
+    if (iTxDmaChannel)
+        {
+        // TDmaChannel::CancelAll() cancels the current request and 
+        // any pending requests on the DMA channel
+        //     
+        iTxDmaChannel-&gt;CancelAll();
+        }
+    ...
+
+    if(iTxDmaChannel)
+        {
+        // Close the DMA channel. TDmaChannel::Close() closes a 
+        // previously opened channel. All the requests on this 
+        // channel should have been cancelled prior to this, i.e. 
+        // TDmaChannel::CancelAll() should have been called before 
+        // this call.
+        //
+        iTxDmaChannel-&gt;Close();
+        }
+    ...
+    }</codeblock> <p>To stop DMA without closing the channel, simply
+cancel the request. </p></section>
+</conbody><related-links>
+<link href="GUID-C649DB97-F138-4C90-B177-16590F2E3F19-GENID-1-2-1-9-1-6-1-8-1-7-1-3-1.dita"><linktext>DMA
+Channels</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-58AA7257-0951-42AB-9B6E-AAF63343FEFA-GENID-1-2-1-9-1-6-1-8-1-7-1-4-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,88 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-58AA7257-0951-42AB-9B6E-AAF63343FEFA-GENID-1-2-1-9-1-6-1-8-1-7-1-4-1" xml:lang="en"><title>DMA Channel Operations</title><shortdesc>Describes how a device driver should open and close a DMA
+channel.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-C4241738-D4C3-4171-87B2-5EDFFACE4002-GENID-1-2-1-9-1-6-1-8-1-7-1-4-1-3-1"><title>Open</title><p>To use a DMA channel it has to be opened. <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-514BA285-3563-3C24-A067-F360098A6ADF"><apiname>TDmaChannel::Open()</apiname></xref> must be called to open the channel, and the required information
+provided in a <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-6B973278-8BE7-3CE5-97D8-60E8D3F4D473"><apiname>TDmaChannel::SCreateInfo</apiname></xref> structure.
+The actual DMA channel selection is done by the hardware specific
+layer. </p> <codeblock id="GUID-A1CA8DBA-1378-502B-8CC8-6D83F13DD151-GENID-1-2-1-9-1-6-1-8-1-7-1-4-1-3-1-3" xml:space="preserve">/**
+ Initializes the DMA for transmit. This function does all the 
+ required generic initialization to use the DMA framework. This 
+ function does not have any variant specific initialization. 
+    
+ @return     KErrNone on success, else standard error code on failure
+ */
+TInt DExDriverUartTxDma::Init()
+    {
+    ...
+
+    // Initialize the channel information to select and configure the DMA     
+    // channel
+    TDmaChannel::SCreateInfo info;
+    info.iCookie = (TUint);
+    info.iDesCount = 1; // For single buffered transfers
+    info.iDfcPriority = 4; // Set the priority of this DFC for DMA
+    info.iDfcQ = iUartComm-&gt;DfcQ(); // DFCQ onto which this request
+ // has to be queued    
+
+    // DMA channel has to be opened before doing any operations on 
+    // the channel. TDmaChannel::Open() opens the DMA channel as 
+    // set by info passed and selected by the hardware-specific layer. 
+   
+    r = TDmaChannel::Open(info, iTxDmaChannel);
+    if (r!=KErrNone)
+        {
+        return r;
+        }
+    ...
+    }</codeblock> </section>
+<section id="GUID-5E09A55C-A2B9-4E02-9BCF-F23558357B70-GENID-1-2-1-9-1-6-1-8-1-7-1-4-1-3-2"><title>Close</title> <p>A DMA channel has to be closed after completing all the DMA operations.
+This releases the DMA channel for other resources and peripherals.
+To close a previously opened channel, the channel should be idle,
+with no pending requests. So, before closing, call <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-0A98D2DC-2A61-3FBD-AB7A-623FE926A183"><apiname>TDmaChannel::CancelAll()</apiname></xref>, which cancels the current request and any pending DMA requests.
+This should then be followed by closing the channel using <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-8204AFBD-2A60-372E-B626-35BD19851FF7"><apiname>TDmaChannel::Close()</apiname></xref>. </p> <codeblock id="GUID-4BA5CDD2-6BD3-5179-89B8-7337ED5809AA-GENID-1-2-1-9-1-6-1-8-1-7-1-4-1-3-2-3" xml:space="preserve">/**
+ Destructor. Deinitializes the member variables, cancels any 
+ requests, closes the channel, deletes the DMA requests, frees the 
+ hardware chunks allocated.
+ */    
+
+DExDriverUartTxDma::~DExDriverUarttxDma()
+    {
+    ...
+    // if DMA channel is existing, cancel all requests on it.    
+    //
+    if (iTxDmaChannel)
+        {
+        // TDmaChannel::CancelAll() cancels the current request and 
+        // any pending requests on the DMA channel
+        //     
+        iTxDmaChannel-&gt;CancelAll();
+        }
+    ...
+
+    if(iTxDmaChannel)
+        {
+        // Close the DMA channel. TDmaChannel::Close() closes a 
+        // previously opened channel. All the requests on this 
+        // channel should have been cancelled prior to this, i.e. 
+        // TDmaChannel::CancelAll() should have been called before 
+        // this call.
+        //
+        iTxDmaChannel-&gt;Close();
+        }
+    ...
+    }</codeblock> <p>To stop DMA without closing the channel, simply
+cancel the request. </p></section>
+</conbody><related-links>
+<link href="GUID-C649DB97-F138-4C90-B177-16590F2E3F19-GENID-1-2-1-9-1-6-1-8-1-7-1-3-1.dita"><linktext>DMA
+Channels</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-592B6D20-4ABA-5C79-9734-D18E2CE4A86C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,166 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-592B6D20-4ABA-5C79-9734-D18E2CE4A86C" xml:lang="en"><title>Writable
+Data Paging Overview</title><shortdesc>Overview of data paging, the next phase in Symbian's implementation
+of demand paging. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-B1D8D3AD-4438-4C51-B900-1DD2B55202BC"><title>Purpose</title> <p>Writable
+data paging allows the demand paging of any user-side data (for example thread
+stacks and heaps). Writable data paging makes use of a fixed size backing
+store to page out data. The backing store may use a NAND flash partition or
+an embedded MMC (eMMC). </p> <p>The aim of data paging is to enable more memory-hungry
+use cases without increasing the amount of physical RAM present in the device. </p> <p>For
+example, data paging enables: </p> <ul>
+<li id="GUID-F3B36258-F661-5562-A641-1875D33600B7"><p>running applications
+that are not designed with the memory constraints of embedded devices in mind,
+for example applications ported from other environments with writable data
+paging (such as a PC). </p> </li>
+<li id="GUID-7BB35E5C-6E38-50E6-B27E-094948F0F6A8"><p>running multiple applications
+at the same time where previously there would not have been enough memory. </p> </li>
+</ul> <p> <note> Data paging offers no performance increase, unlike code paging
+which can speed up application loading by reading only the necessary pages
+into RAM. </note></p> <p> </p> <p>However, writable data paging does have
+the following limitations: </p> <ul>
+<li id="GUID-EB2514D7-CE57-52F2-91D5-E790A41D12B2"><p>It is only possible
+to page the following types of memory: </p> <ul>
+<li id="GUID-9C9002DF-BF9B-5656-A57F-84C442E855B7"><p>user heaps, </p> </li>
+<li id="GUID-8F6AC93B-F1BE-5CA6-899E-8433E2055013"><p>user thread stacks, </p> </li>
+<li id="GUID-0EC7E799-24CC-590E-A67D-DAA014825A1E"><p>private chunks, </p> </li>
+<li id="GUID-9789A61F-CB01-5AD8-8886-41CA74EA564F"><p>global chunks, </p> </li>
+<li id="GUID-1C8479BE-B4E6-5E6D-83C0-D23E8DC6F9CF"><p>static data. </p> </li>
+</ul> </li>
+<li id="GUID-E11A66FB-C2DF-5DE7-B074-0CBDFC7EBE6D"><p>A single memory object
+(e.g. a heap, stack, DLL or chunk) is the smallest granularity at which paging
+can be configured </p> </li>
+<li id="GUID-06F9012E-85CE-587C-B0E9-6BF7EE37A39F"><p>No attempt will be made
+to page kernel-side data </p> </li>
+<li id="GUID-88EE2287-EF50-5B7C-B63E-C2D172A1EA80"><p>No attempt will be made
+to implement memory mapped files (e.g. posix's mmap) </p> </li>
+<li id="GUID-C79316F5-BFF4-569E-8D44-AF5BDCBD0811"><p>No attempt will be made
+to implement any kind of paging on the emulator. </p> </li>
+</ul> </section>
+<section id="GUID-9E27B27E-898B-43DA-8614-4AAEEE0A294E"><title>Required background</title> <p>This
+document assumes that the reader is familiar with the concept of <xref href="GUID-F123D574-44DE-528A-806C-DB64229BCEA2.dita">Demand
+Paging</xref>, and the existing implementation of ROM and code paging in Symbian
+platform. </p> </section>
+<section id="GUID-1028A9E3-C9D7-4A4B-9DD4-B719475D09E5"><title>Key concepts
+and terms</title> <dl>
+<dlentry>
+<dt>Page</dt>
+<dd><p>Memory is managed in fixed size units called pages. The size of a page
+is usually determined by the hardware, and for ARM architectures this is 4K. </p> </dd>
+</dlentry>
+<dlentry>
+<dt>Paged in or Paged out</dt>
+<dd><p>If a given page of memory is present in RAM it is said to be <i>paged
+in</i> (or just 'present'), as opposed to <i>paged out</i>. </p> </dd>
+</dlentry>
+<dlentry>
+<dt>Paging in</dt>
+<dd><p>The process of moving a page of memory from being paged out to being
+paged in. </p> </dd>
+</dlentry>
+<dlentry>
+<dt>Paging out</dt>
+<dd><p>The process of moving a page of memory from being paged in to being
+paged out. </p> </dd>
+</dlentry>
+<dlentry>
+<dt>backing store</dt>
+<dd><p>The external media used to hold <i>paged out</i> pages is referred
+to as the <i>swap area</i>. This area may be much larger than physical RAM,
+although a factor of around twice as large is considered normal in existing
+systems. </p> </dd>
+</dlentry>
+<dlentry>
+<dt>Working set</dt>
+<dd><p>The term <i>working set</i> is defined as the memory accessed during
+a given time period. </p> </dd>
+</dlentry>
+<dlentry>
+<dt>Pinning</dt>
+<dd><p> <i>Pinning</i> pages refers to paging in demand-paged memory and forcing
+it to remain in RAM until it is <i>unpinned</i> at a later time. </p> </dd>
+</dlentry>
+</dl> </section>
+<section id="GUID-AED67EBB-6176-4357-BC22-4A0B4E518265"><title>Classes</title> <p>The
+following classes are affected by the use of writable data demand paging: </p> <p>The
+following classes are involved in the use of threads and processes: </p> <table id="GUID-24779260-DE34-5184-9A58-560F06F0DE9D">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>Class </p> </entry>
+<entry><p>Description </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B0E661BC-4058-3256-B9C3-5A4FD52F6DE5.dita"><apiname>RThread</apiname></xref>  </p> </entry>
+<entry><p>This class is used to handle threads. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-9DD1EA2B-DC59-315C-8E9C-CE6D9461B695.dita"><apiname>RProcess</apiname></xref>  </p> </entry>
+<entry><p>This class is used to handle processes. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-1D0D14AD-43CF-3B52-AD8D-641F75B8098C.dita"><apiname>TThreadCreateInfo</apiname></xref>  </p> </entry>
+<entry><p>Used to specify the attributes of a new thread. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>These classes are used in handling memory: </p> <table id="GUID-ACCA6C7E-92B5-51BE-B86E-D94E9FB0FF9F">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>Class </p> </entry>
+<entry><p>Description </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita"><apiname>RChunk</apiname></xref>  </p> </entry>
+<entry><p>Handle a chunk. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita"><apiname>TChunkCreateInfo</apiname></xref>  </p> </entry>
+<entry><p>A structure that specifies the type and properties of the chunk
+that is to be created. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-3DCB92FB-9C74-3B73-B229-BF7944087EE9.dita"><apiname>TChunkHeapCreateInfo</apiname></xref>  </p> </entry>
+<entry><p>A structure that specifies the type and properties of a chunk with
+a heap within it. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C5D0C7E7-061F-3BA5-AE24-B83237684B01.dita"><apiname>UserHeap</apiname></xref>  </p> </entry>
+<entry><p>A set of functions that are used to create heaps. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>The following classes are used in client/server communication: </p> <table id="GUID-E823BA5C-620C-5B58-9945-8135EF7D39D1">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>Class </p> </entry>
+<entry><p>Description </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-8E316AC4-4676-301A-9A23-659E83AA1D1C.dita"><apiname>CServer2</apiname></xref>  </p> </entry>
+<entry><p>The abstract base class for servers. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-4AD02F14-1142-372F-9D11-224595932034.dita"><apiname>TIpcArgs</apiname></xref>  </p> </entry>
+<entry><p>A client/server class that clients use to package arguments that
+are to be sent to a sever. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+</conbody><related-links>
+<link href="GUID-9D66A168-AF11-51D9-903C-4A6C6D31DA3D.dita"><linktext>Flexible
+Memory Model Overview</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-59322A4F-B9CB-5997-B843-C4A80F8D42F1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-59322A4F-B9CB-5997-B843-C4A80F8D42F1" xml:lang="en"><title>Adaptation</title><shortdesc>Adaptation is the software side of adding new hardware
+to a device, including drivers and interfaces. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This content is provided under our joint company non-disclosure
+agreement. All content included in the documentation set is confidential
+and can only be used for the limited purpose of viewing it as a potential
+documentation solution. It cannot be redistributed or reused for any
+purpose. </p>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-59FF3BFE-21E2-554D-99EC-1A1D34AAEB7C-master.png has changed
Binary file Adaptation/GUID-59FF3BFE-21E2-554D-99EC-1A1D34AAEB7C_d0e35295_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-5B24741C-7CE0-58E8-98C9-1D1CACCD476F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,106 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-5B24741C-7CE0-58E8-98C9-1D1CACCD476F" xml:lang="en"><title>Fair Scheduling and File Caching Background</title><shortdesc>This document describes the fair scheduling and file caching
+features of the File Server.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-CBF527A2-EF30-5D4D-9BF4-631748315BE9"><title>Fair
+scheduling</title><p>The current design of the file server supports
+the processing of client requests concurrently, as long as those requests
+are made to different drives in the system. For example, a read operation
+may take place on the NAND user area partition while a write operation
+to the MMC card takes place concurrently. </p><p>However, requests
+to the same drive are serialized on a first-come first-served basis,
+which under some circumstances leads to bad user experience. For example:</p><ol>
+<li id="GUID-6550B420-5545-42C9-B304-9A8FA7D9DA01"><p>An incoming
+call arrives while a large video file is being written to the NAND
+user area by an application that writes the file in very large chunks.</p></li>
+<li id="GUID-7B08B626-E610-448B-917C-CB6CC127F2B9"><p>In order to
+display the caller’s details, the phone needs to read from the contacts
+database which is also stored on the NAND user area.</p></li>
+<li id="GUID-3A42569B-66CF-420F-A09D-F02A6BA4E4F9"><p>The write operation
+takes a very long time to complete, so the call is lost.</p></li>
+</ol><p> This is one of many scenarios where the single threaded nature
+of the file server may lead to unresponsive behavior. In order to
+improve the responsiveness of the system, the Symbian platform implements
+a fair scheduling policy that splits up large requests into more manageable
+chunks, thus providing clients of the file server with a more responsive
+system when the file server is under heavy load.</p><p>See <xref href="GUID-89BCF9A5-ABBD-5523-BA76-FDB00B806A30.dita#GUID-89BCF9A5-ABBD-5523-BA76-FDB00B806A30/GUID-450D57A3-928B-5389-B941-595DB20A7CEA">Enabling fair scheduling</xref>.</p></section>
+<section id="GUID-84C18F69-D193-4010-A9B2-B533FC6ACF51"><title>Read
+caching</title><p>Read caching aims to improve file server performance
+by addressing the following use case: <ul>
+<li><p>A client (or multiple clients) issues repeated requests to
+read data from the same locality within a file. Data that was previously
+read (and is still in the cache) can be returned to the client without
+continuously re-reading the data from the media. </p></li>
+</ul></p><note>Read caching is of little benefit for clients/files
+that are typically accessed sequentially in large blocks and never
+re-read.</note><p>There may be a small degradation in performance
+on some media due to the overhead of copying the data from the media
+into the file cache. To some extent this may be mitigated by the affects
+of read-ahead, but this clearly does not affect large (&gt;= 4K) reads
+and/or non-sequential reads. It should also be noted that any degradation
+may be more significant for media where the read is entirely synchronous,
+because there is no scope for a read-ahead to be running in the file
+server drive thread at the same time as reads are being satisfied
+in the context of the file server’s main thread.</p></section>
+<section id="GUID-7C6E6FDB-1419-4A8E-82F8-74EE6E62D468"><title>Demand
+paging effects</title><p>When ROM paging is enabled, the kernel maintains
+a <i>live list</i> of pages that are currently being used to store
+demand paged content. It is important to realize that this list also
+contains non-dirty pages belonging to the file cache. The implication
+of this is that reading some data into the file cache, or reading
+data already stored in the file cache, may result in code pages being
+evicted from the live list. </p><p>Having a large number of clients
+reading through or from the file cache can have an adverse effect
+on performance. For this reason it is probably not a good idea to
+set the <xref href="GUID-3B777E89-8E4C-3540-958F-C621741895C8.dita"><apiname>FileCacheSize</apiname></xref> property to too large a value
+– otherwise a single application reading a single large file through
+the cache is more likely to cause code page evictions if the amount
+of available RAM is restricted. See <xref href="GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3.dita">Migration Tutorial:
+Demand Paging and Media Drivers</xref>.</p></section>
+<section id="GUID-9BCF8F2A-F919-4AC7-BA05-02CC763429C1"><title>Read-ahead
+caching</title><p>Clients that read data sequentially (particularly
+using small block lengths) impact system performance due to the overhead
+in requesting data from the media. Read-ahead caching addresses this
+issue by ensuring that subsequent small read operations may be satisfied
+from the cache after issuing a large request to read ahead data from
+the media.</p><p>Read-ahead caching builds on read caching by detecting
+clients that are performing streaming operations and speculatively
+reading ahead on the assumption that once the data is in the cache
+it is likely to be accessed in the near future, thus improving performance.</p><p>The number of bytes requested by the read-ahead mechanism is initially
+equal to double the client’s last read length or a page, for example,
+4K (whichever is greater) and doubles each time the file server detects
+that the client is due to read outside of the extents of the read-ahead
+cache, up to a pre-defined maximum (128K). </p></section>
+<section id="GUID-976EE014-E3C3-42FD-8467-1D008DEC27FD"><title>Write
+caching</title><p>Write caching is implemented to perform a small
+level of write-back caching. This overcomes inefficiencies of clients
+that perform small write operations, thus taking advantage of media
+that is written on a block basis by consolidating multiple file updates
+into a single larger write as well as minimizing the overhead of metadata
+updates that the file system performs. </p><p>By implementing write
+back at the file level, rather than at the level of the block device,
+the possibility of file system corruption is removed as the robustness
+features provided by rugged FAT and LFFS are still applicable.</p><p>Furthermore, by disabling write back by default, allowing the
+licensee to specify the policy on a per drive basis, providing APIs
+on a per session basis and respecting Flush and Close operations,
+the risk of data corruption is minimized.</p><note>The possibility
+of data loss increases, but the LFFS file system already implements
+a simple write back cache of 4K in size so the impact of this should
+be minimal.</note><note>Write caching must be handled with care, as
+this could potentially result in loss of user data.</note><p>Database
+access needs special consideration as corruption may occur if the
+database is written to expect write operations to be committed to
+disk immediately or in a certain order (write caching may re-order
+write requests).</p><p>For these reasons, it is probably safer to
+leave write caching off by default and to consider enabling it on
+a per-application basis. See <xref href="GUID-89BCF9A5-ABBD-5523-BA76-FDB00B806A30.dita#GUID-89BCF9A5-ABBD-5523-BA76-FDB00B806A30/GUID-719C7E0C-790B-5C61-9EA8-E2687397340F">Enabling read and write caching</xref>.</p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-5BD2D468-838A-49BC-BA92-F41102D37CBC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE reference
+  PUBLIC "-//OASIS//DTD DITA Reference//EN" "reference.dtd">
+<reference id="GUID-5BD2D468-838A-49BC-BA92-F41102D37CBC" xml:lang="en"><title>Generic Implementation</title><shortdesc>Adaptation software providing a realization of the Client
+Interface.  The Generic Implementation is also known as the Platform
+Independent Layer (PIL).</shortdesc><prolog><metadata><keywords/></metadata></prolog><refbody>
+<section id="GUID-61F8F50C-8701-40B3-A8D2-1C5C796BE4CD"> 			 		</section>
+</refbody></reference>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-5C17A2E7-DE18-5CFB-A5D5-421D427CD5DD.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-5C17A2E7-DE18-5CFB-A5D5-421D427CD5DD" xml:lang="en"><title>Code Organisation</title><shortdesc>This topic describes the source code for interrupt driven
+keyboard drivers and related libraries.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This topic describes the source code for interrupt driven keyboard
+drivers and related libraries that Symbian platform provides. </p>
+<section id="GUID-50504915-1C7C-4DA7-859B-AD2D4D584EE5"><title>Keyboard
+driver</title> <p>In a reference board port, the <filepath>.mmp</filepath> file for the keyboard driver is <filepath>...\template_variant\exkey_inttemplate.mmp</filepath>. This is one of the PRJ_MMPFILES referenced in the template variant's <filepath>bld.inf</filepath> file in the <filepath>...\template_variant\...</filepath> directory, and means that the keyboard driver is built as part of
+the Variant. </p> <p>The source for the driver is contained entirely
+within <filepath>...\template_variant\specific\keyboard_interrupt.cpp</filepath>. </p> </section>
+<section id="GUID-29C36C83-B2A2-467A-84FA-A683C09C7E68"><title>Key
+translation DLL (ektran.dll)</title> <p>This DLL is part of Symbian
+platform generic code and is built as part of the Text Window Server
+component. </p> <p>The mmp file is located in Symbian platform generic
+code in <filepath>...\e32\wserv\ektran.mmp</filepath>, which defines
+the location of the source files, header files and other dependencies. </p> </section>
+<section id="GUID-DE8BF244-419B-443E-BD72-9F425DF9540E"><title>Keyboard
+mapping DLL (ekdata.dl)</title> <p>The DLL is platform specific. It
+is built as part of the Variant. </p> <p>The mmp file has a name with
+format <filepath>cakd</filepath> <i>xx</i> <filepath>.mmp</filepath>, where <i>xx</i> is the suffix that identifies the Variant in the
+Variant specific <filepath>.oby</filepath> file. In the template port,
+the mmp file has the name <filepath>cakdtemplate.mmp</filepath>. </p> <p>The source code for the tables is located in <filepath>keymap.cpp</filepath>, and is located in the Variant specific directory. The template
+port provides outline code. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-5C223AD5-4676-58B4-B3A5-066F6B69AA4D.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-5C223AD5-4676-58B4-B3A5-066F6B69AA4D" xml:lang="en"><title>Local Media
+Subsystem</title><shortdesc>Provides the logical device driver for the internal and removable
+storage media on a phone. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p id="GUID-868866C8-E90C-5291-8732-BB4E86D6B43E"> Local Media Subsystem uses
+physical device drivers, called media drivers, that manage the storage media
+hardware. A base port can implement new media drivers and implement ports
+of the media drivers that are supplied in Symbian platform. </p>
+</conbody><related-links>
+<link href="GUID-F3BD37EC-0CCB-5859-908F-215E22C9FC20.dita#GUID-F3BD37EC-0CCB-5859-908F-215E22C9FC20/GUID-143780ED-4A23-5E72-A923-F605172EC8B5">
+<linktext>File   Server</linktext></link>
+<link href="GUID-6CF2F4EF-383F-5850-A522-F425A83AA89E.dita#GUID-6CF2F4EF-383F-5850-A522-F425A83AA89E/GUID-20E09BC9-35CA-594A-BA91-D8D0C928FD98">
+<linktext>File Systems</linktext></link>
+<link href="GUID-9540A82E-F83D-55F5-B441-868CF77468E9.dita#GUID-9540A82E-F83D-55F5-B441-868CF77468E9/GUID-CFED15B1-E768-534E-9043-7AADE45EE9AF">
+<linktext>Media Drivers</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-5CCF303A-B7D5-570D-9BE8-29DFBE184995.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,79 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-5CCF303A-B7D5-570D-9BE8-29DFBE184995" xml:lang="en"><title>Porting Overview</title><shortdesc>This topic describes the typical steps that you will need
+to do to create a base port. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The easiest way to create a base port is to take the supplied template
+port and expand it to suit your own hardware configuration(s). The
+template port, is an outline, but working, framework that you can
+modify to suit your own hardware. </p>
+<p>The template port can be found under the <filepath>sf/os/kernelhwsrv/bsptemplate/</filepath> directory. For more information about the template port see <xref href="http://developer.symbian.org/wiki/index.php/Kernel_%26_Hardware_Services_Quick_Start" scope="external">Kernel &amp; Hardware Quick Start Guide</xref>.</p>
+<section id="GUID-F8897488-2A94-461D-AA11-7AC2BDA1D3C5"><title>Set
+up the environment</title> <p>The first thing to do is to set up your
+environment for building, downloading onto your hardware, and testing
+that the port works. </p> </section>
+<section id="GUID-124A8A3A-D114-4A68-9E9E-7062815A8717"><title>Build,
+download, and test the supplied template port</title> <p>As supplied,
+the template port is designed to boot on any hardware. It should boot
+successfully, but clearly, the system can do nothing more at this
+time. A successful boot shows that your build environment has been
+set up correctly. </p> </section>
+<section id="GUID-89940537-DA6E-4DE6-9133-74771EB15F6F"><title>Copy
+and rename the Template port</title> <p>When porting the base to a
+new platform, you will need to code and build the Variant. This provides
+those hardware dependent services required by the kernel. In nearly
+all ports, this is split into an ASSP DLL and a Variant DLL. We usually
+refer to the ASSP layer and the Variant layer. </p> <p>It is desirable
+that code that depends only on the properties of the ASSP be segregated
+from code that depends on details of the system outside the ASSP,
+so that multiple systems that use the same ASSP can share common code. </p> <p>For example, in the template reference port, the <filepath>..\template_assp\...</filepath> directory contains source code that contains the ASSP code, whereas
+the <filepath>...\template_variant\...</filepath> directory contains
+the code specific to the template board. </p> </section>
+<section id="GUID-B43B51BC-9ED4-4737-B738-182DBAF04C25"><title>Code
+the Bootstrap</title> <p>The bootstrap consists of several generic
+source and header files supplied as part of Symbian platform, and
+a set of platform specific files. You need to create these platform
+specific files as part of a base port. </p> <p>For details, see <xref href="GUID-53944506-5CA2-52BA-8D5A-9EE72092612B.dita">Bootstrap</xref>. </p> <p>The updated port can then be built, downloaded and tested. </p> </section>
+<section id="GUID-699C7EE9-A65A-5431-B23D-C5BD80494C09"><title>Implement
+the interrupt dispatcher</title> <p>An interrupt is a condition that
+causes the CPU to suspend normal execution, enter interrupt handling
+state and jump to a section of code called an interrupt handler. The
+ASSP/Variant part of the base port must implement an interrupt dispatcher
+class to manage interrupts. </p> <p>For details, see the <xref href="GUID-3C34724F-B476-5329-B0B1-6D5A34294979.dita">Interrupt Dispatcher
+Implementation Tutorial</xref>. </p> <p>The updated port can then
+be built, downloaded and tested. </p> </section>
+<section id="GUID-57F05EBC-310B-5288-B35E-CAA27E933590"><title>Implement
+the Asic class</title> <p>The Kernel requires that the ASSP/Variant
+part of the base port provides an implementation of the <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita"><apiname>Asic</apiname></xref> interface. This defines a small number of hardware-specific functions
+that are used by the Kernel. </p> <p>For details, see the <xref href="GUID-E0DCBDCF-C056-53E5-A375-778327F848E4.dita#GUID-E0DCBDCF-C056-53E5-A375-778327F848E4/GUID-39010DA3-632A-5C27-92BF-9AA8B5966EAB">Asic Class Tutorial</xref>. </p> <p>The updated port can then be
+built, downloaded and tested. </p> </section>
+<section id="GUID-88B8F550-4E17-48FE-8A5A-1961E7F0642F"><title>Port
+the User-Side Hardware Abstraction (HAL)</title> <p>The User-Side
+Hardware Abstraction (HAL) component provides a simple interface for
+programs to read and set hardware-specific settings, for example,
+the display contrast. A base port must define the attributes that
+clients can use on a phone, and implement any functions that are required
+to get and set the attributes. </p> <p>For details, see <xref href="GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8.dita#GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8/GUID-4DA41221-40B9-5BC7-B2C6-7C6EB4522508">User-Side Hardware Abstraction</xref>. </p> </section>
+<section id="GUID-BB519F80-9BE3-4816-9C84-FDD5DE67B6D0"><title>Port
+the other drivers</title> <p>The remaining drivers can now be ported.
+Go and see: </p> <ul>
+<li id="GUID-6D6B4F23-9F27-5DBF-A0FB-9E48CCCAA4AF"><p><xref href="GUID-DF2F0439-AE1A-599C-91B9-6EF2177C3C7E.dita">DMA Framework</xref>  </p> </li>
+<li id="GUID-A0CF718D-29D3-5137-9964-40A5C179674D"><p><xref href="GUID-E081474F-6B17-5D2E-833B-E8177778577A.dita">Digitizer Driver</xref>  </p> </li>
+<li id="GUID-92D3BEC0-2BCD-51D1-9222-8214F9B6889E"><p><xref href="GUID-D048E187-6B1C-5A80-9CD0-89CD10688C6F.dita">Keyboard Driver</xref>  </p> </li>
+<li id="GUID-E9E1CE2D-B8F4-577F-99EB-A9622F302C2A"><p><xref href="GUID-8C22AF20-EE0E-5AD2-BEFD-FED5A7DBB09B.dita">LCD Extension</xref>  </p> </li>
+<li id="GUID-A59034CE-8742-5666-9585-0FD1A2DE30E7"><p> <xref href="GUID-5C223AD5-4676-58B4-B3A5-066F6B69AA4D.dita#GUID-5C223AD5-4676-58B4-B3A5-066F6B69AA4D/GUID-868866C8-E90C-5291-8732-BB4E86D6B43E">Local Media Subsystem</xref>   </p> </li>
+<li id="GUID-85D744D4-81B2-55EC-B746-F3DF263B306D"><p><xref href="GUID-F5430A12-D89D-4936-B846-E917B434F755.dita">Power Management</xref>   </p> </li>
+<li id="GUID-9AD5A0B3-83F7-50DC-AB8D-BDE8830235FA"><p> <xref href="GUID-A04F46F8-1BA9-5A77-B455-59C67DD4AA36.dita#GUID-A04F46F8-1BA9-5A77-B455-59C67DD4AA36/GUID-2AC9DD85-20AB-5E41-B21C-A08300989531">Serial Port Driver</xref>   </p> </li>
+<li id="GUID-B9994028-8D4E-5752-8F84-018346EC617B"><p><xref href="GUID-669C77A3-89BA-5321-ABB1-4356A5FE478C.dita">Sound Driver</xref>   </p> </li>
+<li id="GUID-C69A5E75-E65B-51F7-AE89-22DC80AFB6F9"><xref href="GUID-C06CFF3E-23E9-5E0B-99A1-51B8ED95465F.dita">USB Client Driver
+Technology</xref><p>  </p> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-5CF162CA-4395-58AC-A318-2BF178276A57-master.png has changed
Binary file Adaptation/GUID-5CF162CA-4395-58AC-A318-2BF178276A57_d0e69352_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-5E24CFFD-1F87-4B77-B7A0-59A419ADBC90.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-5E24CFFD-1F87-4B77-B7A0-59A419ADBC90" xml:lang="en"><title>IIC </title><shortdesc>Describes the Inter-Integrated Circuit (IIC) platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-5E358AB4-03A7-5859-ABF2-A8B64B74AF56.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-5E358AB4-03A7-5859-ABF2-A8B64B74AF56" xml:lang="en"><title>Vector Floating Point Architecture (VFP)</title><shortdesc>Describes the implementation of the ARM Vector Floating
+Point Architecture (VFPv2) on Symbian platform. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>ARM provide a hardware floating point coprocessor that provides
+floating point computation that is fully compliant with IEEE Std 754-1985.We
+refer to the coprocessor as the <i>VFP unit</i>. </p>
+<p>Symbian platform supports the use of VFPv2 on platforms where the
+required hardware is present in both <i>RunFast</i> mode and in <i>IEEE-without-exceptions</i> mode. See ARM's Vector Floating-point
+Coprocessor Technical reference Manual for more details on the coprocessor,
+its architecture, and its execution modes. </p>
+<p>You should read Floating point support in Symbian^3 Tools Guide
+&gt; Building. The guide contains information about applications
+and user-side code, which is also applicable to code running on the
+kernel side. However there are a number of restrictions that must
+be observed: </p>
+<ul>
+<li id="GUID-2205026D-0E6F-54AE-B74F-5478D6047B70"><p>You <i>cannot</i> use VFP instructions in any interrupt service routine. </p> </li>
+<li id="GUID-C8D896E1-CF36-52CD-A984-61D7A8189268"><p>You <i>cannot</i> use VFP instructions when the kernel is locked, for example, in
+an IDFC or after calling <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-7CBBF72B-4519-38DD-92CA-38AF636AFD8A"><apiname>NKern::Lock()</apiname></xref>  </p> </li>
+<li id="GUID-A7466A83-A8F2-58CE-AB8B-E05607BB6D95"><p>You <i>cannot</i> use VFP instructions in any section of code which runs with a fast
+mutex held. </p> </li>
+</ul>
+<p>Using VFP instructions in these situations can lead to data being
+corrupted, or the kernel panicking. If you rely on the compiler to
+generate VFP instructions, rather than using inline assembler, it
+is extremely important that you do not use any floating point values
+in these situations. The compiler may generate VFP instructions for
+the most trivial floating point operations and even for simple assignments. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-5EB03086-A87D-5588-8927-7A7F8DB38366.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-5EB03086-A87D-5588-8927-7A7F8DB38366" xml:lang="en"><title>Port Implementation
+Tutorial</title><shortdesc>This section describes how to implement a port of the bootstrap.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/><related-links>
+<link href="GUID-A74BC61D-85E6-5DB5-93F4-DFE4F0B93EF2.dita"><linktext>Concepts</linktext>
+</link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-5F35ED29-18A0-4764-B84D-B43BF23BF44F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,72 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-5F35ED29-18A0-4764-B84D-B43BF23BF44F" xml:lang="en"><title>Time Testing Guide</title><shortdesc>Describes how to test a Time SHAI implementation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There is no conformance testing suite for the Time platform service.
+So, this is a list of tests that have to be conducted to check that
+the Time platform service is working correctly:</p>
+<section id="GUID-7CF6788A-D44E-456C-AF6D-2B3A93E89539"><title>Time
+Tests</title><p>The following table is a list of the tests that need
+to be carried out in order to test the Time SHAI implementation.</p><table id="GUID-541A8B76-7008-4E81-8AFD-C2955996E79B">
+<tgroup cols="4"><colspec colname="COLSPEC0" colwidth="0.41*"/><colspec colname="col1" colwidth="0.79*"/><colspec colname="col2" colwidth="1.40*"/>
+<colspec colname="col3" colwidth="1.41*"/>
+<thead>
+<row>
+<entry align="center" valign="top"><p><b>No.</b></p></entry>
+<entry align="center" valign="top"><p><b>Functionality To Test</b></p></entry>
+<entry align="center" valign="top"><p><b>Description</b></p></entry>
+<entry align="center" valign="top"><p><b>Correct Result</b></p></entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p>1</p></entry>
+<entry><p>The Real Time Clock (RTC) works correctly.</p></entry>
+<entry><p>Check the output from the RTC with a reliable clock.</p></entry>
+<entry><p>The date and time should be identical.</p></entry>
+</row>
+<row>
+<entry><p>2</p></entry>
+<entry><p>Validating the RTC.</p></entry>
+<entry><p>The function <xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita#GUID-CC79A63E-15DF-3437-983B-9A90966B3004/GUID-AC7C2EFB-BE71-301A-9C03-A15BDC0EF310"><apiname>MRtcAdaptation::ValidateRtc()</apiname></xref> is called.</p></entry>
+<entry><p>The <codeph>KErrorNone</codeph> should be returned in the
+variable passed in the second argument.</p></entry>
+</row>
+<row>
+<entry><p>3</p></entry>
+<entry><p>Setting the wake-up alarm.</p></entry>
+<entry><p>The function <xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita#GUID-CC79A63E-15DF-3437-983B-9A90966B3004/GUID-208F81E5-E9F0-3152-9BCF-04A5147922A2"><apiname>MRtcAdaptation::SetWakeupAlarm()</apiname></xref></p></entry>
+<entry><p>The wake-up alarm should start at the set time.</p></entry>
+</row>
+<row>
+<entry><p>4</p></entry>
+<entry><p>Un-set the wake-up alarm.</p></entry>
+<entry><ol>
+<li id="GUID-7E749595-4BC7-4D28-8292-45C11D4160DB"><p>Set the wake-up
+alarm to a known date and time.</p></li>
+<li id="GUID-26183817-BD96-4DFD-B898-285546F9B318"><p>Execute the
+function <xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita#GUID-CC79A63E-15DF-3437-983B-9A90966B3004/GUID-13192CC5-661C-3696-BEFC-198C45C38B8C"><apiname>MRtcAdaptation::UnsetWakeupAlarm()</apiname></xref> to
+cancel the wake-up alarm.</p></li>
+</ol></entry>
+<entry><p>The wake-up alarm will not go off at the original preset
+time.</p></entry>
+</row>
+<row>
+<entry><p>5</p></entry>
+<entry><p>Cancel a request.</p></entry>
+<entry><p>As for the above, except that the function <xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita#GUID-CC79A63E-15DF-3437-983B-9A90966B3004/GUID-ADC7041A-23F0-319F-A163-29E8BB261D0B"><apiname>MRtcAdaptation::Cancel()</apiname></xref> is called instead of<xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita#GUID-CC79A63E-15DF-3437-983B-9A90966B3004/GUID-13192CC5-661C-3696-BEFC-198C45C38B8C"><apiname>MRtcAdaptation::UnsetWakeupAlarm()</apiname></xref>.</p></entry>
+<entry><p>The wake-up alarm will not go off at the original preset
+time.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept xml:lang="en" id="GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834"><title>Set the Interface Descriptors </title><shortdesc>A short document that describes how to set the interface descriptors. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody><section id="GUID-078753F0-B95D-59F6-B820-8CB8E0C9E903"><title>Introduction</title> <p>Before setting the interface descriptors, get the device and endpoint capabilities of the USB Device Controller (UDC) hardware. </p> <ul><li id="GUID-A1822AA8-7D19-500B-86AB-F6020A6D5A6B"><p> <xref href="GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita#GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834/GUID-E816E6FE-BD6A-5FF6-B450-CA5304BC0175">Get device capabilities,</xref>  </p> </li> <li id="GUID-692A31F3-F583-585B-9288-E40863145D8C"><p> <xref href="GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita#GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834/GUID-8B403342-D4CC-5DB7-AD4E-402DFD75FA62">Define the interface data,</xref>  </p> </li> <li id="GUID-A1AB1EB3-A95C-5E38-AE82-1DA7AB9BA807"><p> <xref href="GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita#GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834/GUID-9D773343-8597-5A85-9511-32E176D06E8F">Set the interface,</xref>  </p> </li> <li id="GUID-43CA2C0D-1B24-5D7B-A5C2-D158262EE44A"><p> <xref href="GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita#GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834/GUID-44EC5C8F-C795-57C7-AB1A-C8918C187CDE">Finalise the interface.</xref>  </p> </li> </ul> </section> <section id="GUID-E816E6FE-BD6A-5FF6-B450-CA5304BC0175"><title>Get device capabilities</title> <p>Use <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-990AB6D3-D659-33C9-BE33-117ACE95A106"><apiname>RDevUsbcScClient::DeviceCaps()</apiname></xref> to get the device capabilities and <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-A16F2D62-FCBC-3E97-B058-F9D4ED68817C"><apiname>RDevUsbcScClient::EndpointCaps()</apiname></xref> to get the endpoint capabilities. </p> <p> <xref href="GUID-638DE142-E894-3EC9-9406-CAF67DB822A1.dita"><apiname>TUsbDeviceCapsV01</apiname></xref> is the structure used to return the device capabilities. </p> <codeblock id="GUID-EC77C1A0-510E-57B9-848E-5B58D51B3438" xml:space="preserve">TUsbDeviceCaps d_caps;
+TInt r = gPort.DeviceCaps(d_caps);</codeblock> <p> <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-A16F2D62-FCBC-3E97-B058-F9D4ED68817C"><apiname>RDevUsbcScClient::EndpointCaps()</apiname></xref> returns the object <xref href="GUID-70D18C87-249C-3E9C-895F-85FFB9B0139B.dita"><apiname>TUsbEndpointData</apiname></xref> which contains a <xref href="GUID-581F651B-9D13-3C26-908B-5A12259914CE.dita"><apiname>TUsbEndpointCaps</apiname></xref> object and a boolean variable that indicates whether the endpoint is in use. <codeph>TUsbEndpointCaps</codeph> contains the endpoint capabilities as reported by the driver. </p> <codeblock id="GUID-59FAB2C1-43B8-5549-A3CE-8E01E41858DB" xml:space="preserve">TUsbcEndpointData data[KUsbcMaxEndpoints];
+TPtr8 dataptr(reinterpret_cast&lt;TUint8*&gt;(data), sizeof(data), sizeof(data));
+r = gPort.EndpointCaps(dataptr);</codeblock> <p> <b>Note</b>: Endpoint zero is only supported as a control endpoint. The capabilities of endpoint zero are not included in the list of endpoint cababilities returned. </p> </section> <section id="GUID-8B403342-D4CC-5DB7-AD4E-402DFD75FA62"><title>Define the interface data</title> <p>Before calling <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-8DD93FEC-4B48-3789-B850-41EEB867C25F"><apiname>RDevUsbcScClient::SetInterface()</apiname></xref>, the class, subclass and protocol must be defined in the <xref href="GUID-0A45BEF9-973E-3C73-8F23-4383AB694C1E.dita"><apiname>TUsbcScInterfaceInfo</apiname></xref> object. <codeph>TUsbcScInterfaceInfo</codeph> is in the <xref href="GUID-D93648BC-3702-34EC-8550-C038009C3FE6.dita"><apiname>TUsbcScInterfaceInfoBuf</apiname></xref> package buffer. </p> <p>In the example below we set the interface data in the <codeph>TUsbcScInterfaceInfo</codeph> object. </p> <codeblock id="GUID-E9DA752C-2200-5173-99BA-B446EE5595B0" xml:space="preserve">TUsbcScInterfaceInfoBuf ifc;
+
+// Endpoint zero
+ifc().iEndpointData[0].iType = KUsbEpTypeBulk;
+ifc().iEndpointData[0].iDir = KUsbEpDirIn;
+ifc().iEndpointData[0].iSize = KUsbEpSize64;    
+
+//Endpoint 1
+ifc().iEndpointData[1].iType = KUsbEpTypeBulk;
+ifc().iEndpointData[1].iDir = KUsbEpDirOut;
+ifc().iEndpointData[1].iSize = KUsbEpSize64;
+
+_LIT16(string, "T_USBCSC Interface");
+ifc().iString = const_cast&lt;TDesC16*&gt;(&amp;string);
+ifc().iTotalEndpointsUsed = 2;
+ifc().iClass.iClassNum      = 0xff;
+ifc().iClass.iSubClassNum = 0xff;
+ifc().iClass.iProtocolNum = 0xff;
+
+// Tell the driver that this setting is interested in Ep0 requests:
+ifc().iFeatureWord |= 0;</codeblock> <p> <codeph>TUsbcScInterfaceInfo</codeph> contains the following data members: </p> <ul><li id="GUID-EC42ACC1-2390-5038-BBB2-ECD9BED00095"><p> <codeph>iEndpointData</codeph> is is an array of n <xref href="GUID-D59AC3E3-2F3D-3D85-BBA4-271A78515993.dita"><apiname>TUsbcScEndpointInfo</apiname></xref> elements where n = <codeph>iTotalEndpointsUsed</codeph>, </p> <p>For each endpoint the <codeph>TUsbcScEndpointInfo</codeph> object must, at the very least, contain: </p> <ul><li id="GUID-13CC90A8-B9BE-52D4-9B8D-DC436E8B7D2C"><p>The endpoint type (<codeph>iType</codeph>), direction (<codeph>iDir</codeph>) and maximum packet size (<codeph>iSize</codeph>) must be specified to claim each endpoint. </p> </li> <li id="GUID-01B1592E-3680-5815-A192-8EC181BF549A"><p>The members <codeph>iBufferSize</codeph> and <codeph>iReadSize</codeph> help with performance tuning and memory optimisation. For example, a capture of 64KB may be an optimal size to pull off the bus without incurring timeout penalties in the PSL. Some classes may benefit from having multiple captures in the endpoint buffer, so <codeph>iBufferSize</codeph> would be some multiple of <codeph>iReadSize</codeph>. </p> </li> <li id="GUID-23779A3C-783F-56BE-AABF-CA035021552F"><p> <codeph>iExtra</codeph> and <codeph>iPairing</codeph> allow for possible future support of classes that require pairing of endpoints by physical address and function. <b>Note</b>: This is not yet supported and any attempt to pair endpoints will result in failure to create the interface. </p> </li> </ul> </li> <li id="GUID-59C914DF-E81E-5ECD-A957-20505BE84EAF"><p> <codeph>iString</codeph> is a <xref href="GUID-440FF2B4-353B-3097-A2BA-5887D10B8B23.dita"><apiname>TDesC16</apiname></xref>, </p> <p>A description string for the interface. </p> </li> <li id="GUID-17D47697-E796-59B5-8BF7-87D62848757A"><p> <codeph>iTotalEndpointsUsed</codeph> is a <xref href="GUID-F9432D7B-41C9-3048-AC50-B5BCF8BE11D0.dita"><apiname>TUint</apiname></xref>, </p> <p>This number is all the endpoints you wish to use excluding endpoint zero. For example, if you wish to use 4 endpoints and the control endpoint, this value is should be four. </p> <p> <b>Note</b>: If you wish to implement a control-only interface then this value should be zero. </p> </li> <li id="GUID-A244CB5A-D7E5-562E-9BEA-55E891106E8E"><p> <codeph>iClass</codeph> is of type <xref href="GUID-4BA5287B-69D8-3714-BA3A-D4DBA4DD6AE8.dita"><apiname>TUsbcClassInfo</apiname></xref>, </p> <p>Sets the class type for this interface. </p> </li> <li id="GUID-5514EA9C-2B41-545A-9249-84DB03A0A5B3"><p> <codeph>iFeatureWord</codeph> is 32 flag bits used for specifying miscellaneous interface features. </p> <p>See <xref href="GUID-0A9C35DA-DF54-5885-AFE0-F4D5B3E49941.dita">Allocate Resources for Endpoints</xref>. </p> </li> </ul> </section> <section id="GUID-9D773343-8597-5A85-9511-32E176D06E8F"><title>Set the interface</title> <p>To set the interface pass the initialised <xref href="GUID-D93648BC-3702-34EC-8550-C038009C3FE6.dita"><apiname>TUsbcScInterfaceInfoBuf</apiname></xref> to <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-8DD93FEC-4B48-3789-B850-41EEB867C25F"><apiname>RDevUsbcScClient::SetInterface()</apiname></xref>. </p> <codeblock id="GUID-E96684EB-8012-59D1-9ECF-4C0AA19F3B9B" xml:space="preserve">// Set up the interface.
+r = gPort.SetInterface(0, ifc);</codeblock> <p>The interface number passed to <codeph>SetInterface()</codeph> along with <xref href="GUID-D93648BC-3702-34EC-8550-C038009C3FE6.dita"><apiname>TUsbcScInterfaceInfoBuf</apiname></xref> distinguishes between <i>alternate interfaces</i>. If alternate interfaces are not used then this value is always zero. When used, the value must be one greater than that of the proceeding alternate interface. </p> <p> <b>Note</b>: The whole <xref href="GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita">Setting interface descriptors</xref> section up to this point should be repeated for the number of alternative settings required. </p> </section> <section id="GUID-44EC5C8F-C795-57C7-AB1A-C8918C187CDE"><title>Finalise the interface</title> <p> <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-B0818D26-B205-3BF9-863B-6F67162BE06F"><apiname>RDevUsbcScClient::RealizeInterface()</apiname></xref> is called after <codeph>SetInterface()</codeph> has been called for all alternative settings. </p> <p>On success, a chunk handle is created and passed back through <codeph>aChunk</codeph>. </p> <codeblock id="GUID-B0376164-FF6A-53E2-98CE-FF3BB48F7C4A" xml:space="preserve">RChunk gChunk;
+r = gPort.RealizeInterface(gChunk);</codeblock> <p>If you are using the <xref href="GUID-6E89E787-749D-5AC5-957D-967B4B9ACD74.dita">Buffer Interface Layer (BIL)</xref> then use <codeph>FinalizeInterface()</codeph> instead of <codeph>RealizeInterface()</codeph>. <codeph>FinalizeInterface()</codeph> has the same effect a calling <codeph>RealizeInterface()</codeph>, except that the BIL owns the <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita"><apiname>RChunk</apiname></xref> handle. This function must be used if you want to use any other BIL method. </p> <codeblock id="GUID-CD5C8BCC-7F55-5D95-A244-7999C1A0FAF4" xml:space="preserve">RChunk *tChunk = &amp;gChunk;
+gPort.FinalizeInterface(tChunk);</codeblock> <p> <b>Note</b>: Calling <codeph>RealizeInterface()</codeph> or <codeph>FinalizeInterface()</codeph> invalidates all further calls to <codeph>SetInterface()</codeph>. All alternative settings must have been initialised before calling these functions. </p> </section> <section><p>After you have set the interface descriptors you could optionally <xref href="GUID-0A9C35DA-DF54-5885-AFE0-F4D5B3E49941.dita">Allocate Resources for Endpoints</xref> or go straight to <xref href="GUID-9597DB22-D932-5A58-9C3C-4E5FCA244253.dita">Re-Enumerate</xref>. </p> </section> </conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-5FB6BEFD-579B-4139-B54D-9CDCF2198A14.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-5FB6BEFD-579B-4139-B54D-9CDCF2198A14" xml:lang="en"><title>Interrupt Implementation</title><shortdesc>Describes the implementation of the Interrupt platform
+service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
Binary file Adaptation/GUID-5FDAF564-6BE1-544A-B5C0-E0D6E25D82E7-master.png has changed
Binary file Adaptation/GUID-5FDAF564-6BE1-544A-B5C0-E0D6E25D82E7_d0e15107_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6060F138-CEB6-482A-B0E9-BBBE261568B0.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,99 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6060F138-CEB6-482A-B0E9-BBBE261568B0" xml:lang="en"><title>Baseport Template Overview</title><shortdesc>This section provides a summary of the Baseport Template
+platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-55C84C61-0BD1-4E01-A454-9B10B305169C"><title>What
+is the Baseport Template</title><p>The Baseport Template is a reference
+board template, which provides a basic framework consisting of base
+parts of the Symbian platform. This framework can be modified to suit
+your hardware configurations.</p><p>The Baseport Template code is
+categorized into Application Specific Standard Product (ASSP) layer
+and variant layer. The ASSP layer provides the source code for hardware-specific
+functions (for example, GPIO, DMA, IIC, USB Client Controller) that
+are used by the kernel. This layer is implemented by the <xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita"><apiname>TemplateAssp</apiname></xref> class. The variant layer provides common peripheral
+control functions such as power, bootstrap, keymap, keyboard and sound
+that other extensions and device drivers can use. This layer is implemented
+by the <xref href="GUID-F041A785-0E01-3288-98EE-73627AC43B8B.dita"><apiname>Template</apiname></xref> class.</p><p>ASSP and variant layers
+provide control functions for hardware which is used by multiple devices.
+This is done by placing Baseport Template code in a single DLL, called
+the Variant DLL (<codeph>ecust.dll</codeph>). For hardware architectures
+based on an ASSP, you can allow multiple phone types that use the
+same ASSP to share the common code. To achieve this, implement the
+common ASSP code in a kernel extension, and <codeph>ecust.dll</codeph> implements the code that is specific to each variant. </p></section>
+<section id="GUID-94D4C137-A1C0-4A30-B115-A8C3ABB873DF"><title>Purpose
+of the Baseport Template</title><p>The Baseport Template is mostly
+useful in creating a baseport and testing the software. The following
+is a list of some of the key uses of the Baseport Template.</p><p>The Baseport Template is useful in handling:</p><ul>
+<li><p>data exchange between devices connected to the bus</p></li>
+<li><p>data copy between memory locations or between memory location
+and peripheral</p></li>
+<li><p>communication interface between the microprocessor components</p></li>
+<li><p>hardware events and registers</p></li>
+<li><p>USB functions of the device</p></li>
+<li><p>power resources</p></li>
+<li><p>phone restart after a hardware reset </p></li>
+<li><p>shared chunks of camera and sound physical device driver</p></li>
+<li><p>CPU idle operations</p></li>
+<li><p>HAL, interrupt and keyboard functions</p></li>
+<li><p>data storage based on NOR type flash memory</p></li>
+<li><p>variant specific initialization (not the same as ASSP specific
+initialization).</p></li>
+</ul></section>
+<section id="GUID-0E2FF597-880E-49B5-98EF-0228B9EE70F4"><title>Users
+of Baseport Template</title>The Baseport Template documentation cover
+users who: <ul>
+<li><p>manufacture devices and want to develop software and get an
+early debug output.</p></li>
+<li><p>develop baseport. See <xref href="GUID-0C84FD76-87B2-4AD1-B23A-2C5C8668BC4C.dita">Base Porting Guide</xref> for base porting details</p></li>
+</ul></section>
+<section id="GUID-575E1FDC-6BA8-4847-A7F3-ADDF0D74B929"><title>Baseport
+Template details</title><p>The following table lists the Baseport
+Template details:</p><table id="GUID-BCE51448-8AE7-4D00-BADC-68A630392145">
+<tgroup cols="3"><colspec colname="col1" colwidth="0.66*"/><colspec colname="col2" colwidth="0.67*"/><colspec colname="col3" colwidth="2.31*"/>
+<thead>
+<row>
+<entry valign="top"><p>DLL</p></entry>
+<entry valign="top"><p>Library</p></entry>
+<entry valign="top"><p>Description</p></entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p><filepath>katemplate.dll</filepath></p></entry>
+<entry><p>None</p></entry>
+<entry><p> ASSP DLL. This DLL is made up of the following template
+files and can be found under <filepath>...template\asspandvariant\template_assp\</filepath> directory:<ul>
+<li><p><filepath>template_assp.cpp</filepath> </p></li>
+<li><p><filepath>interrupts.cpp</filepath></p></li>
+<li><p><filepath>assp.cpp</filepath></p></li>
+<li><p><filepath>register.cpp</filepath></p></li>
+<li><p><filepath>template_assp.cia</filepath></p></li>
+<li><p><filepath>interrupts.cia</filepath></p></li>
+<li><p><filepath>assp.cia</filepath></p></li>
+</ul></p></entry>
+</row>
+<row>
+<entry><p><filepath>ecust.dll</filepath></p></entry>
+<entry><p>None</p></entry>
+<entry><p>Variant DLL. This DLL is made up of the following template
+files and can be found in <filepath>...template\asspandvariant\template_variant\</filepath> directory:<ul>
+<li><p><filepath>variant.cpp</filepath>   </p></li>
+<li><p><filepath>variant.cia</filepath> </p></li>
+</ul></p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+</conbody><related-links>
+<link href="GUID-0C84FD76-87B2-4AD1-B23A-2C5C8668BC4C.dita"><linktext>Base
+Porting Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-60949ACD-AAA9-540E-85AE-BB173382D548-master.png has changed
Binary file Adaptation/GUID-60949ACD-AAA9-540E-85AE-BB173382D548_d0e13468_href.png has changed
Binary file Adaptation/GUID-610E0C09-F014-4DA2-8411-D7A0CDAF5BBB-master.png has changed
Binary file Adaptation/GUID-610E0C09-F014-4DA2-8411-D7A0CDAF5BBB_d0e90471_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6114133F-E738-4DF1-8308-B09C02B9CEEA.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,279 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6114133F-E738-4DF1-8308-B09C02B9CEEA" xml:lang="en"><title>DMAv2 Interface Overview</title><shortdesc>Describes the interfaces provided by the DMAv2 platform
+service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-37ADE1EE-C4AB-41FD-B639-DE447AA4BD53"><title>Client
+functions</title><p>The clients that require to use the DMA framework
+functionality use the <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita"><apiname>DDmaRequest</apiname></xref> class functions
+to request DMA transfers. The clients should not set any parameters
+directly but use functions of the <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita"><apiname>DDmaRequest</apiname></xref> class.</p><table id="GUID-B53C9C8A-C5D5-4CA2-A81B-85D5EF9F86EA">
+<tgroup cols="2"><colspec colname="col1" colwidth="1.00*"/><colspec colname="col2" colwidth="1.00*"/>
+<thead>
+<row>
+<entry>API</entry>
+<entry>Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-311897BE-5079-3945-A299-333B9B8E4071"><apiname>DDmaRequest::DDmaRequest(TDmaChannel&amp; aChannel,
+TCallback, TAny*, TInt)</apiname></xref></entry>
+<entry>The constructor for the <codeph>DDmaRequest</codeph> class. </entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-55E31857-CCA8-3463-BB72-D45A8952A39F"><apiname>DDmaRequest::Fragment(const TDmaTransferArgs&amp;
+aTransferArgs)</apiname></xref></entry>
+<entry>Split request into a list of fragments small enough to be fed
+to the DMA Controller. The size of the fragment should be less than
+or equal to the maximum transfer size supported by the DMA controller.</entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-0A83F782-DB62-39ED-8D32-DBD5949C8D3F"><apiname>DDmaRequest::Queue()</apiname></xref></entry>
+<entry>Asynchronous transfer request.</entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-E91276AA-EC8A-39C7-802F-22F713E2BBAC"><apiname>DDmaRequest::ExpandDesList(TInt)</apiname></xref></entry>
+<entry>Add new descriptors to the existing list. The function is to
+be used by the clients that require to build a custom descriptor list.</entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-8A34A869-3593-308E-93CC-36951C8B310B"><apiname>DDmaRequest::ExpandSrcDesList(TInt)</apiname></xref></entry>
+<entry>Add new descriptors to the existing source port descriptor
+list.</entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-6A9CE3CA-BECF-3A8C-802A-D53FBB152627"><apiname>DDmaRequest::ExpandDstDesList(TInt)</apiname></xref></entry>
+<entry>Add new descriptors to the existing destination port descriptor
+list.</entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-6E1A6759-E6E0-3C04-BEED-318AF42A892F"><apiname>DDmaRequest::FreeDesList()</apiname></xref></entry>
+<entry>Free resources associated with this request.</entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-57047E56-CEC0-364D-A276-6F66AC2B2F3F"><apiname>DDmaRequest::FreeSrcDesList()</apiname></xref></entry>
+<entry>Free resources associated with this request from the source
+port descriptor chain.</entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-1826EE8C-817B-3086-B524-CEC9329007DC"><apiname>DDmaRequest::FreeDstDesList()</apiname></xref></entry>
+<entry>Free resources associated with this request from the destination
+port descriptor chain.</entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-C5CFD281-7E51-3366-8BAE-1D702F9BD142"><apiname>DDmaRequest::EnableSrcElementCounting(TBool)</apiname></xref></entry>
+<entry>Enables the functionality for counting the transferred source
+elements.</entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-7C978E94-20B0-3445-9785-4135FAEFAFE3"><apiname>DDmaRequest::EnableDstElementCounting(TBool)</apiname></xref></entry>
+<entry>Enables the functionality for counting the transferred destination
+elements.</entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-ED613C3E-CD72-342B-B8A1-F26F4B3319A8"><apiname>DDmaRequest::DisableSrcElementCounting()</apiname></xref></entry>
+<entry>Disables  the functionality for counting the transferred source
+elements.</entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-021492C7-B778-3F58-A097-376A414B40B6"><apiname>DDmaRequest::DisableDstElementCounting()</apiname></xref></entry>
+<entry>Disables the functionality for counting the transferred destination
+elements.</entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-6613A1DA-1E18-34A8-9FD8-4DE9269FA2B9"><apiname>DDmaRequest::TotalNumSrcElementsTransferred()</apiname></xref></entry>
+<entry>Get the number of transferred elements at the source port.
+This function can only be used if the counting is enabled.</entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-5B1350AB-FFF6-3172-BB08-B50925CB89E9"><apiname>DDmaRequest::TotalNumDstElementsTransferred()</apiname></xref></entry>
+<entry>Get the number of transferred elements at the destination port.
+This function can only be used if the counting is enabled.</entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-A43A6A70-EEA7-31B1-A9FB-A75865D64FC4"><apiname>DDmaRequest::FragmentCount()</apiname></xref></entry>
+<entry>Returns the number of fragments that are created by this transfer
+request. </entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-F2B9B9ED-A2DF-3E43-A080-323CC67CD9DD"><apiname>DDmaRequest::SrcFragmentCount()</apiname></xref></entry>
+<entry>Returns the number of source port fragments that are created
+by this transfer request.</entry>
+</row>
+<row>
+<entry><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-74BEEB4D-04B6-3722-A7CD-8ED9EE3267AC"><apiname>DDmaRequest::DstFragmentCount()</apiname></xref></entry>
+<entry>Returns the number of destination port fragments that are created
+by this transfer request.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-C10135FD-8CCB-3032-9865-F86A8428A54D"><apiname>TDmaChannel::Open(const SCreateInfo&amp; aInfo, TDmaChannel*&amp;
+aChannel)</apiname></xref></entry>
+<entry>Open a specified channel.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-8204AFBD-2A60-372E-B626-35BD19851FF7"><apiname>TDmaChannel::Close()</apiname></xref></entry>
+<entry>Close a previously opened channel.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-0588547C-300B-3558-8173-E7581956D8DB"><apiname>TDmaChannel::LinkToChannel(TDmaChannel* aChannel)</apiname></xref></entry>
+<entry>Logically link a channel with the specified argument. When
+the argument is NULL the channel is unlinked.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-39306527-CBB8-3C89-90F5-BB21A7F34A0F"><apiname>TDmaChannel::Pause()</apiname></xref></entry>
+<entry>Pause an active transfer.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-5BC3DDA2-D6EB-375D-9FFC-DD40F26BD01C"><apiname>TDmaChannel::Resume()</apiname></xref></entry>
+<entry>Resume transfer on this channel.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-0A98D2DC-2A61-3FBD-AB7A-623FE926A183"><apiname>TDmaChannel::CancelAll()</apiname></xref></entry>
+<entry>Cancel current and all pending requests.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-FC57221E-0C3D-3150-80DC-B3532725607F"><apiname>TDmaChannel::MaxTransferLength(TUint aSrcFlags, TUint
+aDstFlags, TUint32 aPslInfo)</apiname></xref></entry>
+<entry>Get the maximum transfer length of the current channel.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-F53A4F88-971E-37E9-973E-33DF9AD4847A"><apiname>TDmaChannel::AddressAlignMask(TUint aTargetFlags,
+TUint aElementSize, TUint32 aPslInfo)</apiname></xref></entry>
+<entry>Get the address or memory alignment mask.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-4DCC8674-E4C7-365B-AE19-244F62C2273D"><apiname>TDmaChannel::DmacCaps()</apiname></xref></entry>
+<entry>Get the reference to the structure that contains the features
+and the capabilities of the DMAC associated with the current channel.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-5C1CB8FB-31BC-3968-A5BD-B187EE0051D0"><apiname>TDmaChannel::IsrRedoRequest(TUint32 aSrcAddr=KPhysAddrInvalid,
+TUint32 aDstAddr=KPhysAddrInvalid, TUint aTransferCount=0, TUint32
+aPslRequestInfo=0, TBool aIsrCb=ETrue)</apiname></xref></entry>
+<entry>Repeat the current transfer request with modified parameters.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-B3887AA6-FEB6-3109-A98A-2854ED903628"><apiname>TDmaChannel::IsQueueEmpty()</apiname></xref></entry>
+<entry>Check if the current transfer queue is empty.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-A84A0711-4573-3ED1-A20E-759215F21255"><apiname>TDmaChannel::PslId()</apiname></xref></entry>
+<entry>Get the PSL specific ID of the current channel. This function
+is used for debugging by the PIL.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-B65DAEB8-C389-33DC-AD46-EFB0D34C42FC"><apiname>TDmaChannel::FailNext(TInt)</apiname></xref></entry>
+<entry>Force to fail the next transfer request. This function is for
+testing purpose only.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-640C7397-434C-3EB4-9931-9E462CE0FB22"><apiname>TDmaChannel::MissNextInterrupts(TInt)</apiname></xref></entry>
+<entry>Force the DMAC to miss one or more interrupts.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-DEABB054-CAF1-3FC4-BC14-87581AFD5370"><apiname>TDmaChannel::Extension(TInt aCmd, TAny* aArg)</apiname></xref></entry>
+<entry>Allows PSL to extend the DMA API with a channel specific functionality.</entry>
+</row>
+<row>
+<entry><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-89BD759C-7269-3C93-ABE2-34E6DA087DA6"><apiname>TDmaChannel::StaticExtension(TInt aCmd, TAny* aArg)</apiname></xref></entry>
+<entry>Allows PSL to extend the DMA API with a channel independent
+functionality.</entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-827B3A45-FB7F-4E4E-901A-BB50C2D19EC3"><title>DMA
+controller implementation</title>The <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> class
+provides the functions of a DMA controller:<table id="GUID-FCA888C8-F648-4A9F-8595-1ABF8AE305C5">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-5B418CE9-7050-3301-927E-059C55B2FC0F"><apiname>TDmac::Transfer(const TDmaChannel&amp; aChannel, const
+SDmaDesHdr&amp; aHdr)</apiname></xref></entry>
+<entry>Initiate a transfer request on a specified channel.</entry>
+</row>
+<row>
+<entry><xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-5191C7E1-A805-3BD1-9743-76B94A457538"><apiname>TDmac::StopTransfer(const TDmaChannel&amp; aChannel)</apiname></xref></entry>
+<entry>Stop a data transfer on a specified channel.</entry>
+</row>
+<row>
+<entry><xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-216083D9-6506-3DD0-B884-80AB16A929A2"><apiname>TDmac::IsIdle(const TDmaChannel&amp; aChannel)</apiname></xref></entry>
+<entry>Get the state of a specified channel.</entry>
+</row>
+<row>
+<entry><xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-D6D011E9-9D75-3881-87D8-1986FFBBA106"><apiname>TDmac::Extension()</apiname></xref></entry>
+<entry>Implement a platform specific functionality per channel.</entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-FD5756CA-CAA7-4259-8508-2F37E2D30C42"><title>Channel
+manager implementation</title><p>The <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita"><apiname>DmaChannelMgr</apiname></xref> class provides functions to open and close the channels by the PIL.
+Implement the following functions in the PSL:</p><table id="GUID-965FE251-FE92-4D1A-B35D-92E5104CBB6F">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita#GUID-176B8E0D-0422-341B-A134-7C85432E1303/GUID-23FE411E-A058-3C6F-957C-BB36F0EBE3E6"><apiname>DmaChannelMgr::Open(TUint32 aOpenId, TBool aDynChannel,
+TUint aPriority)</apiname></xref></entry>
+<entry>Open a channel with a specified channel ID.</entry>
+</row>
+<row>
+<entry><xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita#GUID-176B8E0D-0422-341B-A134-7C85432E1303/GUID-909D795A-7303-3A76-9C8E-3B07A97DD716"><apiname>DmaChannelMgr::Close() </apiname></xref></entry>
+<entry>Close a channel.</entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-868DC865-577F-43F2-A8F2-E5649804F1AD"><title>DMA
+channel implementation</title><p>The <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref> class provides the functions to implement a DMA channel. There are
+three types of DMA channels that be can be implemented as described
+below.</p> <table id="GUID-7EDF7986-AA5A-456C-8BF4-0ADE3E348F65">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">Class</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-A8B4AD1B-770C-363E-A0DE-C78A9786CBDC.dita"><apiname>TDmaSbChannel</apiname></xref></entry>
+<entry>Class to implement a single buffer channel.</entry>
+</row>
+<row>
+<entry><xref href="GUID-FD76AF08-6250-3054-8A06-16343E385B23.dita"><apiname>TDmaDbChannel</apiname></xref></entry>
+<entry>Class to implement a double buffer channel.</entry>
+</row>
+<row>
+<entry><xref href="GUID-2D4CFBB1-8D64-3CF5-B6F0-B24D16D5BAD4.dita"><apiname>TDmaSgChannel</apiname></xref></entry>
+<entry>Class to implement a scatter-gather channel.</entry>
+</row>
+<row>
+<entry><xref href="GUID-B0100F2B-6C01-3429-8B48-DFFB96EA85D0.dita"><apiname>TDmaAsymSgChannel</apiname></xref></entry>
+<entry>Channel class for controllers using asymmetric descriptor lists.</entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-616C3426-A8C4-5653-912D-7150944E5836.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,95 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-616C3426-A8C4-5653-912D-7150944E5836" xml:lang="en"><title>Keyword reference (G-O)</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This page lists the keywords starting from G to O. </p>
+<section id="GUID-DDB9FC14-73FF-5D99-963E-C289D3091FD1"><title>heapmax</title> <codeblock id="GUID-61F649D2-AC86-5EC7-BE9D-3C32D7A644FB" xml:space="preserve">heapmax = &lt;hex-size&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Overrides the default maximum
+heap size for the executable. </p> </section>
+<section id="GUID-250AC57D-0430-5DBD-B04E-99A874E42256"><title>heapmin</title> <codeblock id="GUID-5E9AE355-8824-5364-80A0-BED24579C043" xml:space="preserve">heapmin = &lt;hex-size&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Overrides the default minimum
+heap size for the executable. </p> </section>
+<section id="GUID-0A8E6B07-1C40-55DD-A2D8-122E62A285F1"><title>hide[[HWVD]]</title> <codeblock id="GUID-3BC215FB-B263-5D03-9FB0-421305AC41DD" xml:space="preserve">hide[[HWVD]] = &lt;existing-file&gt;</codeblock> <p> <i>rombuild and rofsbuild</i>  </p> <p>Marks the existing file
+as hidden. The file is still available to resolve DLL static links. </p> </section>
+<section id="GUID-50550839-5F46-5096-98A4-857B62E19C34"><title>_HIDE__ECOM_PLUGIN</title> <codeblock id="GUID-E3AC5736-7A2B-562A-BE90-2A69379BA504" xml:space="preserve">_HIDE__ECOM_PLUGIN(&lt;local build directory&gt;, &lt;rom binary directory&gt;, &lt;local epoc32\data\Z directory&gt;, &lt;rom resources directory&gt;, &lt;DLL filename&gt;, &lt;resource filename&gt;)</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Specifies an ECom plug-in, consisting
+of an implementation DLL and an ECom registration resource file, to
+be hidden in the ROM and in the SPI file. </p> <p>Symbian platform
+code does not use this keyword directly. Instead, it uses the macro <codeph>HIDE_ECOM_PLUGIN</codeph> defined in <filepath>\epoc32\rom\include\header.iby</filepath>. This macro allows the plug-in to be specified more briefly in the
+following form: </p> <codeblock id="GUID-ECA76B8E-6BE5-5A3E-80A8-6D6BADE77599" xml:space="preserve">HIDE_ECOM_PLUGIN(&lt;DLL name&gt;,&lt;resource file name&gt;)</codeblock> <p>For example: </p> <codeblock id="GUID-7ED2A190-ED9B-55C9-AEDC-8E9402BDD0A1" xml:space="preserve">HIDE_ECOM_PLUGIN(foo.dll,12345abc.rsc)</codeblock> <p>This feature allows <codeph>BUILDROM</codeph> to hide the ECom
+plug-ins. In particular, <codeph>BUILDROM</codeph> hides the DLL associated
+with the specified plug-in. The resource registration files that are
+passed using the macro are marked as hidden in the SPI file should
+you choose to generate one. <codeph>BUILDROM</codeph> implements this
+feature using the <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-E54F3C5D-ED40-5196-8D9C-6B7B71826F79">spidatahide</xref> keyword. </p> <p>As part of the ROM building process,
+it is possible to add support for multiple languages. This affects
+how ECom resource files are specified by <codeph>BUILDROM</codeph>: </p> <ul>
+<li id="GUID-A87ABC01-AD2F-5150-A4AD-086EBA94A31B"><p>If an SPI file
+is being created, the <codeph>HIDE_ECOM_PLUGIN</codeph> lines are
+processed at an intermediate <codeph>BUILDROM</codeph> stage to produce: </p> <codeblock id="GUID-D0BB3B3C-E6D7-56F0-8B95-E41D65B969D1" xml:space="preserve">spidatahide=MULTI_LINGUIFY( EXT sourcename ) &lt;spi-id&gt; &lt;target-spi-dir&gt;</codeblock> <p>During the <codeph>BUILDROM</codeph> localisation stage, these
+lines become: </p> <codeblock id="GUID-50A55664-7ECF-561E-9B26-66180E9107BB" xml:space="preserve">spidatahide = &lt;source-file&gt; &lt;spi-id&gt; &lt;target-spi-dir&gt;</codeblock> </li>
+<li id="GUID-209212CC-DC03-52A3-8C8A-44CC715274A5"><p>If an SPI file
+is not being created, the <codeph>HIDE_COM_PLUGIN</codeph> lines are
+processed at an intermediate <codeph>BUILDROM</codeph> stage to produce: </p> <codeblock id="GUID-C0206459-7309-5074-A414-75DDD20DC474" xml:space="preserve">hide=MULTI_LINGUIFY(EXT sourcename)</codeblock> <p>During the <codeph>BUILDROM</codeph> localisation stage, these
+lines become: </p> <codeblock id="GUID-6F7E86C6-1957-5417-8619-FD417CE1981D" xml:space="preserve">hide=sourcename.EXT for the default extension
+hide=sourcename.Enn for all the language codes nn</codeblock> </li>
+</ul> </section>
+<section id="GUID-C1133A70-FD7E-4D65-BB4B-E272011F89E7"><title>hcrdata</title><p><codeblock xml:space="preserve">hcrdata = &lt;hcrdata&gt;</codeblock></p><p>Specifies
+the location of an HCR data file which is included in
+the SMR partition image. </p></section>
+<section id="GUID-A1ACEB2A-EAB5-4FAA-BE8C-910D4596A1C2"><title>imagename</title><p><codeblock xml:space="preserve">imagename = &lt;imagename&gt;</codeblock></p><p>Creates
+an SMR partition image.</p><draft-comment time="2010-06-24T14:25" translate="no">&lt;section id="GUID-178037D5-6040-4767-A185-0BC91B084770"&gt;&lt;title&gt;keepIAT&lt;/title
+&gt;&lt;codeblock&gt;keepIAT&lt;/codeblock&gt;&lt;p&gt;&lt;i&gt;rombuild only&lt;/i&gt;&lt;/p&gt;&lt;p&gt;Retains
+old-style  Import Address Table.&lt;/p&gt;&lt;/section&gt;</draft-comment></section>
+<section id="GUID-046089DD-D441-5960-9C3C-97639C6CD0AD"><title>kerneldataaddress</title> <codeblock id="GUID-93C4F853-ED21-575C-BF22-1AE4B5C00268" xml:space="preserve">kerneldataaddress = &lt;hex-address&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Kernel data/bss chunk base virtual
+address. </p> <p>The recommended value is 0x64000000. </p> </section>
+<section id="GUID-85ECD9AF-EDA0-42BB-9989-306F0A0F21B5"><title>kernelconfig </title><codeblock xml:space="preserve">kernelconfig &lt;bit-of-kervel-config&gt; &lt;on | off&gt;</codeblock><p><i>rombuild only</i></p><p>This keyword sets the specified bit
+of the kernel configuration flag to <codeph>ON</codeph> or <codeph>OFF</codeph>. The value of <codeph>&lt;bit-of-kervel-config&gt;</codeph> must be between 0 and 31.</p></section>
+<section id="GUID-8F83C7C7-9DEC-5EA2-85AF-C5E1CEA68462"><title>kernelheapmax</title> <codeblock id="GUID-33F31257-B9C0-54C4-B777-12F4A4112EEF" xml:space="preserve">kernelheapmax = &lt;hex-size&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Maximum size of the Kernel's heap. </p> <p>The Kernel heap grows in virtual address space until this value
+is reached: It can then grow no further. The value is rounded up to
+a multiple of the virtual address space mapped by a single page directory
+entry - on ARM CPUs this is 1MB. Usually 1 page directory entry's
+worth of RAM is specified. The default value is 0x100000; this is
+used if none is supplied. </p> </section>
+<section id="GUID-00885DED-DF1A-5489-91A7-FA07D915EA2F"><title>kernelheapmin</title> <codeblock id="GUID-E677FADD-D228-5E30-8610-8A6A6C521C22" xml:space="preserve">kernelheapmin = &lt;hex-size&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Minimum size of the Kernel heap,
+allocated immediately when the Kernel boots. Specify either a minimal
+value or a working set size based on envisaged use. </p> <p>The recommended
+value is 0x10000, and is the default value if none is explicitly supplied. </p> </section>
+<section id="GUID-560AF806-B405-529A-9222-C43220355D81"><title>kernelromname</title> <codeblock id="GUID-791C3BD2-46DC-5372-893B-A24B4885DAF4" xml:space="preserve">kernelromname = &lt;rom-file-name&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>ROM image on which an extension
+ROM is based. This keyword is only valid for extension ROMs </p> </section>
+<section id="GUID-1443CA1F-7234-5480-8306-9C28BF16AF82"><title>kerneltrace</title> <codeblock id="GUID-6759ECAB-4531-5C63-94A6-36DC2E3ACBD3" xml:space="preserve">kernelTrace = &lt;32 bit hex-number | decimal number&gt; [&lt;32 bit hex-number | decimal number&gt;]{0,7}</codeblock> <p> <i>rombuild only</i>  </p> <p>Initial value for the kernel trace
+mask. You can supply upto eight separate 32 bit masks in order to
+enable higher trace flags. The bit values are defined in <filepath>nk_trace.h</filepath>, and only apply to a debug Kernel. </p> <p>To define kernel trace in an <filepath>.oby</filepath> file is optional.
+The default value is set as <codeph>0x80000000</codeph> if kernel
+trace is not defined. This default value allows the kernel to raise
+a panic when an error occurs during runtime. If an invalid value is
+set, Buildrom removes the invalid value. For example, if kernel trace
+has only 1 invalid bit mask value, Buildrom removes it and resets
+the default value. </p> </section>
+<section id="GUID-8BC22156-1E47-542F-88CC-37274B879E8A"><title>LANGUAGE_CODE</title> <codeblock id="GUID-58B140B4-ADC8-5F23-94B7-2781D22234C3" xml:space="preserve">LANGUAGE_CODE NN</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Localisation support. Specifies
+the Symbian 2-digit codes for languages to be supported in this ROM.
+The keyword may be used as many times as necessary. </p> </section>
+<section id="GUID-92BCC365-0353-4B29-9D71-356016ABBFCC"><title>maxunpagedsize</title> <codeblock id="GUID-1EBD700F-BF75-552F-9A6C-BD63D690BEFC" xml:space="preserve">maxunpagedsize &lt;maximum_size_of_unpaged_data&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Sets the maximum value for the
+size of uncompressed unpaged data for which you can flash the image.
+If the size of the unpaged data is greater than <codeph>maximum_size_of_unpaged_data</codeph>, a warning message is displayed. </p> </section>
+<section id="GUID-F57DE321-5C08-5D3B-BFE8-B4BD0BA1EBE4"><title>memmodel</title> <codeblock id="GUID-A0643B9B-E6C1-59DD-BE0F-B29353BB03CA" xml:space="preserve">memmodel = moving | direct | multiple &lt;chunk size&gt; &lt;page size&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Specifies the memory model to
+be used at runtime together with the chunk size and the page size. </p> </section>
+<section id="GUID-B97ECBBE-B28F-5241-9D78-DBA20108BB14"><title>multikernel</title> <codeblock id="GUID-198B5D0A-48C8-568A-B345-FA3041C3A479" xml:space="preserve">multikernel</codeblock> <p> <i>rombuild only</i>  </p> <p>Specifies that the ROM image has
+multiple kernel executables. These kernels are specified with multiple
+primary keywords in the files-section. </p> <p>Note that this keyword
+is mutually exclusive with <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-0E5CF5E6-0547-5185-9AE8-B6BF57802017">singlekernel</xref> keyword. </p> </section>
+<section id="GUID-977C6041-365A-5D23-A370-A9939689FFD7"><title>MULTI_LINGUIFY</title> <codeblock id="GUID-D9EBBBBB-15D6-5D3A-9D5C-89837DD1F7BF" xml:space="preserve">&lt;xxx&gt;=MULTI_LINGUIFY(EXT &lt;sourcename&gt; &lt;destname&gt;)</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Localisation support. During the
+localisation pass, the MULTI_LINGUIFY lines are expanded into one
+line per language code. </p> <p>For example, the line: </p> <codeblock id="GUID-435C8CA9-9795-501F-BB34-81B78421C1F4" xml:space="preserve">data=MULTI_LINGUIFY( EXT sourcename destname )</codeblock> <p>is expanded to the lines: </p> <codeblock id="GUID-06DF3C0B-0842-5866-BD47-478F0054E339" xml:space="preserve">data=sourcename.Enn destname.EXT
+data=sourcename.Enn destname.Enn</codeblock> <p>The first line is
+for the default language code; the remaining lines are for all other
+language codes. </p> <p>This provides support for the <codeph>BaflUtils::NearestLanguageFile()</codeph> function, which performs a similar mapping from language codes to
+filenames. </p> </section>
+<section id="GUID-0432CA22-868F-5C9E-B778-378662954DD8"><title>nowrapper</title> <codeblock id="GUID-9B0830B6-318E-5A39-A2A7-7A99D2EC04DC" xml:space="preserve">nowrapper</codeblock> <p> <i>rombuild only</i>  </p> <p>Specifies that no ROM wrapper
+is required. </p> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-622D6337-E60A-5252-8B2B-BA8232927453-master.png has changed
Binary file Adaptation/GUID-622D6337-E60A-5252-8B2B-BA8232927453_d0e29152_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-627FC480-AF4F-4B23-8671-6E0A0DABA0EF.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-627FC480-AF4F-4B23-8671-6E0A0DABA0EF" xml:lang="en"><title>Baseport Template Testing Guide</title><shortdesc>Explains how to test the Baseport Template implementation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There is no conformance testing suite available for Baseport Template.
+However, Kernel testing (E32) and File system testing (F32) tests
+should be run with 100% pass rate for any successful baseport. The
+E32 and F32 tests are written to test the generic base code using
+very minimal hardware services.  As a result, if the baseport cannot
+pass the minimal requirements of the base code, it is unlikely that
+it will be suitable for running a production device. </p>
+<section id="GUID-D24E9188-EB9E-4543-88A3-029B33D0E652"><title>Baseport
+Template tests</title><p>The Baseport Template is designed to boot
+on any hardware. It should boot successfully, but clearly, the system
+can do nothing more at this time. A successful boot shows that your
+build environment has been set up correctly.</p><p>You can conduct
+a series of tests to check if the template works correctly. To test
+different functionality of the template, see:</p><ul>
+<li><p><xref href="GUID-B1199AFF-F44F-440A-90D7-EAB5F982BD42.dita">DMA
+Testing Overview</xref> for information on DMA testing.</p></li>
+<li><p><xref href="GUID-092F414B-2279-4ADB-970F-75DAB8A80BD7.dita">SDIO
+Implementation Testing Guide</xref> for information on SDIO testing.</p></li>
+<li><p><xref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1.dita">Kernel
+API Validity Checks</xref> for information on testing the Kernel APIs. </p></li>
+<li><p><xref href="GUID-9D26E38F-5C7B-5330-A54B-8F97D0F204D0-GENID-1-2-1-8-1-1-7-1-1-5-1.dita">Performance
+Logging</xref> for information on writing trace logs and testing the
+performance.</p></li>
+<li><p><xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita">Validation</xref> for information on how to test a USB port.</p></li>
+<li><p><xref href="GUID-66E5F769-1156-54CA-94BC-8912159A1240.dita">Testing
+the PRM PSL</xref> for information on how to test the Power Resource
+Manager (PRM).</p></li>
+<li><p><xref href="GUID-180973A1-5C0A-5A85-82CC-E6B739A7F207.dita">Platform
+Specific Layer Validation</xref> for information on how to test a
+port of the MMC Controller.</p></li>
+</ul></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,433 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8" xml:lang="en"><title>Pre-Conditions
+and Post-Conditions for Kernel APIs</title><shortdesc>Reference documentation for kernel side function APIs, specifies
+a wide variety of pre-conditions and post-conditions. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<ul>
+<li id="GUID-C8EAD446-F9B7-50A3-8A7C-FA45487287BA"><p>A <i>pre-condition</i> is
+something that must be true before using the function. </p> </li>
+<li id="GUID-0360AD60-7A36-5949-AFF8-6649619F9F6A"><p>A <i>post-condition</i> is
+something that is true on return from the function. </p> </li>
+</ul>
+<p>Such conditions are expressed using a standard phrase, wherever possible,
+and this section explains what those conditions mean. </p>
+<p>Where more than one pre-condition is stated for a given function, then
+you can assume that all pre-conditions apply. In this sense, there is an implied
+AND relation between conditions. For example, in the description of the function <xref href="GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497.dita#GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497/GUID-9DF684E6-F367-3A3B-BA02-301297607160"><apiname>DObject::AppendFullName()</apiname></xref>,
+the following pre-conditions apply: </p>
+<codeblock id="GUID-A81563CA-D72C-5B9F-820E-1AA1623E75F7" xml:space="preserve">No fast mutex can be held.
+Call in a thread context.</codeblock>
+<p>Both conditions must be true before calling the functions. </p>
+<p>There are exceptions to this rule, where a precondition applies only if
+some other factor is true. For example, in the description of the function <xref href="GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497.dita#GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497/GUID-3120933C-095D-3D20-A024-148BA0D473EB"><apiname>DObject::TraceAppendName()</apiname></xref>,
+you will find the following pre-conditions: </p>
+<codeblock id="GUID-3BC88AB3-DBCD-5F4A-9E5E-14B5C711F604" xml:space="preserve">Call either in a thread or an IDFC context, if aLock=TRUE
+Call in any context, if aLock=FALSE.</codeblock>
+<p>Clearly, only one pre-condition will apply, depending on the supplied value
+of the <codeph>aLock</codeph> argument. </p>
+<p>A few conditions are self-explanatory, and these are not included in these
+lists. </p>
+<p>NOTE that some familiarity with kernel side programming is assumed. </p>
+<ul>
+<li id="GUID-331B0761-C3D7-517F-872E-97E5E11A1E3C"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-5F986149-D75B-5B3F-92F3-7B4FB89F4718">Pre-conditions</xref>  </p> </li>
+<li id="GUID-080AD617-2744-556C-AF4E-7FF8AB0B7091"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-F2DE76D5-0970-584F-9526-52E85932ACE8">Post-conditions</xref>  </p> </li>
+</ul>
+<section id="GUID-5F986149-D75B-5B3F-92F3-7B4FB89F4718"><title>Pre-conditions</title> <p>This
+describes the meaning of each precondition, and tries to provide insight as
+to why it needs to be satisfied, and explains what you need to do to ensure
+that the preconditions are met. </p> <ul>
+<li id="GUID-AB16CE53-001A-51C9-B6EE-CDCC74B034A6"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-B0F8E686-A86D-5A99-8560-7D591CE84BD0">Calling thread must be in a critical section</xref>  </p> </li>
+<li id="GUID-2EC96768-6346-50E1-BA85-81F0D27444BE"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-3EE55520-0F0D-508B-A384-55082ED10D72">Calling thread must not be in a critical section</xref>  </p> </li>
+<li id="GUID-AACA75DB-5494-536B-ABF5-CA3ACF5351D6"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-09CB97CE-8DAF-58FA-B240-5B396ABC9614">Calling thread can either be in a critical section or not</xref>  </p> </li>
+<li id="GUID-88BB1943-77A6-5AA1-805A-FADF0C56880F"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-EDA4EF5D-B6CB-5446-AEBD-A9888C86FBA1">No fast mutex can be held</xref>  </p> </li>
+<li id="GUID-C683D62F-7918-54C6-A184-32A2B64F9D58"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-B6943D58-99B9-5A4B-A1DD-577B6197F274">Kernel must be locked</xref>  </p> </li>
+<li id="GUID-668F8DB9-5FB1-5DC3-B1F2-4BD9C3F5B4F9"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-8027AB9A-858F-5945-A75B-E817AD76DEC3">Kernel must be unlocked</xref>  </p> </li>
+<li id="GUID-0B48309C-E7C9-5857-BA1F-731D69E73118"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-F80292D9-E3C8-5466-ABD3-0416CDE2BD00">Kernel can be locked or unlocked</xref>  </p> </li>
+<li id="GUID-7F1C7BE6-1B5E-5800-8B9F-30279A24727E"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-EC063E55-66F7-52E9-AF47-F981B63E446E">Kernel must be locked, with lock count 1</xref>  </p> </li>
+<li id="GUID-8AEFABE4-320E-5AF8-89F8-6402EE9BBCE6"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-A55086AA-382B-5F93-9CE0-42C6FB428A19">Interrupts must be enabled</xref>  </p> </li>
+<li id="GUID-B56F2B78-49D8-5B51-BA27-F8BC07DA948C"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-9384C08B-D56F-5284-BA4B-4CF6C85E06E4">Interrupts must be disabled</xref>  </p> </li>
+<li id="GUID-8113FADD-4E41-5589-9CBD-3B63B9231A19"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-E1A36F24-AC68-58AF-B344-A59111F621FA">Interrupts can either be enabled or disabled</xref>  </p> </li>
+<li id="GUID-C8FF141B-C104-5B4A-9F3C-7857B20ABEC1"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-1E584D23-5233-5A38-A629-FBFE834F8248">System lock must be held</xref>  </p> </li>
+<li id="GUID-43383A78-182B-5F42-8458-FAD5DB768ACB"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-74F93316-0DAC-5F4F-A307-C0C15B14E794">System lock must not be held</xref>  </p> </li>
+<li id="GUID-AB5BDF10-F90A-5ECB-AF56-FE4A06038271"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-BA42435C-85B9-5A86-B875-50FE69B99B48">Call in a thread context</xref>  </p> </li>
+<li id="GUID-BBE5C5FC-9497-5FEB-8FCF-B43F0800FBBF"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-3FE5AA98-FD6C-528D-9DF2-7C50BE7FEF8E">Call in an IDFC contex</xref>  </p> </li>
+<li id="GUID-102DFFA4-D584-54D0-BF4A-FB5CC3F622BB"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-6957D624-5176-591C-A667-4DF78B29F271">Call either in a thread or an IDFC context</xref>  </p> </li>
+<li id="GUID-2530C61A-5997-5BB8-B7BC-E249F2C32A6C"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-A45A1D39-8C76-5E14-8DCF-FCE0A26758CE">Call in any context</xref>  </p> </li>
+<li id="GUID-0FFD6392-52C4-5403-81A5-35ADC75B5A0A"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-0DCAE842-45E1-5F5F-BC68-121775D0B702">Do not call from an ISR</xref>  </p> </li>
+<li id="GUID-F018CCD9-7FEC-5CD7-A424-B4F1B874938D"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-F17D0FE5-BA42-575B-8971-C5B034CF404E">The calling thread must own the semaphore</xref>  </p> </li>
+<li id="GUID-A9B993F9-A833-56CE-A3AE-D7CBF749A002"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-8D9D08F5-0CBD-52BB-B416-636516982D47">The calling thread must not be explicitly suspended</xref>  </p> </li>
+<li id="GUID-561FCAEF-10F5-52A0-B84D-0B10C6E6F051"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-910660F9-F30F-5725-981D-52F65F7FDB81">The calling thread must hold the mutex</xref>  </p> </li>
+<li id="GUID-F20B2CE8-975E-55FE-9994-7920E106209B"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-DDEB4D47-04F5-5736-A8BE-3F1AC543F9D7">Call only from ISR, IDFC or thread with the kernel locked</xref>  </p> </li>
+<li id="GUID-AB365D33-E6D5-544C-8A85-13635F7D8A46"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-3D8578BC-86EE-5E64-9C1E-CCD512A344D1">Call only from IDFC or thread with the kernel locked</xref>  </p> </li>
+<li id="GUID-DDDF61AA-0B7B-5862-B854-A776F5375D3E"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-2147A0B6-365A-5AC3-8EBE-AC0D89ED0C70">Do not call from thread with the kernel unlocked</xref>  </p> </li>
+<li id="GUID-416323F1-316F-5F91-9210-5B7B02D5214A"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-7E26E475-5D7E-5C68-B3A4-BC9EC6D29D98">Do not call from ISR or thread with the kernel unlocked</xref>  </p> </li>
+<li id="GUID-107003E0-BBAF-5408-AEE8-6B285A2D44D6"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-6C17250C-4FD0-5A2E-B448-BC08504F4FE4">Thread must not already be exiting</xref>  </p> </li>
+<li id="GUID-7598A74D-A7C3-544A-A856-A95639CC874B"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-021E54DB-7F22-5ADB-A80D-CAFBB08596A2">Property has not been opened</xref>  </p> </li>
+<li id="GUID-F8900E2C-BB1C-547F-8945-269D8FCE6D99"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-D924E37C-300A-58FF-890B-F1FA5349FA05">Property has been opened</xref>  </p> </li>
+<li id="GUID-DFDC1EB0-72CE-5C6D-BDBB-69160E8D6CFD"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-F1485BCB-8384-518B-AE5B-F8387DF0C8F4">Must be called under an XTRAP harness or calling thread must not be in a
+critical section</xref>  </p> </li>
+<li id="GUID-0E1D40B1-C88B-5EE8-BDB7-A5897900444F"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-4D6B9502-0F88-5E0E-8E92-5783FE76555A">DObject::Lock fast mutex held</xref>  </p> </li>
+<li id="GUID-E766DB63-A091-5577-8FA3-6AC8D3E36A4E"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-D6BB3BE3-E0DD-50B9-B9D1-275E51CE7FC6">DCodeSeg::CodeSegLock mutex held</xref>  </p> </li>
+<li id="GUID-8DCD023D-BC60-5FCE-B3E2-FB9BD98360C2"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-9A82D0DD-7599-5511-AD9E-2930ADC99AC0">Any kind of lock can be held</xref>  </p> </li>
+<li id="GUID-66EB3E8B-19F1-5189-A029-1AF10FCCE787"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-F9800056-B5E5-576D-B440-544AE067D4DC">Call only from Init1() in base port</xref>  </p> </li>
+<li id="GUID-83F3A08D-0A58-58C3-99C0-AC976FC376C6"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-6122C9C6-05EB-508C-8C9A-45B6A8DAB42C">The various parameters must be valid. The PIL or PSL will fault the kernel
+if not</xref>  </p> </li>
+<li id="GUID-E6325367-1F64-53AF-B992-D94DC7FD88A5"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-041025B4-95B9-5493-ACC3-649B6683DE0D">The request is not being transferred or pending</xref>  </p> </li>
+<li id="GUID-CB33058C-50D1-520B-BB5B-FA723301367F"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-582E833B-C0E9-5986-86C5-24BF15648D61">Wait on TimerMutex before calling this</xref>  </p> </li>
+<li id="GUID-A42C4B9A-6B96-51A7-952C-DD3905307B7C"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-98CBADF3-8CD3-54BC-8CB7-C2BD8D48289A">Message must be in ACCEPTED state</xref>  </p> </li>
+<li id="GUID-736AEF0F-17DB-5DF4-9236-51D32F51291D"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-B9E940EF-0EC8-5EEB-B29B-B402BFF09350">Queue must not be in asynchronous receive mode</xref>  </p> </li>
+<li id="GUID-253F522F-B0BF-5EBC-8EE9-F312807BC432"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-52D720FB-7F57-5340-8C34-F39FE1E50C36">Container mutex must be held</xref>  </p> </li>
+<li id="GUID-CBE2383B-2861-50F3-BEE5-0AEDCFEF2AFA"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-52D720FB-7F57-5340-8C34-F39FE1E50C36">Thread container mutex must be held</xref>  </p> </li>
+<li id="GUID-3E90CD26-6578-5FE2-904C-8C2E648267F0"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-52D720FB-7F57-5340-8C34-F39FE1E50C36">Process container mutex must be held</xref>  </p> </li>
+</ul> <p id="GUID-B0F8E686-A86D-5A99-8560-7D591CE84BD0"><b>Calling thread must be in
+a critical section</b> </p> <p>Critical sections are sections of code that
+leave the kernel in a compromised state if they cannot complete. A thread
+enters a critical section by calling <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-841D587C-E9E6-34EE-8ED0-E9A206F64379"><apiname>NKern::ThreadEnterCS()</apiname></xref> and
+leaves it by calling <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-2C897BA5-2BD7-3ABA-9F2B-F0B1AC14D1AE"><apiname>NKern::ThreadLeaveCS()</apiname></xref>. </p> <p>While
+in a critical section, the thread cannot be suspended or killed. These actions
+are deferred until the end of the critical section. If a thread takes an exception
+while inside a critical section, this is treated as fatal to the system, and
+cause a <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-45337A03-5893-3D0D-948C-23BDCF8AECBD"><apiname>Kern::Fault()</apiname></xref>. </p> <p>The described function must
+be in a critical section when called. </p> <p id="GUID-3EE55520-0F0D-508B-A384-55082ED10D72"><b>Calling thread must not
+be in a critical section</b> </p> <p>Critical sections are sections of code
+that leave the kernel in a compromised state if they cannot complete. A thread
+enters a critical section by calling <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-841D587C-E9E6-34EE-8ED0-E9A206F64379"><apiname>NKern::ThreadEnterCS()</apiname></xref> and
+leaves it by calling <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-2C897BA5-2BD7-3ABA-9F2B-F0B1AC14D1AE"><apiname>NKern::ThreadLeaveCS()</apiname></xref>. </p> <p>While
+in a critical section, the thread cannot be suspended or killed. These actions
+are deferred until the end of the critical section. If a thread takes an exception
+while inside a critical section, this is treated as fatal to the system, and
+cause a <codeph>Kern::Fault()</codeph>. </p> <p>There are some functions winthin
+the system that must <i>NOT</i> be in a critical section when called. This
+applies to the described functions. </p> <p id="GUID-09CB97CE-8DAF-58FA-B240-5B396ABC9614"><b>Calling thread can either
+be in a critical section or not</b> </p> <p>Critical sections are sections
+of code that leave the kernel in a compromised state if they cannot complete.
+A thread enters a critical section by calling <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-841D587C-E9E6-34EE-8ED0-E9A206F64379"><apiname>NKern::ThreadEnterCS()</apiname></xref> and
+leaves it by calling <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-2C897BA5-2BD7-3ABA-9F2B-F0B1AC14D1AE"><apiname>NKern::ThreadLeaveCS()</apiname></xref>. </p> <p>While
+in a critical section, the thread cannot be suspended or killed. These actions
+are deferred until the end of the critical section. If a thread takes an exception
+while inside a critical section, this is treated as fatal to the system, and
+cause a <codeph>Kern::Fault()</codeph>. </p> <p>When this pre-condition applies
+to the described function, it means that it does not matter whether the code
+is in a critical section or not. </p> <p id="GUID-EDA4EF5D-B6CB-5446-AEBD-A9888C86FBA1"><b>No fast mutex can be held</b> </p> <p>A
+thread can hold no more than one fast mutex at any given time. The described
+function uses a fast mutex, which means that on entry to the function, the
+calling thread must <i>not</i> hold another one. </p> <p id="GUID-B6943D58-99B9-5A4B-A1DD-577B6197F274"><b>Kernel must be locked</b> </p> <p>Many
+kernel side functions run with interrupts enabled, including code that manipulates
+global structures, such as the thread ready list. To prevent such code from
+being reentered and potentially corrupting the structure concerned, a lock
+known as the kernel lock (sometimes referred to as the preemption lock) is
+used. </p> <p>Sections of code that need to be protected against rescheduling
+call <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-7CBBF72B-4519-38DD-92CA-38AF636AFD8A"><apiname>NKern::Lock()</apiname></xref>. Interrupt Service Routines (ISRs) can
+still run but no other thread (or IDFC) can run until the kernel is unlocked
+by a call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-A1A42137-906C-30F1-AF61-4F786FC372DE"><apiname>NKern::Unlock()</apiname></xref>. </p> <p>The pre-condition
+means that the kernel lock must be set before calling the described function. </p> <p id="GUID-8027AB9A-858F-5945-A75B-E817AD76DEC3"><b>Kernel must be unlocked</b> </p> <p>Many
+kernel side functions run with interrupts enabled, including code that manipulates
+global structures, such as the thread ready list. To prevent such code from
+being reentered and potentially corrupting the structure concerned, a lock
+known as the kernel lock (sometimes referred to as the preemption lock) is
+used. </p> <p>Sections of code that need to be protected against rescheduling
+call <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-7CBBF72B-4519-38DD-92CA-38AF636AFD8A"><apiname>NKern::Lock()</apiname></xref>. Interrupt Service Routines (ISRs) can
+still run but no other thread (or IDFC) can run until the kernel is unlocked
+by a call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-A1A42137-906C-30F1-AF61-4F786FC372DE"><apiname>NKern::Unlock()</apiname></xref>. </p> <p>The pre-condition
+means that the kernel lock must <i>NOT</i> be set when the described function
+is called. </p> <p id="GUID-F80292D9-E3C8-5466-ABD3-0416CDE2BD00"><b>Kernel can be locked or
+unlocked</b> </p> <p>Many kernel side functions run with interrupts enabled,
+including code that manipulates global structures, such as the thread ready
+list. To prevent such code from being reentered and potentially corrupting
+the structure concerned, a lock known as the kernel lock (sometimes referred
+to as the preemption lock) is used. </p> <p>Sections of code that need to
+be protected against rescheduling call <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-7CBBF72B-4519-38DD-92CA-38AF636AFD8A"><apiname>NKern::Lock()</apiname></xref>. Interrupt
+Service Routines (ISRs) can still run but no other thread (or IDFC) can run
+until the kernel is unlocked by a call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-A1A42137-906C-30F1-AF61-4F786FC372DE"><apiname>NKern::Unlock()</apiname></xref>. </p> <p>The
+pre-condition means that it does not matter whether the kernel lock is set
+or unset when the described function is called. </p> <p id="GUID-EC063E55-66F7-52E9-AF47-F981B63E446E"><b>Kernel must be locked, with
+lock count 1</b> </p> <p>Many kernel side functions run with interrupts enabled,
+including code that manipulates global structures, such as the thread ready
+list. To prevent such code from being reentered and potentially corrupting
+the structure concerned, a lock known as the kernel lock (sometimes referred
+to as the preemption lock) is used. </p> <p>Sections of code that need to
+be protected against rescheduling call <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-7CBBF72B-4519-38DD-92CA-38AF636AFD8A"><apiname>NKern::Lock()</apiname></xref>. Interrupt
+Service Routines (ISRs) can still run but no other thread (or IDFC) can run
+until the kernel is unlocked by a call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-A1A42137-906C-30F1-AF61-4F786FC372DE"><apiname>NKern::Unlock()</apiname></xref>. </p> <p>In
+addition, calls to <codeph>NKern::Lock()</codeph> and <codeph>NKern::Unlock()</codeph> are
+counted. The count value is zero when the kernel is unlocked; a call to <codeph>NKern::Lock()</codeph> adds
+one to the count value, and a call to <codeph>NKern::Unlock()</codeph> subtracts
+one from the count value. </p> <p>The pre-condition means that there must
+be exactly one call to <codeph>Kern::Lock()</codeph> that has not yet had
+a matching call to <codeph>Kern::Unlock()</codeph>. </p> <p>See also <xref href="GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953.dita#GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953/GUID-76E5AE32-9A70-344A-9E6B-5B439622715A"><apiname>NFastMutex::Wait()</apiname></xref>. </p> <p id="GUID-A55086AA-382B-5F93-9CE0-42C6FB428A19"><b>Interrupts must be enabled</b> </p> <p>This
+pre-condition states that interrupts must be enabled before calling the described
+function. </p> <p>Possible reasons why interrupts may need to be enabled include: </p> <ul>
+<li id="GUID-B3D25D93-BDBA-5CFB-98ED-78A4BEF95DF0"><p>the function needs interrupts
+to occur; for example, it may wait for timer ticks. </p> </li>
+<li id="GUID-1B806059-76C7-5C0F-ADAA-84134217C5A2"><p>the function may take
+a long or potentially unbounded time to run, so interrupts need to be enabled
+to guarantee bounded interrupt latency. </p> </li>
+</ul> <p>See also the function <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-2D328082-3A9F-3467-81CF-B1C68866E163"><apiname>NKern::RestoreInterrupts()</apiname></xref> and
+the associated function <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-CA1C36B7-02EE-31D5-B700-27DE4769ECCF"><apiname>NKern::DisableInterrupts()</apiname></xref>. </p> <p id="GUID-9384C08B-D56F-5284-BA4B-4CF6C85E06E4"><b>Interrupts must be disabled</b> </p> <p>This
+pre-condition states that interrupts must be disabled before calling the described
+function. </p> <p>See also the function <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-CA1C36B7-02EE-31D5-B700-27DE4769ECCF"><apiname>NKern::DisableInterrupts()</apiname></xref> and
+the associated function <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-2D328082-3A9F-3467-81CF-B1C68866E163"><apiname>NKern::RestoreInterrupts()</apiname></xref>. </p> <p id="GUID-E1A36F24-AC68-58AF-B344-A59111F621FA"><b>Interrupts can either be
+enabled or disabled</b> </p> <p>This pre-condition states that it does not
+matter whether interrupts are enabled or disabled before calling the described
+function. </p> <p id="GUID-1E584D23-5233-5A38-A629-FBFE834F8248"><b>System lock must be held</b> </p> <p>The
+system lock is a specific fast mutex that only provides exclusion against
+other threads acquiring the same fast mutex. Setting, and acquiring the system
+lock means that a thread enters an implied critical section. </p> <p>The major
+items protected by the system lock are: </p> <ul>
+<li id="GUID-B5FDF231-881B-5F4C-9FC1-256647FA502A"><p> <codeph>DThread</codeph> member
+data related to thread priority and status. </p> </li>
+<li id="GUID-E583EC5A-3572-5E83-9B73-724B63853D52"><p>the consistency of the
+memory map; on the kernel side, the state of user side memory or the mapping
+of a process is not guaranteed unless (a) you are a thread belonging to the
+process that owns the memory or (b) you hold the system lock. </p> </li>
+<li id="GUID-B65EFDDA-6327-5F6C-91D5-F9C703E1B109"><p>the lifetime of <codeph>DObject</codeph> type
+objects and references to them, including handle translation in Exec dispatch. </p> </li>
+</ul> <p>Note that the system lock is different from the kernel lock; the
+kernel lock protects against any rescheduling. When the system lock is set,
+the calling thread can still be pre-empted, even in the locked section. </p> <p>The
+system lock is set by a call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-B3837744-B8CC-3DC0-BA1D-417016E88EE9"><apiname>NKern::LockSystem()</apiname></xref>. </p> <p>The
+pre-condition means that the system lock must be set before calling the described
+function. </p> <p id="GUID-74F93316-0DAC-5F4F-A307-C0C15B14E794"><b>System lock must not be
+held</b> </p> <p>See the pre-condition <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-1E584D23-5233-5A38-A629-FBFE834F8248">System
+lock must be held</xref> for a brief description of the system lock. </p> <p>The
+system lock is unset by a call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-63B882C8-C5D0-3595-BBF1-74E942A5060A"><apiname>NKern::UnlockSystem()</apiname></xref>. </p> <p>The
+pre-condition means that the system lock must not be set before calling the
+described function. </p> <p id="GUID-BA42435C-85B9-5A86-B875-50FE69B99B48"><b>Call in a thread context</b> </p> <p>This
+pre-condition means that the described function must be called directly, or
+indirectly, from a DFC or a thread. The thread can be a user thread or a kernel
+thread. </p> <p id="GUID-3FE5AA98-FD6C-528D-9DF2-7C50BE7FEF8E"><b>Call in an IDFC contex</b> </p> <p>This
+pre-condition means that the described function must be called directly, or
+indirectly, from an IDFC. </p> <p>Note that when calling a function from an
+IDFC: </p> <ul>
+<li id="GUID-2935ED8F-A340-5718-944C-56B2A8404D95"><p>the kernel is locked,
+so pre-emption is disabled </p> </li>
+<li id="GUID-ECCD22D2-9504-57EA-9245-5BD071B84694"><p>user memory cannot be
+accessed </p> </li>
+<li id="GUID-35C14F6F-EAFF-549A-BA2B-7EF5F2B6D093"><p>the function cannot
+block or wait. </p> </li>
+</ul> <p id="GUID-6957D624-5176-591C-A667-4DF78B29F271"><b>Call either in a thread
+or an IDFC context</b> </p> <p>This pre-condition means that the described
+function can be called directly, or indirectly, from an IDFC, a DFC or a thread.
+The thread can be a user thread or a kernel thread. </p> <p>Note that when
+calling a function from an IDFC: </p> <ul>
+<li id="GUID-7B6B2A5B-D282-529E-9D6B-7B1E2EC0BE0F"><p>the kernel is locked,
+so pre-emption is disabled </p> </li>
+<li id="GUID-BDEA9088-1340-59C9-B94F-848AF530F55A"><p>user memory cannot be
+accessed </p> </li>
+<li id="GUID-2073105B-FFE9-57C0-AB9D-3D3459BCED16"><p>the function cannot
+block or wait. </p> </li>
+</ul> <p id="GUID-A45A1D39-8C76-5E14-8DCF-FCE0A26758CE"><b>Call in any context</b> </p> <p>This
+pre-condition means that the described function can be called directly, or
+indirectly, from an IDFC, a DFC or a thread, or it can be called from an Interrupt
+Service Routine (ISR). </p> <p>A thread can be a user thread or a kernel thread. </p> <p>Note
+that when calling a function from an IDFC: </p> <ul>
+<li id="GUID-4E80B3B7-BBBC-51F5-AC6D-996240416B29"><p>the kernel is locked,
+so pre-emption is disabled </p> </li>
+<li id="GUID-BCF8F1AA-2F70-54BC-9FB6-C5EDD9057C79"><p>user memory cannot be
+accessed </p> </li>
+<li id="GUID-A7B6B42D-0FDB-589E-860B-F2D1D8892BC7"><p>the function cannot
+block or wait. </p> </li>
+</ul> <p id="GUID-0DCAE842-45E1-5F5F-BC68-121775D0B702"><b>Do not call from an ISR</b> </p> <p>This
+pre-condition means that the described function must not be called from an
+Interrupt Service Routine (ISR). </p> <p>Note that ISRs have the following
+characteristics: </p> <ul>
+<li id="GUID-D773586B-422C-5B03-8588-1A24058A5DD1"><p>they have an unknown
+context </p> </li>
+<li id="GUID-3BACC342-0768-5D2F-BE53-58C33B74C392"><p>they must not allocate
+or free memory </p> </li>
+<li id="GUID-DE919B78-9516-5F3D-98B2-3A99D8C3EE15"><p>they cannot access user
+memory </p> </li>
+<li id="GUID-04AFFA6E-C742-5068-81B7-AFEA47422763"><p>they must not call functions
+that interfere with critical sections of code. </p> </li>
+</ul> <p id="GUID-F17D0FE5-BA42-575B-8971-C5B034CF404E"><b>The calling thread must
+own the semaphore</b> </p> <p>A semaphore can be waited on only by the thread
+that owns it. This precondition is needed when the described function calls
+a semaphore wait function. </p> <p id="GUID-8D9D08F5-0CBD-52BB-B416-636516982D47"><b>The calling thread must
+not be explicitly suspended</b> </p> <p>This refers to nanokernel threads,
+not Symbian platform threads. The described function must not be used if the
+thread is in the suspended state. One of the possible reasons for this is
+that the described function does not check the thread's suspend count. </p> <p>A
+thread may be created suspended, or the thread may be put into a suspended
+state using <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita#GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC/GUID-FF94D458-C2D0-3D20-ADD6-AAE68A3296C3"><apiname>NThreadBase::Suspend()</apiname></xref>. If you don't know whether
+or not the thread is suspended, use <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita#GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC/GUID-82E43D79-721D-31A9-B9ED-1277F2300914"><apiname>NThreadBase::CheckSuspendThenReady()</apiname></xref>. </p> <p>See
+also <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita#GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC/GUID-C0A6E734-7DE6-37B9-AAB2-A2A0E2664731"><apiname>NThreadBase::Resume()</apiname></xref> and <xref href="GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC.dita#GUID-379D9320-AC3C-3206-8A5D-EE6E5983EBDC/GUID-BE92FBC3-A7D9-3576-A1A9-7BBA6EE64226"><apiname>NThreadBase::ForceResume()</apiname></xref>. </p> <p> <i>Note
+that these functions are for use only in an RTOS personality layer.</i>  </p> <p id="GUID-910660F9-F30F-5725-981D-52F65F7FDB81"><b>The calling thread must
+hold the mutex</b> </p> <p>The calling thread has waited for a mutex and acquired
+it. This precondition is needed when the thread is about to release the mutex,
+ie call one of the <codeph>Signal()</codeph> functions. </p> <p id="GUID-DDEB4D47-04F5-5736-A8BE-3F1AC543F9D7"><b>Call only from ISR, IDFC
+or thread with the kernel locked</b> </p> <p>See the pre-condition <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-B6943D58-99B9-5A4B-A1DD-577B6197F274">Kernel must be locked</xref>. </p> <p id="GUID-3D8578BC-86EE-5E64-9C1E-CCD512A344D1"><b>Call only from IDFC or thread
+with the kernel locked</b> </p> <p>See the pre-condition <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-B6943D58-99B9-5A4B-A1DD-577B6197F274">Kernel must be locked</xref>. </p> <p id="GUID-2147A0B6-365A-5AC3-8EBE-AC0D89ED0C70"><b>Do not call from thread
+with the kernel unlocked</b> </p> <p>See the pre-condition <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-8027AB9A-858F-5945-A75B-E817AD76DEC3">Kernel must be unlocked</xref>. </p> <p id="GUID-7E26E475-5D7E-5C68-B3A4-BC9EC6D29D98"><b>Do not call from ISR or
+thread with the kernel unlocked</b> </p> <p>See the pre-condition <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-8027AB9A-858F-5945-A75B-E817AD76DEC3">Kernel must be unlocked</xref>. </p> <p id="GUID-6C17250C-4FD0-5A2E-B448-BC08504F4FE4"><b>Thread must not already
+be exiting</b> </p> <p>The pre-condition means that the described function
+should not be called after the thread has been killed. </p> <p>In EKA2, threads
+do not die immediately, they are placed on a queue to be deleted later. </p> <p>Functions
+with this pre-condition are not likely to used in a device driver. </p> <p id="GUID-021E54DB-7F22-5ADB-A80D-CAFBB08596A2"><b>Property has not been opened</b> </p> <p>A
+property is a single value used by “Publish and Subscribe”. Each property
+must be opened before it can be used. To open a property, use either <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-DBEDDC3A-AE6F-3CAF-B251-4AA556EAF21C"><apiname>RPropertyRef::Attach()</apiname></xref> or <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-6F8EB0AB-C01A-3BFD-B334-D9C9FB923865"><apiname>RPropertyRef::Open()</apiname></xref>. Once opened, the property cannot be opened again. </p> <p>The pre-condition
+means that the property must <i>NOT</i> already be open when the described
+function is called. </p> <p id="GUID-D924E37C-300A-58FF-890B-F1FA5349FA05"><b>Property has been opened</b> </p> <p>A
+property is a single value used by “Publish and Subscribe”. Each property
+must be opened before it can be used. To open a property, use either <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-DBEDDC3A-AE6F-3CAF-B251-4AA556EAF21C"><apiname>RPropertyRef::Attach()</apiname></xref> or <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-6F8EB0AB-C01A-3BFD-B334-D9C9FB923865"><apiname>RPropertyRef::Open()</apiname></xref>. Once opened, the property cannot be opened again. </p> <p>The pre-condition
+means that the property must already be open before calling the described
+function. </p> <p id="GUID-F1485BCB-8384-518B-AE5B-F8387DF0C8F4"><b>Must be called under an
+XTRAP harness or calling thread must not be in a critical section</b> </p> <p>Each
+Symbian platform thread can be associated with a kernel-side
+exception handler, set using XTRAP(); for example, to detect bad memory accesses. </p> <p>The
+described function can legitimately cause an exception, and the pre-condition
+means that </p> <p> <i>either</i>: </p> <ul>
+<li id="GUID-485A8370-E3D5-5E67-9136-3150EC050DF0"><p>the described function
+should be called inside an XTRAP() harness to catch the exception </p> </li>
+</ul> <p> <i>or</i>  </p> <ul>
+<li id="GUID-BDF6FFE8-E447-5E3D-A809-364A0A515C33"><p>the thread must not
+be in a critical section, because exceptions are not allowed inside them.
+If a thread takes an exception while inside a critical section, this is treated
+as fatal to the system, and causes a <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-45337A03-5893-3D0D-948C-23BDCF8AECBD"><apiname>Kern::Fault()</apiname></xref>. </p> </li>
+</ul> <p id="GUID-4D6B9502-0F88-5E0E-8E92-5783FE76555A"><b>DObject::Lock fast mutex
+held</b> </p> <p>The described function accesses an object whose internal
+data needs to be protected by the specified fast mutex. </p> <p>The operations
+of: </p> <ul>
+<li id="GUID-B358DA23-F140-5F08-878F-69455A83A729"><p>obtaining an object’s
+name </p> </li>
+<li id="GUID-3838D839-5210-5FB7-AF0C-3F3C299AA7B8"><p>setting an object's
+name </p> </li>
+<li id="GUID-2AD3BEC1-E934-513B-BAED-3FF164161F2D"><p>setting an object's
+owner </p> </li>
+</ul> <p>are all protected by the global fast mutex, <codeph>DObject::Lock</codeph>.
+This is done to avoid inconsistent results caused by, for example, one thread
+renaming an object while another is reading its name or full name. </p> <p>Setting
+the owner is protected as the owner's name is part of the object's full name. </p> <p id="GUID-D6BB3BE3-E0DD-50B9-B9D1-275E51CE7FC6"><b>DCodeSeg::CodeSegLock mutex
+held</b> </p> <p>The <codeph>DCodeSeg::CodeSegLock</codeph> mutex protects
+the global code graph from simultaneous accesses. Wait on this mutex before
+calling the described function, e.g. by calling <codeph>DCodeSeg::Wait()</codeph>. </p> <p id="GUID-9A82D0DD-7599-5511-AD9E-2930ADC99AC0"><b>Any kind of lock can be
+held</b> </p> <p>The described function can be called with any kind of lock. </p> <p id="GUID-F9800056-B5E5-576D-B440-544AE067D4DC"><b>Call only from Init1() in
+base port</b> </p> <p>The pre-condition means that the described function
+can only be called during the first phase of kernel initialisation, i.e. during
+execution of the Base Port implementation of <codeph>Asic::Init1()</codeph>.
+See the <xref href="GUID-DEB51862-A72B-5FB7-B1BA-F34685E71BFF.dita">Board Support
+Packages Quick Start</xref>. </p> <p>This condition may apply because the
+described function: </p> <ul>
+<li id="GUID-62621625-D712-5F4C-B31D-067E5887D8FD"><p>must be called before
+any context switch </p> </li>
+<li id="GUID-FB33B022-A388-5508-9C98-33518154BBBA"><p>must be called before
+the MMU is turned on. </p> </li>
+</ul> <p id="GUID-6122C9C6-05EB-508C-8C9A-45B6A8DAB42C"><b>The various parameters must
+be valid. The PIL or PSL will fault the kernel if not</b> </p> <p>This pre-condition
+refers to a DMA request. </p> <p>The parameters used when calling the described
+function must be as specified. If they are not, the platform independent layer
+or the platform specific layer cannot recover and will cause the kernel to
+fault, i.e. the device will reset. </p> <p id="GUID-041025B4-95B9-5493-ACC3-649B6683DE0D"><b>The request is not being
+transferred or pending</b> </p> <p>This pre-condition refers to a DMA request. </p> <p>The
+described function must not be called if a DMA request has already been set
+up, or is in progress. A possible reason for this is that the described function
+resets parameters that have been already setup. </p> <p id="GUID-582E833B-C0E9-5986-86C5-24BF15648D61"><b>Wait on TimerMutex before
+calling this</b> </p> <p>The <codeph>TimerMutex</codeph> mutex protects the
+timer queues. Wait and signal operations on the timer mutex are accomplished
+with the static functions <xref href="GUID-68509286-C337-3ED1-9162-31507CC564E1.dita#GUID-68509286-C337-3ED1-9162-31507CC564E1/GUID-7E855355-3AC7-3449-B501-C387C4CBA3B9"><apiname>TTickQ::Wait()</apiname></xref> and <xref href="GUID-68509286-C337-3ED1-9162-31507CC564E1.dita#GUID-68509286-C337-3ED1-9162-31507CC564E1/GUID-36F604B8-EBE6-3ED1-B969-F2C4F0975036"><apiname>TTickQ::Signal()</apiname></xref>.
+This precondition is necessary when the described function manipulates the
+timer queue. </p> <p id="GUID-98CBADF3-8CD3-54BC-8CB7-C2BD8D48289A"><b>Message must be in ACCEPTED
+state</b> </p> <p>This pre-condition indicates that the message has been read
+by the receiving thread. It is not attached to a message queue but is currently
+in use by the receiving thread. </p> <p id="GUID-B9E940EF-0EC8-5EEB-B29B-B402BFF09350"><b>Queue must not be in asynchronous
+receive mode</b> </p> <p>This pre-condition refers to kernel side message
+queues. A kernel thread can receive messages: </p> <ul>
+<li id="GUID-4C36A2DD-3E27-507E-BB18-143AF8B210A2"><p>asynchronously by calling <xref href="GUID-382DD935-E9D7-3E00-88B2-B28A89CAD4FB.dita#GUID-382DD935-E9D7-3E00-88B2-B28A89CAD4FB/GUID-EF06556E-9EC6-3D1C-AEE9-0CDDF6B42A24"><apiname>TMessageQue::Receive()</apiname></xref>  </p> </li>
+<li id="GUID-BF8FB0AB-CA7F-5A02-BE61-43AECE226113"><p>by polling, by calling <xref href="GUID-D14B3E02-A9A4-37F8-9638-26C12BF5AFA8.dita#GUID-D14B3E02-A9A4-37F8-9638-26C12BF5AFA8/GUID-D2B157FB-FA55-3F27-A463-691B3B6C5570"><apiname>MessageQue::Poll()</apiname></xref>  </p> </li>
+</ul> <p>A possible reason for this precondition is that the queue is about
+to be polled. </p> <p>The queue may be polled either: </p> <ul>
+<li id="GUID-FD59C03B-1B65-52F6-A1C6-177D48D4CFC2"><p>before the first <codeph>Receive()</codeph> is
+issued </p> </li>
+<li id="GUID-7551CDCD-67B1-5A1A-B1AA-5F95CF63EBD4"><p>while processing a message
+but before <codeph>Receive()</codeph> is called again </p> </li>
+</ul> <p id="GUID-52D720FB-7F57-5340-8C34-F39FE1E50C36"><b>Container mutex must be
+held / Thread container mutex must be held / Process container mutex must
+be held</b> </p> <p>Each of the containers is protected by a mutex. </p> <p>The
+pre-condition means that the calling thread must acquire the relevant mutex
+before calling the described function. Object containers are <xref href="GUID-7FB9067F-D200-382C-84F7-49F0548D0A7F.dita"><apiname>DObjectCon</apiname></xref> types,
+and the relevant mutexes are acquired and freed by calling <codeph>Wait()</codeph> and <codeph>Signal()</codeph> on
+the container object. </p> </section>
+<section id="GUID-F2DE76D5-0970-584F-9526-52E85932ACE8"><title>Post-conditions</title> <p>A
+post condition describes what is true on return from a kernel API function. </p> <ul>
+<li id="GUID-018783B2-3BA2-5046-B9EA-7F2CF1485839"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-BCA4F419-3306-5AB4-AA78-451FDA60BB22">Calling thread is in a critical section</xref>  </p> </li>
+<li id="GUID-DCB3FFD2-054D-5F14-B846-FE5A00E13756"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-24DFFB87-639C-5D68-BCA0-D78AE870C485">Calling thread is not in a critical section</xref>  </p> </li>
+<li id="GUID-8E6C6BCD-C1A5-5433-A0D9-A86962A47A1F"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-47393215-B2A5-5426-A0B6-CDB617218B7D">No fast mutex is held</xref>  </p> </li>
+<li id="GUID-3A44F461-F5D6-5E50-9951-4DD97396602B"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-ECEA91E4-EB90-57AE-997E-4C8A95C3C337">Kernel is locked</xref>  </p> </li>
+<li id="GUID-DE72541B-3AE6-5F23-A431-8CBDFB92BB81"><p><xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-7A7AC948-D84D-5581-80CE-328F1C6DA89E">Kernel is unlocked</xref></p> </li>
+<li id="GUID-CFA7FF52-E930-5074-BABF-5F1148FA9513"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-B7FAE304-FF14-5A43-9ECB-DAD6F33DFDEE">Kernel is locked, with lock count 1</xref>  </p> </li>
+<li id="GUID-208AEF9F-3BF5-59B9-A090-9B53BD4A72F1"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-B811C561-CAB3-5B91-9C31-38A228734F46">Interrupts are enabled</xref>  </p> </li>
+<li id="GUID-CD794794-94D9-53B8-A96B-C78D6EE274D5"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-298793D0-D6E0-5FE3-84DF-FE0057E83B31">Interrupts are disabled</xref>  </p> </li>
+<li id="GUID-1588AEB8-3B08-5659-8B93-DB0F60F038B2"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-236D2CCB-1A32-5B30-A28D-96A9416A62A1">System lock is held</xref>  </p> </li>
+<li id="GUID-36D4EC99-5BA4-5510-B15C-DB37BC19D26C"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-53E54EE1-92BF-5E68-8FE4-43EB0AC84F8B">The calling thread holds the mutex</xref>  </p> </li>
+<li id="GUID-FF5097D1-680A-578F-A67A-031151D1BE7A"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-C293EDE0-B326-54A2-AB4F-17E9158B67AC">Container mutex is held</xref>  </p> </li>
+<li id="GUID-BA3DFAFE-8CAF-567D-B9D3-144DA8AABBAE"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-C293EDE0-B326-54A2-AB4F-17E9158B67AC">Thread container mutex is held</xref>  </p> </li>
+<li id="GUID-343FA4B5-9217-5152-BD23-E3BCDACD7E56"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-C293EDE0-B326-54A2-AB4F-17E9158B67AC">Process container mutex is held</xref>  </p> </li>
+<li id="GUID-1514A5FA-1B49-5C4A-BC47-36D008282C8D"><p> <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-A5EED271-3A9C-5373-BC84-66546DE4DDD9">DCodeSeg::CodeSegLock mutex held</xref>  </p> </li>
+</ul> <p id="GUID-BCA4F419-3306-5AB4-AA78-451FDA60BB22"><b>Calling thread is in a critical
+section</b> </p> <p>The code is in a critical section on return from the function. </p> <p>See
+also the pre-condition: <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-B0F8E686-A86D-5A99-8560-7D591CE84BD0">Calling
+thread must be in a critical section</xref>. </p> <p id="GUID-24DFFB87-639C-5D68-BCA0-D78AE870C485"><b>Calling thread is not in
+a critical section</b> </p> <p>The code is <i>NOT</i> in a critical section
+on return from the function. </p> <p>See also the pre-condition: <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-3EE55520-0F0D-508B-A384-55082ED10D72">Calling thread must not be in a critical section</xref>. </p> <p id="GUID-47393215-B2A5-5426-A0B6-CDB617218B7D"><b>No fast mutex is held</b> </p> <p>A
+thread can hold no more than one fast mutex at any given time. A fast mutex
+is <i>NOT</i> held on exit from the function. </p> <p id="GUID-ECEA91E4-EB90-57AE-997E-4C8A95C3C337"><b>Kernel is locked</b> </p> <p>The
+post-condition means that, on exit from the described function, the kernel
+lock is on. The described function might have explicitly set the kernel lock
+or, more commonly, the lock was set before entry to the described function,
+and has not been unset by that function. </p> <p>See also the pre-condition <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-B6943D58-99B9-5A4B-A1DD-577B6197F274">Kernel
+must be locked</xref>. </p> <p id="GUID-7A7AC948-D84D-5581-80CE-328F1C6DA89E"><b>Kernel is unlocked</b> </p> <p>The
+kernel is <i>NOT</i> locked on exit from the described function. The described
+function might have explicitly unset the kernel lock or, more commonly, the
+lock was not set before entry to the described function, and has not been
+set by that function. </p> <p>See also the pre-condition <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-8027AB9A-858F-5945-A75B-E817AD76DEC3">Kernel must be unlocked</xref>. </p> <p id="GUID-B7FAE304-FF14-5A43-9ECB-DAD6F33DFDEE"><b>Kernel is locked, with lock
+count 1</b> </p> <p>See the pre-condition <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-EC063E55-66F7-52E9-AF47-F981B63E446E">Kernel
+must be locked, with lock count 1</xref>. </p> <p id="GUID-B811C561-CAB3-5B91-9C31-38A228734F46"><b>Interrupts are enabled</b> </p> <p>This
+post-condition states that interrupts are enabled on return from the described
+function. </p> <p>See the pre-condition <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-A55086AA-382B-5F93-9CE0-42C6FB428A19">Interrupts
+must be enabled</xref>  </p> <p id="GUID-298793D0-D6E0-5FE3-84DF-FE0057E83B31"><b>Interrupts are disabled</b> </p> <p>This
+post-condition states that interrupts are disabled on return from the described
+function. </p> <p>See the pre-condition <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-9384C08B-D56F-5284-BA4B-4CF6C85E06E4">Interrupts
+must be disabled</xref>  </p> <p id="GUID-236D2CCB-1A32-5B30-A28D-96A9416A62A1"><b>System lock is held</b> </p> <p>This
+post-condition states that the system lock is held on return from the described
+function. </p> <p>The system lock is a specific fast mutex that only provides
+exclusion against other threads acquiring the same fast mutex. Setting, and
+acquiring the system lock means that a thread enters an implied critical section. </p> <p>The
+major items protected by the system lock are: </p> <ul>
+<li id="GUID-63E77673-0405-5E59-8102-67454FF96D1C"><p> <codeph>DThread</codeph> member
+data related to thread priority and status. </p> </li>
+<li id="GUID-3A37E1EF-89CF-50DA-B4B4-174A3B307873"><p>the consistency of the
+memory map; on the kernel side, the state of user side memory or the mapping
+of a process is not guaranteed unless (a) you are a thread belonging to the
+process that owns the memory or (b) you hold the system lock. </p> </li>
+<li id="GUID-D25EE56D-2FF5-515A-B826-08331B16C72E"><p>the lifetime of <codeph>DObject</codeph> type
+objects and references to them, including handle translation in Exec dispatch. </p> </li>
+</ul> <p><note> System lock is different from the kernel lock; the kernel
+lock protects against any rescheduling. When the system lock is set, the calling
+thread can still be pre-empted, even in the locked section.</note> </p> <p>The
+system lock is set by a call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-B3837744-B8CC-3DC0-BA1D-417016E88EE9"><apiname>NKern::LockSystem()</apiname></xref>, and
+unset by call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-63B882C8-C5D0-3595-BBF1-74E942A5060A"><apiname>NKern::UnlockSystem()</apiname></xref>. </p> <p id="GUID-53E54EE1-92BF-5E68-8FE4-43EB0AC84F8B"><b>The calling thread holds
+the mutex</b> </p> <p>The calling thread has waited for a mutex and acquired
+it. On return from the described function, the thread still holds the mutex. </p> <p>See
+also the pre-condition <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-910660F9-F30F-5725-981D-52F65F7FDB81">The
+calling thread must hold the mutex</xref>. </p> <p id="GUID-C293EDE0-B326-54A2-AB4F-17E9158B67AC"><b>Container mutex is held
+/ Thread container mutex is held / Process container mutex is held</b> </p> <p>Each
+of the containers is protected by a mutex. </p> <p>The post-condition means
+that the calling thread has the relevant mutex on return from the described
+function. This is most likely because the mutex was acquired before entering
+the described function. </p> <p>Object containers are <xref href="GUID-7FB9067F-D200-382C-84F7-49F0548D0A7F.dita"><apiname>DObjectCon</apiname></xref> types,
+and the relevant mutexes are acquired and freed by calling <codeph>Wait()</codeph> and <codeph>Signal()</codeph> on
+the container object. </p> <p id="GUID-A5EED271-3A9C-5373-BC84-66546DE4DDD9"><b>DCodeSeg::CodeSegLock mutex
+held</b> </p> <p>The <codeph>DCodeSeg::CodeSegLock</codeph> mutex protects
+the global code graph from simultaneous accesses. </p> <p>This post condition
+means that the mutex is held on exit. The most common situation is that the
+mutex was acquired before entry to the described function. Relinquish the
+mutex by calling <codeph>DCodeSeg::Signal()</codeph>. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6381BC82-3060-5023-8221-79B18CCB2CDB.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6381BC82-3060-5023-8221-79B18CCB2CDB" xml:lang="en"><title>Writable Data
+Paging Guides</title><shortdesc>Contains guides that describe various aspects of writable data
+paging in more detail. </shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-63CDD34D-936A-459C-B40B-495696204722.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,148 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-63CDD34D-936A-459C-B40B-495696204722" xml:lang="en"><title>Baseport Template Quick Start</title><shortdesc>This document describes how to get started with the Baseport
+Template and also, briefly explains the baseport architecture.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Baseport Template is the most important part of the system,
+since it consists of the kernel and essential peripherals.</p>
+<section id="GUID-3802B8EE-3ED9-4B8B-B1EB-D2AFBDE6F463"><title>Getting
+started with the Baseport Template</title><p>The <xref href="GUID-D7D7615F-B67D-44D0-82DF-24853159A114.dita">Baseport Template
+Client Interface Guide</xref> describes the Baseport
+Template APIs.</p><p>The <xref href="GUID-AE486C82-8854-463F-8CB9-B7353D6B2804.dita">Baseport Template
+Build Guide</xref> section describes how to build the Baseport Template
+platform service.</p><p>The <xref href="GUID-10FD1B94-EC0C-458F-839F-B60A8E47BAD6.dita">Baseport Template
+Configuration Guide</xref> section describes how to configure the
+Baseport Template platform service.</p><p>The <xref href="GUID-627FC480-AF4F-4B23-8671-6E0A0DABA0EF.dita">Baseport Template
+Testing Guide</xref> section describes how to test the Baseport Template
+platform service.</p><p>The <xref href="GUID-37B8243E-027A-49D0-A896-27946DAC9052.dita">Baseport Template
+Tools Guide</xref> section describes the tools that are specific to
+the Baseport Template platform service.</p></section>
+<section id="GUID-90A87FBB-25BD-4C2E-8B17-90B54EF80D22"><title>Baseport
+architecture</title><p>The simplified architecture of the Baseport
+Template platform service and how it fit into the Symbian platform
+is shown below:</p><fig id="GUID-8454F25F-9A8B-4B22-82C0-AD3E10068AAC">
+<title>The system architecture (simplified)</title>
+<image href="GUID-746BD53F-F637-4BC9-91AC-E53BA182B823_d0e87730_href.png" placement="inline"/>
+</fig><p>In the above diagram, the following are not part of the Baseport
+Template:</p><table id="GUID-35449CF0-ED63-492D-8F56-F260731B5A2C">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry align="center" valign="top"><p><b>Legend</b></p></entry>
+<entry align="center" valign="top"><p><b>Purpose</b></p></entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p><filepath>EUSER</filepath></p></entry>
+<entry><p>User library</p></entry>
+</row>
+<row>
+<entry><p><filepath>EWSRV</filepath></p></entry>
+<entry><p>Window server</p></entry>
+</row>
+<row>
+<entry><p><filepath>EFILE</filepath></p></entry>
+<entry><p>File server</p></entry>
+</row>
+<row>
+<entry><p><filepath>ESTART</filepath></p></entry>
+<entry><p>Initializes the file system</p></entry>
+</row>
+<row>
+<entry><p>HAL</p></entry>
+<entry><p>Hardware Abstraction Layer</p></entry>
+</row>
+<row>
+<entry><p>MMU</p></entry>
+<entry><p>Memory Management Unit</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p>In the above diagram, the following are part of the Baseport
+Template:</p><table id="GUID-B612ECF8-10B0-4B67-A1F9-26A941502FB1">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry align="center" valign="top"><p><b>Legend</b></p></entry>
+<entry align="center" valign="top"><p><b>Purpose</b></p></entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p>Kernel</p></entry>
+<entry><p>The kernel</p></entry>
+</row>
+<row>
+<entry><p>1</p></entry>
+<entry><p>Variant PDD</p></entry>
+</row>
+<row>
+<entry><p>2</p></entry>
+<entry><p>Debugging PDD</p></entry>
+</row>
+<row>
+<entry><p>3</p></entry>
+<entry><p>Serial comms PDD</p></entry>
+</row>
+<row>
+<entry><p>4</p></entry>
+<entry><p>LCD PDD</p></entry>
+</row>
+<row>
+<entry><p>5</p></entry>
+<entry><p>Digitizer PDD</p></entry>
+</row>
+<row>
+<entry><p>6</p></entry>
+<entry><p>Power control PDD</p></entry>
+</row>
+<row>
+<entry><p>7</p></entry>
+<entry><p>Keyboard PDD</p></entry>
+</row>
+<row>
+<entry><p>8</p></entry>
+<entry><p>Keyboard map PDD</p></entry>
+</row>
+<row>
+<entry><p>9</p></entry>
+<entry><p>Log Flash File System (LFFS) PDD</p></entry>
+</row>
+<row>
+<entry><p>10</p></entry>
+<entry><p>Sound PDD</p></entry>
+</row>
+<row>
+<entry><p>11</p></entry>
+<entry><p>Camera PDD</p></entry>
+</row>
+<row>
+<entry><p>12</p></entry>
+<entry><p>I2S PDD</p></entry>
+</row>
+<row>
+<entry><p>13</p></entry>
+<entry><p>IIC PDD</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-E3785C96-D0D5-4B3B-913A-EA086A51AB65"><title>Key
+users of the Baseport Template</title><p>The Baseport Template is
+of interest to engineers who are to port the Symbian platform to a
+new hardware platform. Along with engineers that are producing drivers
+that will cover the functionality in the above table. This document
+is of interest to:</p><ul>
+<li><p>Device driver and kernel-side component developers</p></li>
+<li><p>Hardware implementors and base port developers.</p></li>
+</ul></section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-647ADEDA-AB5A-548F-93C3-D099EAE6A030-master.png has changed
Binary file Adaptation/GUID-647ADEDA-AB5A-548F-93C3-D099EAE6A030_d0e17089_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-654A788A-526A-4C3F-838C-05B09F0D5445.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,109 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-654A788A-526A-4C3F-838C-05B09F0D5445" xml:lang="en"><title>Interrupt Technology Guide</title><shortdesc>Describes the concepts of the Interrupts platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Interrupt platform service provides an interface to the kernel
+and device drivers to associate interrupt with an Interrupt Service
+Routine (ISR). There are three levels of interrupt management: <ol>
+<li id="GUID-74C645F7-29BE-452F-97DB-1D32134FB553"><p>CPU level: Control
+of interrupts available only to the kernel.</p></li>
+<li id="GUID-999F3089-0CF3-4C28-8547-0DCFD634F8B8"><p>Controller level:
+Control provided by functions of the <codeph>Interrupt</codeph> class.</p></li>
+<li id="GUID-47E985FB-1990-4FD8-A1B2-752A58A799A3"><p>Device level:
+Control of hardware sources that are managed by a device specific
+control scheme.</p></li>
+</ol></p>
+<section id="GUID-F80CF14A-3CB2-41B1-A3BD-DBD116FDBA8C-GENID-1-2-1-10-1-5-1-7-1-1-6-1-3-2">         
+   <title>Key concepts</title><dl>
+<dlentry>
+<dt>Interrupt</dt>
+<dd><p>An interrupt is a hardware or a software event that may need
+to be serviced. An example of a hardware interrupt is a key press
+.</p></dd>
+</dlentry>
+<dlentry>
+<dt>Interrupt ID</dt>
+<dd><p>The unique ID of an interrupt source. The interrupt ID are
+defined by the developers creating ASSP and variant.</p></dd>
+</dlentry>
+<dlentry>
+<dt>Spurious interrupts</dt>
+<dd><p>Interrupts not associated with an Interrupt Service Routine
+are called the spurious interrupts. The spurious interrupts are handled
+by a spurious interrupt handler which is only used for debugging.</p></dd>
+</dlentry>
+<dlentry>
+<dt>ISR</dt>
+<dd><p>An Interrupt Service Routine (ISR ) is the function to handle
+an interrupt. ISR is not a class member. ISR provides the minimum
+processing such as storing data that may not be available later and
+requests a DFC for further processing.</p></dd>
+</dlentry>
+<dlentry>
+<dt>Interrupt priority</dt>
+<dd><p>The Interrupt platform service allows developers to set a priority
+for each interrupt source. The meaning of the priority value depends
+on the hardware and the baseport implementation.</p></dd>
+</dlentry>
+<dlentry>
+<dt>Interrupt dispatch</dt>
+<dd><p>When an interrupt is received by the system, it calls the associated
+ISR. This is called interrupt dispatch. The interrupt dispatch is
+provided by the implementation of the <codeph>interrupt</codeph> class
+in the ASSP layer.</p></dd>
+</dlentry>
+<dlentry>
+<dt>ISR table</dt>
+<dd><p>The table that maps the interrupt ID and the associated ISR.
+The ISR table is implemented by the developers creating the baseport
+variant.</p></dd>
+</dlentry>
+<dlentry>
+<dt>Binding</dt>
+<dd><p>The process of associating an interrupt ID with an ISR. Unbinding
+removes the association.</p></dd>
+</dlentry>
+<dlentry>
+<dt>Chained interrupts</dt>
+<dd><p>The output of a low priority interrupt controller is provided
+as an input to a higher priority interrupt controller.</p></dd>
+</dlentry>
+</dl><dl>
+<dlentry>
+<dt>Pseudo-interrupts</dt>
+<dd><p>Pseudo-interrupts correspond to multiple interrupt sources
+sharing a single input to an interrupt controller but requiring separate
+ISRs to service them. The ISRs cannot all be bound to the single real
+interrupt and are therefore bound to the pseudo-interrupt instead.</p></dd>
+</dlentry>
+</dl><dl>
+<dlentry>
+<dt>IRQs and FIQs</dt>
+<dd><p>An IRQ (interrupt request) is the signal generated by an item
+of hardware or software to request an interrupt from the processor.
+An FIQ (fast IRQ) is an IRQ with high priority on systems
+which support prioritization of requests.</p></dd>
+</dlentry>
+</dl>                     </section>
+<section id="GUID-02A23FEF-2E96-4DC7-9AFB-D836B019C37B"><title>Typical
+uses</title><p>The Interrupt platform service allows the kernel and
+device drivers to :</p><ul>
+<li><p>associate an ISR with an interrupt ID</p></li>
+<li><p>enable/disable a specific interrupt</p></li>
+<li><p>clear pending actions on a specific interrupt</p></li>
+<li><p>change the priority of a specific interrupt.</p></li>
+</ul></section>
+</conbody><related-links>
+<link href="GUID-2E54DA7D-1094-41C6-AFB0-9999471991F8.dita"><linktext>Interrupt
+Implementation Guide</linktext></link>
+<link href="GUID-68446E8E-129C-444A-836A-EF8F56BFE0BC.dita"><linktext>Handling
+Interrupts</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-6597A895-37D5-51D1-86B3-E74F6E845899-master.png has changed
Binary file Adaptation/GUID-6597A895-37D5-51D1-86B3-E74F6E845899_d0e23392_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-65CDCA83-C726-5173-8E46-B8981D1D7B02.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-65CDCA83-C726-5173-8E46-B8981D1D7B02" xml:lang="en"><title>Battery
+Monitor Implementation Tutorial</title><shortdesc>A base port can implement code to monitor the battery of the phone
+and to provide notifications when the battery power is low.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> The battery monitor code is implemented in the power controller kernel
+extension. </p>
+<p>Note: to implement battery monitor code, the battery monitor hardware must
+be accessible to the Application CPU of the phone. </p>
+<p>Typically, your battery monitor class would derive from the <codeph>DBatteryMonitor</codeph> class,
+defined as: </p>
+<codeblock id="GUID-D0249D2C-933F-584F-9596-126CCC4361AC" xml:space="preserve">class DBatteryMonitor
+    {
+public:
+    IMPORT_C DBatteryMonitor();
+    IMPORT_C void Register();
+public:
+    virtual TSupplyStatus MachinePowerStatus() = 0;
+    virtual void SystemTimeChanged(TInt anOldTime, TInt aNewTime) = 0;
+    };</codeblock>
+<p>Symbian platform considers that batteries can be in one of 4 possible logical
+states, defined by the <codeph>TSupplyStatus</codeph> enum. It is up to the
+implementor of the battery monitor component to map these logical states to
+points on the main battery discharge curve. </p>
+<p>There are two pure virtual functions to be implemented: </p>
+<ul>
+<li id="GUID-714DB74E-2405-54B5-B129-B6D2A3C4D5B5"><p> <xref href="GUID-65CDCA83-C726-5173-8E46-B8981D1D7B02.dita#GUID-65CDCA83-C726-5173-8E46-B8981D1D7B02/GUID-3471CC3E-0903-54F0-8EB2-5201AB139731">DBatteryMonitor::MachinePowerStatus()</xref> </p> </li>
+<li id="GUID-4296048D-82EC-5513-A089-E723D390EF5E"><p> <xref href="GUID-65CDCA83-C726-5173-8E46-B8981D1D7B02.dita#GUID-65CDCA83-C726-5173-8E46-B8981D1D7B02/GUID-1A5D9A50-1A28-59B5-862B-3DA5EAAAC26F">DBatteryMonitor::SystemTimeChanged()</xref> </p> </li>
+</ul>
+<p>We also suggest that the battery monitor component offer a public function
+prototyped as: </p>
+<codeblock id="GUID-EFB607B3-828C-54C3-A365-662FD6A74701" xml:space="preserve">void SupplyInfo(TSupplyInfoV1&amp; si);</codeblock>
+<p>to supply information about the state of the main battery and the backup
+battery (if there is one), or external power to user side components that
+may require it (e.g. a user-side power monitor component that is used to track
+the state of batteries and initiate an orderly shutdown if it reaches a critically
+low level), and is usually called by the <codeph>EHalGroupPower</codeph> handler
+for <codeph>EPowerHalSupplyInfo</codeph> in response to calling <codeph>HAL::Get()</codeph> with <codeph>EPowerGood</codeph>, <codeph>EPowerBatteryStatus</codeph>, <codeph>EPowerBackupStatus</codeph>, and <codeph>EPowerExternal</codeph>.
+Such a function would need to fill in a subset of the fields defined by <codeph>TSupplyInfoV1</codeph>. </p>
+<section id="GUID-3471CC3E-0903-54F0-8EB2-5201AB139731"><title>DBatteryMonitor::MachinePowerStatus()</title> <codeblock id="GUID-32E4B2FF-F638-59DC-98B9-CBFE15E1FCEC" xml:space="preserve">virtual TSupplyStatus MachinePowerStatus() = 0;</codeblock> <p>This
+should read and return the logical state of the main battery or, if external
+power is connected, it should return <codeph>EGood</codeph>. </p> <p><b>When
+is it called?</b> </p> <p>The function is called by peripheral drivers via
+a call to <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-84835157-E5B9-3834-8FFC-CD482A946F4A"><apiname>Kern::MachinePowerStatus()</apiname></xref> before starting lengthy
+operations or operations that may result in a substantial increase in power
+consumption. </p> <p><b>Implementation issues</b> </p> <p>A suggested implementation
+would have the function reading the state of the main battery, or whether
+external power is connected, and mapping to one of the logical states defined
+by <codeph>TSupplyStatus</codeph>. When requested by the power manager it
+returns the logical state. </p> </section>
+<section id="GUID-1A5D9A50-1A28-59B5-862B-3DA5EAAAC26F"><title>DBatteryMonitor::SystemTimeChanged()</title> <codeblock id="GUID-CC55B65D-B849-5FAA-A678-3DFD58D14F9D" xml:space="preserve">virtual void SystemTimeChanged(TInt anOldTime, TInt aNewTime) = 0;</codeblock> <p>This
+function is now deprecated, and you should just define an empty implementation. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-65F012C2-19BA-474E-8E94-D0E89DADF7B8.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,56 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-65F012C2-19BA-474E-8E94-D0E89DADF7B8" xml:lang="en"><title>Multiple
+Unit Support</title><shortdesc>This document describes how to support multiple units of hardware
+with a single device driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-F35C9966-6107-43D4-88BE-B65F820F7CBA">       <title>Supporting
+multiple units</title>       <p>An LDD can support more than one device by
+providing a separate channel to each device. </p> <p>There can be more than
+one PDD associated with a given LDD, where each PDD supports a different variation
+of a similar device. </p> <p>Alternatively, a single PDD can be designed to
+support multiple instances of an identical device by supporting more than
+one channel. For example, a platform that contains two identical UARTS could
+support these by providing a PDD that can open a channel on either (or both)
+UARTs. </p> <p>Where a driver supports multiple devices on a platform, then
+it uses a unit number to distinguish between each instance of the device.
+Clients open a channel to the driver for a particular unit. The following
+shows an example of this, and the example driver function that creates the
+channel: </p> <codeblock id="GUID-713E591A-2C4C-546B-934E-5F7C825332B5" xml:space="preserve">// User application opens the driver for unit1
+RExDriverChannel ldd;
+r = ldd.Open(KUnit1);
+test(r==KErrNone);</codeblock> <codeblock id="GUID-D0BFA95B-F3E6-579E-902A-F10664422D9F" xml:space="preserve">// User side wrapper function to driver API
+inline TInt RExDriverChannel::Open(TInt aUnit)
+    {    
+    return DoCreate(KDriverName,VersionRequired(),
+                aUnit,NULL,NULL,EOwnerThread);    
+    }</codeblock>     </section>
+<section id="GUID-A62D1C51-9974-4C82-974F-335144691DD2"><title>System information</title> <p>The
+driver must inform the framework that it supports the use of unit numbers.
+A driver can use unit numbers to ensure that it only opens on one unit. This
+is done by setting the <xref href="GUID-7616AA05-83E6-3989-AB9D-11AE01245BEB.dita#GUID-7616AA05-83E6-3989-AB9D-11AE01245BEB/GUID-EB891156-94D9-323A-AB23-7B5994CD95E3"><apiname>DLogicalDevice::iParseMask</apiname></xref> bitmask
+with the <xref href="GUID-F7186198-62A7-3915-B29B-87AC31A7B90C.dita"><apiname>KDeviceAllowUnit</apiname></xref> flag. </p> <codeblock id="GUID-AC71E4B9-7C7F-540F-86D3-CE8D876E67DE" xml:space="preserve">// Logical Channel Second stage constructor
+DExDriverLogicalDevice:: DExDriverLogicalDevice ()
+    {
+    iParseMask = KDeviceAllowPhysicalDevice | KDeviceAllowUnit;
+    ...
+    }</codeblock></section>
+<section id="GUID-A6817059-DA9B-4CFA-B1D0-AE1DE8116C58"><title>Unit number
+validation</title> <p>The device driver framework validates if the driver
+supports unit numbers. In the following example, the PDD checks if the unit
+number passed is valid. </p> <codeblock id="GUID-32369EB3-BF09-58C1-9F9E-B17B4369BB19" xml:space="preserve">TInt DExH4PhysicalDevice::Validate(TInt aUnit, const TDesC8* 
+/*aInfo*/, const TVersion&amp; aVer)
+    {    
+    ...        
+    if (aUnit&lt;0 || aUnit&gt;=KNumUarts)
+        return KErrNotSupported;
+    }</codeblock></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-660A8E4C-F930-415C-8CCC-CB1DCCAA2442.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-660A8E4C-F930-415C-8CCC-CB1DCCAA2442" xml:lang="en"><title>Interrupts</title><shortdesc>This document describes how device drivers use interrupts.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-7B450286-637E-4BAB-9D36-9228764CD0D4">      
+      <p>Devices generate interrupts to indicate hardware events. Generally
+drivers provide an interrupt service routine (ISR) to handle the interrupts
+and perform the required responses to the events. Symbian provides an <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita"><apiname>Interrupt</apiname></xref> class
+(implemented by the ASSP) with an API to bind and unbind an interrupt source
+and an ISR. </p> <codeblock id="GUID-9EB4BFFE-55A2-56D4-BCF3-6D278C3EC4F4" xml:space="preserve">// Bind the interrupt source ID and interrupt service routine
+TInt Bind(TInt aId, TIsr aIsr, TAny* aPtr);
+// Unbind the interrupt
+TInt Unbind(TInt aId);
+// Enable interrupts on device interrupt source
+TInt Enable(TInt aId);
+// Disable interrupts on device interrupt source
+TInt Disable(TInt aId);
+// Clear the device interrupt
+TInt Clear(TInt aId);
+// Set the priority of the interrupt
+TInt SetPriority(TInt aId, TInt aPriority);</codeblock> <p>Interrupt handling
+is typically done in a PDD, as device hardware access is done at that level.
+Interrupt handling is generally done in two stages in the driver. High priority
+and short time running tasks are done in the ISR, and the remaining processing
+is deferred for handling later. </p> <p>Interrupt handling is a blocking high
+priority task and needs to take a minimal amount of time. The Kernel will
+be in an indeterminate state and puts restrictions on doing various operations. </p> 
+   </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-669C77A3-89BA-5321-ABB1-4356A5FE478C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-669C77A3-89BA-5321-ABB1-4356A5FE478C" xml:lang="en"><title>Sound Driver</title><shortdesc>Describes how to create a port of the sound driver for your phone
+hardware. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Sound Driver is a device driver that controls the audio hardware of
+a phone. Symbian platform provides a User-Side API, a Logical Device Driver,
+and a base class for physical channels. You must provide a PDD that implements
+the physical channels that interface to the sound hardware on your phone. </p>
+</conbody><related-links>
+<link href="GUID-6BFB2062-077A-5FC3-890A-F9257C6C0551.dita"><linktext>Integrated
+     Interchip Sound</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-66E5F769-1156-54CA-94BC-8912159A1240.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-66E5F769-1156-54CA-94BC-8912159A1240" xml:lang="en"><title>Testing
+the PRM PSL</title><shortdesc>This document describes using the test suite for the PRM. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-A009D3D3-BD1B-40B8-B39D-8F35AD5FCF1E"><title>Purpose</title> <p>Use this test suite to ensure that your
+Power Resource Manager implementation runs correctly. </p> <p><b>Introduction</b> </p> <p> <codeph>T_PRMACCTST</codeph> is
+a test application that verifies the resources registered with the PSL of
+the PRM. For more information refer to the description of individual test
+cases in <filepath>e32test/resourceman/acctst/t_prmacctst.cpp</filepath>. </p> <p>The
+following tasks are preformed by the test suite: </p> <ul>
+<li id="GUID-86D22263-7F34-5F98-A673-909C64F1B929"><p>enumerate all registered
+resources, </p> </li>
+<li id="GUID-82F19722-C930-55CA-B7DF-B10F23660F5E"><p>check that resources
+behave consistently with their properties, </p> </li>
+<li id="GUID-37BA8D2B-E226-55EE-99DE-B0DA34D2CD1C"><p>ensure that resources
+are reset to their default level when not in use, </p> </li>
+<li id="GUID-6A399DB5-996B-503D-AE5B-F89797FB6722"><p>ensure all actual resources
+dependencies have been declared (only the extended version of the PRM allows
+dependencies). </p> </li>
+</ul> <p>To ensure that single-user resources are available to the test application, <codeph>T_PRMACCTST</codeph> is
+coupled with a kernel extension, <codeph>D_PRMACCTST</codeph> that takes control
+of such resources immediately after the PRM has been initialised. It then
+releases the resources when the test application ends. </p> </section>
+<section id="GUID-99C0A3AE-5C14-4B6E-9623-FE536E259D08"><title>Using the test suite</title> <p>The instructions to run the
+PRM acceptance test suite are as follows: </p> <ol id="GUID-2C3603D2-1CFD-55AF-B2D1-9532A09FA6A3">
+<li id="GUID-90FBCCDF-C195-5007-AB19-C2910D7CD1AB"><p>build the test code
+in <filepath>e32test/resourceman/acctst</filepath>, </p> </li>
+<li id="GUID-5DA609A8-64D1-5533-820D-2115B0412D8A"><p>build a rom for H4HRP
+of type <codeph>prmacctst</codeph> in <filepath>e32/rombuild</filepath>: </p> <p><userinput>rom
+-v=h4hrp -I=armv5 -b=urel -t=prmacctst</userinput> </p> <p>This command generates
+a self-starting ROM. The test output is captured from the default debug port
+of the device. </p> </li>
+</ol> <p>To build a manual test ROM (so the test application does not run
+automatically), use the <codeph>-d=MANUALROM</codeph> option. The usual ESHELL
+command prompt will be displayed and the test application can be run by calling <codeph>T_PRMACCTST</codeph>. </p> <p> <b>Note</b>:
+This test must be run with minimal required components because the test driver
+is a kernel extension and takes control of all single-user resources during
+its entry point. This test randomly changes the state of all the resources
+between a minimum and maximum value. If there are any restrictions on a resources
+state change (i.e. the resource state can be only be changed to a certain
+value) then that resource should not be registered while running this test. </p> </section>
+</conbody><related-links>
+<link href="GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9.dita"><linktext>Porting the
+Power Resource Manager</linktext></link>
+<link href="GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671.dita"><linktext>Implement
+the controllable power resources</linktext></link>
+<link href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita"><linktext>Implement
+the PSL for the target</linktext></link>
+<link href="GUID-E7F91A65-235D-589C-9A8C-0B207D19A24B.dita"><linktext>Port client
+drivers to use the PRM</linktext></link>
+<link href="GUID-C8DF0CB0-92F4-5F9E-A8F1-7DE50954C4F1.dita"><linktext>Debugging
+the PRM</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,336 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-66FD040B-133E-57CF-80DD-9369F62709C6" xml:lang="en"><title>Implement
+the PSL for the target</title><shortdesc>This document describes how to implement the Platform Specific
+Layer for the Power Resource Manager.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-AA174659-DAC6-47C2-A308-63C72E4C4C29"><title>Purpose</title> <p>The PSL must be implemented in order for
+the PRM and the hardware to be able to communicate. </p> <p><b>Introduction</b> </p> <p>The
+PSL side of the Resource Controller should be derived from the class <xref href="GUID-46F2174F-0206-345B-8C5D-F8B5763652E0.dita"><apiname>DPowerResourceController</apiname></xref>. </p> </section>
+<section id="GUID-E744193B-0A9F-4E43-905A-E62414D75816"><title> Implementing the PSL </title> <p>The following tasks are
+covered in this tutorial: </p> <ul>
+<li id="GUID-2D247D75-FAB8-5ACA-895F-9F5EE58E70F6"><p> <xref href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita#GUID-66FD040B-133E-57CF-80DD-9369F62709C6/GUID-2919DA2A-22EF-5DA7-8B90-EC70BFEAC04A">Create an entry point</xref>, </p> </li>
+<li id="GUID-920C5334-D4A2-53E6-9381-F00F31EFE3E4"><p> <xref href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita#GUID-66FD040B-133E-57CF-80DD-9369F62709C6/GUID-E1119981-C3E9-5EED-90FA-5196A60A8E57">Override the pure virtual functions</xref>, </p> </li>
+<li id="GUID-DD00864E-83A8-5D39-9A74-257A980B97A1"><p> <xref href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita#GUID-66FD040B-133E-57CF-80DD-9369F62709C6/GUID-9E18F595-D826-5244-89CC-A76871120287">Create static resources that support dependencies</xref>, </p> </li>
+<li id="GUID-E3745946-B84D-556D-8A1C-62D32F117EEB"><p> <xref href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita#GUID-66FD040B-133E-57CF-80DD-9369F62709C6/GUID-252E7413-D8A9-575C-858F-E4F4E238A7B0">Initialise the pools</xref>, </p> </li>
+<li id="GUID-15313D5D-5CEB-52A7-A8BA-7C6BC0EF5973"><p> <xref href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita#GUID-66FD040B-133E-57CF-80DD-9369F62709C6/GUID-08BFCAF4-9AF0-5999-A1C4-7BBD107C9354">Registering with the Power Controller</xref>. </p> </li>
+</ul> <p id="GUID-2919DA2A-22EF-5DA7-8B90-EC70BFEAC04A"><b>Create an entry
+Point</b> </p> <p>The PIL layer of the PRM offers the following macro. This
+needs to be invoked from the PSL. The macro calls the <xref href="GUID-C0788D78-2700-3094-BDE2-F1ABC93CE433.dita"><apiname>DoInitController()</apiname></xref> and <xref href="GUID-616D2132-0676-3CAD-9FF4-41CE147E8DF0.dita"><apiname>DoInitResources()</apiname></xref> functions
+implemented by the PSL. </p> <codeblock id="GUID-3040AB12-1884-5967-AEA6-27B1162172D8" xml:space="preserve">/**
+Extension entry point
+*/
+DECLARE_RESOURCE_MANAGER_EXTENSION()
+    {
+    __KTRACE_OPT(KBOOT, Kern::Printf("CreateController called"));
+    return new DH4PowerResourceController;
+    }</codeblock> <p>If the PRM is a <keyword>PDD</keyword> the entry point
+is as follows: </p> <codeblock id="GUID-DE03EEAB-BC7E-57F4-9E28-A16028A86F24" xml:space="preserve">static DH4PowerResourceController TheController;
+DECLARE_STANDARD_PDD()
+    {
+    TInt r = DPowerResourceController::InitController();     
+    if® == KErrNone)
+        r = TheController-&gt;InitResources();
+    if® == KErrNone)
+        return new DResConPddFactory;
+    return NULL;                            
+    }</codeblock> <p id="GUID-E1119981-C3E9-5EED-90FA-5196A60A8E57"><b>Override
+the pure virtual functions</b> </p> <p>Override the virtual functions of the <xref href="GUID-46F2174F-0206-345B-8C5D-F8B5763652E0.dita"><apiname>DPowerResourceController</apiname></xref> base
+class: </p> <ul>
+<li id="GUID-F81D44B9-97A4-52D1-859D-80E11CC86B86"><p> <xref href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita#GUID-66FD040B-133E-57CF-80DD-9369F62709C6/GUID-67C338A7-E163-5253-B495-B9E081340F1A">DoInitController()</xref>, </p> </li>
+<li id="GUID-6D167188-8750-5E2C-952B-E61D18400298"><p> <xref href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita#GUID-66FD040B-133E-57CF-80DD-9369F62709C6/GUID-61471315-14E1-5A0F-A164-92CF928C3604">DoRegisterStaticResources()</xref>. </p> </li>
+</ul> <p>Here is an example H4 HRP implementation: </p> <codeblock id="GUID-90F8FCCA-8A95-50D8-AF16-9CA974E04CDE" xml:space="preserve">class DH4PowerResourceController : DPowerResourceController
+   {
+public:
+   DH4PowerResourceController();
+   TInt DoInitController();
+   TInt DoRegisterStaticResources(DStaticPowerResource**&amp; aStaticResourceArray, TUint16&amp; aStaticResourceCount);
+private:
+   static DStaticPowerResource* iResources[];</codeblock> <p id="GUID-67C338A7-E163-5253-B495-B9E081340F1A"><b>DoInitController()</b> </p> <p>Override <xref href="GUID-46F2174F-0206-345B-8C5D-F8B5763652E0.dita#GUID-46F2174F-0206-345B-8C5D-F8B5763652E0/GUID-58713E4F-DB41-3DD9-B180-ECA5DAA830D4"><apiname>DPowerResourceController::DoInitController()</apiname></xref> so that it creates
+a DFC queue and then invokes the base class function <xref href="GUID-46F2174F-0206-345B-8C5D-F8B5763652E0.dita#GUID-46F2174F-0206-345B-8C5D-F8B5763652E0/GUID-A3E9F7E9-885E-37CB-9077-CBC686B46E15"><apiname>DPowerResourceController::SetDfcQ()</apiname></xref>. <codeph>DoInitController()</codeph> should
+also initialise the pools by invoking <xref href="GUID-46F2174F-0206-345B-8C5D-F8B5763652E0.dita#GUID-46F2174F-0206-345B-8C5D-F8B5763652E0/GUID-0CAA5314-F418-31F8-863E-0082C5A617A5"><apiname>DPowerResourceController::InitPools()</apiname></xref> passing
+the platform defined sizes for the pools of clients, <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-F47D2098-16A7-5590-A68A-7AE4B2DAB462">client levels</xref> and <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-E8F3AF8E-387C-5285-A2B2-0B067F01BC3A">request
+objects</xref>. <xref href="GUID-C0788D78-2700-3094-BDE2-F1ABC93CE433.dita"><apiname>DoInitController()</apiname></xref> is called by the PSL
+during its initialisation. Below is the reference implementation code. </p> <codeblock id="GUID-06466787-59E3-5C0F-9E14-2144BEF3CBBB" xml:space="preserve">#define KERNEL_CLIENTS 0x2 // Expected number of kernel clients (MMC and Sound_SC)
+#define USER_CLIENTS   0x0 // No user side clients expected.
+#define CLIENT_LEVELS  0x8 // Expected resource state change of 8 resources 
+#define REQUESTS       0x0 // No asynchronous operation (state change or read) expected. 
+
+TInt DH4PowerResourceController::DoInitController()
+    {
+    // Create a DFC queue and then invoke SetDfcQ()
+__KTRACE_OPT(KRESMANAGER, Kern::Printf("&gt;DH4PowerResourceController::DoInitController\n"));
+
+    // NKern::ThreadEnterCS(); // Not needed, as this is executed during kernel boot which is done within a critical section.
+    TInt r = Kern::DfcQCreate(iDfcQ,28,&amp;KResThreadName);
+
+    // NKern::ThreadLeaveCS();
+    if (KErrNone!=r) return r;
+    SetDfcQ(iDfcQ);
+    r = InitPools(KERNEL_CLIENTS,USER_CLIENTS,CLIENT_LEVELS,REQUESTS);
+__KTRACE_OPT(KRESMANAGER, Kern::Printf("&lt;DH4PowerResourceController::DoInitController\n"));
+    return r;
+    }</codeblock> <p id="GUID-61471315-14E1-5A0F-A164-92CF928C3604"><b> DoRegisterStaticResources()</b> </p> <p> <codeph>DoRegisterStaticResources()</codeph> is called by the PIL during its initialisation. Override the pure virtual
+function <xref href="GUID-46F2174F-0206-345B-8C5D-F8B5763652E0.dita#GUID-46F2174F-0206-345B-8C5D-F8B5763652E0/GUID-E76A1967-CED5-341C-9B29-015C8AD2B54D"><apiname>DPowerResourceController::DoRegisterStaticResources()</apiname></xref> so
+that it: </p> <ul>
+<li id="GUID-274C20C9-C8C1-5E04-916C-32D8AEA06F66"><p>creates all the static
+resources in the kernel heap, </p> </li>
+<li id="GUID-FDD08EF6-78E4-5583-987B-E27D6B160554"><p>creates an array of
+pointers to the static resources (indexed by their id), </p> </li>
+<li id="GUID-F85D8EA4-44CF-577A-A423-6A60A5C55DDD"><p>sets the passed pointer
+(<codeph>aStaticResourceArray</codeph>) to point to the created array of pointers, </p> </li>
+<li id="GUID-A129EA68-9942-54CF-85A5-C5F9507B1447"><p>updates the count of
+the static resources (in <codeph>aStaticResourceCount</codeph>). </p> </li>
+</ul> <p>The reference implementation is below: </p> <codeblock id="GUID-81F2F9EB-A42E-5FBF-BDB2-091AA2C56096" xml:space="preserve">TInt DH4PowerResourceController::DoRegisterStaticResources(DStaticPowerResource**&amp; aStaticResourceArray, TUint16&amp; aStaticResourceCount)
+    {
+    aStaticResourceCount = 0;
+   __KTRACE_OPT(KRESMANAGER, Kern::Printf("&gt;DH4PowerResourceController::DoRegisterStaticResources\n"));
+   aStaticResourceArray = (DStaticPowerResource**) new (DStaticPowerResource*[EH4ResourceCount]);
+   if(!aStaticResourceArray)
+      return KErrNoMemory;
+
+   DH4MmcFclkResource *pMmcFclk = new (DH4MmcFclkResource);
+   if (!pMmcFclk) 
+      return KErrNoMemory;
+   aStaticResourceArray[EMmcFclkRes] = pMmcFclk;
+
+   DH4MmcIclkResource *pMmcIclk = new (DH4MmcIclkResource);
+   if (!pMmcIclk)
+      CLEAN_AND_RETURN(KErrNoMemory, EMmcIclkRes)
+   aStaticResourceArray[EMmcIclkRes] = pMmcIclk;
+
+   DH4MmcClkResource *pMmcBusClk = new (DH4MmcClkResource);
+   if (!pMmcBusClk)
+      CLEAN_AND_RETURN(KErrNoMemory, EMmcClkRes)
+   aStaticResourceArray[EMmcClkRes] = pMmcBusClk;
+
+   DH4MmcCtrllerPwrResource *pMmcCtrlrPwr = new (DH4MmcCtrllerPwrResource);
+   if (!pMmcCtrlrPwr)
+      CLEAN_AND_RETURN(KErrNoMemory, EMmcCtrlrPwrRes)
+   aStaticResourceArray[EMmcCtrlrPwrRes] = pMmcCtrlrPwr;
+    
+   DH4MmcPowerResource *pMmcPwr = new (DH4MmcPowerResource);
+   if (!pMmcPwr)
+      CLEAN_AND_RETURN(KErrNoMemory, EMmcPwrRes)
+   aStaticResourceArray[EMmcPwrRes] = pMmcPwr;
+    
+   DH4SndFclkResource *pSndFclk = new (DH4SndFclkResource);
+   if (!pSndFclk)
+      CLEAN_AND_RETURN(KErrNoMemory, ESndFclkRes)
+   aStaticResourceArray[ESndFclkRes] = pSndFclk;
+
+   DH4SndIclkResource *pSndIclk = new (DH4SndIclkResource);
+   if (!pSndIclk)
+      CLEAN_AND_RETURN(KErrNoMemory ,ESndIclkRes)
+   aStaticResourceArray[ESndIclkRes] = pSndIclk;
+
+   DH4SndMClkResource *pSndMclk = new (DH4SndMClkResource);
+   if (!pSndMclk)
+      CLEAN_AND_RETURN(KErrNoMemory, ESndMClkRes)
+   aStaticResourceArray[ESndMClkRes] = pSndMclk;
+
+   aStaticResourceCount = EH4ResourceCount;
+
+   __KTRACE_OPT(KRESMANAGER, Kern::Printf("&lt;DH4PowerResourceController::DoRegisterStaticResources, Total resources:%d\n", EH4ResourceCount));
+
+   return KErrNone;
+   }</codeblock> <p id="GUID-9E18F595-D826-5244-89CC-A76871120287"><b>Create
+static resources that support dependencies</b> </p> <p>If there are static
+resources that support dependencies then the PSL must implement the function <xref href="GUID-46F2174F-0206-345B-8C5D-F8B5763652E0.dita#GUID-46F2174F-0206-345B-8C5D-F8B5763652E0/GUID-933848C2-2589-3EBC-9765-6BD215F09E1C"><apiname>DPowerResourceController::DoRegisterStaticResourcesDependency()</apiname></xref>. <b>Note</b>: Static resources that support dependencies are only available
+in the extended version of the library. See <xref href="GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9.dita#GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9/GUID-0F328055-DBCE-5B2B-A1EB-77F73BA1FC82">setup
+and configuration</xref>. </p> <p>The function <codeph>DoRegisterStaticResourcesDependency()</codeph>: </p> <ul>
+<li id="GUID-8AA323AF-92D9-5217-8BC5-86E879F30475"><p>creates all static resources
+that support dependencies in kernel heap, </p> </li>
+<li id="GUID-904B8533-FA65-5958-88BF-307385D06BF6"><p>creates an array of
+pointers to them, </p> </li>
+<li id="GUID-ABC35D75-FA42-5627-A0B4-4F407AD08AC8"><p>establishes the dependencies
+between them (using the resource's <xref href="GUID-1CD49D40-1FF9-301C-8160-02A007485ADE.dita#GUID-1CD49D40-1FF9-301C-8160-02A007485ADE/GUID-806D0179-FC98-3106-BCBA-0D3634B43815"><apiname>DStaticPowerResourceD::AddNode()</apiname></xref> function),
+See <xref href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita#GUID-66FD040B-133E-57CF-80DD-9369F62709C6/GUID-A912A328-D646-5516-9731-FFA7F3B2EDDA">creating
+dependencies between static resources</xref> for a description of <codeph>AddNode()</codeph> and
+the <xref href="GUID-D44EF8E9-19EF-320A-8935-3E068C1097DB.dita"><apiname>SNode</apiname></xref> structure. </p> </li>
+<li id="GUID-B83ED866-7BB2-5227-A9B0-DE7CBFA92AA8"><p>sets the passed pointer
+(<codeph>aStaticResourceDArray</codeph>) to point to the array of pointers
+to static resource with dependency, </p> </li>
+<li id="GUID-62E7421E-9816-556F-ACF9-BEC02F9AF530"><p>updates the count of
+the static resource that supports dependency in <codeph>aStaticResourceDCount</codeph>. </p> </li>
+</ul> <p>This function is called by the PIL during PRM initialisation. Below
+is an example: </p> <codeblock id="GUID-2E044CAC-24E3-530F-8595-049D6512153F" xml:space="preserve">/** 
+This function creates all static resources that support dependencies and establishes the dependencies between them. This is called by the PIL.
+This is the dependency tree input:
+   ResourceA &lt;---------&gt; ResourceD &lt;-------&gt; ResourceE &lt;--------&gt; ResourceC
+                             |                   |
+                             |                   |
+                             |                   |
+                         ResourceF           ResourceG       
+*/
+TInt DSimulatedPowerResourceController::DoRegisterStaticResourcesDependency(DStaticPowerResourceD**&amp; aStaticResourceDArray, TUint16&amp; aStaticResourceDCount)
+   {
+   aStaticResourceDArray = (DStaticPowerResourceD**) new (DStaticPowerResourceD*[MAX_DEPENDENT_RESOURCE_COUNT]);
+   if(!aStaticResourceDArray)
+     return KErrNoMemory;
+
+   DStaticPowerResourceD* pR = NULL;
+
+   pR = new DMLSLGLSPDependResource();
+   if(!pR)
+     CLEAN_AND_RETURN(iStaticResDependencyCount, aStaticResourceDArray, KErrNoMemory)
+   aStaticResourceDArray[iStaticResDependencyCount++] = pR;
+
+   pR = new DMLSIGLSNDependResource();
+   if(!pR)
+     CLEAN_AND_RETURN(iStaticResDependencyCount, aStaticResourceDArray, KErrNoMemory)
+   aStaticResourceDArray[iStaticResDependencyCount++] = pR;
+    
+   pR = new DBSIGLSPDependResource();
+   if(!pR)
+     CLEAN_AND_RETURN(iStaticResDependencyCount, aStaticResourceDArray, KErrNoMemory)
+   aStaticResourceDArray[iStaticResDependencyCount++] = pR;
+
+   pR = new DMLSHIGLSPDependResource();
+   if(!pR)
+     CLEAN_AND_RETURN(iStaticResDependencyCount, aStaticResourceDArray, KErrNoMemory)
+   aStaticResourceDArray[iStaticResDependencyCount++] = pR;
+
+   pR = new DBSHLGLSNDependResource();
+   if(!pR)
+     CLEAN_AND_RETURN(iStaticResDependencyCount, aStaticResourceDArray, KErrNoMemory)
+   aStaticResourceDArray[iStaticResDependencyCount++] = pR;
+
+   pR = new DMLSHLGLSNDependResource();
+   if(!pR)
+     CLEAN_AND_RETURN(iStaticResDependencyCount, aStaticResourceDArray, KErrNoMemory)
+   aStaticResourceDArray[iStaticResDependencyCount++] = pR;
+
+   // Establish resource dependencies
+   if(CreateResourceDependency(aStaticResourceDArray))
+     CLEAN_AND_RETURN(iStaticResDependencyCount, aStaticResourceDArray, KErrNoMemory)
+
+   iDependencyResources = aStaticResourceDArray;
+
+   aStaticResourceDCount = iStaticResDependencyCount;
+   return KErrNone;
+   }    
+
+// This function establishes above dependency between static dependent resource
+TInt DSimulatedPowerResourceController::CreateResourceDependency(DStaticPowerResourceD** pResArray)
+   {
+   iNodeArray = new SNode[10];
+   SNode* pN1;
+   SNode* pN2;
+   iNodeCount = 0;
+
+   if(!iNodeArray)
+     return KErrNoMemory; 
+   // Create Dependency between Resource A and Resource D 
+   pN1 = &amp;iNodeArray[iNodeCount++];
+   pN2 = &amp;iNodeArray[iNodeCount++];
+   CREATE_DEPENDENCY_BETWEEN_NODES(pN1, pN2, pResArray[0], pResArray[1], 1, 1)
+
+   // Create Dependency between Resource D and Resource F
+   pN1 = &amp;iNodeArray[iNodeCount++];
+   pN2 = &amp;iNodeArray[iNodeCount++];
+   CREATE_DEPENDENCY_BETWEEN_NODES(pN1, pN2, pResArray[0], pResArray[2], 1, 3)
+
+   // Create Dependency between Resource D and Resource E
+   pN1 = &amp;iNodeArray[iNodeCount++];
+   pN2 = &amp;iNodeArray[iNodeCount++];
+   CREATE_DEPENDENCY_BETWEEN_NODES(pN1, pN2, pResArray[0], pResArray[3], 3, 2)
+
+   // Create Dependency between Resource E and Resource C
+   pN1 = &amp;iNodeArray[iNodeCount++];
+   pN2 = &amp;iNodeArray[iNodeCount++];
+   CREATE_DEPENDENCY_BETWEEN_NODES(pN1, pN2, pResArray[3], pResArray[4], 1, 1)
+
+   // Create Dependency between Resource E and Resource G
+   pN1 = &amp;iNodeArray[iNodeCount++];
+   pN2 = &amp;iNodeArray[iNodeCount++];
+   CREATE_DEPENDENCY_BETWEEN_NODES(pN1, pN2, pResArray[3], pResArray[5], 1, 2)
+
+   return KErrNone;
+   }
+
+#define CREATE_DEPENDENCY_BETWEEN_NODES(pN1, pN2, pRes1, pRes2, priRes1, priRes2)    \
+        pN1-&gt;iPriority = priRes1;                                                 \
+        pN1-&gt;iResource = pRes1;                                                   \
+        pN1-&gt;iPropagatedLevel = 0;                                                \
+        pN1-&gt;iVisited = EFalse;                                                   \
+        pN2-&gt;iPriority = priRes2;                                                 \
+        pN2-&gt;iResource = pRes2;                                                   \
+        pN2-&gt;iPropagatedLevel = 0;                                                \
+        pN2-&gt;iVisited = EFalse;                                                   \
+        pN1-&gt;iResource-&gt;AddNode(pN2);                                             \
+        pN2-&gt;iResource-&gt;AddNode(pN1);</codeblock> <p id="GUID-A912A328-D646-5516-9731-FFA7F3B2EDDA"><b>Creating
+dependencies between static resources</b> </p> <p> <xref href="GUID-1CD49D40-1FF9-301C-8160-02A007485ADE.dita#GUID-1CD49D40-1FF9-301C-8160-02A007485ADE/GUID-806D0179-FC98-3106-BCBA-0D3634B43815"><apiname>DStaticPowerResourceD::AddNode()</apiname></xref> is
+used to establish a dependency between static resources. Dependencies between
+static resources cannot be removed. </p> <p> <codeph>AddNode()</codeph> takes
+a pointer to an <xref href="GUID-D44EF8E9-19EF-320A-8935-3E068C1097DB.dita"><apiname>SNode</apiname></xref> object that contains the dependent
+resource information. This passed node pointed is added to the resource dependency
+list within the class <codeph>DStaticPowerResourceD</codeph>. <b>Note</b>:
+the kernel panics if the specified dependency priority is already in use. </p> <p>Information
+within <codeph>SNode</codeph> includes: </p> <ul>
+<li id="GUID-9A0E98EA-6510-5C71-B0AD-013E77BD94C0"><p> <codeph>iResource</codeph> is
+a pointer to dependent resource, </p> </li>
+<li id="GUID-0C62E787-DEA9-5A2A-BFA1-DFB7A30A6AE7"><p> <codeph>iPriority</codeph> is
+the priority of the dependency resource. This is used by the PRM when propagating
+the resource change, </p> </li>
+<li id="GUID-F1E5C122-E38D-5D0D-B1E6-6808DAF5631C"><p> <codeph>iSpare</codeph> is
+reserved for future use, </p> </li>
+<li id="GUID-DD0AA8A3-F301-5996-907E-F35BCD38840D"><p> <codeph>iNext</codeph> is
+a pointer to next node in the list. </p> </li>
+</ul> <p>The members <codeph>iPropagatedLevel</codeph>, <codeph>iRequiresChange</codeph> and <codeph>iVisited</codeph> are
+used internally by the PRM. </p> <p>To link to dynamic resources that support
+dependency use the PRM function <xref href="GUID-5EC9C7EB-3E69-3DAE-B777-C0952F949CF3.dita"><apiname>RegisterResourceDependency()</apiname></xref> as
+described in <xref href="GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671.dita#GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671/GUID-A5D57D89-4499-5C85-80D5-5A7DC5644983">creating
+resource dependencies</xref>. </p> <p id="GUID-252E7413-D8A9-575C-858F-E4F4E238A7B0"><b>Initialise
+the pools</b> </p> <p>Pools are implemented as singly linked lists during
+the initialisation of the PRM. The PSL initialises the pools by invoking <xref href="GUID-46F2174F-0206-345B-8C5D-F8B5763652E0.dita#GUID-46F2174F-0206-345B-8C5D-F8B5763652E0/GUID-0CAA5314-F418-31F8-863E-0082C5A617A5"><apiname>DPowerResourceController::InitPools()</apiname></xref> and
+passing the platform defined sizes for the pools of kernel side clients, user
+side clients, client levels and requests. See the <xref href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita#GUID-66FD040B-133E-57CF-80DD-9369F62709C6/GUID-67C338A7-E163-5253-B495-B9E081340F1A">example DoInitController() implementation</xref>. </p> <p>The PRM has three
+types of pools: </p> <ul>
+<li id="GUID-BB2EE131-0010-51BE-BD56-716D62D29E87"><p>client pools to store
+client information, </p> </li>
+<li id="GUID-C75A9188-7105-5F22-95AA-27B29E6A55FD"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-E8F3AF8E-387C-5285-A2B2-0B067F01BC3A">request pools</xref> to send requests for operation on long latency resource
+to the Resource Controller thread, </p> </li>
+<li id="GUID-7204C320-5150-5FF1-99C7-CD4868D106E1"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-F47D2098-16A7-5590-A68A-7AE4B2DAB462">client level</xref> pools to capture the resource level request by each client
+for a resource. </p> </li>
+</ul> <p>If the client pool is set to zero, then the PRM will not allow a
+client of that type to register. For example, if the kernel side clients pool
+is set to zero, then the PIL will not allow any kernel side clients to register.
+The size of the client pools to specify depends on how many kernel side device
+drivers (clients) and user side clients will access PRM and size of request
+pool depends on the number of long latency resource available in the system.
+Size of client level pool depends on number of clients that will request a
+resource state change. If the client pools are exhausted the PIL will try
+to increase the size of the pool. The size of the pool never decreases. </p> <p id="GUID-08BFCAF4-9AF0-5999-A1C4-7BBD107C9354"><b>Registering with the Power
+Controller</b> </p> <p>The Resource Controller must call <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita#GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366/GUID-42896B4D-9F77-3D91-82BD-50102A8F3DA4"><apiname>DPowerController::RegisterResourceController()</apiname></xref> to
+register itself with the Power Controller. <codeph>RegisterResourceController()</codeph> sets
+the <codeph>iResourceControllerData.iResourceController</codeph> data member
+within <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita"><apiname>DPowerController</apiname></xref> to the passed Resource Controller
+pointer and sets <codeph>iResouceControllerData.iClientId</codeph> to the
+client ID used by the Power Controller when calling the Resource Controller's
+APIs. </p> <p>The platform specific implementation of the Power Controller
+overrides the <codeph>RegisterResourceController()</codeph> function. See <xref href="GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita#GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703/GUID-DCD91EBA-CB0E-5EA9-84E0-8F8FED6FC91E">DPowerController::RegisterResourceController()</xref>. </p> <p><b> Idle power management</b> </p> <p>The resource controller's APIs
+cannot be called from a NULL thread. However, the PSL may need to know the
+state of the resources from a NULL thread to take the system to appropriate
+power states. To allow access to this information the PRM provides the virtual
+function <xref href="GUID-46F2174F-0206-345B-8C5D-F8B5763652E0.dita#GUID-46F2174F-0206-345B-8C5D-F8B5763652E0/GUID-52DC308A-9DF1-3BDE-A905-A4DD3B692638"><apiname>DPowerResourceController::RegisterResourcesForIdle()</apiname></xref>. </p> </section>
+</conbody><related-links>
+<link href="GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9.dita"><linktext>Porting the
+Power Resource Manager</linktext></link>
+<link href="GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671.dita"><linktext>Implement
+the  controllable power resources</linktext></link>
+<link href="GUID-E7F91A65-235D-589C-9A8C-0B207D19A24B.dita"><linktext>Port client
+drivers to use the PRM</linktext></link>
+<link href="GUID-C8DF0CB0-92F4-5F9E-A8F1-7DE50954C4F1.dita"><linktext>Debugging
+the PRM</linktext></link>
+<link href="GUID-66E5F769-1156-54CA-94BC-8912159A1240.dita"><linktext>Testing the
+PRM PSL</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-670B0580-B81B-4211-A4C0-23A2D8EDF96C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-670B0580-B81B-4211-A4C0-23A2D8EDF96C" xml:lang="en"><title>Time Build Guide</title><shortdesc>How to build a Time platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Time platform service is a plug-in to the System State Manager. </p>
+<section id="GUID-E8401DC2-7A7D-4726-8202-70A98CC2DD2F"><title>Requirements</title><ul>
+<li><p>System state manager</p></li>
+<li><p>You must be familiar with building ROM for the Symbian platform.</p></li>
+</ul>         </section>
+<section id="GUID-3610FAC2-97AE-4933-84C9-0C625A56071C"><title>Reference
+code</title><p>A reference template is provided at <filepath>os/devicesrv/sysstatemgmt/systemstateplugins/adptplugin/inc/rtcadaptationref.h</filepath>. Use the reference code as a guide to implement on
+the hardware. </p><p>Note that the reference source code is not supported
+on the <xref href="http://developer.symbian.org/wiki/index.php/SYBORG/QEMU" scope="external">emulator</xref>. </p></section>
+<section id="GUID-AF046960-A3B5-4AFB-ABCB-051134367A66"><title>Building
+a ROM</title><p>The system state manager plug-ins are built as a DLL.</p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6752A77F-B1D1-49BE-A672-5DDE3B7976BF.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6752A77F-B1D1-49BE-A672-5DDE3B7976BF" xml:lang="en"><title>Other
+Synchronisation APIs</title><shortdesc>This document describes APIs other than the nanokernel which device
+drivers use for synchronisation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Kernel provides APIs to wait in blocked state, unblocked state, and
+nanokernel APIs to get the tick period, timer ticks, to sleep on nanothread,
+and so on. </p>
+<codeblock id="GUID-E70B072C-6CE9-572C-BF74-C7F4EE812CBF" xml:space="preserve">// Wait for a length of time specified in nanoseconds
+// This is a blocking call, and is not generally recommended
+// to be used. It should be used only for very short periods.
+//
+Kern::NanoWait(TUint32 aInterval);
+ 
+// This API polls at specified regular intervals, for a
+// specified number of attempts. A function implementing the polling
+// operation is called at these intervals. This does not block the 
+// thread. The poll period is in milliseconds.
+// 
+TInt Kern:: PollingWait(TPollFunction aFunction, TAny *aPtr, 
+                TInt aPollPeriodMs, TInt aMaxPoll);
+</codeblock>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6786C7D8-34B9-496C-890E-03DE018D2DE1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,85 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6786C7D8-34B9-496C-890E-03DE018D2DE1" xml:lang="en"><title>IIC Testing Guide</title><shortdesc>Describes how to test an IIC platform service implementation</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The IIC bus has a standard <xref href="http://www.nxp.com/acrobat/literature/9398/39340011.pdf.dita">IIC
+bus specification v2-1 Jun 2000</xref>. For generic testing, there
+is also an IIC test harness.</p>
+<section id="GUID-02B42C64-BA3B-493D-97A0-8FF4430DD6DC"><title>IIC
+test source files</title><p>The following test code is available to
+test an IIC port.</p><table id="GUID-9F373E0B-6A39-494C-A421-4041F1765724">
+<tgroup cols="4"><colspec colname="col1" colwidth="1.00*"/><colspec colname="col2" colwidth="1.44*"/><colspec colname="col3" colwidth="1.12*"/>
+<colspec colname="col4" colwidth="0.44*"/>
+<thead>
+<row>
+<entry align="center" valign="top"><p><b>File</b></p></entry>
+<entry align="center" valign="top"><p><b>Description</b></p></entry>
+<entry align="center" valign="top"><p><b>Location</b></p></entry>
+<entry align="center" valign="top"><p><b>Usage</b></p></entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p>t_iic.exe</p></entry>
+<entry><p>This file interacts with test-specific LDD to instigate
+tests of functionality that would normally be invoked by kernel-side
+device driver clients of the IIC</p></entry>
+<entry><p>/sf/os/kernelhwsrv/kerneltest/e32test/iic/t_iic.cpp</p></entry>
+<entry><p>Mandatory</p></entry>
+</row>
+<row>
+<entry><p>iic_client_ctrless.ldd</p></entry>
+<entry><p>Kernel-side proxy LDD acting as a client of the IIC.</p></entry>
+<entry><p>/sf/os/kernelhwsrv/kerneltest/e32test/iic/t_iic.cpp</p></entry>
+<entry><p>Mandatory</p></entry>
+</row>
+<row>
+<entry><p>iic_slaveclient_ctrless.ldd</p></entry>
+<entry><p>Kernel-side proxy LDD acting as a slave client of the IIC.</p></entry>
+<entry><p>/sf/os/kernelhwsrv/kerneltest/e32test/iic/t_iic.cpp</p></entry>
+<entry><p>Mandatory</p></entry>
+</row>
+<row>
+<entry><p>iic_client.ldd</p></entry>
+<entry><p>Kernel-side proxy LDD acting as a client of the IIC.</p></entry>
+<entry><p>/sf/os/kernelhwsrv/kerneltest/e32test/iic/t_iic.cpp</p></entry>
+<entry><p>Mandatory</p></entry>
+</row>
+<row>
+<entry><p>iic_slaveclient.ldd</p></entry>
+<entry><p>Kernel-side proxy LDD acting as a slave client of the IIC.</p></entry>
+<entry><p>/sf/os/kernelhwsrv/kerneltest/e32test/iic/t_iic.cpp</p></entry>
+<entry><p>Mandatory</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p>The above test system consists of the executable (t_iic.exe)
+and associated ldd files. The default version of t_iic.exe is used
+to test that the platform independent layers of the IIC component
+work correctly. The default version only works on the emulator, so
+the layer below the SHAI is a series of stubs. In order for this test
+harness to work with actual hardware, extensive modification to t_iic.exe
+will have to be undertaken. </p></section>
+<section id="GUID-99B49CF1-FEE1-4F60-8265-DC592360ED04"><title>Test
+application use cases</title><p>The IIC test application is used to
+test:</p><ul>
+<li><p>The basic master channel functionality.</p></li>
+<li><p>The master channel data handling for transaction functionality.</p></li>
+<li><p>The master channel preamble and multi-transaction functionality.</p></li>
+<li><p>The slave channel capture and release APIs.</p></li>
+<li><p>The slave channel capture for receive and transmit of data.</p></li>
+<li><p>That MasterSlave channels can only be used for one mode at
+a time.</p></li>
+</ul></section>
+<section id="GUID-CCAF786E-A52C-4BAF-8C84-07FF68776376"><title>Limitations</title><p>The IIC test application has the following known limitations:</p><ul>
+<li><p>This test suite does not work on hardware.</p></li>
+</ul></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-67CFF27B-55AF-42AC-95AF-E71A7C54039E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-67CFF27B-55AF-42AC-95AF-E71A7C54039E" xml:lang="en"><title>Sample
+Device Drivers</title><shortdesc>This document describes the steps and options for coding a device
+driver, and how to use APIs to access the services provided by the Symbian
+platform kernel.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Illustrations of the use of APIs are taken from a number of example device
+drivers. These are summarised below. All of the drivers implement support
+for serial communications over a UART. They are designed to show a number
+of different implementation techniques. </p>
+<table id="GUID-6AD1B279-724D-5EBD-9372-66400B8C9465">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Name</b>  </p> </entry>
+<entry><p> <b>Key functionality</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <filepath> exdriver_pio</filepath>  </p> </entry>
+<entry><p>Shows a simple driver running on a kernel DFC thread. It polls for
+data using a timer. </p> <p><xref href="GUID-1AFAD1C4-340B-4119-94A8-F50E9D8DA8E6.dita">Timers</xref> discusses
+timers in detail. </p> </entry>
+</row>
+<row>
+<entry><p> <filepath> exdriver_int</filepath>  </p> </entry>
+<entry><p>Illustrates the use of interrupts and asynchronous request handling. </p> <p><xref href="GUID-4DAC39E0-2EC2-40F7-9AEF-4FDA09F1A151.dita">Asynchronous Requests</xref> describes
+how to implement handling of asynchronous requests. </p> <p><xref href="GUID-8FA1B2B0-5842-4D5D-BD61-C2D79B56ADC6.dita">Interrupt
+Service Routine (ISR)</xref> describes how to write ISRs to handle interrupts
+from hardware devices. </p> </entry>
+</row>
+<row>
+<entry><p> <filepath> exdriver_dma</filepath>  </p> </entry>
+<entry><p>Illustrates the use of DMA (Direct Memory Access). </p> <p><xref href="GUID-D1F7D21F-BA9D-482C-9B58-7C53A680145A.dita">DMA</xref> describes how
+to use DMA for fast copying of data from memory to memory, and between memory
+and peripherals. </p> </entry>
+</row>
+<row>
+<entry><p> <filepath>exdriver_chnk</filepath>  </p> </entry>
+<entry><p>Illustrates shared chunks and synchronization in a multi-thread
+context. </p> <p><xref href="GUID-132349A6-9A5F-4866-A54D-F01B6F58ABDD.dita">Shared
+Chunks</xref> describes how to share data efficiently without the overhead
+of memory copy operations. </p> </entry>
+</row>
+<row>
+<entry><p> <filepath> exdriver_sync</filepath>  </p> </entry>
+<entry><p>Illustrates synchronous request handling, and the use of the <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita"><apiname>DLogicalChannelBase</apiname></xref> base
+class for LDDs. </p> <p><xref href="GUID-CFE0A4EB-845C-43B6-A732-AA155AFD99D6.dita">User
+Requests and Synchronisation</xref> discusses the options for how LDDs can
+handle requests. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table>
+<p>The source code for the example device drivers is delivered as part of
+the Symbian platform source code on kits, using the directory structure described
+previously in the <xref href="GUID-2ADB873A-1580-476A-9642-AB47D13D4A98.dita">Source
+Directory Structure</xref> section. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,192 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF" xml:lang="en"><title>Keyword reference (S-Z)</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This page lists the keywords starting from S to Z. </p>
+<section id="GUID-41316071-4988-5E48-896C-61F7E6E766DD"><title>secondary</title> <codeblock id="GUID-512F128C-4794-576B-9638-58270CA31F19" xml:space="preserve">secondary = &lt;source-file&gt; &lt;destination-image-file&gt; [File-attribute-list] [Override-Attribute-list]</codeblock> <p> <i>rombuild only</i>  </p> <p>A standard executable file that
+is loaded by the kernel; this is the file server. All subsequent files
+can be loaded through the file server. </p> <p>As with all standard
+executable files, this is loaded, relocated and stripped of its relocation
+information. </p> </section>
+<section id="GUID-D31658A3-6346-5BBE-B79C-D274113C6120"><title>section</title> <p> <i>rombuild only</i>  </p> <p>ROMs can be sectioned into two
+parts allowing the upper part of the ROM to be switched for language
+variations and file patching. This is independent of the extension
+ROM mechanism. </p> <p>This keyword appears at the point in the obey
+file where the ROM to be split. All files before this line appear
+in the first (constant) section: Files after appear in the second
+(patch/language) section. </p> </section>
+<section id="GUID-FBB17172-11E6-53AC-A833-7DEF02EFA57E"><title>SECTION2</title> <codeblock id="GUID-8A665DE5-9F68-5DB6-8F47-23CB9B32D03F" xml:space="preserve">SECTION2 &lt;anything&gt;</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Provides support for <codeph>rombuild</codeph>'s capability to create ROMs divided into two sections. </p> <p>The
+two sections are termed the upper and lower section. The upper section
+can be replaced without needing to change the lower section. This
+facility is most often used to put localised resource files into the
+upper section. This keyword provides <codeph>BUILDROM</codeph>'s support
+for gathering marked obey source lines and placing them in the upper
+section of the ROM. </p> <p>All lines beginning with the <codeph>SECTION2</codeph> keyword are removed from the <filepath>.iby</filepath> file and
+are placed into a separate list with the <codeph>SECTION2</codeph> keyword removed. When <codeph>BUILDROM</codeph> encounters the <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-D31658A3-6346-5BBE-B79C-D274113C6120">section</xref> keyword, the accumulated <codeph>SECTION2</codeph> list is inserted after the <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-D31658A3-6346-5BBE-B79C-D274113C6120">section</xref> line, and subsequent <codeph>SECTION2</codeph> keywords
+are removed as they occur. If no <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-D31658A3-6346-5BBE-B79C-D274113C6120">section</xref> keyword is found the accumulated <codeph>SECTION2</codeph> list is emitted after the end of the input file(s). </p> <p>For
+example: </p> <codeblock id="GUID-F284667A-1538-5963-9906-D6A3717B43BF" xml:space="preserve">LANGUAGE_CODE 01
+LANGUAGE_CODE 10
+DEFAULT_LANGUAGE 10
+file=sourcedir\myapp.dll destdir\myapp.dll
+SECTION2 REM bitmaps for myapp
+SECTION2 bitmap=MULTI_LINGUIFY( MBM sourcedir\myapp destdir\myapp )
+file=sourcedir\myengine.dll destdir\myengine.dll
+section 0x800000
+file=sourcedir\example destdir\example
+SECTION2 data=sourcedir\example2 destdir\example2
+      </codeblock> <p>becomes: </p> <codeblock id="GUID-73534907-1DC4-5CCB-B6FA-9C13F56196EC" xml:space="preserve">file=sourcedir\myapp.dll destdir\myapp.dll
+file=sourcedir\myengine.dll destdir\myengine.dll
+
+section 0x800000
+REM bitmaps for myapp
+data=sourcedir\myapp.M01_rom destdir\myapp.M01
+data=sourcedir\myapp.M10_rom destdir\myapp.MBM
+
+file=sourcedir\example destdir\example
+data=sourcedir\example2 destdir\example2
+</codeblock> <p>See also <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-977C6041-365A-5D23-A370-A9939689FFD7">MULTI_LINGUIFY</xref>. </p> </section>
+<section id="GUID-908AECD2-5F98-55B9-BFFF-E25D7AA90D50"><title>sectorsize</title> <codeblock id="GUID-248A8CFB-23B7-540B-9F20-6CAFC7A4292A" xml:space="preserve">sectorsize=&lt;number of bytes&gt;</codeblock> <p> <i>rofsbuild only</i>  </p> <p>Configures the number of bytes
+in each sector for the file system in data-drive images. </p> </section>
+<section id="GUID-0E5CF5E6-0547-5185-9AE8-B6BF57802017"><title>singlekernel</title> <codeblock id="GUID-B1B9F517-46B2-5F5B-9F63-0E6E3D7A1CE9" xml:space="preserve">singlekernel</codeblock> <p> <i>rombuild only</i>  </p> <p>Specifies that this ROM image
+has one kernel executable within it. This is the default. </p> <p>Note that this keyword is mutually exclusive with <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-B97ECBBE-B28F-5241-9D78-DBA20108BB14">multikernel</xref> keyword. </p> </section>
+<section id="GUID-AD2096D6-D991-5044-83E2-1E47411227DD"><title>sisfile</title> <codeblock id="GUID-563E57B0-8B13-558D-96C1-75F259FAE99E" xml:space="preserve">sisfile = &lt;source-file&gt;</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Specifies the <filepath>sis</filepath> files to be installed on the data drive. </p> <p> <b>Note</b>: A
+directory containing <filepath>sis</filepath> files can also be provided
+as input to this keyword. </p> </section>
+<section id="GUID-04F39AC1-3947-5C80-90BB-55CDF4D34571"><title>spidata</title> <codeblock id="GUID-A35138A6-58F5-5EB8-8337-5DFB8B3CE65E" xml:space="preserve">spidata = &lt;source-file&gt; &lt;original-destination-file&gt; &lt;spi-id&gt; &lt;target-spi-dir&gt;</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Specifies input files used to
+create a static plug-in information (SPI) file. </p> <p>Its parameters
+are: </p> <table id="GUID-D4D2480C-19EF-57F0-8F1A-7C7F173DAABA">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>source-file</codeph>  </p> </entry>
+<entry><p>The location of the source file. This is the resource file
+to build into the SPI file. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>original-destination-file</codeph>  </p> </entry>
+<entry><p>The location that the resource should be placed in if the
+SPI file is not created. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>spi-id</codeph>  </p> </entry>
+<entry><p>Name of the SPI file in which the resource should be stored.
+For ECom, this is <filepath>ecom.spi</filepath>. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>target-spi-dir</codeph>  </p> </entry>
+<entry><p>The directory in which to create the SPI file in the ROM
+image. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>An SPI file concatenates several resource files together.
+It is currently used to record the ECom plug-ins that are in ROM.
+This allows the ECom framework to register the ROM-based plug-ins
+without having to scan the file system for individual resource files.
+IBY files are not expected to use the <codeph>spidata</codeph> keyword
+directly for this purpose: instead, they should use the <codeph>ECOM_PLUGIN</codeph> macro (see <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-92EAD7F7-6524-57BF-9417-B455AF469C7A">__ECOM_PLUGIN</xref>) which <codeph>BUILDROM</codeph> converts to
+the required <codeph>spidata</codeph> statement. </p> <p>Note that
+creation of SPI files is optional (see <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">BUILDROM</xref>).
+If it is switched on: </p> <ul>
+<li id="GUID-64974587-F170-5AE0-8465-1E660D62BBDC"><p>the <codeph>spidata</codeph> statements are processed to determine which SPI
+files need to be created. <xref href="GUID-922E4771-C1FD-5C88-9C11-57499684DB97.dita">spitool</xref> is
+called to create an SPI file, and a data statement is generated in
+the final IBY file to include an SPI file in ROM. </p> </li>
+<li id="GUID-66FAF689-CAE1-5D4B-926F-D157410C0DD3"><p>copies of each
+SPI file are placed in the same directory as the created ROM image.
+This is necessary for the possibility of creating extension/composite
+ROMs. </p> </li>
+<li id="GUID-2E615A16-5F25-5CEB-A4A5-369594E3575F"><p>any resource
+files included in an SPI file are not placed in the ROM image. This
+avoids duplication and an unnecessary increase in the size of the
+ROM. </p> </li>
+</ul> <p>If SPI creation is switched off all resource files are placed
+in the ROM image in the locations specified by the <codeph>&lt;original-destination-file&gt;</codeph> parameters of the <codeph>spidata</codeph> statements. </p> </section>
+<section id="GUID-E54F3C5D-ED40-5196-8D9C-6B7B71826F79"><title>spidatahide</title> <codeblock id="GUID-B0AFC9FE-A750-57F5-AA4E-E8757F0616B4" xml:space="preserve">spidatahide = &lt;source-file&gt; &lt;spi-id&gt; &lt;target-spi-dir&gt;</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Specifies the files that need
+to be marked as hidden in the static plug-in information (SPI) file,
+to hide the associated ECom plug-in in the ROM. </p> <p>Its parameters
+are: </p> <table id="GUID-A0D56D11-CE2C-583F-B88E-20D8CAAF898D">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>source-file</codeph>  </p> </entry>
+<entry><p>The location of the source file to be marked as hidden in
+the SPI file. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>spi-id</codeph>  </p> </entry>
+<entry><p>The SPI file name in which the resource should be stored.
+For ECom, this is <filepath>ecom.spi</filepath> or <filepath>ecom.snn</filepath>. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>target-spi-dir</codeph>  </p> </entry>
+<entry><p>The directory in which to create the SPI file in the ROM
+image. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>The file is marked as hidden in the SPI file by writing
+the data length of the file as 0. A resource language file can be
+overridden using this keyword in the IBY file. If you intend to hide
+both the resource file and the DLL, use the <codeph>HIDE_ECOM_PLUGIN</codeph> macro (see <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-50550839-5F46-5096-98A4-857B62E19C34">_HIDE__ECOM_PLUGIN</xref>), which enables <codeph>BUILDROM</codeph> to generate the required <codeph>spidatahide</codeph> statement. </p> <p>Note that creation of SPI files is optional (see <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">BUILDROM</xref>).
+If <codeph>BUILDROM</codeph> is allowed to generate the SPI files,
+the <codeph>spidatahide</codeph> statements are processed to determine
+which resource file should be hidden in the SPI files that are to
+be created. The <codeph>BUILDROM</codeph> calls the <codeph>spitool</codeph> to create an SPI file, and a <codeph>data</codeph> statement is
+added to the final <filepath>.IBY</filepath> file to include the SPI
+file in the ROM. </p> </section>
+<section id="GUID-1D2BBB97-2406-55D2-AEAB-4A584EEB3808"><title>srecordbase</title> <codeblock id="GUID-1C267252-68BB-5619-9532-467873276926" xml:space="preserve">srecordbase = &lt;hex-address&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Destination address for S-record
+download. </p> </section>
+<section id="GUID-B784EA89-934C-55CB-9819-A28B98E4F5FA"><title>srecordfilename</title> <codeblock id="GUID-C315C23F-B9EA-5026-8FC3-6E9EA62F52FB" xml:space="preserve">srecordfilename = &lt;srec-file-name&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p> <codeph>rombuild</codeph> can
+write an image in Motorola S-record format. This happens if a name
+for the output file is specified here. A filename of "*" can be specified,
+which means use the file name specified on the <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-29BEF45C-2361-5245-9184-0261B99B6FB1">romname</xref> keyword and append <filepath>.screc</filepath>. </p> </section>
+<section id="GUID-205BE385-1937-5034-9DBE-51D1A276326A"><title>stack</title> <codeblock id="GUID-C78890E1-4E75-5891-A933-A22085A456C2" xml:space="preserve">stack = &lt;hex-size&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Overrides the default stack size
+for the executable. </p> </section>
+<section id="GUID-2F8E864B-0754-566B-9F88-3FC44E4ECF91"><title>stackreserve</title> <codeblock id="GUID-A8699692-D710-55C7-96C2-7C0C7767D1C9" xml:space="preserve">stackreserve = &lt;hex-size&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Overrides the maximum size of
+the stack. </p> </section>
+<section id="GUID-0D56F068-91DE-50C8-94FF-9744B5E5B3E6"><title>stop</title> <codeblock id="GUID-4FB3979B-FF24-56C7-8F56-F9FC6FE9D71D" xml:space="preserve">stop</codeblock> <p> <i>rombuild and rofsbuild</i>  </p> <p>Stops processing the
+obey file. The rom image is not generated. </p> </section>
+<section id="GUID-39410510-6C93-5203-8577-5C4D1520517F"><title>time</title> <codeblock id="GUID-96248FC4-DA06-5EF4-AA22-33E08F14BCFC" xml:space="preserve">time = dd/mm/yyyy hh:mm:ss</codeblock> <p> <i>rombuild and rofsbuild</i>  </p> <p>If specified, overwrites
+the date-time stamp of the ROM image with this value. If not specified,
+the image is time and date stamped from the system clock of the build
+PC. </p> </section>
+<section id="GUID-B375C7B6-DFA5-593C-8BEC-763789B89CE0"><title>TODAY</title> <codeblock id="GUID-D9B15174-1313-570F-AB87-4D9B441B8705" xml:space="preserve">TODAY</codeblock> <p> <i>BUILDROM only</i>  </p> <p>A pre-defined substitution. This
+is replaced with today's date in the format <codeph>dd/mm/yy</codeph>  </p> <p>Note that there is no UNDEFINE facility, and substitutions
+are applied in an unspecified order. </p> </section>
+<section id="GUID-31DD609C-5C70-5626-B892-5FD7BA63B640"><title>trace</title> <codeblock id="GUID-8F0E90BB-5880-5A62-94CE-2DF8CA354EC7" xml:space="preserve">trace = &lt;32 bit hex-number&gt;</codeblock> <p> <i>rombuild and rofsbuild</i>  </p> <p>Turns on rombuild tracing.
+This is internal to Symbian. </p> </section>
+<section id="GUID-A53DC5BA-7531-53F4-9117-4F26D372F212"><title>uid1</title> <codeblock id="GUID-510DD6AA-ACDC-53B6-A246-EA072069969E" xml:space="preserve">uid1 = &lt;uid-value&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Overrides the first UID for the
+executable. </p> </section>
+<section id="GUID-342B6CA5-8508-5673-900F-9CF331F5AC79"><title>uid2</title> <codeblock id="GUID-B641C5A8-B032-528E-9AE4-E354B2238759" xml:space="preserve">uid2 = &lt;uid-value&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Overrides the second UID for the
+executable. </p> </section>
+<section id="GUID-6F5B7223-A8E2-51EC-B950-79426DB0AAB4"><title>uid3</title> <codeblock id="GUID-66016978-0FDB-5620-A378-024C62BC7E86" xml:space="preserve">uid3 = &lt;uid-value&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Overrides the third UID for the
+executable. </p> </section>
+<section id="GUID-AF6440C5-839B-5CC7-A645-405F34BC643F"><title>unicode</title> <codeblock id="GUID-8D9D383D-A8BA-5194-BDFB-27AC8C99E322" xml:space="preserve">unicode</codeblock> <p> <i>rombuild only</i>  </p> <p>Indicates that this is a Unicode
+build; this is the default if not present and <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-A97C37B0-8909-58FA-9BC2-2BD68F25A8B0">ascii</xref> is not coded. </p> </section>
+<section id="GUID-AE7F4574-69AD-4817-A15D-A4560BA210D6"><title>unpaged</title><p><codeph>unpaged</codeph></p><p><i>rombuild and rofsbuild</i></p><p>Use the <codeph>unpaged</codeph> keyword to specify that the executable
+is not paged. This is the same as specifying both <codeph>unpagedcode</codeph> and <codeph>unpageddata</codeph> keywords for an executable.</p></section>
+<section id="GUID-6423A7D6-1129-49A1-882E-64C5182A197F"><title>unpagedcode</title><p><codeph>unpagedcode</codeph></p><p><i>rombuild and rofsbuild</i></p><p>Use the <codeph>unpagedcode</codeph> keyword to specify that
+the executable is not code paged. </p></section>
+<section id="GUID-F6B182CA-4042-4E03-8718-893423913EB8"><title>unpageddata</title><p><codeph>unpageddata</codeph></p><p><i>rombuild and rofsbuild</i></p><p>Use the <codeph>unpageddata</codeph> keyword to specify that
+the data in the executable is not <xref href="http://developer.symbian.org/main/documentation/reference/s3/pdk/GUID-1391CDCC-9A09-54FB-BA7D-BC7A91DB2351.html" scope="external">data paged</xref>. </p></section>
+<section id="GUID-434D1F4F-5CA5-5793-9119-8C89A8C0B251"><title>variant[[HWVD]]</title> <codeblock id="GUID-C5ACF3A5-68ED-52AA-8705-73236AA4BF5B" xml:space="preserve">variant[[HWVD]] = &lt;source-file&gt; &lt;destination-image-file&gt; [File-attribute-list] [Override-Attribute-list]</codeblock> <p> <i>rombuild only</i>  </p> <p>Defines hardware variants. </p> <p>It should be applied to the variant DLL. The <filepath>ecust.dll</filepath> of each hardware variant to be supported, and must specify a suitable <codeph>HWVD</codeph>. Note that the HWVD must be enclosed within square
+brackets. </p> </section>
+<section id="GUID-6CD93289-02BF-57B9-8BD4-CFC0FF1EB3E0"><title>version</title> <codeblock id="GUID-997783A0-4F8F-5749-96ED-1BB3B3BFBD50" xml:space="preserve">version = [ &lt;major&gt; ] [ .&lt;minor&gt; ] [ (&lt;build&gt;) ]</codeblock> <p> <i>rombuild and rofsbuild</i>  </p> <p>The ROM version number
+as represented by its three component values. </p> </section>
+<section id="GUID-169AE2D3-6382-5262-A763-E68B1678967F"><title>volume</title> <codeblock id="GUID-B05502B6-5EE5-5AA6-9339-C09B4D519A51" xml:space="preserve">volume=&lt;volume label&gt;</codeblock> <p> <i>rofsbuild only</i>  </p> <p>Configures the volume label for
+the file system in data-drive images. </p> </section>
+<section id="GUID-821B5D5B-D800-5CB1-BFF1-7AD0D1402CC6"><title>WARNING</title> <codeblock id="GUID-5D46FA03-B8E5-5925-AD86-7A5EC63D2B26" xml:space="preserve">WARNING &lt;anything at all&gt;</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Prints the rest of the line following
+the WARNING keyword to standard output, and reports the source file
+name and the line number. </p> </section>
+<section id="GUID-996F3E94-4AB8-599A-A3BD-4F4621F0CB98"><title>zdriveimagename</title> <codeblock id="GUID-09B31D56-01F9-5F6E-A999-963A91EA382B" xml:space="preserve">zdriveimagename = &lt;image name.img&gt;</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Specifies the name of the Z drive
+description image file( ROM, ROFS, extension ROFS or CORE image). </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-68446E8E-129C-444A-836A-EF8F56BFE0BC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,72 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE task
+  PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
+<task id="GUID-68446E8E-129C-444A-836A-EF8F56BFE0BC" xml:lang="en"><title>Handling Interrupts</title><shortdesc>Describes how a device driver can use interrupts.</shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody>
+<prereq id="GUID-FCD339E1-54B6-4F3F-9DF0-1C920667001C"><p>The clients
+of the Interrupt platform service must know the following:<ul>
+<li><p>ISR function</p></li>
+<li><p>Interrupt ID</p></li>
+</ul></p></prereq>
+<context id="GUID-3EB0898F-D1ED-47D4-B675-3B8627909384"><p>Interrupts
+are sent by hardware to indicate an event has occurred. Interrupts
+typically cause an Interrupt Service Routine (ISR) to be executed.
+The Interrupt platform service specifies the interface APIs for setting
+up the ISRs and connecting them to specific Interrupt IDs. Interrupt
+handling is a blocking high priority task and needs to take a minimal
+amount of time. While the ISR is executed the kernel will be in an
+indeterminate state and this puts restrictions on doing various operations,
+such as allocating heap storage. </p><p>The device driver provides
+an ISR to handle an interrupt and perform the required response to
+the events. Symbian platform provides an <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita"><apiname>Interrupt</apiname></xref> class (implemented by the ASSP) with an API to bind and unbind an
+Interrupt ID with an ISR. </p><p>An Interrupt ID is identified by
+number, defined as a <codeph>TInt</codeph> type. Typically, the ASSP
+layer may define this number for each interrupt in a header file and
+export it so that it can be included and used by device drivers. Alternatively,
+device drivers may be required to retrieve the appropriate Interrupt
+ID from the Hardware Configuration Repository (HCR). The scheme used
+is implementation dependent.</p></context>
+<steps id="GUID-4DD07DEC-6017-4237-BE46-1D69E5FBD744-GENID-1-2-1-10-1-5-1-7-1-1-8-1-6-1-3-3">
+<step id="GUID-0CFB6DD5-2309-40EE-84F5-4BC4449BE5BB"><cmd>Call <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-1D846CC9-843D-363B-A0F2-5719B18C0854"><apiname>Interrupt::Bind(TInt, TIsr, TAny*)</apiname></xref> with appropriate Interrupt
+ID, ISR and argument to be passed to the ISR. This function binds
+the interrupt to the ISR.</cmd>
+</step>
+<step id="GUID-94DAD86A-0721-4663-A992-8FA001864B5F"><cmd>Assign the
+priority to the Interrupt if needed using the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-975988C3-B9B0-3B82-8CE8-9691E8C54515"><apiname>Interrupt::SetPriority(TInt,
+TInt)</apiname></xref> function.</cmd>
+</step>
+<step id="GUID-E731F5A3-B31F-43A5-BE61-81AA25DCCE3F"><cmd>Enable the
+interrupt by calling the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-23BE001A-205A-33AE-9533-8D50C494211F"><apiname>Interrupt::Enable(TInt)</apiname></xref> function. This function is called when the device driver is ready
+to  handle hardware events.</cmd>
+<info><p>An ISR is a static function that will be executed when an
+interrupt is received by the interrupt handler. The interrupt handler
+executes the ISR that is bound to the received Interrupt ID. It performs
+the actions necessary to service the event of the peripheral that
+generated the interrupt. The ISR must either remove the condition
+that caused the interrupt or call  <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-2D14E023-E6ED-39BF-8B31-6FA510957A8A"><apiname>Interrupt::Disable()</apiname></xref> otherwise the machine will hang. The device driver may queue a DFC
+within the ISR to perform deferred processing.</p></info>
+</step>
+<step id="GUID-A088A6FD-67B5-4112-894E-5CE1A2A3BAE6"><cmd>Once the
+DFC processing is completed, it is a good practice to enable the interrupt
+if it is disabled, using <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-23BE001A-205A-33AE-9533-8D50C494211F"><apiname>Interrupt::Enable(TInt)</apiname></xref> function. </cmd>
+</step>
+<step id="GUID-611D449F-C0EB-4027-8E4C-D5CC5D44A29D"><cmd>At the point
+when the PDD of the device driver gets unloaded, unbind the ISR from
+the specified Interrupt Id using <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-4980B3FF-0C14-3E64-8BB3-E8431CB649F9"><apiname>Interrupt::Unbind(TInt)</apiname></xref> function by passing Interrupt ID as the parameter.</cmd>
+</step>
+</steps>
+<result id="GUID-286F666E-B037-4C0E-9A87-02A3CBAB9B8A"><p>The device
+driver is able to handle interrupts.</p></result>
+</taskbody><related-links>
+<link href="GUID-D0F5D40A-28D2-4A2E-9B40-180537E60F56.dita"><linktext>Interrupt
+Client Interface Guide</linktext></link>
+<link href="GUID-654A788A-526A-4C3F-838C-05B09F0D5445.dita"><linktext>Interrupt
+Technology Guide</linktext></link>
+</related-links></task>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6873E764-4132-46C8-8444-6301CF4D2033.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,68 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6873E764-4132-46C8-8444-6301CF4D2033" xml:lang="en"><title>DMA Hardware Interface</title><shortdesc>Describes the interface between the DMA hardware and the
+DMA platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-2E3C9F69-CAE2-4F36-8291-F426B36F911B"><title>Introduction</title><p>This document describes the functionality that the DMA hardware
+has to provide in order to be compliant with the DMA platform service.</p></section>
+<section id="GUID-83EFC137-9C18-477A-A042-ACBF70CFCA3C"><title>Interface
+limitations</title><p>None</p></section>
+<section id="GUID-0C191930-C521-4BA4-8B41-AA3C730B2606"><title>Adaptation
+dependencies</title><p>Dependent on the Application Specific Standard
+Product (ASSP) chip that is being used.</p></section>
+<section id="GUID-8F209D96-3E1E-4C9C-BB60-B38082126242"><title>The
+interface</title><p>In order to use the DMA platform service, the
+following information is required:</p><ul>
+<li><p>The location of the data source.</p></li>
+<li><p>The location of the data destination.</p></li>
+<li><p>The channel to be used.</p></li>
+<li><p>The amount of data to be transferred.</p></li>
+<li><p>How much data is to be transferred at once (packet size).</p></li>
+<li><p>Synchronization setup</p></li>
+<li><p>Interrupt settings</p></li>
+</ul><p>How the above settings relate to the operation of the DMA
+is shown in the diagram below:</p><fig id="GUID-3B24E56D-A82D-411C-B3AF-BB5556B4BD1A">
+<title>DMA settings</title>
+<image href="GUID-610E0C09-F014-4DA2-8411-D7A0CDAF5BBB_d0e90471_href.png" placement="inline"/>
+</fig><p>The settings listed above will now be discussed in more detail.</p><p><b>Location of the data source</b></p><p>This specifies where
+data is to be transferred from (the source). This can be one of the
+following:</p><ul>
+<li><p>Memory</p></li>
+<li><p>Peripheral</p></li>
+</ul><p>If the source location is a peripheral, then its port will
+have to be specified along with the location of the data source.</p><p><b>Location of the data destination</b></p><p>This specifies the
+final location of the data to be transferred (the destination). As
+with the location of the data source, this can be one of the following:</p><ul>
+<li><p>Memory</p></li>
+<li><p>Peripheral</p></li>
+</ul><p>If the destination is to be a peripheral, then the port configuration
+will have to be specified along with the location of the destination.</p><p><b>Channel</b></p><p>The DMA platform service transfers data over
+channels which are configured independently. The priority order of
+the each channel is specified in the DMA platform service API.</p><p><b>Amount of data to be transferred</b></p><p>This setting specifies
+the amount of data that is to be transferred from the source to the
+destination.</p><p><b>Data packet size</b></p><p>Data is transferred
+in packets of a specified size. The acceptable values are:</p><ul>
+<li><p>4 bytes</p></li>
+<li><p>8 bytes</p></li>
+<li><p>16 bytes</p></li>
+<li><p>32 bytes</p></li>
+<li><p>64 bytes</p></li>
+<li><p>128 bytes</p></li>
+</ul><p><b>Synchronization settings</b></p><p>These specify how the
+transfer between the source and destination is to be controlled. This
+is used when either the source or the destination can only take part
+in a data transfer depending on external events. The synchronization
+can be set up to be one of the following:</p><ul>
+<li><p>No synchronized transfer</p></li>
+<li><p>Synchronize the transfer after a preset number of bytes</p></li>
+</ul><p><b>Interrupt settings</b></p><p>These are used to specify
+how the DMA and/or specific channels should react to interrupt events.</p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-687997B5-BDFD-49D1-947B-4AB21C3AF58C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-687997B5-BDFD-49D1-947B-4AB21C3AF58C" xml:lang="en"><title>The
+Running Model</title><shortdesc>This document describes the model by which a device driver handles
+requests.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-697C8B0A-2468-4699-82FF-2E02E3F857A0">      
+      <p>Once a logical channel and a physical channel, if appropriate, have
+been created and initialised, the driver is ready to handle requests. </p> <p>On
+the kernel-side, requests can be handled by one or more kernel-side threads,
+allowing for rich and complex behaviour. Alternatively, if appropriate, a
+request can be handled by code running in the context of the client user-side
+thread, but running in supervisor mode. </p> <p>There are two kinds of request,
+synchronous and asynchronous. </p>     </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-690F943E-7459-4FBA-B33C-258969D7759A-master.png has changed
Binary file Adaptation/GUID-690F943E-7459-4FBA-B33C-258969D7759A_d0e93193_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6A4FE3A3-2E5D-51BB-8272-5995586291E9.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,222 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6A4FE3A3-2E5D-51BB-8272-5995586291E9" xml:lang="en"><title>LCD Extension Implementation Tutorial</title><shortdesc>This topic describes how to create an LCD Extension.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The topic uses a reference board port named <filepath>template_variant</filepath> as an example implementation. </p>
+<section id="GUID-7DDD91D2-A69F-4940-AA58-74EB2A989E55"><title>Build
+environment</title> <p>In the template reference board port, the <filepath>.mmp</filepath> file for the LCD Extension is <filepath>...\template_variant\lcdtemplate.mmp</filepath>. This is one of the <codeph>PRJ_MMPFILES</codeph> referenced in
+the template variant's <filepath>bld.inf</filepath> file in the <filepath>...\template_variant\...</filepath> directory, and means that the
+LCD Extension is built as part of the Variant. </p> <p>The source
+for the driver is contained entirely within <filepath>...\template_variant\specific\lcd.cpp</filepath>. </p> <p>The driver is defined as a kernel extension and is loaded
+early in the boot sequence. </p> </section>
+<section id="GUID-FC49B296-5DFA-4C19-BEDE-F641D70E5ED9"><title>Initialization</title> <p>The driver functionality is almost entirely encapsulated by the <codeph>DLcdPowerHandler</codeph> class. This is a power handler class derived
+from <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita"><apiname>DPowerHandler</apiname></xref>. An instance of <codeph>DLcdPowerHandler</codeph> is created when the extension is loaded. </p> <p> <codeph>DLcdPowerHandler</codeph> is defined within the source file itself <filepath>...\template_variant\specific\lcd.cpp</filepath>. </p> <p>As the driver is a kernel extension, it must have a <codeph>DECLARE_STANDARD_EXTENSION()</codeph> statement. In the template
+port, this is implemented as follows: </p> <codeblock id="GUID-BB93E7E7-06DA-5A12-ABA1-D07AA246D6FC" xml:space="preserve">DECLARE_STANDARD_EXTENSION()
+    {
+    __KTRACE_OPT(KPOWER,Kern::Printf("Starting LCD power manager"));
+    
+    // create LCD power handler
+    TInt r=KErrNoMemory;
+    DLcdPowerHandler* pH=new DLcdPowerHandler;
+    if (pH)
+        r=pH-&gt;Create();
+    
+    __KTRACE_OPT(KPOWER,Kern::Printf("Returns %d",r));
+    return r;
+    }
+</codeblock> <p>This simply creates an instance of the <codeph>DLcdPowerHandler</codeph> class and then calls its <codeph>Create()</codeph> function which
+implements the display setup. This function should do the following: </p> <ul>
+<li id="GUID-4D3B36C6-C782-5B3F-8244-7FD33B9976C6"><p>map the video
+RAM </p> </li>
+<li id="GUID-B693BD2B-50FF-554D-AF2B-1992A472F586"><p>setup the video
+info structure </p> </li>
+<li id="GUID-1DF67FC0-90FA-5853-88C2-6DBA5C60F377"><p>install the
+HAL handler </p> </li>
+<li id="GUID-2B8080C4-2A9F-5AA2-B609-3DC8F5759DDE"><p>install the
+power handler. </p> </li>
+</ul> <p><b> Map the video RAM</b> </p> <p>The frame buffer is a <xref href="GUID-2A34A3DD-A7FE-34A0-B0B7-BB0A4F04B098.dita"><apiname>DPlatChunkHw</apiname></xref> object, and should be mapped as globally accessible,
+readable and writeable. It should <i>not</i> be mapped as writeback
+cached, it should be either not-cached or write-through. The advantage
+of write through is that it allows the use of the write buffer. </p> <codeblock id="GUID-148795D9-45A2-526B-A2F7-57B5B2AAC8AB" xml:space="preserve">TInt DLcdPowerHandler::Create()
+    {
+    ...
+
+    // map the video RAM
+    TInt vSize = ((TemplateAssp*)Arch::TheAsic())-&gt;VideoRamSize();
+    ivRamPhys = TTemplate::VideoRamPhys();                // EXAMPLE ONLY: assume TTemplate interface class
+    TInt r = DPlatChunkHw::New(iChunk,ivRamPhys,vSize,EMapAttrUserRw|EMapAttrBufferedC);
+    if ® != KErrNone)
+        return r;
+ ...
+</codeblock> <p>If the frame buffer resides in main RAM and there
+is no restriction on which physical addresses may be used for it,
+physical RAM for the frame buffer should be reserved by using <xref href="GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680.dita#GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680/GUID-B506D835-505D-3D89-A840-475F291908DC"><apiname>Epoc::AllocPhysicalRam()</apiname></xref>. </p> <p>If the frame buffer does
+not reside in main RAM, there is no problem about reserving it. </p> <p>If the frame buffer must reside at a specific address in main
+RAM, there are two strategies available for reserving it: </p> <ul>
+<li id="GUID-29D3BF5F-442B-5912-A8B9-4F1F76C1879E"><p>If no conflicts
+are permitted between the frame buffer and memory allocations made
+during the kernel boot (for example, if the frame buffer must reside
+at the end of main memory), simply use <xref href="GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680.dita#GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680/GUID-78F136DC-023B-30AB-A1AB-34D6BC4F1B3E"><apiname>Epoc::ClaimPhysicalRam()</apiname></xref>. This function just marks a region of physical RAM as allocated,
+returning an error if any part of the region has already been used. </p> </li>
+<li id="GUID-F2C5ED3A-767A-58CA-BDC6-78D3C1820C80"><p>The required
+physical RAM region can be reserved in the bootstrap. The correct
+place to do this is in the implementation of the boot table function <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-B3C6ACE9-A803-59D4-8EBD-314363905427">BTF_Reserve</xref> when writing platform-specific source code for
+the bootstrap. See the Bootstrap <xref href="GUID-5EB03086-A87D-5588-8927-7A7F8DB38366.dita">Port Implementation
+Tutorial</xref> for more detail and look at <filepath>...\template_variant\bootstrap\template.s</filepath> for a concrete example. </p> </li>
+</ul> <p>Note that all Symbian platform base ports currently create
+a second frame buffer for a secure screen. However, as platform security
+is not yet implemented, this is wasteful of RAM and should be omitted. </p> <p id="GUID-57223C8C-0381-51AC-8E8A-771434136A5C"><b> Set up the video
+information structure</b> </p> <p>The video information structure
+is used to define several aspects of the display including display
+size, bits per pixel and address of the frame buffer. This structure
+is the class <xref href="GUID-C4712A78-6C58-39ED-AF84-11038DB8571D.dita"><apiname>TVideoInfoV01</apiname></xref> defined in the header
+file <filepath>...\eka\include\videodriver.h</filepath> and exported
+to <filepath>...\epoc32\include</filepath>. </p> <codeblock id="GUID-0680E467-9552-5FD6-BBDE-60AE95F0B941" xml:space="preserve">TInt DLcdPowerHandler::Create()
+    {
+       ...
+       // setup the video info structure, this will be used to remember the video settings
+       iVideoInfo.iDisplayMode = KConfigLcdInitialDisplayMode;
+       iVideoInfo.iOffsetToFirstPixel = Lcd_Mode_Config[KConfigLcdInitialDisplayMode].iOffsetToFirstVideoBuffer;
+       iVideoInfo.iIsPalettized = Lcd_Mode_Config[KConfigLcdInitialDisplayMode].iIsPalettized;
+       iVideoInfo.iOffsetBetweenLines = Lcd_Mode_Config[KConfigLcdInitialDisplayMode].iOffsetBetweenLines;
+       iVideoInfo.iBitsPerPixel = Lcd_Mode_Config[KConfigLcdInitialDisplayMode].iBitsPerPixel;
+
+       iVideoInfo.iSizeInPixels.iWidth = KConfigLcdWidth;
+       iVideoInfo.iSizeInPixels.iHeight = KConfigLcdHeight;
+       iVideoInfo.iSizeInTwips.iWidth = KConfigLcdWidthInTwips;
+       iVideoInfo.iSizeInTwips.iHeight = KConfigLcdHeightInTwips;
+       iVideoInfo.iIsMono = KConfigLcdIsMono;
+       iVideoInfo.iVideoAddress=(TInt)pV;
+       iVideoInfo.iIsPixelOrderLandscape = KConfigLcdPixelOrderLandscape;
+       iVideoInfo.iIsPixelOrderRGB = KConfigLcdPixelOrderRGB;
+    ...
+    }</codeblock> <p><b> Install the HAL handler</b> </p> <p>Control of the display is
+done by using the HAL, the Hardware Abstraction Layer. </p> <p>The <codeph>DLcdPowerHandler</codeph> class provides the implementation for the
+HAL handler for the HAL function group <xref href="GUID-7F299BFC-D8A5-3A5A-B8DA-39BF42C99DC6.dita"><apiname>EHalGroupDisplay</apiname></xref> and this needs to be registered with the kernel by calling <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-8C8DCE9D-0094-3909-8FDA-2F3134D0BC88"><apiname>Kern::AddHalEntry()</apiname></xref>. </p> <codeblock id="GUID-F9E86404-742D-5931-BA77-DA246A3975E5" xml:space="preserve">TInt DLcdPowerHandler::Create()
+    {
+       ...
+       // install the HAL function
+       r=Kern::AddHalEntry(EHalGroupDisplay, halFunction, this);
+       if (r!=KErrNone)
+              return r;
+    ...
+    }</codeblock> <p>See <xref href="GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8.dita#GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8/GUID-4DA41221-40B9-5BC7-B2C6-7C6EB4522508">User-Side Hardware Abstraction</xref> for more detailed information
+on the HAL. </p> <p><b> Install the power handler</b> </p> <p>A call must be made to
+the <codeph>Add()</codeph> function, which is supplied by the <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita"><apiname>DPowerHandler</apiname></xref> base class of <codeph>DLcdPowerHandler</codeph>, to register the handler with the power manager. </p> <codeblock id="GUID-9286C3A2-DC2B-54F1-9F28-4EBE085AEE84" xml:space="preserve">TInt DLcdPowerHandler::Create()
+    {
+       ...
+        // install the power handler
+        // power up the screen
+        Add();
+    ...
+    }</codeblock> </section>
+<section id="GUID-85B93308-2EDF-462C-8F64-6AE40B8B16B6"><title>HAL
+handler implementation</title> <p>Requests to get and set hardware
+attributes are made through calls to <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-573C49D6-7763-37AE-B2B2-4C8FB1327E21"><apiname>HAL::Get()</apiname></xref> and <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-9454F1B2-D525-3D6D-A872-C6457CACD4FC"><apiname>HAL::Set()</apiname></xref>. These two HAL functions take
+a value that identifies a hardware attribute, one of the <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-1959915A-BA99-3F94-AFD4-FD1AA540BFBF"><apiname>HALData::TAttribute</apiname></xref> values. </p> <p>For the LCD Extension,
+the relevant hardware attributes are: <codeph>EDisplayMode</codeph>, <codeph>EDisplayBitsPerPixel</codeph>, <codeph>EDisplayIsPalettized</codeph>, <codeph>EDisplayIsMono</codeph>, <codeph>EDisplayMemoryAddress</codeph>, <codeph>EDisplayMemoryHandle</codeph>, <codeph>EDisplayOffsetToFirstPixel</codeph>, <codeph>EDisplayOffsetBetweenLines</codeph>, <codeph>EDisplayXPixels</codeph>, <codeph>EDisplayYPixels</codeph>, <codeph>EDisplayPaletteEntry</codeph> and <codeph>EDisplayOffsetBetweenLines</codeph>. </p> <p>The HAL
+handler is registered with the kernel as the handler for the <xref href="GUID-66A851A0-2A0C-3624-AEC1-22F6629FABF7.dita#GUID-66A851A0-2A0C-3624-AEC1-22F6629FABF7/GUID-950EA0D3-747F-305E-92EA-1579023A111E"><apiname>THalFunctionGroup::EHalGroupDisplay</apiname></xref> group. The HAL handler
+itself takes a function ID, which is one of the <xref href="GUID-BB011D9B-105F-345C-9FC0-39B0BA509394.dita"><apiname>TDisplayHalFunction</apiname></xref> enumerators. </p> <p>A call to <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-573C49D6-7763-37AE-B2B2-4C8FB1327E21"><apiname>HAL::Get()</apiname></xref> and <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-9454F1B2-D525-3D6D-A872-C6457CACD4FC"><apiname>HAL::Set()</apiname></xref> that takes one of the hardware attributes relevant
+to the LCD Extension is ultimately routed to a call to this HAL handler
+function passing an appropriate function ID. The association between
+the hardware attribute and the function ID is the responsibility of
+the accessor functions. </p> <p>See <xref href="GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8.dita#GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8/GUID-4DA41221-40B9-5BC7-B2C6-7C6EB4522508">User-Side Hardware Abstraction</xref> for more information on the
+way this works in general. </p> <p>The HAL handler is implemented
+as a case statement, switching on the function ID. For example, the
+following code fragment taken from <codeph>DLcdPowerHandler::HalFunction()</codeph> gets and sets the brightness: </p> <codeblock id="GUID-41D5153A-107A-5FCC-9E51-C6250857F3AC" xml:space="preserve">TInt DLcdPowerHandler::HalFunction(TInt aFunction, TAny* a1, TAny* a2)
+    {
+    TInt r=KErrNone;
+    switch(aFunction)
+        {
+    
+        ...
+         case EDisplayHalSetDisplayBrightness:
+             if(!Kern::CurrentThreadHasCapability(ECapabilityWriteDeviceData,
+       __PLATSEC_DIAGNOSTIC_STRING("Checked by Hal function EDisplayHalSetDisplayBrightness")))
+                       return KErrPermissionDenied;
+             r=SetBrightness(TInt(a1));
+             break;
+            
+         case EDisplayHalDisplayBrightness:
+             kumemput32(a1,&amp;iBrightness,sizeof(iBrightness));
+             break;
+        ...
+</codeblock> <p>where <codeph>SetBrightness()</codeph> is implemented
+as: </p> <codeblock id="GUID-82F38251-19A9-54BC-A066-80ED5AC549AF" xml:space="preserve">TInt DLcdPowerHandler::SetBrightness(TInt aValue)
+    {
+     __KTRACE_OPT(KEXTENSION,Kern::Printf("SetBrightness(%d)", aValue));
+
+     if (aValue &gt;= KConfigLcdMinDisplayBrightness &amp;&amp; aValue &lt;= KConfigLcdMaxDisplayBrightness)
+         {
+         iBrightness=aValue;
+    
+         // TO DO: (mandatory)
+         // set the brightness
+         //
+         return KErrNone;
+         }
+    return KErrArgument;
+    }
+</codeblock> <p>If an attribute does not have an implementation, the
+HAL handler function should return <xref href="GUID-F89DA3F0-2A48-3F9B-8F08-29350E92D0E4.dita"><apiname>KErrNotSupported</apiname></xref>. </p> <p>For platform security, the code only allows the attribute
+to be set if the current thread has been authorized to write system
+data. Otherwise, it returns <xref href="GUID-213DE05E-24F7-3E94-9B35-F4A72B3EBFD8.dita"><apiname>KErrPermissionDenied</apiname></xref>. </p> <p><b>Switch on and switch off operations</b> </p> <p>All of the HAL
+operations are seen to be synchronous by the user side. However there
+are some operations such as turning the display on and off which may
+need to be implemented asynchronously. </p> <p>The display on/off
+code is implemented using synchronous kernel-side messages. There
+is only one message per thread and the thread always blocks while
+a message is outstanding. This means it is possible to make an asynchronous
+operation appear synchronous. </p> <p>When turning on the screen the
+kernel-side message is queued and this thread is blocked until the
+message is completed, which happens when the display has been turned
+on. </p> <p>If a display needs to be turned on and off truly asynchronously
+(for example, if millisecond timer waits are required during the process
+of turning on the display), the above functionality must be changed
+so that the complete occurs when the display is truly on. </p> <p><b>Accessing the video information structure</b> </p> <p>When any
+part of the <xref href="GUID-6A4FE3A3-2E5D-51BB-8272-5995586291E9.dita#GUID-6A4FE3A3-2E5D-51BB-8272-5995586291E9/GUID-57223C8C-0381-51AC-8E8A-771434136A5C">video information structure</xref> is read or written to, this must
+be done within a critical section to prevent potential collisions
+with other threads attempting to access the structure concurrently.
+A fast mutex is used to ensure that only one thread can access the
+video information at any one time, as the code segment below shows. </p> <codeblock id="GUID-E30D9790-109C-541F-A534-C92CBD4E1706" xml:space="preserve">TInt DLcdPowerHandler::GetCurrentDisplayModeInfo(TVideoInfoV01&amp; aInfo, TBool aSecure)
+    {
+     __KTRACE_OPT(KEXTENSION,Kern::Printf("GetCurrentDisplayModeInfo"));
+     NKern::FMWait(&amp;iLock);
+     if (aSecure)
+          aInfo = iSecureVideoInfo;
+     else
+         aInfo = iVideoInfo;
+     NKern::FMSignal(&amp;iLock);
+     return KErrNone;
+     }
+</codeblock> </section>
+<section id="GUID-04C06DAE-EE8E-4EE9-940F-807F82FBACD1"><title>Power
+handler implementation</title> <p>The <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita"><apiname>DPowerHandler</apiname></xref> class defines the interface that the driver must implement to provide
+power handling behaviour. For the template reference board, the LCD
+Extension defines and implements the <codeph>DLcdPowerHandler</codeph> class derived from <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita"><apiname>DPowerHandler</apiname></xref>. </p> <p> <b>Note</b>: </p> <ul>
+<li id="GUID-32D95977-F46B-50E0-B575-BE7369C05F62"><p> <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-578DB5FB-731D-36B2-A459-AAC7F250D726"><apiname>DPowerHandler::PowerDown()</apiname></xref> and <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-DDC564B4-BD12-30E9-B04A-DBA6CFAF8743"><apiname>DPowerHandler::PowerUp()</apiname></xref>  </p> <p>These functions
+are called in the context of the thread that initiates power down
+or power up, and synchronization is required, typically by means of
+power up and power down DFCs. </p> </li>
+<li id="GUID-7DC988A6-C60E-5951-9DD7-82DA129A8CB6"><p> <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-038F9D7D-7DA0-3299-8AA2-85F175206887"><apiname>DPowerHandler::PowerUpLcd()</apiname></xref> and <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-6EAF00D1-3CBA-3BC0-BAD9-7301EE5F9E12"><apiname>DPowerHandler::PowerDownLcd()</apiname></xref>  </p> <p>These
+functions generally queue DFCs which then call platform-specific functions
+to power the display up and down. </p> </li>
+<li id="GUID-51152EA7-C1A5-5AB3-8ACD-6FF6F16A255D"><p> <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-BF62042B-FB7B-3D5B-8379-490FBA284A7A"><apiname>DPowerHandler::PowerUpDone()</apiname></xref> and <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-EBE8CFF8-50BD-3AC3-A4C8-47094DA5674D"><apiname>DPowerHandler::PowerDownDone()</apiname></xref>  </p> <p>When
+power up or down is complete, the interface supplies a set of acknowledgment
+functions which must be called when the change of state has taken
+place. </p> </li>
+</ul> </section>
+</conbody><related-links>
+<link href="GUID-0C3A4156-E5CF-55F9-91A0-A7961FDEE030.dita"><linktext>LCD
+Extension Architecture</linktext></link>
+<link href="GUID-8DF46A11-874A-52E5-9298-C083EA633BA0.dita"><linktext>Implementing
+Dynamic DSA                 Allocation</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6AC01B10-92C1-4E56-813B-6853DFCF3386-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-4-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6AC01B10-92C1-4E56-813B-6853DFCF3386-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-4-1" xml:lang="en"><title>DMA Requests</title><shortdesc>Describes how device drivers use DMA requests to initiate
+a DMA transfer.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>DMA transfer requests are the way in which a device driver sets
+up and initiates a DMA transfer. A transfer request internally comprises
+a linked list of DMA descriptor headers and is associated with a single
+DMA channel. A transfer request also stores an optional client-provided
+callback function, which can be invoked when the whole request completes,
+whether successfully or not. A DMA request can be in any of the four
+states: Not configured, Idle, Being transferred, and Pending. However,
+these states are not used by the driver. </p>
+<p>A device driver creates a DMA request by specifying a DMA channel
+and an optional DMA callback function to be called after the request
+completion. A DMA request must be fragmented. </p>
+<p>The following shows the creation of a DMA request: </p>
+<codeblock id="GUID-B2753DE7-800E-57CC-B2B6-CA2548AC25C4-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-4-1-3-4" xml:space="preserve">TInt DExDriverUartTxDma::Init()
+    {
+    ...
+    // A DMA request has to be created for any DMA transfer. This 
+    // specifies the channel on which the DMA request shall be 
+    // made, the service callback function to be called after the 
+    // request completion (TxDmaService), and an object pointer that will be passed 
+    // as an argument to DMA request service function (this).
+    // A DMA request is a list of fragments small enough to be 
+    // transferred in one go by the DMA Controller.
+    //
+    iTxDmaRequest = new DDmaRequest(*iTxDmaChannel, TxDmaService,    this);
+    if(iTxDmaRequest == NULL)
+        {
+        return KErrNoMemory;
+        }
+    ...
+    }</codeblock>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6AC01B10-92C1-4E56-813B-6853DFCF3386-GENID-1-2-1-9-1-6-1-8-1-7-1-5-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6AC01B10-92C1-4E56-813B-6853DFCF3386-GENID-1-2-1-9-1-6-1-8-1-7-1-5-1" xml:lang="en"><title>DMA Requests</title><shortdesc>Describes how device drivers use DMA requests to initiate
+a DMA transfer.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>DMA transfer requests are the way in which a device driver sets
+up and initiates a DMA transfer. A transfer request internally comprises
+a linked list of DMA descriptor headers and is associated with a single
+DMA channel. A transfer request also stores an optional client-provided
+callback function, which can be invoked when the whole request completes,
+whether successfully or not. A DMA request can be in any of the four
+states: Not configured, Idle, Being transferred, and Pending. However,
+these states are not used by the driver. </p>
+<p>A device driver creates a DMA request by specifying a DMA channel
+and an optional DMA callback function to be called after the request
+completion. A DMA request must be fragmented. </p>
+<p>The following shows the creation of a DMA request: </p>
+<codeblock id="GUID-B2753DE7-800E-57CC-B2B6-CA2548AC25C4-GENID-1-2-1-9-1-6-1-8-1-7-1-5-1-3-4" xml:space="preserve">TInt DExDriverUartTxDma::Init()
+    {
+    ...
+    // A DMA request has to be created for any DMA transfer. This 
+    // specifies the channel on which the DMA request shall be 
+    // made, the service callback function to be called after the 
+    // request completion (TxDmaService), and an object pointer that will be passed 
+    // as an argument to DMA request service function (this).
+    // A DMA request is a list of fragments small enough to be 
+    // transferred in one go by the DMA Controller.
+    //
+    iTxDmaRequest = new DDmaRequest(*iTxDmaChannel, TxDmaService,    this);
+    if(iTxDmaRequest == NULL)
+        {
+        return KErrNoMemory;
+        }
+    ...
+    }</codeblock>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6B2221F2-A598-4677-A2D3-40FF27C7373F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6B2221F2-A598-4677-A2D3-40FF27C7373F" xml:lang="en"><title>SDIO Tools Guide</title><shortdesc>Describes the tools required for SDIO implementation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There are no specific tools required to use or implement SDIO.</p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6B9041F7-79A6-5CCA-9B4D-B8EF377FD378.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,45 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE task
+  PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
+<task id="GUID-6B9041F7-79A6-5CCA-9B4D-B8EF377FD378" xml:lang="en"><title>Building
+ROM Tutorial </title><shortdesc>Describes how to build a ROM that will use demand paging. It assumes
+that the configuration files have been suitably modified. </shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody>
+<context id="GUID-0EF40712-F6BE-516A-871E-5E98BA86F3BF"><p>This is the final
+step required to build a ROM that can use Writable Data Paging (WDP). The
+previous steps required to produce a ROM image that can use Writable Data
+Paging (WDP) are: </p> <ul>
+<li id="GUID-E4AB8E69-E18D-522A-8CD1-CF0CFBA0E387"><p><xref href="GUID-16423056-C435-5C4D-BE3D-4A15F95F7F68.dita">Configuration
+Tutorial</xref>  </p> </li>
+<li id="GUID-53279F00-E850-53C7-BD67-054B80747697"><p><xref href="GUID-4862EA2E-6BFE-5E11-B527-7EBA94BB0EA2.dita">oby
+tutorial</xref>  </p> </li>
+<li id="GUID-EB986AF2-E4F8-5C22-B303-17F434ACDBB0"><p><xref href="GUID-16423056-C435-5C4D-BE3D-4A15F95F7F68.dita#GUID-16423056-C435-5C4D-BE3D-4A15F95F7F68/GUID-9A892A74-0823-57D7-A146-BC8E14508B99">mmp tutorial</xref>  </p> </li>
+</ul> <p> <note> It is assumed that the both the configuration files and the
+media drivers have been modified to use demand paging.</note>  </p> </context>
+<steps id="GUID-95FD1C29-408C-55FE-A9D0-30D2CED91C65">
+<step id="GUID-5C1EB773-0F2F-59CC-9B6C-3836C3D8CC4C"><cmd/>
+<info>If the new OBY file appears before <filepath>base.iby</filepath>, then
+no change to the configuration of the rombuild command is needed. </info>
+</step>
+<step id="GUID-29B770D9-9823-518A-A6F9-980FC134AE16"><cmd/>
+<info>If the new OBY file appears after <filepath>base.iby</filepath>, then <codeph>USE_DATA_PAGING</codeph> must
+be defined on the command line (along with <codeph>PAGED_ROM, USE_CODE_PAGING
+and CODE_PAGING_FROM_ROFS</codeph>) </info>
+<info> <codeph>USE_DATA_PAGING, PAGED_ROM, USE_CODE_PAGING and CODE_PAGING_FROM_ROFS</codeph> are
+macros that are used to indicate which types of paging is to be used. If they
+are specified in the parameter list for buildrom (with -D in fount of it)
+then that type of paging will be implemented. </info>
+</step>
+</steps>
+<result id="GUID-619040F2-098F-5A57-840B-78B1BD223E3B"><p>Executing the buildrom
+command builds the ROM image with no errors or warnings. </p> </result>
+<example id="GUID-E065C47A-B95B-579D-A64F-1ADADF2430A1"><title>buildrom example</title> <p>An
+example of a buildrom command that produces a demand paging ROM is: </p> <codeblock id="GUID-05DF5C47-B13F-5054-826B-88D50E6CC991" xml:space="preserve">buildrom –D_NAND2 -DWITH_FLEXIBLE_MM –DPAGED_ROM –DUSE_CODE_PAGING –DCODE_PAGING_FROM_ROFS –DUSE_DATA_PAGING h4hrp techview MyDPConfig</codeblock> </example>
+</taskbody></task>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6C27AAD6-EB88-53AF-8E04-921A957042CF.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6C27AAD6-EB88-53AF-8E04-921A957042CF" xml:lang="en"><title>Concepts</title><shortdesc>Describes the technology, architecture, and behaviour of the Digitizer
+Driver. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/><related-links>
+<link href="GUID-0563266C-8B5A-5664-9AC6-A5504AB5056F.dita"><linktext>Port Implementation
+  Tutorial</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6C74A8B4-50B6-486C-A75F-A50636F4C566.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,47 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6C74A8B4-50B6-486C-A75F-A50636F4C566" xml:lang="en"><title>Register Access Overview</title><shortdesc>Provides a summary of the Register Access platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Register Access platform service is intended for use in writing
+device drivers. Writing device drivers involves frequent access to
+hardware registers for reading, writing and modifying them. </p>
+<section id="GUID-65EDE628-937F-4472-9662-8FE36D77B12D">         
+   <title>What is a register</title>             <p>A register is
+a memory location on the ASSP hardware to store data that relates
+to the operation of that hardware. For example, a register can be
+a counter, or a bit field, or the next sequence number or the next
+byte or word of data that has arrived over a bus.</p><p>The Symbian
+platform provides access functions for registers that have the following
+sizes:<ul>
+<li><p>8–bit</p></li>
+<li><p>16–bit</p></li>
+<li><p>32–bit</p></li>
+<li><p>64–bit</p></li>
+</ul></p>         </section>
+<section id="GUID-25E7482D-B837-4228-9BE5-836DF48AD664"><title>What
+functions are available</title><p>There are three types of function
+provided for register access:<ul>
+<li><p><codeph>Read</codeph> - get the value of a register</p></li>
+<li><p><codeph>Write</codeph> - write a value to a register</p></li>
+<li><p><codeph>Modify</codeph> - use bitmasks to clear or set specific
+bits in a register</p></li>
+</ul></p><p>Each function takes a first argument of a <xref href="GUID-7452AD53-A7EE-3B1E-BC3D-C4202E5DAEBC.dita"><apiname>TLinAddr</apiname></xref> which is an address. The device driver only needs to know the address,
+and the size of the register. The implementation of the Register Access
+must map the exposed physical hardware register to a linear address.</p><p>Each type of function (read, write, modify) has 8–bit, 16–bit,
+32–bit and 64–bit versions.</p><p>The <codeph>Modify</codeph> functions
+take two bitmasks as parameters, to specify which bits to clear to
+zero (clear mask) and which bits to set to one (set mask). This means
+that you could call <codeph>Modify16(myaddress, 0xC000,0x000F)</codeph> and the top two bits would be set to zero, the bottom four bits
+would be set to one, and the ten bits in the middle would retain their
+current value.</p><p>See <xref href="GUID-DB55C1A0-2901-4661-B6B1-3B61BF6FF4FA.dita">Register Access Client
+Interface Guide</xref> for more details on each function and how to
+use them.</p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6CCF249B-DEDD-4E0B-A081-0FCD9FCCBB5A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6CCF249B-DEDD-4E0B-A081-0FCD9FCCBB5A" xml:lang="en"><title>SDIO
+Quick Start Guide</title><shortdesc>Provides a collection of documents that describe SDIO (Secure Digital
+Input Output).</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-065966E9-90AD-4E82-8096-1122F3997FEA"><title>Getting started
+with SDIO</title><p>The SDIO overview provides a description of the basic
+concepts relevant to SDIO.</p><xref href="GUID-7D535B68-CA7F-4796-80FB-AE7A27642A88.dita">SDIO
+Overview</xref><p>The technology guide provides a description of the technologies
+used by SDIO.</p><xref href="GUID-D089C2E9-1BE4-4B37-B8A8-21E5B2425E6C.dita">SDIO
+Technology Guide</xref><p>The interface overview document provides a description
+to the SDIO adaptation APIs.</p><xref href="GUID-B77ED382-9D88-48E0-8AD7-F0E273A45119.dita">SDIO
+Interface Guide</xref><p>The implementation overview describes
+how SDIO is included in a build of the Symbian platform. </p><xref href="GUID-9BBDFF77-5E2C-4E13-BEB3-716CC80B3375.dita">SDIO
+Implementation Guide</xref></section>
+<section id="GUID-53E70AA1-5B26-4767-A5FA-7D8F1ED79C69"><title>Architecture</title><p>The
+following illustration shows the basic architecture of SDIO.</p><fig id="GUID-1147EE7F-7B31-46D4-BE4B-F172EDBAEA5F">
+<image href="GUID-A819DE06-7B00-4643-9D3E-EFE14132981C_d0e99345_href.png" placement="inline"/>
+</fig></section>
+<section id="GUID-966BC8CE-F510-4C18-8E48-7F3EDB3F364E"><title>Technologies</title><p>SDIO
+is a standard that combines an SD (Secure Digital) card and an I/O device
+to produce a peripheral that can use an SD slot. </p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6CE68645-D8C5-52E1-88B3-76AEFB80DE51.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,60 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6CE68645-D8C5-52E1-88B3-76AEFB80DE51" xml:lang="en"><title>Peripherals
+As Power Resources</title><shortdesc>Peripherals that provide services to other peripherals can be considered
+as power resources from the point of view of the client driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>As they can offer a service to more than one other peripheral, we suggest
+that the driver that manages them presents a <xref href="GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A.dita"><apiname>MPowerInput</apiname></xref> derived
+interface to client peripheral drivers, providing <codeph>Use()</codeph> and <codeph>Release()</codeph> functions
+that can be used by dependent peripheral drivers to issue power requests.
+The driver for the peripheral providing that interface may then use the built-in
+usage counting feature to control the peripheral power state. </p>
+<p>A typical example of a shared Peripheral is an Inter-Component serial Bus
+(I2C, SPI, etc): </p>
+<codeblock id="GUID-2E454D22-496D-5D9C-9F67-281D6F340459" xml:space="preserve">class MySharedPeripheral : public MPowerInput , (other parent classes)
+    {
+public:    
+    // from MPowerInput
+    void Use();
+    void Release();
+    TUint GetCount();
+    ...
+    (other methods and data members required to model the interface)
+    };
+      </codeblock>
+<p>Special care must be taken to not create circular dependencies, for example,
+Peripheral A depends on Peripheral B, which depends on Peripheral C which
+depends on Peripheral A. Such circular dependencies would cause the <xref href="GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A.dita#GUID-10105403-AF16-3908-AE9E-96CF2A03AD3A/GUID-606ECD77-A5F7-3408-9B63-C68C0A7B73C6"><apiname>MPowerInput::Release()</apiname></xref> mechanism
+not to work properly, and preventing the chain of peripherals from powering
+down when due. </p>
+<p>The shared peripheral driver’s power handler asynchronous <codeph>PowerDown()</codeph> must
+examine the usage count of that peripheral if the power manager issues a <codeph>PowerDown()</codeph> request
+to the shared peripheral driver’s power handler while the peripheral is still
+in use by another driver. In this situation, the shared peripheral driver
+must defer powering down until all the dependent peripherals have released
+their request on it. </p>
+<p>Some peripherals may also be represented as power resources to prevent
+the base port power saving operations inhibiting their usage. For example,
+a base port may consider DRAM to be a shared power resource with the DMA controller,
+or the DSP controller as clients. This will allow them to still be able to
+access DRAM whilst the CPU is idling, thus stopping the DRAM going into self-refresh
+if either one of its clients has pending operations on it. </p>
+<p>As another example, to save power some base ports might decide to reduce
+the refresh rate of the LCD whilst the CPU is idling or even power it down
+for short periods and rely on the persistence of the LCD to prevent degredation
+of the user experience. However, on a multiple core solution the LCD might
+be used by the second core (e.g. DSP), for example, for playing back video
+whilst the main CPU is idling. In this situation the LCD should be represented
+as a shared power resource and the DSP must be able to request usage of this
+resource. The DSP controller software could assert a request on the LCD preventing
+the main CPU from initiating the power saving measures. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6D75968E-53CF-5436-8390-54CA12BCFDE9.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6D75968E-53CF-5436-8390-54CA12BCFDE9" xml:lang="en"><title>Concepts</title><shortdesc>Describes the technology, architecture, and behaviour of the Sound
+Driver. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p id="GUID-C869F627-8218-5482-A04B-C6B74F62EFBF"> Sound Driver concepts are
+described here. </p>
+</conbody><related-links>
+<link href="GUID-3335663A-BC11-556E-B5A6-F83622AE34C3.dita"><linktext>Port Implementation
+  Tutorial</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6DE69F29-45B0-5E62-AA13-DA4041B1BC46.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,99 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6DE69F29-45B0-5E62-AA13-DA4041B1BC46" xml:lang="en"><title>Factory
+Implementation</title><shortdesc>Describes how to implement a factory.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Serial Port Driver PDD must provide a factory class to create channels.
+The purpose of the PDD factory is to create the physical channel. For the
+Uart, this is defined by the <codeph>DDriverComm</codeph> class, which is
+derived from <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita"><apiname>DPhysicalDevice</apiname></xref>. The class is defined in the
+Uart source code: </p>
+<codeblock id="GUID-15ED5794-BC8A-5CF0-BE5D-8620AFDEDEEA" xml:space="preserve">class DDriverComm : public DPhysicalDevice
+    {
+public:
+    DDriverComm();
+    virtual TInt Install();
+    virtual void GetCaps(TDes8 &amp;aDes) const;
+    virtual TInt Create(DBase*&amp; aChannel, TInt aUnit, const TDesC8* anInfo, const TVersion &amp;aVer);
+    virtual TInt Validate(TInt aUnit, const TDesC8* anInfo, const TVersion &amp;aVer);
+    };
+</codeblock>
+<p>This implements the four virtual functions that the base class defines,
+as well as a default constructor. </p>
+<section id="GUID-5A36A559-CBB6-4495-A1ED-0C4F9289F9B0"><title>Install()</title> <p> <codeph>Install()</codeph> sets
+the driver name. The name is the way that the physical device is identified.
+The name is the same as the LDD name, but followed by a dot and a short string
+to represent the physical device. If you have similar existing source, just
+copy from there. The function is implemented as: </p> <codeblock id="GUID-6988B583-5060-5CE7-9404-C631C40B188A" xml:space="preserve">TInt DDriverComm::Install()
+    {
+    return SetName(&amp;KPddName);
+    }
+</codeblock> <p>In the template port, the name is the string <codeph>Comm.Template</codeph>. </p> <p>See
+also <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita#GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930/GUID-0065FAAF-D734-3ED2-816A-CCE9BF607BAB"><apiname>DPhysicalDevice::Install()</apiname></xref>  </p> </section>
+<section id="GUID-CBFB3280-3C16-4F15-A7DB-EDCA278562F6"><title>GetCaps()</title> <p> <codeph>GetCaps()</codeph> returns
+the capabilities of the physical driver <i>factory</i> (not the driver object).
+Since driver factories all produce polymorphic objects there is no point in
+differentiating between them so the function should ignore the passed in descriptor
+reference. The driver object’s capabilities are returned by the <codeph>DComm</codeph> derived <codeph>Caps()</codeph> function. </p> <p>GetCaps()
+can be implemented as a stub function, i.e.: </p> <codeblock id="GUID-338ECD13-DD25-55E0-812F-3ED3A49826CD" xml:space="preserve">Void DDriverComm::GetCaps(TDes8&amp;  /* aDes */)
+    {
+    }</codeblock> <p>See also <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita#GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930/GUID-CA336905-B068-3CFB-80D7-4DF29B92BF4F"><apiname>DPhysicalDevice::GetCaps()</apiname></xref>  </p> </section>
+<section id="GUID-70BBF195-3943-4ABE-9EFB-FCC2BDAC52DD"><title>Validate()</title> <p> <codeph> Validate()</codeph> verifies
+that the physical driver version is compatible with the caller’s version.
+This function can be copied in its entirety from any current driver source.
+It also checks that the unit number used to create a physical channel object
+is valid, typically checking that the number lies within a valid range. </p> <codeblock id="GUID-03DC2E07-FEBF-5F52-B3A5-7F52C855FC06" xml:space="preserve">TInt DDriverComm::Validate(TInt aUnit, const TDesC8* /*anInfo*/, const TVersion&amp; aVer)
+    {
+    if (
+        (!Kern::QueryVersionSupported(iVersion,aVer)) || 
+        (!Kern::QueryVersionSupported(aVer,TVersion(KMinimumLddMajorVersion,KMinimumLddMinorVersion,KMinimumLddBuild)))
+       )
+    return KErrNotSupported;
+    if (aUnit&lt;UART_UNIT_OFFSET || aUnit&gt;=(UART_TOTAL_NUMBER_UNITS+UART_UNIT_OFFSET))
+        return KErrNotSupported;
+    return KErrNone;
+    }
+</codeblock> <p>Note that <codeph>iVersion</codeph> is a data member in the
+base class <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita"><apiname>DPhysicalDevice</apiname></xref>. </p> <p>See also: </p> <ul>
+<li id="GUID-0EF9F2F1-EC2A-50E3-9E1B-2D6112FE8623"><p> <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita#GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930/GUID-70B6293C-9000-31D9-AE9E-441C9760B92E"><apiname>DPhysicalDevice::Validate()</apiname></xref>  </p> </li>
+<li id="GUID-4ED7473E-D789-5813-9404-0F6BDCB83D3F"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-A28757CC-B89B-3F63-AD39-9955FBE7533B"><apiname>Kern::QueryVersionSupported()</apiname></xref>  </p> </li>
+</ul> </section>
+<section id="GUID-48EF94F9-ACBC-58DA-9F0E-4034E56C6C74"><title>Create()</title> <p> <codeph>Create()</codeph> creates
+and returns a pointer to the physical channel object through the <xref href="GUID-4FCB6127-84F3-38F6-8AD2-FC3B94D67DA3.dita"><apiname>DBase</apiname></xref> *&amp;
+type argument. In the case of serial device drivers, a physical channel is
+an instance of a class derived from <codeph>DComm</codeph>, which is itself
+derived from <xref href="GUID-4FCB6127-84F3-38F6-8AD2-FC3B94D67DA3.dita"><apiname>DBase</apiname></xref>. </p> <p>Implementing this function
+may involve: </p> <ul>
+<li id="GUID-D6D5111E-22E1-5EA2-B217-EAC3BA5B9599"><p>setting up any port
+related hardware; for example, defining GPIO pins as UART port I/O </p> </li>
+<li id="GUID-6769D49B-478C-5282-A918-6D659F823B95"><p>initialising the UART
+device itself; for example, enabling UART clock sources </p> </li>
+<li id="GUID-BFEC3036-6F9C-5499-81AF-7A5D01BDD890"><p>binding any interrupt
+resources to the UART Interrupt Service Routine (ISR). </p> </li>
+</ul> <p>The function sets a reference argument to point to the newly instantiated
+physical channel object, but returns an error code if object allocation or
+initialisation fails, i.e. the call to the physical channel object’s <codeph>DoCreate()</codeph> function
+fails. Error codes are returned to the caller. </p> <p>This code is typical,
+and can be copied from any current source. </p> <codeblock id="GUID-E93C6DEA-852D-5B5F-8531-CA4B76B91879" xml:space="preserve">TInt DDriverComm::Create(DBase*&amp; aChannel, TInt aUnit, const TDesC8* anInfo, const TVersion&amp; aVer)
+    {
+    DCommXXX* pD=new DCommXXX;
+    aChannel=pD;
+    TInt r=KErrNoMemory;
+    if (pD)
+        r=pD-&gt;DoCreate(aUnit,anInfo);
+    return r;
+    }
+</codeblock> <p>where <codeph>DCommXXX</codeph> is a <codeph>DComm</codeph> derived
+class. </p> <p>Customisation depends on the functions in the <codeph>DCommXXX::DoCreate()</codeph> function. </p> </section>
+</conbody><related-links>
+<link href="GUID-3C34724F-B476-5329-B0B1-6D5A34294979.dita"><linktext>Interrupt
+Dispatcher Tutorial</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,609 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE" xml:lang="en"><title>Power
+Resource Manager (PRM)</title><shortdesc>Describes the Power Resource Manager.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<ul>
+<li id="GUID-16097C0C-7354-5B9E-B405-1785F7511878"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-2F312E19-71BC-5396-996F-EA48EAEDF2F2">Introduction</xref>  </p> </li>
+<li id="GUID-9780C08F-CBA2-5C72-B6D2-C751F3CF18C7"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-F830F456-A436-5025-821D-21855C7AE056">Concepts</xref>  </p> </li>
+<li id="GUID-FBAB865C-C003-504A-A8DB-058C9BCA2D20"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-5C3F684C-D4F6-5343-AFFC-009B70210F9C">User-side</xref>  </p> </li>
+<li id="GUID-6FE7DE11-1781-5F85-99B6-83B544148D3A"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-DE8EE84C-D46F-504A-8254-C212B7C5D5C1">Kernel-side</xref>  </p> </li>
+</ul>
+<section id="GUID-2F312E19-71BC-5396-996F-EA48EAEDF2F2"><title>Introduction</title> <p>The
+Power Resource Manager (PRM) integrates the Symbian device driver with existing
+power control and functions used for resource state changing and querying.
+It defines an exported API that device drivers and other users of power resources
+(represented by kernel-side components) can use to control the state of power
+resources. The PRM assists the development of device drivers by removing the
+need to understand the complexities of platform specific power resource management
+by providing a simple to use generic framework. </p> <p>The PRM also allows
+user-side clients to gain access to the services. Clients of the PRM can: </p> <ul>
+<li id="GUID-1F23255C-A662-5755-A4C7-387A57FEB2C3"><p>request information
+on the clients and resources registered with PRM </p> </li>
+<li id="GUID-3E6406A9-757A-53EE-AE1C-839CA87C1120"><p>get the current state
+of the resources </p> </li>
+<li id="GUID-4FD981E6-EA1E-5E49-83D1-CC017BB753FE"><p>request changes to the
+state of power resources </p> </li>
+<li id="GUID-3ED36326-E905-53A1-907F-51DD6846B5BC"><p>request notification
+of changes (i.e. power-down or change clock frequency) to the power resources
+that they depend on. </p> </li>
+</ul> <p>The following diagram shows the generic and customisable parts of
+the framework: </p> <ul>
+<li id="GUID-D4A341D5-84C4-543E-A392-426B6E9905FB"><p>exported kernel level
+API (<xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita"><apiname>PowerResourceManager</apiname></xref>) </p> </li>
+<li id="GUID-D0A636FF-9520-5CA1-82EF-E7B7AF645063"><p>base virtual class for
+Power Resource Controller (<xref href="GUID-46F2174F-0206-345B-8C5D-F8B5763652E0.dita"><apiname>DPowerResourceController</apiname></xref>) </p> </li>
+<li id="GUID-C7C11053-E43B-5A1F-B5E7-6BBE36C02C1D"><p>PDD required for user-side
+proxy client </p> </li>
+<li id="GUID-404A1110-40E3-5E28-8C04-19232FB047B5"><p>platform specific implementation
+of resource control at the level of register interface to hardware resource
+controller (<codeph>DXXXPowerResourceController</codeph>) </p> </li>
+</ul> <fig id="GUID-72B93745-2089-526F-8AF5-0E7522CADBEC">
+<image href="GUID-99C4FCCC-9E8B-51CC-85F8-F03BE18DF19E_d0e82580_href.png" placement="inline"/>
+</fig> </section>
+<section id="GUID-F830F456-A436-5025-821D-21855C7AE056"><title>Concepts</title> <ul>
+<li id="GUID-3F2C2733-A287-5AB8-A695-4863EBA1FF52"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-4CC0C003-1952-5CAD-A7C5-163C5DDA52C8">Power resources</xref> </p> </li>
+<li id="GUID-D4CDE568-00CA-50BD-A3CD-C12523B81180"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-8BBC100D-BB97-5675-AA2F-E730A0DF4B26">Clients</xref>  </p> </li>
+</ul> <p id="GUID-4CC0C003-1952-5CAD-A7C5-163C5DDA52C8"><b>Power resources</b> </p> <p>A
+power resource is anything that has an effect on power consumption. These
+are typically platform specific and either physical or logical. Physical power
+resources are provided by hardware: for example, clocks, outputs from voltage
+regulators, switched power domains and performance levels. Logical power resources
+do not directly map to hardware components, but their state has an effect
+on overall power consumption. In this category we include, for example, shared
+buses and devices that provide services to other components. </p> <p>Power
+resources can be further categorised based on: </p> <ul>
+<li id="GUID-CF16C658-A90F-5378-825B-CEC9C8D2DF1B"><p>Number of <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-8BBC100D-BB97-5675-AA2F-E730A0DF4B26">clients</xref>  </p> <p>A power resource can have a single user or it can
+be shared. There is no limit to the number of clients sharing a resource.
+If the resource is shared, then a request system is used. This comprises a
+list of <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-F47D2098-16A7-5590-A68A-7AE4B2DAB462">client
+level objects</xref>, one for each client requesting a level on the resource.
+The resource level is determined by a set of rules which govern whether a
+request is accepted or declined. </p> </li>
+<li id="GUID-B5BBF273-19B4-5A3B-9B85-792837D70258"><p>States </p> <p>The <xref href="GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC.dita#GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC/GUID-1817A738-2351-526F-881D-7EB479E93C4C">resource
+state</xref> may be binary, multi-level or multi-property. A binary state
+is either On or Off and a multi-level state can change either discretely or
+continuously between a minimum (which could be Off) and a maximum value (which
+could be fully On). </p> <p>A multi-property resource has different properties
+across different portions of the operating curve. For example, the level may
+be controllable within the ‘operational’ part of that curve but have different
+discrete fixed states for the ‘idle’ or ‘sleep’ modes of operation. </p> </li>
+<li id="GUID-FC70680E-1595-54FC-A611-295688470176"><p>Execution time </p> <p>The
+execution time of a resource can be either instantaneous or long latency.
+An instantaneous resource can be operated almost immediately (no longer than
+a few system clock cycles, comparable to a CPU instruction execution time).
+Operations on long latency resources take a significant time to complete (a
+non-negligible amount of CPU clock cycles). </p> <p>Power resources may be
+long latency for state change operations and instantaneous for obtaining the
+current state. This is typically the case of a PLL (Phase Locked Loop) device
+(<xref href="http://en.wikipedia.org/wiki/Phase-locked_loop" scope="external">definition
+from Wikipedia</xref>), which requires time to stabilise after a frequency
+change is initiated but whose current output frequency can be read from a
+register. <b>Note</b>: instantaneous operations may pre-empt operations on
+long latency resources, and requests to get the state of a shared resource
+may be issued while a state change is underway. If the read operation is instantaneous
+and the change is long latency, care must be taken (at the PSL level) to not
+return inconsistent values. </p> <p>Other power resources may be long latency
+on both state change and state read operations. This is typically the case
+for any resources accessed through an inter-IC bus (even if their operation
+is instantaneous). </p> </li>
+<li id="GUID-8ABE5ED4-C2CB-557E-BF53-9630567AE7DC"><p>Resource <i>sense</i>  </p> <p>Each
+client sharing a resource may have a different requirement on its state. The
+resource <i>sense</i> is used to determine whose requirement prevails. </p> <table id="GUID-BECBC606-95E8-5C6F-BC71-2DA2AA838C88">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>Positive sense </p> </entry>
+<entry><p>Can have their value increased without affecting their sharers. </p> <p>The
+level is set to the highest level that is requested. The highest requirement
+for binary resources is the On state. </p> </entry>
+</row>
+<row>
+<entry><p>Negative sense </p> </entry>
+<entry><p>Can have their value decreased without affecting their sharers. </p> <p>The
+level is set to the lowest level that is requested. The lowest requirement
+for binary resources is the Off state. </p> </entry>
+</row>
+<row>
+<entry><p>Custom sense </p> </entry>
+<entry><p>May be increased or decreased freely by some privileged sharers
+but not by others, which are bound by the requirement of the privileged sharers. </p> <p>The
+decision to change the prevailing level (or binary state) depends on the privileges
+of the client and past usage of the resource. This decision is made by the
+PSL <xref href="GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671.dita#GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671/GUID-9526B472-00ED-583A-8BFC-C02363D4DFA2">custom
+function</xref> implementation. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </li>
+<li id="GUID-CF996934-F142-5A79-BE7B-D91FE3109D95"><p>Static or Dynamic </p> <p>Most
+power resources are known at device creation time, so their control should
+be addressed by such components as the Variant or ASSP. These resources are
+registered during the creation of the Resource Controller; these are static
+resources. Resources controlled by device drivers (internal or external) are
+only registered at driver-creation time using the registration and deregistration
+API provided by the PRM; these are known as dynamic resources. </p> <p> <b>Note</b>:
+Dynamic resources are only available when you use the extended library. See <xref href="GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9.dita#GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9/GUID-0F328055-DBCE-5B2B-A1EB-77F73BA1FC82">setup
+and configuration</xref>. </p> </li>
+</ul> <p>Physical resources may belong to one or more of these categories,
+for example, a multilevel resource may be shared between different clients
+and take a significant time to change state (long latency). </p> <p>External
+devices may include and control their own power resources. In some cases,
+an external device can function as a bus expander, allowing other devices
+to be connected, and eventually share the power resources it controls. </p> <p id="GUID-121C14E3-D446-565E-AAAE-C43C131ACD3C"><b>Caching the prevailing level</b> </p> <p>The
+PRM caches the prevailing level of each resource as well as the client that
+requested it. The cached state is guaranteed to be the state that the resource
+was in when the last request to change or read the state from its hardware
+was issued. </p> <p>On resource state read operations, the PRM allows clients
+to select the cached state instead of the current state of the hardware resource.
+A cached state read is always an instantaneous operation executed in the context
+of the calling client thread (even for long latency resources). </p> <p>However,
+care must be taken as the cached state may not be the state the resource is
+at that moment. For example, a resource can be non-sticky: when it is turned
+on it stays on during an operation but then automatically switches itself
+off. </p> <p>The consistency of the cached state relies on all resource state
+operations being requested through the <xref href="GUID-4804B6E0-9199-5F3E-984A-4B00B3984E45.dita">Power
+Resource Controller</xref>. </p> <p><b>Dynamic
+resources</b> </p> <p>A generic layer provides basic functionality for static
+resources an extended version of the PRM provides APIs for dynamic resources
+and resource dependencies. These dynamic resource and resource dependent APIs
+are only available through the extended library <filepath>resmanextended.lib</filepath>. </p> <p>A
+dynamic resource is registered with the PRM using <xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita#GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00/GUID-1AB3CD4A-2BD3-366A-9359-791B3BBC9127"><apiname>PowerResourceManager::RegisterDynamicResource()</apiname></xref>.
+This function is also used to register a dynamic resource that supports dependencies
+between resources. </p> <codeblock id="GUID-0325A795-F99E-5098-947E-24A10C5D5416" xml:space="preserve">TInt RegisterDynamicResource(TUint aClientId, DDynamicPowerResource* aResource, TUint&amp; aResourceId)</codeblock> <p>Pass the ID of the client that requests the dynamic resource and the
+dynamic resource (<xref href="GUID-CA01041D-8FD6-3B5B-BB5D-A5159DF7C9AB.dita"><apiname>DDynamicPowerResource</apiname></xref>) to register. The
+PRM sets <codeph>aResourceId</codeph> to the resource ID of this resource.
+Dynamic resources that support dependencies are derived from the class <xref href="GUID-6B224A9F-D2B9-3289-922D-766EF093FCD6.dita"><apiname>DDynamicPowerResourceD</apiname></xref>. </p> <p><b>Deregistering a dynamic resource</b> </p> <p>Use <xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita#GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00/GUID-8E388C73-F26D-30F7-9CA9-5ED0439E4C4D"><apiname>PowerResourceManager::DeRegisterDynamicResource()</apiname></xref> to
+deregister a dynamic resource from the PRM. You can also use the function
+to deregister a dynamic resource that supports a dependency. </p> <codeblock id="GUID-89FC49A8-FC66-5B8C-A82C-18987E2BA0E7" xml:space="preserve">TInt DeRegisterDynamicResource(TUint aClientId, TUint aResourceId, TInt* aState)</codeblock> <p> <codeph>aState</codeph> is a pointer to the final state that the resource is set
+to before deregistration if this value is NULL the state of the resource is
+changed to its default. </p> <p><b>Changing resource state on a dynamic resource </b> </p> <p>Because a dynamic
+resource can deregister from the PRM it is necessary to indicate to clients
+that this has happened. Any remaining notification requests are completed
+with a -2 in the client field of the callback function. This indicates that
+this notification is because the resource has been deregistered and not because
+the notification conditions have been met. When a client recieves a notification
+of this type the request notification should be cancelled using <xref href="GUID-51CAD2A1-C978-3EBD-984F-4C5C59D68885.dita"><apiname>CancelNotification()</apiname></xref>. </p> <p id="GUID-473BBE32-6831-52BE-8752-CB6DBBBABD2C"><b>Resource dependencies</b> </p> <p>A
+resource may register a dependency on another resource. At least one of the
+resources must be a dynamic resource. Request a dependency between resources
+with <xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita#GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00/GUID-9C1BF3D5-6F5D-3BEF-9DF0-A5FED85CC718"><apiname>PowerResourceManager::RegisterResourceDependency()</apiname></xref>. </p> <codeblock id="GUID-EC9D5125-BC25-5196-88E7-3245B3B62AF4" xml:space="preserve">TInt RegisterResourceDependency(TUint aClientId, SResourceDependencyInfo* aResDependecyInfo1, SResourceDependencyInfo* aResDependencyInfo2)</codeblock> <p>This function is passed the ID of the client that sets the resource dependency
+and the dependency information of the resource (<xref href="GUID-88FE83B0-35A1-3913-B38F-1FB925FFE96C.dita"><apiname>SResourceDependencyInfo</apiname></xref>). <codeph>SResourceDependencyInfo</codeph> contains
+the resource ID and the priority of the dependency. </p> <p>The kernel will
+panic if a closed loop dependency is found for the specified dependency or
+if a resource with same dependency priority is already registered. </p> <p>Use <xref href="GUID-A3D65EA0-70B1-35E9-998D-EC4C1A294AB8.dita"><apiname>GetNumDependentsForResource()</apiname></xref> to
+retrieve the number of resources that depend on the specified resource directly
+and <xref href="GUID-9C582DAB-2C0B-331D-BA8D-CED067289055.dita"><apiname>GetDependentsIdForResource()</apiname></xref> to return the IDs of all
+the dependent resources. </p> <p><b>Deregistering
+resource dependencies</b> </p> <p>Use <xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita#GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00/GUID-127E979F-F540-36E2-A759-8ED408E89F38"><apiname>PowerResourceManager::DeRegisterResourceDependency()</apiname></xref> to
+remove a dependency. This function takes the ID of the client that requests
+the deregistration of the resource dependency and the IDs of the linked resources. </p> <codeblock id="GUID-561502A3-2603-5090-98F3-6BF714C8514B" xml:space="preserve">TInt DeRegisterResourceDependency(TUint aClientId, TUint aResourceId1, TUint aResourceId2)</codeblock> <p> <b>Note</b>: These functions are only available when you use the extended
+library. </p> <p><b>Changing
+resource state on a dependent resource</b> </p> <p>A resource state can change
+when the state of any of its dependent resources changes. A state change causes
+a notification if the requested conditions are met. The client ID in the callback
+function is updated with the ID of the resource that triggered this resource
+change (bit 16 of the ID is set for dependency resource; this is used to distinguish
+between a resource ID and a client ID). </p> <p id="GUID-8BBC100D-BB97-5675-AA2F-E730A0DF4B26"><b>Clients</b> </p> <p>The
+PRM has both user and kernel-side clients. Kernel-side clients are: </p> <ul>
+<li id="GUID-7DDBF8D2-80AD-5248-9C8A-2F215E98513E"><p>device drivers </p> </li>
+<li id="GUID-914A7E0F-9FE5-579A-AEB5-35163D89E450"><p>performance scaling
+and/or performance monitoring and prediction components </p> </li>
+</ul> <p>User-side clients are: </p> <ul>
+<li id="GUID-E1A4D6C3-9EEC-54EB-BEF4-90C3DD65E4A3"><p>user-side system-wide
+power management framework </p> </li>
+<li id="GUID-08B28DD8-107E-5142-A887-F685A17915DC"><p>other power-aware servers
+and power-aware applications </p> </li>
+</ul> <p>Clients register with the PRM by name. Clients can request to allocate
+and reserve client level objects and request message objects after registering
+with PRM. </p> <p id="GUID-F47D2098-16A7-5590-A68A-7AE4B2DAB462"><b>Client level objects</b> </p> <p>Client
+level objects represent a client requesting a level on a resource. They are
+used by resources to set the current level of the resource and the current
+owner of the resource level. </p> <p>Each resource has a doubly linked list
+on which client level objects are held. When a client requests a level for
+the first time, a new client level object is added to the list; however, if
+the client already has an object on the list, this object is adjusted to reflect
+the change in the required level. </p> <p>The following rules determine whether
+the change is allowed on positive and negative sense resources: </p> <ul>
+<li id="GUID-18D734C9-F01A-53D8-9B2B-9DED288F8968"><p>If the requested change
+is in the direction permitted by the resource sense and would result in exceeding
+the prevailing level, the change is allowed. </p> <p>The new prevailing level
+is recorded, and the previous prevailing level and the requirements other
+clients have on the resource remain on record. </p> </li>
+<li id="GUID-9901C6DC-D91F-5CB4-BA68-10E941486BBF"><p>If the requested change
+is not in the direction permitted by the resource sense, but the client requesting
+the change is the owner of the prevailing level, the resource state changes
+up to next highest for a positive sense resource, or lowest for a negative
+sense resource. </p> <p>This value is now the prevailing level and the client
+that requested it remains the owner of the prevailing level. </p> </li>
+<li id="GUID-643C8DE3-322C-5C2A-840F-80F02DDFB60D"><p>If the requested change
+is not in the direction permitted by the resource sense, and the client requesting
+the change is not the owner of the prevailing level, the change is not allowed. </p> <p>Even
+though the request was rejected, the client's existing requirement is adjusted
+to reflect the request. </p> </li>
+</ul> <p>Prevailing levels are recorded by either adjusting the previous requirement
+for the client that requested it or, if it is the first time this client requests
+a level, a new requirement is created. </p> <p id="GUID-8FE4BD6A-6A69-5233-88E2-32837A42A544"><b>Notifications</b> </p> <p>A
+client may request a state change notification from a resource. Notifications
+can be conditional or unconditional; conditional notifications specify a threshold
+on the resources state, which when crossed in the direction specified, triggers
+the notification. </p> <p>Notifications are always issued post resource change
+and invoke callback functions executed in the context of the requesting client
+thread. The process of notifying a client involves queuing a DFC in that clients'
+thread. The notification object encapsulating the DFC must be created in kernel
+heap and passed to the notification API by the client that requested the notification.
+The client may share the same callback function between several notifications,
+but a unique DFC must be created and queued per notification. </p> <p>Because
+notifications result in DFCs being queued, it is not possible to guarantee
+that all changes of resource state are notified. If the resource state changes
+again before the first DFC runs, a separate notification cannot be generated.
+It is also not possible to guarantee that by the time the notification callback
+runs, the resource state is still the same as the state that caused the notification
+to be issued: it is the responsibility of the driver to read the resource
+state after receiving a notification. </p> </section>
+<section id="GUID-5C3F684C-D4F6-5343-AFFC-009B70210F9C"> <title>User-side</title> <ul>
+<li id="GUID-80696301-3BF7-5DBC-84DB-5961FB6D2F0E"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-B33A80C1-6079-556E-89D7-BC1F2304384D">Introduction</xref>  </p> </li>
+<li id="GUID-E8D832DE-1879-5508-841D-90D87EE34E02"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-A5D4981F-4B16-5174-A41A-E9EEC70EA62C">Initialisation</xref>  </p> </li>
+<li id="GUID-59F352F4-2602-59F5-BC3A-71544A092361"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-1DC958F3-7952-56C0-A8BC-F52B2A83BE3C">Getting power resource information</xref>  </p> </li>
+<li id="GUID-8437EDA3-1E1E-588C-B25D-719EE6921350"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-8BDF9B79-BC05-593C-B39E-C6B8BD26AA2D">Requesting notifications</xref>  </p> </li>
+<li id="GUID-465111CA-8F3B-52C9-85E9-F81CC0AB87FA"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-ACA22305-8990-54F5-8098-80716F4A5AAE">Changing the state of power resources</xref>  </p> </li>
+</ul> <p id="GUID-B33A80C1-6079-556E-89D7-BC1F2304384D"><b>Introduction</b> </p> <p>The <xref href="GUID-FD3DEFC1-DA39-3A1A-8E00-A46B34B78899.dita"><apiname>RBusDevResManUs</apiname></xref> user-side
+API makes relevant PRM functionality available to user-side applications that
+have power-aware features. </p> <p> <codeph>RBusDevResManUs</codeph> is derived
+from <xref href="GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066.dita"><apiname>RBusLogicalChannel</apiname></xref>, the user-side handle to a logical
+channel base class, and presents the user-side interface to a kernel-side
+LDD. The LDD is built as <filepath>resman.ldd</filepath>. </p> <p>The API
+enables concurrent access by multiple clients, with one channel supported
+for each. Sharing of channels between threads is not supported. </p> <p> <note> To
+open a channel on the user-side API a client must exhibit the <xref href="GUID-4BFEDD79-9502-526A-BA7B-97550A6F0601.dita">PlatSec</xref> capability <codeph>PowerMgt</codeph>.</note></p><p> If a client wishes to access information
+on kernel-side clients of the Resource Controller, it must also exhibit the <codeph>ReadDeviceData</codeph> capability. </p> <p id="GUID-A5D4981F-4B16-5174-A41A-E9EEC70EA62C"><b>Initialisation</b> </p> <p>Clients
+do not need to explicitly load the kernel-side LDD, as this is a kernel extension
+and so is loaded and initialised during kernel initialisation (attempts to
+re-load it returns the error code <codeph>KErrAlreadyExists</codeph> but initialistation
+otherwise appears successful). </p> <p>Clients open a channel on the LDD by
+calling the <xref href="GUID-FD3DEFC1-DA39-3A1A-8E00-A46B34B78899.dita#GUID-FD3DEFC1-DA39-3A1A-8E00-A46B34B78899/GUID-505CFB46-E77B-38D2-AE50-B088D5D2B0F1"><apiname>RBusDevResManUs::Open()</apiname></xref> method. The client
+passes a name to the method - ideally, this is the client’s component name.
+It is the client’s responsibility to ensure the name is unique even if multiple
+channels are opened. </p> <p>The client then needs to call the <xref href="GUID-E735AB4A-E9D5-33C7-ACEC-815013C0777A.dita"><apiname>Initialise()</apiname></xref> method
+specifying the number of request objects required. The numbers passed to <codeph>Initialise()</codeph> determine
+the extent of memory allocation required (in part by the LDD and in addition
+by request to the Resource Controller) and also the maximum number of concurrent
+client requests supported. </p> <p>The number of request objects created at
+initialisation should be the maximum number of concurrent (asynchronous) requests
+that the client expects to have outstanding at any time. </p> <p id="GUID-1DC958F3-7952-56C0-A8BC-F52B2A83BE3C"><b>Getting power resource information</b> </p> <p> <xref href="GUID-FD3DEFC1-DA39-3A1A-8E00-A46B34B78899.dita#GUID-FD3DEFC1-DA39-3A1A-8E00-A46B34B78899/GUID-778D2DB8-A3B4-3F70-BFF0-3EB7B4D68866"><apiname>RBusDevResManUs::GetResourceInfo()</apiname></xref> is a method to retrieve the information for a specified resource, which
+it returns in a <xref href="GUID-A1DDD3E3-C009-3C02-895B-0B2D0EE67A9D.dita"><apiname>TResourceInfo</apiname></xref> object. There is also a method
+to get all the information for all the resources (<xref href="GUID-CF17E4E8-CFBC-31C2-B1CC-84D78006D046.dita"><apiname>GetAllResourcesInfo()</apiname></xref>).
+This function requires the allocation of buffer memory in which the information
+for all the resources is returned. <xref href="GUID-D3AB721D-35AB-36F9-B08D-10E44B6B8129.dita"><apiname>GetNoOfResources()</apiname></xref> returns
+the total number of resources available for access. </p> <p>The example below
+shows these functions in use. The amount of resources available are returned
+by <codeph>GetNoOfResources</codeph>. This figure is used to calculate the
+size of the buffer that is populated with the resource information by the <codeph>GetAllResourcesInfo</codeph> method. </p> <codeblock id="GUID-BB6AC0F1-DC41-51EE-ADA3-1402B3C3E90E" xml:space="preserve"> TInt r = KErrNone;
+ TUint numResources=0;
+    if((r=gChannel.GetNoOfResources(numResources))!=KErrNone)
+        {
+        // Failed
+        return r;
+        }
+
+    RBuf buffer;
+    if((buffer.Create(numResources*sizeof(TResourceInfo)))!=KErrNone)
+        {
+        // Failed
+        return KErrGeneral;
+        }
+
+    buffer.SetLength(numResources*sizeof(TResourceInfo));
+
+    if((r=gChannel.GetAllResourcesInfo(buffer,numResources))!=KErrNone)
+        {
+        // Failed
+        return r;
+        }</codeblock> <p>Get the current resource state with <xref href="GUID-79CC3D60-3B7B-3FC2-8067-205165281E28.dita"><apiname>GetResourceState()</apiname></xref>.
+Passing <codeph>ETrue</codeph> results in the cached state being read rather
+than the current hardware state. The cached state is guaranteed to be the
+state that the resource was in when it was last changed or read from hardware.
+This is why it is important that all change requests are carried out through
+the Resource Controller. <codeph>readValue</codeph> returns the current prevailing
+level and <codeph>levelOwnerId</codeph> the ID of the client that owns the
+prevailing level. <codeph>GetResourceState()</codeph> can be cancelled using <xref href="GUID-BD242DA6-1D09-3770-94BF-CCCB396AEBE4.dita"><apiname>CancelGetResourceState()</apiname></xref> passing
+the resource ID of the resource that the original request was on. Use the
+method <xref href="GUID-2306456B-6502-3E49-B707-885D994E01C5.dita"><apiname>GetResourceIdByName()</apiname></xref> to get the ID of a resource
+from the resource's name. </p> <codeblock id="GUID-FA4561F7-9223-542E-9B3C-2E03AB06FE28" xml:space="preserve">// Get initial state
+TRequestStatus status;
+TBool cached = EFalse;
+TInt readValue;
+TInt levelOwnerId = 0;
+
+gChannel.GetResourceState(status, gSharedResource, cached, &amp;readValue, &amp;levelOwnerId);
+User::WaitForRequest(status);</codeblock> <p> <xref href="GUID-EABEB759-9BF4-3278-B14C-8B887007C1D3.dita"><apiname>GetNumClientsUsingResource()</apiname></xref> and <xref href="GUID-000DC2CE-9C7B-3C0C-AABF-2D5B2C2EFA1D.dita"><apiname>GetNumResourcesInUseByClient()</apiname></xref> are used to retrieve the numbers of clients using a resource and the number
+of resources in use by a client, respectively. <xref href="GUID-EADA4695-1058-34B6-963C-42BFC794C296.dita"><apiname>GetInfoOnClientsUsingResource()</apiname></xref> and <xref href="GUID-8C32B87E-0EBB-34EF-8C6B-6AB159B4CB09.dita"><apiname>GetInfoOnResourcesInUseByClient()</apiname></xref> complement the last two methods by retrieving the resource information for
+each resource that is in use by a specified client or retrieving the client
+information for each client using the specified resource. </p> <p>The API
+supports receiving a number of concurrent (asynchronous) requests from a client;
+the maximum number is determined by the number of resources that were specified
+at initialisation. If a client issues a request that exceeds its allocation,
+the error code <codeph>KErrUnderflow</codeph> is returned. </p> <p>Some synchronous
+methods take a binary value, <codeph>aIncludeKern</codeph>, which defaults
+to <codeph>EFalse</codeph>. If this parameter is set to <codeph>ETrue</codeph>,
+the API attempts to return information that includes kernel-side clients. </p> <p id="GUID-8BDF9B79-BC05-593C-B39E-C6B8BD26AA2D"><b>Requesting notifications</b> </p> <p>Clients
+can request to be notified when a resource changes its state using the <xref href="GUID-FD3DEFC1-DA39-3A1A-8E00-A46B34B78899.dita#GUID-FD3DEFC1-DA39-3A1A-8E00-A46B34B78899/GUID-E1EE8324-E39F-3094-9BF1-932706B35DC1"><apiname>RBusDevResManUs::RequestNotification()</apiname></xref> method.
+Clients can also request to be notified when a resource reaches a specified
+threshold in a specified direction (positive or negative <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-4CC0C003-1952-5CAD-A7C5-163C5DDA52C8">resource sense</xref>) using the same method but also passing it threshold
+and direction values. </p> <p>To cancel a notification, use <xref href="GUID-51CAD2A1-C978-3EBD-984F-4C5C59D68885.dita"><apiname>CancelNotification()</apiname></xref> passing
+the resource ID from which the notification was requested. <b>Note</b>: Any
+notifications issued by a client must be cancelled before the client deregisters. </p> <p>It
+is not guaranteed that all changes of resource state result in a notification
+– a resource may change state more than once before a notification request
+is completed. In addition, it is not guaranteed that a resource is in the
+same state as it was when the notification was generated. For these reasons,
+it is the responsibility of the user-side client to read the state of a resource
+after receiving a notification. </p> <p id="GUID-ACA22305-8990-54F5-8098-80716F4A5AAE"><b>Changing the state of power
+resources</b> </p> <p>To change a resource state call the asynchronous <xref href="GUID-9E260255-90BB-3D17-9A23-F02C8FCD3D72.dita"><apiname>ChangeResourceState()</apiname></xref> method
+passing the ID of the resource on which the change is being requested and
+the requested state. </p> <p> <xref href="GUID-181BB8BF-EA17-3A5E-8B70-94265CBD15E1.dita"><apiname>CancelChangeResourceState()</apiname></xref> cancels
+all the <codeph>ChangeResourceState()</codeph> outstanding requests from the
+client on the specified power resource. For each outstanding request, the
+request object is removed from the doubly linked list within the Resource
+Controller and returned to the request object pool. </p> </section>
+<section id="GUID-DE8EE84C-D46F-504A-8254-C212B7C5D5C1"> <title>Kernel-side</title> <p>The Power Resource Manager component is implemented
+as a kernel extension. It has an exported public interface accessible to kernel-side
+components. Kernel components link to the resource manager kernel extension
+DLL (<filepath>resman.lib</filepath>). Extended features are compiled and
+exported in an additional library (<filepath>resmanextended.lib</filepath>).
+The export library is built from the generic layer. </p> <p>To ease the development
+of the PRM including the functionality provided by the generic layer and the
+mandatory PSL implementation, the generic layer is compiled into a kernel
+library (klib) (<filepath>resmanpsl.lib</filepath> for the basic version and <filepath>resmanextendedpsl.lib</filepath> for
+the extended version) which is included by the PSL to produce the kernel extension. </p> <ul>
+<li id="GUID-5D5302A9-1C1B-5B75-A203-64526CDDEB3E"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-F5E775AB-F428-5800-8844-20A1BA41380D">Concepts</xref>  </p> </li>
+<li id="GUID-2A6C1709-1DE5-5A2F-B925-E81763B85EB0"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-7745C72D-DBFA-5E96-B0EB-497329A5A77D">Registration and initialisation</xref>  </p> </li>
+<li id="GUID-8B1D1CF6-06D0-5C95-8C86-747EAE9C80E8"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-A20D5070-99F1-5B1E-9D3E-D8769030BDEE">Deregistration</xref>  </p> </li>
+<li id="GUID-4D39457D-6193-5C0A-9858-B8BAF957D0CA"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-7F518094-4B91-5EA7-AAFA-8ABC8D7F77CE">Requesting power resource information</xref>  </p> </li>
+<li id="GUID-4B572D4B-EEA9-53A5-A260-01DE4853B5CE"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-AA2EABEC-477F-54BD-AD1A-F2EF7B6BA5B7">Changing the state of power resources</xref>  </p> </li>
+<li id="GUID-6768FCC6-3FC2-532E-9BB9-16BE4C4EE44C"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-198CE312-343E-535D-8EE5-D615A7AC9265">Requesting notifications</xref>  </p> </li>
+</ul> <p id="GUID-F5E775AB-F428-5800-8844-20A1BA41380D"><b>Concepts</b> </p> <ul>
+<li id="GUID-646E0C0A-6E4D-5FA0-83CD-6BE04B08E4BC"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-E8F3AF8E-387C-5285-A2B2-0B067F01BC3A">Requests</xref>  </p> </li>
+<li id="GUID-9D5A30A8-7214-5D82-A819-B5594339A71C"><p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-0A8C9B3F-C96B-589C-819C-07D4C167BFCD">Callbacks</xref>  </p> </li>
+</ul> <p id="GUID-E8F3AF8E-387C-5285-A2B2-0B067F01BC3A"><b>Request messages</b> </p> <p>Request
+message objects represent a request for an operation on a resource by a client.
+For example a request to change a resource's level or notification if a resource's
+level changes. </p> <p>The client may attempt to increase its quota by requesting
+the allocation of request messages, but this may fail with <xref href="GUID-64F6761A-4716-37C3-8984-FF18FC8B7B7D.dita"><apiname>KErrNoMemory</apiname></xref>.
+A long latency resource request on may fail with <xref href="GUID-3673F75F-655F-3561-BD56-F7E1C6980810.dita"><apiname>KErrUnderflow</apiname></xref> if
+the number of request messages pre-allocated by the client has been exceeded
+and no more messages are left in the free pool to satisfy the request. </p> <p>The
+pre-allocation and reservation of <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-F47D2098-16A7-5590-A68A-7AE4B2DAB462">client
+levels</xref> and request messages is synchronously serviced in the context
+of the calling client, although this may result in memory allocation that
+is not time bound. </p> <p>See <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-2DE84E1F-C466-5631-A007-EEF046905388">Pre-allocating
+client level and request message objects</xref> for implementation guidelines. </p> <p id="GUID-0A8C9B3F-C96B-589C-819C-07D4C167BFCD"><b>Callbacks</b> </p> <p>A
+callback object is a customised DFC that is used to signal the completion
+of notifications and the PRM's asynchronous APIs. Use the class <xref href="GUID-9B43C51D-56F7-35E0-BDD5-5D2F27924383.dita"><apiname>TPowerResourceCb</apiname></xref> to
+create a resource callback object that encapsulates callback functions. </p> <p>The
+resource callback object is initialised with a callback function <xref href="GUID-F42CE2D1-6859-352A-89A7-01DFBB1FE249.dita"><apiname>TPowerResourceCbFn</apiname></xref>,
+a pointer to data passed to the callback function, the priority of the DFC
+within the queue (0 to 7, where 7 is highest) and optionally, a pointer to
+the DFC queue that this DFC should use. </p> <codeblock id="GUID-11947A50-7639-550D-BFB0-3B6320088065" xml:space="preserve">inline TPowerResourceCb(TPowerResourceCbFn aFn, TAny* aPtr, TInt aPriority)</codeblock> <p>This one specifies the DFC queue: </p> <codeblock id="GUID-21FE792B-24A2-502C-AA9E-EE8092573DA7" xml:space="preserve">inline TPowerResourceCb(TPowerResourceCbFn aFn, TAny* aPtr, TDfcQue* aQue, TInt aPriority)</codeblock> <p>The user specified callback function is invoked with five arguments: </p> <ul>
+<li id="GUID-0912EE6D-A1DC-528D-8AEE-423D703C12CA"><p>the ID of the client
+is: </p> <ul>
+<li id="GUID-27C7A49B-BFCB-5D96-A129-7AE19A1CB430"><p>the client that issued
+an asynchronous operation - if the callback function is called as a result
+of an asynchronous resource state read operation </p> </li>
+<li id="GUID-F4181885-29F6-53DB-8555-EB735EF83F81"><p>the client that is currently
+holding the resource - if the callback function is called as a result of an
+asynchronous resource state change operation or resource state change notification. </p> </li>
+<li id="GUID-E8720BBB-BF9A-53FB-A123-AACA62A4F435"><p> <b>Note</b>: </p> <ul>
+<li id="GUID-87393CD1-684C-503C-9A2A-982961FC8169"><p>If -1 is passed as the
+client ID this specifies that no client is currently holding the resource. </p> </li>
+<li id="GUID-A3AB501B-004A-538E-B811-6733C76D213C"><p>In the extended version
+of PRM (see Dynamic and Dependant resources) if -2 is passed as the client
+ID in the callback function it signifies that the dynamic resource is deregistering.
+With dependency resources, the ID of the dependent resource is passed as the
+client ID if the state of the resource (specified in <codeph>aResourceId</codeph>)
+changes as a result of the dependant resources stage changing (whose ID is
+specified in <codeph>aClientId</codeph>). </p> </li>
+</ul> </li>
+</ul> <ul>
+<li id="GUID-A38B31E5-DB85-561A-A256-CF6FF025D9B0"><p>issued an asynchronous
+API (state read or change) which leads to the callback function being called </p> </li>
+<li id="GUID-F58DA60D-CA0E-5F82-9655-F1FF4D53D8B5"><p>requested the resource
+state change that leads to queuing a notification, which then leads to the
+callback function being called. </p> </li>
+</ul> </li>
+<li id="GUID-7ABBA59B-71A0-55CC-9722-5A569F95A881"><p>the resource ID - a
+client may have multiple notifications pending on different resources and
+a single callback function. The resource ID can be used to specify which resource
+change is being notified </p> </li>
+<li id="GUID-D18973A1-1E60-5335-BF98-1CCEB229730E"><p>the level of the resource
+when either: </p> <ul>
+<li id="GUID-9AC96325-FA2E-552F-A306-B0CCDA95B5BD"><p>the callback is called
+as a result of a notification of state change </p> </li>
+<li id="GUID-3886E475-28C5-5410-8801-0F4E9B273F13"><p>when the callback is
+called as a result of a non-blocking form of <xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita#GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00/GUID-318F8627-AB72-3AA9-93A8-F8131117FF90"><apiname>PowerResourceManager::GetResourceState()</apiname></xref>. </p> </li>
+<li id="GUID-5C65D90E-A9C8-5439-A8FE-B077AC00F4AF"><p>the requested level
+for the resource when the callback is called as a result of a non-blocking
+form of <xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita#GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00/GUID-9E89A793-A838-3E48-AC24-17367E36EC05"><apiname>PowerResourceManager::ChangeResourceState()</apiname></xref>  </p> </li>
+</ul> </li>
+<li id="GUID-56181048-98E7-57BB-81D9-D863663F44C2"><p>the ID of the resource
+level owner </p> </li>
+<li id="GUID-5924CF16-4493-5845-ADB0-615968D9D8C7"><p>the error code returned
+when the callback is called as a result of an asynchronous request to change
+the state of the resource. This is not relevant when the callback is called
+as a result of a notification of state change </p> </li>
+<li id="GUID-8BAD3C01-7AA1-5C42-A52F-05C1BF5957D0"><p>a user defined argument
+that is passed to the constructor. </p> </li>
+</ul> <p>Cancel an asynchronous request, or its callback, by calling <xref href="GUID-98C67010-FAD0-3D09-BFBF-EE240ADB95E7.dita"><apiname>CancelAsyncRequestCallback()</apiname></xref>. </p> <p id="GUID-7745C72D-DBFA-5E96-B0EB-497329A5A77D"><b> Registration and initialisation</b> </p> <p>Clients
+need to register with the PRM using <xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita#GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00/GUID-4F932142-C551-3DBB-8DC8-F697B92E8168"><apiname>PowerResourceManager::RegisterClient()</apiname></xref> before
+they can request operations on resources. </p> <p>Registration happens at
+different times for different clients: </p> <ul>
+<li id="GUID-491C4B9C-86BC-5AC2-870A-0FA46FDE3CA9"><p>kernel extensions register
+from their entry point during kernel boot </p> </li>
+<li id="GUID-8A6D66CC-DD34-5CC2-9AD3-BEEC7B540BA8"><p>device drivers for internal
+or external devices register on opening a channel. </p> </li>
+</ul> <p>When a client registers with the PRM, a client link object is removed
+from the free pool, populated with the relevant information, and a pointer
+to it is added to a container of clients within the PRM. If no free link exists
+within the pool, a number of client links are created in kernel heap. As a
+result, client registration may fail in out of memory situations. Client links
+are never destroyed after the client deregisters, but are released back into
+the free pool. </p> <p>Clients are registered by name; the PRM does not check
+that a name is unique unless the <codeph>DEBUG_VERSION</codeph> macro is enabled.
+The component registering the client should check that the name is unique.
+The ID returned is a handle to the client link object that represents the
+client in the PRM. </p> <p>On registration, a client also specifies the type
+of ownership (<xref href="GUID-19F111C8-00AC-3A2E-85A6-755DC322C870.dita"><apiname>TOwnerType</apiname></xref>) that applies. This is either: </p> <ul>
+<li id="GUID-E7A9ADE9-8590-5CB0-ADE9-8354BADCE77D"><p> <codeph>EOwnerThread</codeph> -
+the client ID is only used by the thread that registered the client to call
+the PRM APIs </p> </li>
+<li id="GUID-9EED259E-E339-59E0-BE96-8A33EA01AE98"><p> <codeph>EOwnerProcess</codeph> -
+the client ID is used by all threads in the process to call the PRM APIs. </p> </li>
+</ul> <p>The default is <codeph>EOwnerProcess</codeph>. </p> <p id="GUID-2DE84E1F-C466-5631-A007-EEF046905388"><b>Pre-allocating client level
+and request message objects </b> </p> <p>The controller has an initial pool
+of free client levels and request messages whose size can be configured at
+build time by the PSL. After registering with the PRM, a client can request
+the pre-allocation of a number of client levels and request messages to guarantee
+deterministic behaviour (to avoid out of memory failure) of the resource state
+change operation using <xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita#GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00/GUID-F787A2A2-8860-3145-97FB-46D6B8D6E5AC"><apiname>PowerResourceManager::AllocReserve()</apiname></xref>.
+This allocation remains reserved to the specified client until the client
+is deregistered from the PRM. The number of client level objects reserved
+by a client depends on the number of resources on which a resource state change
+will be requested. </p> <p>A client may issue more than one request, possibly
+to the same resource, before the previous one completes, it is therefore more
+difficult to determine how many objects to pre-allocate. </p> <p>It is recommended
+that as many request messages as asynchronous long latency resources the client
+expects to use are pre-allocated. The free pool should be relied on for the
+situations when a resource is requested more than once before the first request
+completes. </p> <p id="GUID-A20D5070-99F1-5B1E-9D3E-D8769030BDEE"><b>Deregistration</b> </p> <p>All
+notifications and asynchronous requests must be cancelled before the client
+is deregistered, otherwise the kernel will panic. Use the <xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita#GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00/GUID-C076174C-D16A-3A8B-825C-F7BE2424EA3D"><apiname>PowerResourceManager::CancelNotification()</apiname></xref> and <xref href="GUID-98C67010-FAD0-3D09-BFBF-EE240ADB95E7.dita"><apiname>CancelAsyncRequestCallback()</apiname></xref> methods to cancel all pending notifications and asynchronous requests. Notifications
+that have been registered with the Controller should be deregistered before
+they are deleted as the Controller may attempt to issue them. Deleting a notification
+that is still registered with the Controller results in the kernel panicking. </p> <p> <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-F47D2098-16A7-5590-A68A-7AE4B2DAB462">Client
+level objects</xref> and request objects reserved by the client remain reserved
+for that client until it deregisters. When the client is deregistering these
+objects are moved to free pool by the PRM. </p> <p>Client deregistration can
+result in a resource state change: </p> <ul>
+<li id="GUID-8C4B2F9D-7B4D-5BC4-8B8C-02D1AEFDF1C5"><p>If the resource is shared
+and the deregistering client owned the prevailing level, the resource state
+is moved to the next level according to its sense. If it is a custom sense
+resource, the resource state is changed as a result of calling a custom function. </p> </li>
+<li id="GUID-DE1341E0-C392-5982-8A0D-3CCE9A8DC950"><p>If the resource is not
+shared or if it is shared but the client is the only one using it at the time
+of deregistration, the resource is moved to the <i>default</i> state. The
+default state is only known by the PSL. </p> </li>
+</ul> <p>A deregistering client can have a number of active requirements on
+a number of resources and more than one of these resources may need to change
+state as a result of the client deregistering. The combined operation of deregistering
+the client and adjusting the state of all resources it shares executes synchronously.
+That is, the client thread is blocked throughout whether the resources whose
+state needs to change is instantaneous or long latency. </p>  <p id="GUID-7F518094-4B91-5EA7-AAFA-8ABC8D7F77CE"><b>Getting power resource information</b> </p> <p>The
+resource information can be retrieved using the method <xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita#GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00/GUID-AFD3385B-362B-3F8B-B7EF-262CB21C0EE2"><apiname>PowerResourceManager::GetResourceInfo()</apiname></xref>,
+information can also be retrieved for all of the resources used by the specified
+client using <xref href="GUID-8C32B87E-0EBB-34EF-8C6B-6AB159B4CB09.dita"><apiname>GetInfoOnResourcesInUseByClient()</apiname></xref>. This function
+takes a buffer that must be the size of the information structure multipled
+by the number of resources in use by the client, this figure can be retrieved
+using the method <xref href="GUID-000DC2CE-9C7B-3C0C-AABF-2D5B2C2EFA1D.dita"><apiname>GetNumResourcesInUseByClient()</apiname></xref>. Specify
+the resource ID as zero to retrieve all information from all the clients registered
+with PRM. </p> <p>To get information about clients using a resource, use the
+method <xref href="GUID-EADA4695-1058-34B6-963C-42BFC794C296.dita"><apiname>GetInfoOnClientsUsingResource()</apiname></xref>. Use the number
+of clients using a resource using <xref href="GUID-EABEB759-9BF4-3278-B14C-8B887007C1D3.dita"><apiname>GetNumClientsUsingResource()</apiname></xref>.
+Specify the client ID as zero to retrieve all information from all the resources
+registered with PRM. </p> <p>Use <xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita#GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00/GUID-318F8627-AB72-3AA9-93A8-F8131117FF90"><apiname>PowerResourceManager::GetResourceState()</apiname></xref> to
+retrieve resource state information. This function can be called synchronously
+or asynchronously. Asynchronous calls require the client to create a callback
+object in the kernel heap or data section. The synchronous <codeph>GetResourceState()</codeph> call. </p> <codeblock id="GUID-00E075BB-E38B-5B15-A7DA-56C032A678C2" xml:space="preserve">TInt GetResourceState(TUint aClientId, TUint aResourceId, TBool aCached, TInt&amp; aState, TInt&amp; aLevelOwnerId);</codeblock> <p>The asynchronous <codeph>GetResourceState()</codeph> call. </p> <codeblock id="GUID-20C6EB70-1CF2-5FDD-85F8-577361E6CA86" xml:space="preserve">TInt GetResourceState(TUint aClientId, TUint aResourceId, TBool aCached, TPowerResourceCb&amp; aCb);</codeblock> <p>If executing asynchronously, the callback function encapsulated in the
+callback object (called in the client’s context) is invoked when the state
+of the resource is available. The third argument of the callback function
+carries the resource state. If this function is called with <codeph>aCached</codeph> set
+as <codeph>ETrue</codeph>, then the callback function is called in the context
+of the calling thread both for instantaneous and long latency resources, thus
+blocking the calling thread throughout. </p> <p>For instantaneous resources, <xref href="GUID-79CC3D60-3B7B-3FC2-8067-205165281E28.dita"><apiname>GetResourceState()</apiname></xref> executes
+in the context of the calling thread and, if specified, the callback function
+is called after getting the state of the requested resource. The calling thread
+is blocked throughout. </p> <p> <codeph>GetResourceState()</codeph> takes
+a boolean value that determines from where the requested resource state information
+is retrieved: </p> <ul>
+<li id="GUID-21044D5D-142F-5E05-9743-3218E99DD7DC"><p>ETrue - the resource
+state is the cached value, this value is returned faster but is not guaranteed
+to be correct </p> </li>
+<li id="GUID-A221B599-2EB3-5E0E-9D3E-E2333BF0AD0F"><p>EFalse - the resource
+state is read from the resource, this value takes longer to return, but is
+much more likely to be correct. </p> </li>
+</ul> <p id="GUID-AA2EABEC-477F-54BD-AD1A-F2EF7B6BA5B7"><b>Changing the state of power
+resources</b> </p> <p>The <xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita#GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00/GUID-9E89A793-A838-3E48-AC24-17367E36EC05"><apiname>PowerResourceManager::ChangeResourceState()</apiname></xref> method
+is used to request a change on a resource. When a state change is requested
+on a shared resource, only the minimum state change that satisfies the request
+is guaranteed. </p> <codeblock id="GUID-48C3E903-398D-5592-8F21-2CE22D824330" xml:space="preserve">TInt ChangeResourceState(TUint aClientId, TUint aResourceId, TInt aNewState, TPowerResourceCb* aCb=NULL);</codeblock> <p>The values passed to the method are: </p> <ul>
+<li id="GUID-5F6B6127-BA40-51BC-829E-90936A8B3FB3"><p>the ID of the client
+requesting the change </p> </li>
+<li id="GUID-5FF24DB5-CA57-571A-846E-6BECB91025A9"><p>the ID of the resource
+that the change is to take place </p> </li>
+<li id="GUID-6764FB93-36D4-56FC-85EC-8EA015ED6F9C"><p>the new state of the
+resource </p> </li>
+<li id="GUID-77092FD0-044D-528B-B62F-56166F21CB3B"><p>a pointer to the resource
+callback object. </p> </li>
+</ul> <p>The requested state is either a binary value for a binary resource,
+an integer level for a multilevel resource or some platform specific token
+for a multi-property resource. The pointer to the callback object is defined
+by the class <xref href="GUID-9B43C51D-56F7-35E0-BDD5-5D2F27924383.dita"><apiname>TPowerResourceCb</apiname></xref>; its use is optional and
+is treated by synchronous and asynchronous resources as described below. </p> <p><b>Changing resource state on a long latency resource </b> </p> <p>If the
+callback object is specified, then <codeph>ChangeResourceState()</codeph> is
+executed asynchronously and returns immediately. The actual resource change
+happens in the resource controller thread and the callback function encapsulated
+in the callback object is called after the resource is changed. </p> <p>If
+the callback object is NULL, then <codeph>ChangeResourceState()</codeph> executes
+synchronously, meaning the client thread is blocked until the resource state
+has changed. The PRM panics if the synchronous version of this API for long
+latency resources is called from DFC thread 0. </p> <p><b>Changing resource state on an instantaneous resource </b> </p> <p>On an
+instantaneous resource <codeph>ChangeResourceState()</codeph> always executes
+synchronously. </p> <p>If a callback object is specified, then the callback
+function encapsulated in the callback object is called from the client thread
+after the resource change and before returning from the function. </p> <p>Use <xref href="GUID-1C044392-213A-3920-93CE-6CAEBBC17D3F.dita"><apiname>CancelAsyncRequestCallBack()</apiname></xref> to
+cancel change requests on a resource. When the client no longer requires a
+level on a resource use the method <xref href="GUID-54784583-DB6D-3847-800E-65DE7ADB8DC6.dita"><apiname>DeRegisterClientLevelFromResource()</apiname></xref> to
+remove a client level object from a resource. </p> <p id="GUID-198CE312-343E-535D-8EE5-D615A7AC9265"><b>Requesting notifications</b> </p> <p>Clients
+can request notification of a state change on a resource. Notifications are
+issued post resource change and invoke the callback function encapsulated
+in a notification object. The callback is executed in the context of the requesting
+client thread. </p> <p>The parameters passed to <xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita#GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00/GUID-316A2B0A-8E58-3D21-B068-5FD228BE0305"><apiname>PowerResourceManager::RequestNotification()</apiname></xref> are: </p> <ul>
+<li id="GUID-DC4C6378-A8A3-564D-8255-F4A91CD498AF"><p>the ID of the client
+requesting the notification </p> </li>
+<li id="GUID-8D08E63E-EEC4-5812-8E42-0A5DAD5DB718"><p>the ID of the resource
+for which notification of state changes is being requested </p> </li>
+<li id="GUID-3C3E2C2F-29B7-5D86-B7A6-A03B814A6C14"><p>a reference to a notification
+object encapsulating a callback function called whenever a resource state
+change takes place. </p> </li>
+</ul> <p>A notification may be unconditional or conditional. An unconditional
+notification request notifies the client each time the state changes. A conditional
+notification request notifies the client when a threshold has been met in
+the direction specified. A conditional notification has these additional parameters: </p> <ul>
+<li id="GUID-0734A09A-010A-57B4-A822-25D709CA55E9"><p>aThreshold - the level
+of the resource state that triggers the notification </p> </li>
+<li id="GUID-FCE1EE43-C431-5967-B778-A7B701CF4983"><p>aDirection - the direction
+the resource state change that triggers a notification: </p> <ul>
+<li id="GUID-3E49268F-EF11-5F18-AC23-16CD26FFA37E"><p>EFalse - the resource
+state is equal to or below the threshold </p> </li>
+<li id="GUID-7FA60FF1-890D-5726-A0CB-3D866504E11F"><p>ETrue - the resource
+state is equal to or above the threshold. </p> </li>
+</ul> </li>
+</ul> <p>The client must create the notification object (<xref href="GUID-80CA4C5E-9575-3EE9-A983-AC74B9DBE351.dita"><apiname>DPowerResourceNotification</apiname></xref>)
+in the kernel heap or data section. <b>Note</b>: The client may share the
+same callback function between several notifications but a unique DFC must
+be created and queued for each notification. </p> <p>Because notifications
+result in DFCs being queued, it is not possible to guarantee that all resource
+state changes are notified. If the resource state changes again, before the
+first DFC runs, it does not generate a separate notification. It is also not
+possible to guarantee that by the time the notification callback runs the
+resource state is still the same state that caused the notification to be
+issued. The client should read the resource state after receiving a notification. </p> <p>Use <xref href="GUID-5E058C0F-39E8-3640-9451-72645567FB04.dita"><apiname>CancelRequestNotification()</apiname></xref> to
+cancel a notification request. It takes a reference to the notification object
+associated with the original notification request that is being cancelled. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6E208C69-AC2C-4A7A-8203-2C4C3F2E54F5.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,60 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6E208C69-AC2C-4A7A-8203-2C4C3F2E54F5" xml:lang="en"><title>Binding
+and Unbinding</title><shortdesc>This document describes how device drivers bind and unbind interrupts.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>To handle events, the interrupt source and the ISR have to be registered
+with the OS: this is called binding the interrupt. An interrupt
+has to be unbound when its use is complete.</p>
+<section id="GUID-36710685-0B8C-4D78-A453-B8772F1D6492"><title>Binding</title> <p> An
+interrupt source ID is bound with the driver's interrupt service routine.
+This is done using the function <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-4E3CB472-3525-32F8-9BC4-8ECFEE931E7B"><apiname>Interrupt::Bind()</apiname></xref> in the <i>second
+stage constructor</i> of the physical channel. Interrupt binding can fail
+if the source has been already used or bound. </p> <codeblock id="GUID-0743023B-86D7-5F76-B58F-A1A2159EFAE4" xml:space="preserve">TInt DExUartPhysicalChannelH4::DoCreate(TInt aUnit, const TDesC8* aInfo, const TVersion&amp; aVer)
+    {
+    ...
+    // Bind the interrupt service routine (ISR) to a specific 
+    // interrupt ID. When the ISR is called, the value aPtr,
+    // (here this object) is passed as the argument. The ISR 
+    // must be a static void function, taking a single TAny* 
+    // parameter: void Isr(TAny* aParam). Interrupt::Enable() 
+    // must be called to start receiving interrupts. Bind() 
+    // returns KErrInUse if the ISR is already bound.
+    //
+    TInt r = Interrupt::Bind(iIrqId,UartIsr,this);
+    if (r!=KErrNone)
+        {
+        KDBG(Kern::Printf("DExUartPhysicalChannel::Interrupt Binding 
+                for UART failed"));
+        return r;
+        }
+
+    return KErrNone;
+    }</codeblock></section>
+<section id="GUID-B68C33DD-AC9D-4211-8ADF-0A2D5F02B721"><title>Unbinding</title> <p> An
+interrupt is unbound by calling <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-DF98A40B-453C-3BC0-B538-D9A6943732E0"><apiname>Interrupt::UnBind()</apiname></xref>, which
+de-registers the interrupt source and routine. This must be done before or
+during physical channel destruction. Unbinding an interrupt does not disable
+its source. Interrupts have to be disabled explicitly before unbinding to
+avoid spurious interrupts. </p> <codeblock id="GUID-7F959F0F-E295-5310-8296-7BBF36D408FB" xml:space="preserve">/**
+ Physical channel destructor. Delete and free any objects created and
+ allocated by the physical channel. This is called by the    
+ framework while unloading the driver (PDD).
+ */
+DExUartPhysicalChannelH4::~DExUartPhysicalChannelH4()
+    {
+    // Unbind the UART interrupt. Interrupt::Unbind() frees the  
+    // interrupt service routine (ISR) function from the specified
+    // interrupt ID.
+    // 
+    Interrupt::Unbind (iIrqId);
+    }</codeblock></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6E89E787-749D-5AC5-957D-967B4B9ACD74.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,121 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE task
+  PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
+<task id="GUID-6E89E787-749D-5AC5-957D-967B4B9ACD74" xml:lang="en"><title>Using
+the BIL Interface</title><shortdesc>This tutorial describes how to use the Buffer Interface Layer (BIL)
+to read and write shared chunks form the client driver. </shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody>
+<context id="GUID-40DA18C7-1949-5495-BC1B-03ED9C437B7C"><p> </p> <p>The BIL
+is a thin layer over the LDD APIs that removes the need for the class driver
+to handle buffers directly. The BIL is consistent between different class
+drivers and reduces the buffer related understanding needed to use the USBSc
+LDD. </p> <p>Using the BIL is optional to the class driver, but very highly
+recommended. </p><p> Before completing these steps you must have followed
+the procedure from
+ the beginning of the tutorial set through to
+<xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-C2FF3692-93FE-3F9B-ADBC-A0875B5290D4"><apiname>RDevUsbcScClient::FinalizeInterface()</apiname></xref></p> </context>
+<steps id="GUID-E17FCECC-D0A2-57C9-9248-0A71E8A0B61D">
+<step id="GUID-C4CEF921-C970-5C0D-AC32-F18A0A482278"><cmd> Open each endpoint
+object.  </cmd>
+
+<info>Use the function <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-98D986E5-6529-375A-84F4-769F20CFD161"><apiname>RDevUsbcScClient::OpenEndpoint()</apiname></xref> for
+each endpoint object. </info>
+<stepxmp><codeblock id="GUID-B1EFEBB5-3FF2-5124-A821-07223946110A" xml:space="preserve">TEndpointBuffer iEpBuf;
+const TUint KWriteEp = 1;
+
+gPort.OpenEndpoint(iEpBuf, KWriteEp);</codeblock> </stepxmp>
+<info> <codeph>OpenEndpoint()</codeph> fills the provided endpoint buffer
+(<codeph>iEpBuf</codeph>) for use with the given endpoint number (<codeph>KWriteEp</codeph>).
+This endpoint will be opened on the current alternate interface setting. </info>
+</step>
+<step id="GUID-1A4579B9-8643-5F42-8048-BCEBADD56406"><cmd/>
+<info> Reading with an OUT endpoint.  </info>
+<info>To read with an endpoint call <xref href="GUID-46F7D0B5-8F71-3D63-AC40-D940240B0373.dita#GUID-46F7D0B5-8F71-3D63-AC40-D940240B0373/GUID-80654761-26F2-3C1A-BD75-86C24A41FB14"><apiname>TEndpointBuffer::GetBuffer()</apiname></xref> to
+request data from the BIL. </info>
+<stepxmp><codeblock id="GUID-985944AC-D3DC-53C1-A0AE-417A51E2F951" xml:space="preserve">r = iEpBuf.GetBuffer(scReadData, readSize, readZlp, aStatus);</codeblock> </stepxmp>
+<info>The first parameter passed to <codeph>GetBuffer()</codeph> can be either
+a pointer to the transfer buffer or the offset of the transfer data within
+the shared chunk. </info>
+<info>This function allows the BIL to expire any previously retrieved transfer
+on this endpoint so that it can be used again for new transfers. If the transfer
+or the LDD are not ready then <codeph>aStatus</codeph> is set to pending.
+If no transfer is available then the variable passed in the first parameter
+is set to NULL or 0 depending on the API. Call this function again on completion,
+to wait for data again. </info>
+<info>The function <codeph>GetBuffer()</codeph> returns: </info>
+
+<substeps id="GUID-3DABE2BC-8A54-503A-B7A2-D6867B0BE306">
+<substep id="GUID-6C7D86C5-60DE-5677-B1F3-2EBE8802CA8F"><cmd/>
+<info> <codeph>KErrCompletion</codeph> if data could be retrieved without
+a pending request, </info>
+</substep>
+<substep id="GUID-ACD12551-A216-5615-B24F-0CEAB33D92B2"><cmd/>
+<info> <codeph>KErrNone</codeph> if an asynchronous request was queued. This
+function should be called again on completion, </info>
+</substep>
+<substep id="GUID-1545994A-F7D2-5904-9B13-BEDA58A9AF06"><cmd/>
+<info> <codeph>KErrEof</codeph> if the end of the data in the endpoint has
+been reached, </info>
+</substep>
+<substep id="GUID-B3CA8F5E-8816-535B-94D1-512305870882"><cmd/>
+<info> <codeph>KErrNotSupported</codeph> if the endpoint is an IN endpoint. </info>
+</substep>
+</substeps>
+<info>If the host has changed to an alternate setting and you wish to continue
+reading and writing data then you must <codeph>Close()</codeph> all endpoints
+and go to step five Process the next alternate set of endpoints. Otherwise,
+if you have finished then go to step four Close each endpoint object. </info>
+</step>
+<step id="GUID-D1347544-106F-5883-9789-0001DF12ED15"><cmd/>
+<info> Writing with an IN endpoint.  </info>
+<info>After filling a shared chunk buffer with some data call <xref href="GUID-46F7D0B5-8F71-3D63-AC40-D940240B0373.dita#GUID-46F7D0B5-8F71-3D63-AC40-D940240B0373/GUID-013E135D-AF87-3FFD-8B35-42D7B3FDECD8"><apiname>TEndpointBuffer::WriteBuffer()</apiname></xref> to
+write the data to endpoint hardware. </info>
+<info> <codeph>WriteBuffer()</codeph> transmits the provided buffer on the
+given endpoint asynchronously. More than one request may be outstanding at
+any time. This reduces the time between buffer transfers. </info>
+<stepxmp><codeblock id="GUID-4F511487-D318-5DFA-BDF5-20CA98BE04BC" xml:space="preserve">r = iEpBuf.WriteBuffer(buffer, length, ETrue, aStatus);</codeblock> </stepxmp>
+<info>The first parameter passed to <codeph>WriteBuffer()</codeph> can be
+either a pointer to the transfer buffer or the offset of the transfer data
+within the shared chunk. </info>
+<info>If the host has changed to an alternate setting and you wish to continue
+reading and writing data then you must <codeph>Close()</codeph> all endpoints
+and go to step five Process the next alternate set of endpoints. Otherwise,
+if you have finished then go to step four Close each endpoint object. </info>
+</step>
+<step id="GUID-6C39309D-0822-59D0-8A47-2E7146991FC6"><cmd/>
+<info> Close each endpoint object.  </info>
+<info>Each endpoint object opened with <codeph>OpenEndpoint()</codeph> must
+be closed with <xref href="GUID-46F7D0B5-8F71-3D63-AC40-D940240B0373.dita#GUID-46F7D0B5-8F71-3D63-AC40-D940240B0373/GUID-CD3F8021-67E2-3AA4-9DA9-7C854A134A54"><apiname>TEndpointBuffer::Close()</apiname></xref>. </info>
+<stepxmp><codeblock id="GUID-CA3F1F92-B224-5246-A91E-67004EDCD754" xml:space="preserve">iEpBuf.Close();</codeblock> </stepxmp>
+<info>If the host has changed to an alternate setting and you wish to continue
+reading and writing data then you must <codeph>Close()</codeph> all endpoints
+and go to step five Process the next alternate set of endpoints. Otherwise,
+if you have finished data transfer then <xref href="GUID-BE73CFE6-D48D-5B92-AF49-E2D967ADF0EC.dita">Close
+and Unload the Driver</xref>. </info>
+<info>If you wish to continue reading and writing data but on an alternate
+setting then call <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-A4726204-4DE4-31FC-9CB3-54A3BC5155C2"><apiname>RDevUsbcScClient::StartNextOutAlternateSetting()</apiname></xref>.
+Otherwise if you have finished then Close and Unload the Driver. </info>
+</step>
+<step id="GUID-1F1A169A-EC61-50D3-BCEA-5CEC8A13C8BE"><cmd/>
+<info> Process the next alternate set of endpoints.  </info>
+<info>Use the function <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-A4726204-4DE4-31FC-9CB3-54A3BC5155C2"><apiname>RDevUsbcScClient::StartNextOutAlternateSetting()</apiname></xref> to
+switch to the next set of endpoints. The alternate interfaces were initialised
+with <codeph>SetInterface()</codeph>. See <xref href="GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita">Set
+the Interface Descriptors</xref>. </info>
+<stepxmp><codeblock id="GUID-81FA57A5-F55A-5437-A9B6-8406D12AF1A2" xml:space="preserve">TInt r = StartNextOutAlternateSetting(ETrue);</codeblock> </stepxmp>
+<info>Pass ETrue to the function to purge the buffers of any data unread for
+the previous setting. </info>
+<info> Note: All open endpoints (except EP0) must be closed before this is
+called. </info>
+</step>
+</steps>
+<postreq><p>When you have finished reading and writing <xref href="GUID-BE73CFE6-D48D-5B92-AF49-E2D967ADF0EC.dita">Close
+and Unload the Driver</xref>. </p> </postreq>
+</taskbody></task>
\ No newline at end of file
Binary file Adaptation/GUID-6EB38F10-849D-5763-96A0-A0A108982D67-master.png has changed
Binary file Adaptation/GUID-6EB38F10-849D-5763-96A0-A0A108982D67_d0e63496_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6EF762B8-DE93-51C0-8A5D-89FC5289B7D0.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE task
+  PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
+<task xml:lang="en" id="GUID-6EF762B8-DE93-51C0-8A5D-89FC5289B7D0"><title>MMP Tutorial </title><shortdesc>This tutorial describes how to set the paging options for an individual executable.  </shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody> <context id="GUID-412D61DE-4334-5ACA-B231-0FD4987DA854"><p>The paging options are:</p><ul id="UL_D8F99583C95448238D57C50ECFA5BB0B"><li id="LI_CFB9F842F9B949D7B7239F19D41663B6">code paging</li><li id="LI_2E3FB77DD0A94611A41B58CB389DB95C">data paging</li><li id="LI_2A568122EAFD4AEFA5635CA75EA475CB">both code and data paging</li></ul><p>Making executables (either exe or dll) paged is the finest level of control of paging at runtime. In the order of precedence for paging keywords, the values in this file will be overridden by those in the oby file. </p> <p>          The following keywords are used to indicate whether the executable is
+          unpaged or paged. If the executable is paged then the keywords indicate if code
+          paging, data paging or both are to be used.</p><table id="GUID-DDE5C1CD-112D-54B8-A819-C95FA0A120DB"><tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/><tbody><row><entry><p> <b>Keyword</b>  </p> </entry> <entry><p> <b>Behaviour on Symbion OS v9.6 and later</b>  </p> </entry> </row> <row><entry><p>paged </p> </entry> <entry><p>Enables code and data paging </p> </entry> </row> <row><entry><p>unpaged </p> </entry> <entry><p>Disables code and data paging </p> </entry> </row> <row><entry><p>pagedcode </p> </entry> <entry><p>Enables code paging </p> </entry> </row> <row><entry><p>unpagedcode </p> </entry> <entry><p>Disables code paging </p> </entry> </row> <row><entry><p>pageddata </p> </entry> <entry><p>Enables data paging </p> </entry> </row> <row><entry><p>unpageddata </p> </entry> <entry><p>Disables data paging </p> </entry> </row> </tbody> </tgroup> </table><p>When using the above keywords, the following points must be considered. </p><ul id="UL_BF3F9DEA52E2443AA028E182B752D96B"><li id="LI_1494C506348640EE8EBB52377EA0F2ED">The keywords <i>pageddata</i> and <i>unpageddata</i> do not make sense for files that are not executable binaries, and will be ignored. </li><li id="LI_0D6678B8EFCE46AA9F5E0BD3BBA34116">The use of the <i>paged</i>, <i>unpaged</i>, <i>pagedcode</i> and <i>unpagedcode</i> keywords only states the default paging behaviour of the data that is to paged by the executable. The behaviour can be overridden by using the <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita"><apiname>TChunkCreateInfo</apiname></xref>, <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita"><apiname>RChunk</apiname></xref> and <xref href="GUID-3DCB92FB-9C74-3B73-B229-BF7944087EE9.dita"><apiname>TChunkHeapCreateInfo</apiname></xref> API. </li><li id="LI_62B6ADBE30C4482D854B48C32713B741">The keywords in the table above, should appear on a separate line on their own and with no arguments</li><li id="LI_A97184F27C5E4D7FADCBBFEE71551AA7">If the build tools are configured to compress executables while building them (this is the default behaviour), then executables marked with paged or the pagedcode keyword will be implicitly byte-pair compressed. </li><li id="LI_53B9F593A2354EB0BB81B86CE41E53A6">If a ROM/ROFS partition defines a <i>pagingoverride</i>, <i>codepagingoverride</i> or <i>datapagingoverride</i> as <i>defaultpaged</i> or <i>defaultunpaged</i>, then the pagability specified in the mmp file will be implemented.</li><li id="LI_DDD2067B2BF64D7FB0D22FBDCB5614AA">If a ROM/ROFS partition has defines <i>pagingoverride</i>, <i>codepagingoverride</i> or <i>datapagingoverride</i> as <i>nopaging</i> or <i>alwayspage</i>, then the pagability specified in the mmp file will be ignored. </li></ul></context>  <result id="GUID-66C2F1AC-E91D-524C-964E-C1F742F8E191"><p>Building the executable with the new keyword does not produce any errors or warnings. </p> </result> <example id="GUID-6D525725-8E22-55A9-8CD3-DFED9E1F09CB"><title>mmp file example</title> <p>Below is an example mmp file with paging: </p> <codeblock id="GUID-CFDB3A59-8379-5336-82F3-CB0463264844" xml:space="preserve">TARGET dummy.dll 
+TARGETTYPE DLL 
+
+UID 0x10003d3a 
+VENDORID 0x12345678 
+
+SOURCEPATH ../dummy 
+SOURCE dummy1.cpp dummy2.cpp 
+
+SYSTEMINCLUDE /epoc32/include 
+
+LIBRARY euser.lib 
+
+CAPABILITY PowerMgmt ReadDeviceData WriteDeviceData LocalServices ReadUserData WriteUserData 
+
+UNPAGED</codeblock> <p>The above mmp file, specifies that the <filepath>dummy.dll</filepath> file is not going to use demand paging. </p> </example> </taskbody></task>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-6F82A35E-9F11-591D-AA5C-8F60734A2827.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-6F82A35E-9F11-591D-AA5C-8F60734A2827" xml:lang="en"><title>Demand Paging
+Guides</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Contains guides that describe various aspects of demand paging in more
+detail. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-70041B11-4C03-42C6-9EC2-307E5FF0F626.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,165 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-70041B11-4C03-42C6-9EC2-307E5FF0F626" xml:lang="en"><title>IIC Interface Overview</title><shortdesc>Provides a summary of IIC interface.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The IIC platform service provides APIs for a master channel and
+a slave channel. The PIL provides the generic platform independent
+functionality.</p>
+<section id="GUID-61CABBE0-B15D-47A1-9F12-95C74DAADFD6">         
+   <title>Master channel</title>             <p>You must derive a
+class from <xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita"><apiname>DIicBusChannelMaster</apiname></xref> and implement certain
+pure virtual functions.</p>      <table id="GUID-C138F5F0-138A-4C1B-A6DC-35548F413B64">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita#GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B/GUID-E64BFB0C-8959-3FF6-B3C1-F6FC918832BF"><apiname>DIicBusChannelMaster::DoRequest(TIicBusTransaction*
+aTransaction)</apiname></xref></entry>
+<entry>Gateway function for the PSL implementation. This function
+allows the client to request a new channel.</entry>
+</row>
+<row>
+<entry><xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita#GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B/GUID-6830B886-FD32-39E1-A0BE-1897131E27CB"><apiname>DIicBusChannelMaster::DoCreate()</apiname></xref></entry>
+<entry>Second phase constructor to create a new channel.</entry>
+</row>
+<row>
+<entry><xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita#GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B/GUID-FB025EB1-1632-360B-AFFB-AEC508D2C291"><apiname>DIicBusChannelMaster::HandleSlaveTimeout()</apiname></xref></entry>
+<entry>Function to be called in the event of slave time out. Implement
+this function to stop the transmission, disable the hardware or call
+PIL function<xref href="GUID-853C87F1-0E44-3B1E-A97E-6461F1188B3A.dita"><apiname> CompleteRequest()</apiname></xref>.</entry>
+</row>
+<row>
+<entry><xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita#GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B/GUID-DDF338C1-4F9F-3E01-9596-FAF42C3AE12A"><apiname>DIicBusChannelMaster::CheckHdr()</apiname></xref></entry>
+<entry>Function to check if the header of the transaction is valid.</entry>
+</row>
+</tbody>
+</tgroup>
+</table>   </section>
+<section id="GUID-CBFFAB9D-B006-4B75-9508-44C29BEDD434"><title>PIL
+functions for master channel</title>The following functions can be
+used by the platform specific implementation of the IIC platform services.<table id="GUID-8ECF612B-CE35-4D94-9778-00481218D131">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API </entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry> <xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita#GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B/GUID-F1103884-A156-36E8-967B-5A65404B5D70"><apiname>DIicBusChannelMaster::Init()</apiname></xref></entry>
+<entry>Initialise the child class  <xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita"><apiname>DIicBusChannelMaster</apiname></xref>.</entry>
+</row>
+<row>
+<entry><xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita#GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B/GUID-3C7168AD-0832-3266-BDD2-991CC49971C5"><apiname>DIicBusChannelMaster::SetDfcQ()</apiname></xref></entry>
+<entry>To set the IIC driver's DFC queue to be used by the DFC of
+PIL.</entry>
+</row>
+<row>
+<entry><xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita#GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B/GUID-740EAD34-9338-319C-BFCC-32664B0680A0"><apiname>DIicBusChannelMaster::StartSlaveTimeOutTimer()</apiname></xref></entry>
+<entry>To start a timer to wait for the slave class functions, if
+the time expires the <xref href="GUID-AD480427-A00E-3BB3-AD62-1B91A86B37A2.dita"><apiname>HandleSlaveTimeout()</apiname></xref> call
+up function is invoked by the clients.</entry>
+</row>
+<row>
+<entry><xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita#GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B/GUID-540783BD-7970-3472-9812-FBE0040D9039"><apiname>DIicBusChannelMaster::CancelTimeOut()</apiname></xref></entry>
+<entry>To cancel the timer monitoring the transactions.</entry>
+</row>
+<row>
+<entry><xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita#GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B/GUID-77CF7770-960A-314F-B97A-A59C9AA437AF"><apiname>DIicBusChannelMaster::CompleteRequest()</apiname></xref></entry>
+<entry>To notify the PIL of a completed transaction</entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-4F13084A-B068-4E94-A167-FFC7B9C82434"><title>Slave
+channel</title>You must derive a class from <xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita"><apiname>DIicBusChannelSlave</apiname></xref> and implement the following pure virtual functions:<table id="GUID-F1E731D5-F983-4439-A7AC-2B82F8828677">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry> <xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita#GUID-22FF70C1-A805-3EBB-B142-15FD16D00837/GUID-07172C58-9EAD-39E3-9F50-34E9F14FAA35"><apiname>DIicBusChannelSlave::DoRequest()</apiname></xref></entry>
+<entry>The gateway function to the SHAI implementation layer.</entry>
+</row>
+<row>
+<entry> <xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita#GUID-22FF70C1-A805-3EBB-B142-15FD16D00837/GUID-695FBFF9-3F47-3DAD-B416-E218BB7624D5"><apiname>DIicBusChannelSlave::DoCreate()</apiname></xref></entry>
+<entry>The second phase constructor function to create a new channel.</entry>
+</row>
+<row>
+<entry> <xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita#GUID-22FF70C1-A805-3EBB-B142-15FD16D00837/GUID-9217102F-6501-3B3D-BB6C-D6833EDB315A"><apiname>DIicBusChannelSlave::ProcessData()</apiname></xref></entry>
+<entry> Called by the PIL in response to the <xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita#GUID-22FF70C1-A805-3EBB-B142-15FD16D00837/GUID-0F1A82C1-E604-36F1-B71B-1387EC414A9A"><apiname>DIicBusChannelSlave::NotifyClient()</apiname></xref> function.</entry>
+</row>
+<row>
+<entry> <xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita#GUID-22FF70C1-A805-3EBB-B142-15FD16D00837/GUID-C412A246-6565-331B-87C1-A32BF6CF6B89"><apiname>DIicBusChannelSlave::ChechHdr()</apiname></xref></entry>
+<entry>The function to validate a configuration.</entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-D7FE7B2B-A9ED-47A1-BC0F-7575BE8DB747"><title>PIL
+function for slave channel</title>The following are the generic functions
+provided by the PIL of the IIC platform service: <table id="GUID-C1016541-E8FD-4C1C-9E7A-D6861FC21050">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita#GUID-22FF70C1-A805-3EBB-B142-15FD16D00837/GUID-163A4AF3-21E4-359F-B10A-FDE2C2FECE82"><apiname>DIicBusChannelSlave::DIicBusChannelSlave()</apiname></xref></entry>
+<entry>Constructor function for PIL.</entry>
+</row>
+<row>
+<entry><xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita#GUID-22FF70C1-A805-3EBB-B142-15FD16D00837/GUID-F6DB5014-3AF9-3573-9B19-9E6761860226"><apiname>DIicBusChannelSlave::Init()</apiname></xref></entry>
+<entry>Initialise the slave channel.</entry>
+</row>
+<row>
+<entry><xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita#GUID-22FF70C1-A805-3EBB-B142-15FD16D00837/GUID-9B1B40FB-3767-3D73-8876-89EAAC96EFF0"><apiname>DIicBusChannelSlave::SetMasterWaitTime()</apiname></xref></entry>
+<entry>Set the timer to wait for the master channel to respond after
+a transmission is started.</entry>
+</row>
+<row>
+<entry><xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita#GUID-22FF70C1-A805-3EBB-B142-15FD16D00837/GUID-16535EB6-2DBB-3682-A704-3BCB0618DA31"><apiname>DIicBusChannelSlave::GetMasterWaitTime()</apiname></xref></entry>
+<entry>Get the current delay to wait for the master channel to respond
+after a transmission is started.</entry>
+</row>
+<row>
+<entry><xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita#GUID-22FF70C1-A805-3EBB-B142-15FD16D00837/GUID-E767FE3F-840C-3B5E-9DDC-CF00C3FF56BF"><apiname>DIicBusChannelSlave::SetClientWaitTime()</apiname></xref></entry>
+<entry>Set the timer of the client to respond for the next operation.</entry>
+</row>
+<row>
+<entry><xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita#GUID-22FF70C1-A805-3EBB-B142-15FD16D00837/GUID-2124E2FF-5F58-35C4-BDB3-E7E3353EB83F"><apiname>DIicBusChannelSlave::GetClientWaitTime()</apiname></xref></entry>
+<entry>Get the current delay of the client to respond for the next
+operation.</entry>
+</row>
+<row>
+<entry><xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita#GUID-22FF70C1-A805-3EBB-B142-15FD16D00837/GUID-0F1A82C1-E604-36F1-B71B-1387EC414A9A"><apiname>DIicBusChannelSlave::NotifyClient()</apiname></xref></entry>
+<entry>Notify clients of the slave channel events.</entry>
+</row>
+</tbody>
+</tgroup>
+</table><p>The header file for the IIC can be found <xref href="http://developer.symbian.org/xref/oss/xref/MCL/sf/os/kernelhwsrv/kernel/eka/include/drivers/iic.h.dita">here</xref></p></section>
+</conbody><related-links>
+<link href="GUID-C24A5B52-0B40-53B2-BF85-6ECC35BDCBA5.dita"><linktext>IIC
+Implementation Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-71271D1C-C385-5687-8A90-46E8B590BB1E-master.png has changed
Binary file Adaptation/GUID-71271D1C-C385-5687-8A90-46E8B590BB1E_d0e1517_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-73B853D5-13E6-54E7-AA8B-C41EEDB5EA7F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-73B853D5-13E6-54E7-AA8B-C41EEDB5EA7F" xml:lang="en"><title> RMdaDevSound-Based
+Driver Migration</title><shortdesc>Explains how to convert an <codeph>RMdaDevSound</codeph> -based
+sound driver to the current Sound Driver architecture. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Symbian converted the PDD of the <codeph>RMdaDevSound</codeph> based driver
+to an <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita"><apiname>RSoundSc</apiname></xref> version of the PDD. The same procedure was
+used for this on all three platforms. </p>
+<p>PDDs for the <codeph>RMdaDevSound</codeph> based driver have a significant
+amount of code that is dedicated to creating and managing a circular buffer, <codeph>DSoundBuffer</codeph>,
+for storing playback or record audio. In the <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita"><apiname>RSoundSc</apiname></xref> version
+of the driver, this is taken care of by the shared chunk and this code can
+be discarded. </p>
+<p>For the remaining PDD code, although the LDD to PDD interface for the <codeph>RMdaDevSound</codeph> based
+version is similar to the <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita"><apiname>RSoundSc</apiname></xref> version, it is best
+to start by taking a copy of the template port as described in <xref href="GUID-C6ABE2CA-901E-55F1-9837-7018A1612BCF.dita">Set
+Up</xref> , then fill in the sections marked TODO in the template code by
+cutting and pasting the relevant code coming from a single function, this
+is often called the same in each version of the driver. </p>
+<p>One complication comes if the <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita"><apiname>RSoundSc</apiname></xref> version is to
+support both record and playback driver channels, as this requires some of
+the functionality to be moved to the shared PDD factory object. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-73D9E2F2-5965-479E-97DB-C3773DA0D90C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-73D9E2F2-5965-479E-97DB-C3773DA0D90C" xml:lang="en"><title>Device Driver Quick Start</title><shortdesc>A quick introduction to the device driver documentation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Device drivers provide a mechanism for applications and other operating
+system functions to access hardware devices without needing to know
+how each specific piece of hardware works. In addition device drivers
+may be written so that part of the device driver is user-side space
+and the rest is kernel-side so that the device driver can access shared
+memory and resources that belong to the Kernel.</p>
+<section id="GUID-D6C44505-3FD8-41A1-A989-666E91BEBB92"><title>Who
+this documentation is for</title><p>There are two main sets of users
+for device drivers:<ul>
+<li><p>Application developers that want to use device drivers</p></li>
+<li><p>Developers that need to create or amend device drivers.</p></li>
+</ul></p><p>This documentation set is aimed at the second category
+of users. If you are an application developer and want to use a particular
+device driver, then you should search for, and read the documentation
+for that specific device driver.</p></section>
+<section id="GUID-25F588AB-D717-44CB-9328-067CEA48D7EF">       <title>Device driver framework</title><p>The device driver guide explains
+the concepts of device driver framework and how to implement a device
+driver.</p><ul>
+<li><p>For the basic concepts of device driver, see <xref href="GUID-79620372-BADC-4826-A3AC-7FDBCFF98DA9.dita">Device Driver Concepts</xref></p></li>
+<li><p>To write a device driver, see <xref href="GUID-C22974D8-CFB9-4A83-BE58-CCC97EA8DF13.dita">Device Driver Writing
+Guide</xref></p></li>
+<li><p>To use the kernel services in a device driver, see <xref href="GUID-DC8D3736-EDCF-54CB-A614-2AAC4664F1CA.dita">Kernel-Side Services</xref></p></li>
+<li><p>To debug your device driver implementation, see <xref href="GUID-26714A57-B6B4-5E81-B512-FB520718482B.dita">Debug Monitor Tool</xref></p></li>
+<li><p>It is important to understand how memory is paged in the system,
+so you should also read <xref href="GUID-896A1177-C3F5-40DF-8B3B-56F4442D8D99.dita">Demand Paging</xref>.</p></li>
+</ul>           </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-73F220EA-F41F-56A5-BAEB-4A37174CFD1F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,117 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-73F220EA-F41F-56A5-BAEB-4A37174CFD1F" xml:lang="en"><title>Power
+Management</title><shortdesc>Describes the power management policies. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The MMC Controller manages the power to the MultiMediaCard hardware.</p>
+<section id="GUID-C54927A1-8631-5DA0-9DDF-C399577B44C0"><title>Normal power
+up and power down handling</title> <p>Before card commands can be issued to
+a card, three operations are required: </p> <ul>
+<li id="GUID-6E4702E7-FAC7-5AFE-BB83-73EAE2774E71"><p>power must be applied
+to the card, i.e. VDD must be turned on </p> </li>
+<li id="GUID-694FED8E-108D-564F-BDDD-078C1F91627D"><p>any requirement from
+the power model must be set, e.g. requesting a necessary system clock </p> </li>
+<li id="GUID-43728A53-CD2B-565A-B436-E3C59B61710E"><p>the clock to the card
+interface must be switched on. </p> </li>
+</ul> <p>All three operations are performed as part of the <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-D8D3CFDC-5292-3853-8618-5D3A21F5C4D7"><apiname>DMMCStack::CIMInitStackSM()</apiname></xref> state
+machine function which then issues the sequence of commands involved in performing
+the <codeph>CIM_UPDATE_ACQ</codeph> macro to initialize a card stack. </p> <p>There
+are two cases: </p> <ul>
+<li id="GUID-EB3AC768-EF05-5BED-867F-E0C65E2AB43E"><p>Local drive requests,
+i.e. those originating from a media driver - if the card is not fully powered
+up when such a request is received, then the local media device driver automatically
+precedes the request with an instruction to the controller to power up the
+card. This results in <xref href="GUID-45B97680-1756-3559-8A2D-2F2E851AD6A7.dita#GUID-45B97680-1756-3559-8A2D-2F2E851AD6A7/GUID-C0E6CF87-8E8B-3B14-9B7E-302E3688CFA5"><apiname>DMMCSocket::InitiatePowerUpSequence()</apiname></xref> being
+called, which in turn invokes the <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-D8D3CFDC-5292-3853-8618-5D3A21F5C4D7"><apiname>DMMCStack::CIMInitStackSM()</apiname></xref> state
+machine function. </p> <p>Once the MultiMediaCard stack has been initialized,
+the MultiMediaCard controller calls <xref href="GUID-C988CAE6-9073-3851-A0B0-5479D1A34CFB.dita#GUID-C988CAE6-9073-3851-A0B0-5479D1A34CFB/GUID-0FEFB701-D37A-320F-A49B-6126EF608BF7"><apiname>DPBusSocket::PowerUpSequenceComplete()</apiname></xref> to
+signal the completion of initialization back to the local media driver, and
+this can then continue to open a media driver and continue with the original
+request. </p> <p>This automatic re-powering of the card applies in all situations
+which can lead to the card not being powered: media change, machine power
+down, card inactivity timeout, VDD power problem etc. In most cases, the process
+of restoring power results in the closure of any existing media driver and
+a new one opened. As the kernel thread used to perform controller requests
+is able to block, this means that no special mechanism is necessary to allow
+for this potential long-running power up sequence prior to a request on the
+device. </p> </li>
+<li id="GUID-D8AA1127-B8B2-52BB-A242-A487A875B908"><p>Requests not originating
+via a local media device driver, for example device drivers for I/O cards
+- if the MultiMediaCard stack is not initialized when the client submits a
+session, then the MultiMediaCard controller automatically precedes the request
+with a call to the <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-D8D3CFDC-5292-3853-8618-5D3A21F5C4D7"><apiname>DMMCStack::CIMInitStackSM()</apiname></xref> state machine
+function. </p> </li>
+</ul> <p>The MultiMediaCard controller will normally be configured with an
+inactivity timer. If a given period elapses where there is no bus activity,
+then the controller automatically turns off the card clock, removes any power
+requirements on the power model, and then removes power from the cards. This
+is the bus power down sequence. The length of this inactivity timeout period
+is set in the platform specific layer as part of porting the controller, and
+can be disabled completely if required; see the reference to porting the <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-99529E84-17E1-5F23-9A1B-EBE3976D9B14">PsuInfo()</xref> function
+as part of implementing the <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-3A1E907E-A74D-59CB-A1D6-FEF4849EF2D5">DMMCPsu
+derived class</xref>. </p> <p>Clients of the controller do not need to worry
+about re-initializing the stack following such a power down as the controller
+does this automatically. </p> <p>In the event of a PSU voltage check failure,
+the controller performs the bus power down sequence. It will not re-power
+the problem card and will expect it to be removed. </p> <p>The power model
+calls <xref href="GUID-C988CAE6-9073-3851-A0B0-5479D1A34CFB.dita#GUID-C988CAE6-9073-3851-A0B0-5479D1A34CFB/GUID-F037A26D-0C72-364F-B3CD-87B9FF22AAB1"><apiname>DPBusSocket::DoPowerDown()</apiname></xref> when the machine is about
+to be normally turned off (due to the off key being pressed or keyboard/touch
+screen inactivity). This leads to the function <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-CF271B2B-A515-3DB7-AD52-8138BAFF901C"><apiname>DMMCStack::PowerDownStack()</apiname></xref> being
+called resulting in the bus power down sequence. </p> <p>When the machine
+is powered back up after a normal power off, the power model calls <xref href="GUID-C988CAE6-9073-3851-A0B0-5479D1A34CFB.dita#GUID-C988CAE6-9073-3851-A0B0-5479D1A34CFB/GUID-C4EC4C74-24CE-3A55-B63F-30E32DB0259A"><apiname>DPBusSocket::DoPowerUp()</apiname></xref>.
+However, the controller normally does not power up the bus, but waits for
+the next request from one of its clients before doing so. The only exception
+is where a card power up sequence was interrupted by the machine being turned
+off. </p> </section>
+<section id="GUID-BBD2119B-99D6-56A1-B42F-EE2953D88898"><title> Emergency
+power down</title> <p>In an emergency power down situation, for example, where
+a battery is in a critically low power state, the MultiMediaCard controller
+performs the normal bus power down sequence as this is not a lengthy operation.
+The power model calls <xref href="GUID-C988CAE6-9073-3851-A0B0-5479D1A34CFB.dita#GUID-C988CAE6-9073-3851-A0B0-5479D1A34CFB/GUID-A893EB7B-289E-36DB-B249-CA8DB81EEAE2"><apiname>DPBusSocket::DoEmergencyPowerDown()</apiname></xref>,
+which results in a call to <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-CF271B2B-A515-3DB7-AD52-8138BAFF901C"><apiname>DMMCStack::PowerDownStack()</apiname></xref>. </p> <p>However,
+there is always a risk that a block being written to a card may become corrupt.
+The solution to this problem lies in the hardware architecture. Two possible
+solutions are: </p> <ul>
+<li id="GUID-02EF5215-2740-5DE9-9418-0BC44ED6051A"><p>to provide enough early
+warning of power being removed before the battery level becomes too low for
+card operation. For example, a catch mechanism on a battery door, making it
+slow to remove. This would provide sufficient time for any write operation
+in progress to be terminated at the next block boundary before the power supply
+is lost. </p> <p>Note, however, that the media driver fails any operations
+involving write operations to a card when the battery level is becoming dangerously
+low, so in general, we are only talking about unexpected battery removal. </p> </li>
+<li id="GUID-FFC11D23-7187-5095-9D18-CF01D85F7A1A"><p>to provide a backup
+battery so that the failing write operation can be re-retried once a good
+battery level has been restored. </p> </li>
+</ul> <p>Even with such mechanisms in place, if power is removed in the middle
+of a multi-block write operation, then some blocks will contain new data while
+others will still contain old data. </p> </section>
+<section id="GUID-8681487C-DD00-58A3-9BFB-8F62A74268C9"><title>Media change</title> <p>When
+a door open event is detected by the MultiMediaCard controller, it attempts
+to remove power from a card as soon as possible. Power is not removed immediately
+if a bus operation is in progress as powering down a card in the middle of
+writing a block could leave the block corrupted. </p> <p>Power is only removed
+from a card immediately a door open event occurs if there are no sessions
+queued by clients on the controller. If one or more sessions are queued then
+these are allowed to complete, with power being removed once the last session
+has completed. Any attempt to engage a new session while the door is open
+fails with <xref href="GUID-51298FCE-7857-39F8-BFAB-49AF5556D0CC.dita"><apiname>KErrNotReady</apiname></xref>. </p> <p>To prevent a card becoming
+corrupt because of attempted removal during a write operation, then it is
+important that the door mechanism and circuitry gives enough early warning
+of a potential card removal before the card is actually removed. This is to
+provide sufficient time for any write operation in progress to proceed to
+the next block boundary before the card is removed. </p> <p>Once the door
+is closed again, then new sessions can be engaged and power can be re-applied
+to the card by the controller. However, power is only restored by the controller
+in response to a client request. The Controller does not automatically re-power
+a card to resume an operation interrupted by a door open event, no matter
+what operation was in progress when the door opened. </p> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-746BD53F-F637-4BC9-91AC-E53BA182B823-master.png has changed
Binary file Adaptation/GUID-746BD53F-F637-4BC9-91AC-E53BA182B823_d0e87730_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,198 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC" xml:lang="en"><title>Interrupt Dispatcher</title><shortdesc>The ASSP/Variant part of the base port must implement an
+interrupt dispatcher to manage interrupts. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>An interrupt source is a hardware device or software action that
+can force the CPU to suspend normal execution, enter interrupt handling
+state and jump to a section of code called an interrupt handler. </p>
+<p>Typically, a number of interrupt sources are monitored by an interrupt
+controller. This is hardware that generates a single interrupt notification
+to the CPU, and provides information about which interrupts are pending,
+i.e. which interrupts require action to be taken. </p>
+<section id="GUID-1FAA26F5-BFB2-55A0-977C-1538EBF3C82A"><title>ISR</title> <p>An interrupt service routine, or ISR, is code that deals with
+a pending interrupt. The Symbian platform kernel responds to an interrupt
+notification by calling an ISR for each pending interrupt. The process
+of calling ISRs is called interrupt dispatch. </p> <p>The ISR is a
+single bare function. It is not a class member. </p> <p>Each ISR takes
+a single 32-bit parameter that is, typically, a pointer to an owning
+class, although it can be any value that is appropriate. The parameter
+is defined as a <xref href="GUID-6D079976-9119-31FA-8E21-C3B815F94648.dita"><apiname>TAny</apiname></xref> * type, so a cast is almost
+always necessary. </p> <p>ISRs are usually kept in an ISR table. </p> </section>
+<section id="GUID-8E58F4C9-0290-55E0-A4FD-B6C2361BE205"><title>Interrupt
+ID</title> <p>An interrupt source is identified by number, defined
+as a <xref href="GUID-7A2A43EC-6125-3BFE-834B-23C37F7B40D5.dita"><apiname>TInt</apiname></xref> type. Typically, the ASSP layer defines
+this number for each interrupt in a header file and exports it so
+that it can be included and used by device drivers. </p> <p>Where
+the ASSP layer is split into a common layer and a variant (device
+specific) layer, then the variant layer may also define its own set
+of interrupt IDs. </p> <p>This number is usually referred to as the
+interrupt ID. </p> </section>
+<section id="GUID-A8C9C079-D043-5A5F-9F08-CD8656F6702A"><title>Binding
+and unbinding</title> <p>Only one ISR can be associated with each
+possible interrupt source. Making this association is known as binding.
+ISRs can be bound and unbound during normal operation, but only one
+ISR can be bound to an interrupt source at any one time. </p> <p>A
+device driver binds an ISR by calling <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-4E3CB472-3525-32F8-9BC4-8ECFEE931E7B"><apiname>Interrupt::Bind()</apiname></xref>, passing the interrupt source ID; similarly, the device driver can
+unbind the ISR by calling <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-CCC9A397-608C-3EAF-830F-A59800C2E8E5"><apiname>Interrupt::Unbind()</apiname></xref>,
+also passing the <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-8E58F4C9-0290-55E0-A4FD-B6C2361BE205">interrupt ID</xref>. </p> </section>
+<section id="GUID-DDA62ABB-9CC6-44DC-B08D-FEE5AC505858"><title>Dispatching
+interrupts</title> <p>At its simplest, this is the process of deciding
+which interrupts are pending and calling the ISR for each. </p> <p>The following pseudo code shows the general principle: </p> <codeblock id="GUID-9C971C66-BB26-5A07-9373-3542B95A16FD" xml:space="preserve">
+    {
+       FOREVER
+              {
+        Get next pending interrupt;
+        if None
+            {
+               return;
+            }
+        call ISR for the pending interrupt;
+        }
+    }
+</codeblock> <p>In practice the dispatcher may have to do some more
+work to communicate with the interrupt controller hardware. </p> </section>
+<section id="GUID-9026A4AC-57AF-545D-887C-AF43E0B37EDC"><title>Chained
+interrupts</title> <p>A system may have multiple interrupt controllers
+to handle a large number of interrupt sources. These are usually prioritised
+by connecting the interrupt output of a lower-priority controller
+to an interrupt input of a higher-priority controller. This is called
+chaining. </p> <fig id="GUID-49264B94-DF6D-5F11-8815-D42CDBF94E39">
+<title>Chained interrupts</title>
+<image href="GUID-0DB79535-E4E6-50BD-852D-B2F177202C9C_d0e13227_href.png" placement="inline"/>
+</fig> <p>An interrupt from a lower priority controller will appear
+as an interrupt on the highest-priority controller. </p> <p>When the
+interrupt dispatcher of the higher-priority controller detects that
+it is the chained interrupt that is pending, the usual way of dealing
+with this is to run a secondary dispatcher to determine which interrupt
+on the chained controller is pending. </p> <p>There may be further
+levels of chaining before the true source of the interrupt has been
+identified. </p> </section>
+<section id="GUID-ED6F2F47-7A16-5AE6-8E5B-B2475F6EDEAA"><title>Multiple
+interrupt sources and pseudo interrupt sources</title> <p>It is possible
+that a single input to an interrupt controller is shared by several
+interrupt sources. </p> <fig id="GUID-DC96E3A8-9820-5CD4-8020-3B55398388D9">
+<title>Multiple interrupt sources</title>
+<image href="GUID-DCBBDFA7-1E6C-5B00-A13E-A25794668E12_d0e13252_href.png" placement="inline"/>
+</fig> <p>It appears necessary to bind multiple ISRs to the same interrupt.
+However, this is not possible. There are two ways of dealing with
+this: </p> <ul>
+<li id="GUID-0D954444-C2C3-51CC-8E1D-7EB063CDACAA"><p>Maintain a list
+of all ISRs that are bound to this single interrupt source, and call
+all the ISRs in the list when the interrupt is dispatched. This is
+most conveniently implemented by binding a single ISR to the interrupt,
+which then calls all the real ISRs bound to this interrupt </p> </li>
+<li id="GUID-C5EFE907-26A5-568D-8CF0-DE5E89ED5CBB"><p>Create pseudo
+interrupts. These are extra interrupt IDs that do not exist in the
+interrupt controller, but represent each of the interrupt sources
+connected to the single shared interrupt source. An ISR can then be
+bound to each pseudo interrupt. The interrupt dispatcher can then
+determine which of the sources are actually signalling and call the
+appropriate ISR via that pseudo interrupt ID. This is effectively
+an implementation of a <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-9026A4AC-57AF-545D-887C-AF43E0B37EDC">chained interrupt</xref>, and assumes that the interrupt dispatcher
+can identify which of the sources is signalling. </p> </li>
+</ul> </section>
+<section id="GUID-A87DE0F9-2095-5CA6-BE88-3A2EAABB0D33"><title>Interrupts
+in the split ASSP/Variant Configuration</title> <p>When a common ASSP
+extension is used, a device may have additional peripherals external
+to the ASSP, and there needs to be a way of allowing extra interrupt
+binding and dispatch functions to be added later by the variant layer.
+This must be handled by the port as Symbian platform does not provide
+any additional API to support this. </p> <p>Device drivers should
+be able to use the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita"><apiname>Interrupt</apiname></xref> class functions without
+having to know where the interrupt is actually implemented. This implies
+that all requests should go to the core implementation of functions
+like <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-4E3CB472-3525-32F8-9BC4-8ECFEE931E7B"><apiname>Interrupt::Bind()</apiname></xref>, <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-BB169E6E-D8F9-3762-899D-6DBA4B29CF87"><apiname>Interrupt::Enable()</apiname></xref> etc. </p> <p>To enable the core implementation of these functions
+to decide whether an interrupt ID refers to a core interrupt or device
+specific interrupt, a common technique is to "tag" the interrupt ID.
+A simple way is to use positive numbers to identify core interrupts
+and negative numbers to identify device specific interrupts. The ISRs
+for device specific interrupts are not stored in the core ISR table,
+instead the device specific layer provides its own ISR table. </p> <p>The general pattern for creating the core-device specific split
+is that the core derives an implementation from class <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita"><apiname>Asic</apiname></xref>, and the device specific part further derives from this core implementation.
+The usual technique is to add a set of virtual functions to the core
+class that can be derived by the device specific part. The core can
+provide default implementations for these functions that would just
+return <xref href="GUID-0BEA3647-7888-3612-A2D3-7E27AC405E29.dita"><apiname>KErrArgument</apiname></xref> to trap illegal ID numbers.
+This API would need functions equivalent to each of the functions
+defined by the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita"><apiname>Interrupt</apiname></xref> class. </p> <p>As an example,
+the core layer for the template reference board defines a class <codeph>TemplateAssp</codeph> that is derived from <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita"><apiname>Asic</apiname></xref>. <codeph>TemplateAssp</codeph> defines the pure virtual functions: <codeph>InterruptBind()</codeph>, <codeph>InterruptUnbind()</codeph>, <codeph>InterruptEnable()</codeph> etc, all with signatures that are the
+same for the comparable functions defined by <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita"><apiname>Interrupt</apiname></xref>, and which are implemented by the <codeph>Template</codeph> class. </p> <fig id="GUID-458C7825-5B35-583C-BDF6-7DCD21DAE670">
+<title>Interrupt binding</title>
+<image href="GUID-B7E7E6D6-7824-505C-BA0B-B7861897E78F_d0e13349_href.png" placement="inline"/>
+</fig> </section>
+<section id="GUID-9D98586F-AD1D-5C50-9AD8-F81D72135382"><title>Spurious
+interrupts</title> <p>In the Kernel Architecture 2, it is a convention
+that unbound interrupts should be bound to a "spurious" interrupt
+handler, i.e. an interrupt handler that faults the system indicating
+the number of the interrupt. This aids debugging by identifying interrupts
+that are enabled without corresponding ISRs. </p> </section>
+<section id="GUID-109C6250-DC5B-48EC-B1A0-24E2E9731B38"><title>Interrupt
+priority</title> <p>The interrupt architecture supports the concept
+of adjustable interrupt priorities. Symbian platform defines the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-FA4CFED7-D694-399C-8F84-FA9FE3C3A171"><apiname>Interrupt::SetPriority()</apiname></xref> function that can implement this.
+The function is passed the ID of the interrupt source to be adjusted
+together with a priority value. The meaning of the priority value
+is hardware and implementation dependent, and is defined by the port. </p> </section>
+<section id="GUID-77E83634-BBF6-5190-9434-9FB700547CD0"><title>The
+ISR table</title> <p>The Variant must provide a table where each entry
+defines which <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-1FAA26F5-BFB2-55A0-977C-1538EBF3C82A">ISR</xref> is bound to which interrupt source. The table must have
+enough space for entries for each interrupt source that is known to
+the Variant. </p> <p>When the Variant is split into an ASSP layer
+and a Variant layer, the ISR table is put in the ASSP layer and will
+not normally include ISRs for the Variant interrupt sources - these
+will be handled by separate chained dispatchers in the Variant layer. </p> <p>Symbian platform provides the <xref href="GUID-2C9B6510-D045-3FA1-AD65-B544E30D34C7.dita"><apiname>SInterruptHandler</apiname></xref> structure, defined in the header file <filepath>...\e32\include\kernel\arm\assp.h</filepath> to encapsulate the entry for an ISR. The ISR table is, therefore,
+just an array of <xref href="GUID-2C9B6510-D045-3FA1-AD65-B544E30D34C7.dita"><apiname>SInterruptHandler</apiname></xref> items. For example,
+if a system has 32 possible interrupt sources, then the ISR table
+would be defined as: </p> <codeblock id="GUID-6C95C2EF-A882-565A-8718-07BF7E4A7AC5" xml:space="preserve">...
+const TInt KInterruptSourceCount = 32;
+SInterruptHandler IsrHandlers[KInterruptSourceCount];
+...</codeblock> <p>Interrupts are identified in the system by their
+interrupt ID number, which is used to index into the ISR table. You
+are free to allocate these numbers any way that is convenient for
+you. </p> <p>On the template reference board, for example, the ISR
+table is defined as a static data member of the <codeph>VariantASSPInterrupt</codeph> class, which is derived from <xref href="GUID-5E593C59-BA22-3B70-AAFB-BFE19E22538A.dita"><apiname>TemplateInterrupt</apiname></xref>. The class is defined in <filepath>...\template_assp\template_assp_priv.h</filepath>. </p> <codeblock id="GUID-59D7A629-353C-5117-84B7-15CD425481C6" xml:space="preserve">class TemplateInterrupt : public Interrupt
+    {
+    ... // functions
+public:
+    static SInterruptHandler Handlers[KNumTemplateInts];
+    ...
+    };</codeblock> <p>where KNumTemplateInts is defined in the same
+header file. </p> <p><b>Factors that decide the size of the ISR table</b> </p> <p>The number of entries to be reserved in the ISR table depends
+on the following factors: </p> <ul>
+<li id="GUID-05AE4B19-AA29-56E4-842A-CC65546EFB54"><p>Where the ASSP
+is targeted at only a single device, the number of possible interrupts
+is usually known, and the table can include an entry for each one. </p> </li>
+<li id="GUID-C62B31BD-FAD7-5A76-9E43-2387FD8AFCC8"><p>If any <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-ED6F2F47-7A16-5AE6-8E5B-B2475F6EDEAA">pseudo sources</xref> exist, they should be included in the main
+table for efficiency, but note that this is not strictly necessary. </p> </li>
+</ul> <p><b>Other factors affecting the ISR table</b> </p> <p>IRQs
+and FIQs may need to be distinguished, although the exact requirement
+is hardware dependent. Although the table has one entry for each possible
+interrupt source, a possible scheme may be to group IRQs at the start
+of the table, and FIQs at the end of the table. If the hardware has
+separate interrupt controller hardware for IRQs and FIQs (or at least,
+different registers) then you will need to arrange the table so that
+you can determine from the <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-8E58F4C9-0290-55E0-A4FD-B6C2361BE205">interrupt ID</xref> whether the interrupt is an IRQ or FIQ. </p> <p>For example: </p> <fig id="GUID-9DD2CC92-A5DB-5C78-A9A6-64402FF04FE2">
+<title>ISR table</title>
+<image href="GUID-60949ACD-AAA9-540E-85AE-BB173382D548_d0e13468_href.png" placement="inline"/>
+</fig> </section>
+<section id="GUID-EACCBDFD-46CD-4D67-B60C-D705867C9116"><title>Location
+of interrupt handling code</title> <p>Most of the interrupt dispatching
+code is implemented in the ASSP layer. This includes a list of ISRs,
+code for adding and removing ISRs, enabling and disabling interrupt
+sources, and dispatching ISRs. The kernel only provides a pre-amble
+and post-amble. </p> <p>The kernel defines, but does not implement,
+a class called <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita"><apiname>Interrupt</apiname></xref> that exports interrupt
+functionality to device drivers and other kernel code. The class provides
+the public API for using interrupts (but not for dispatching them).
+The port must provide an implementation for each function defined
+by the class. </p> <p>The class is defined in the header files <filepath>...\e32\include\kernel\arm\assp.h</filepath>, which is exported to <filepath>...\epoc32\include\kernel\arm</filepath>. </p><p>See <b>Symbian OS
+Internals Book, Chapter 6  - Interrupts and Exceptions</b></p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-772C2721-DD84-54A6-ACE0-ECACC6432B95.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,81 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-772C2721-DD84-54A6-ACE0-ECACC6432B95" xml:lang="en"><title>Kernel
+Objects and Containers Information Commands</title><shortdesc>Describes how to use the <codeph>c</codeph> and <codeph>o</codeph> commands
+to get information about kernel objects. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-3D86C17E-3412-5DD9-ADA2-ABC24D5D6C32"><title>Kernel objects</title> <p>Kernel
+objects such as <codeph>DProcess</codeph>, <codeph>DThread</codeph>, <codeph>DSemaphore</codeph>, <codeph>DChunk</codeph> are
+all instances of classes derived from <xref href="GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497.dita"><apiname>DObject</apiname></xref>. </p> <p>To
+show basic information about a <xref href="GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497.dita"><apiname>DObject</apiname></xref>, use the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-3494E61C-7097-544C-AE7D-73750337744A">o</xref> command. </p> <p>To show more detail, use the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-1DED2B2F-E780-50A0-8325-5DA22BC7D3E0">O</xref> command. </p> <p>As an example, use these commands to show information
+about a <codeph>DProcess</codeph> object whose address is shown using the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-D0175D78-6F84-5F4F-BA90-2C591B473C69">i</xref> command: </p> <codeblock id="GUID-DA14CB69-B70E-5D79-8EBF-64EB2E60C625" xml:space="preserve">...
+TheCurrentDataSectionProcess=6403bb4c
+...</codeblock> <p><userinput>o 6403bb4c</userinput> </p> <p>This gives: </p> <codeblock id="GUID-C94EEF55-67D2-59A5-88D2-8AB75179F295" xml:space="preserve">.o 6403bb4c
+PROCESS at 6403bb4c VPTR=f8046c78 AccessCount=6 Owner=00000000
+Full name crash
+</codeblock> <p>All objects derived from <xref href="GUID-4FCB6127-84F3-38F6-8AD2-FC3B94D67DA3.dita"><apiname>DBase</apiname></xref> have a virtual
+table pointer, access count, owner and name. Using the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-1DED2B2F-E780-50A0-8325-5DA22BC7D3E0">O</xref> command on this address would you give you the full process information. </p> <p>You
+can use <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-3494E61C-7097-544C-AE7D-73750337744A">o</xref> to
+examine other types of objects, for example chunks. The thread information
+for the current data section process shows two chunks: </p> <codeblock id="GUID-DD8E61B2-B96F-5BE6-86C7-4890163D70B9" xml:space="preserve">NumChunks=2
+0: Chunk 6403c044, run 00400000, access count 1
+1: Chunk 64039688, run 00600000, access count 1
+</codeblock> <p>Using the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-3494E61C-7097-544C-AE7D-73750337744A">o</xref> command
+on the first of these chunk objects gives you the basic information: </p> <codeblock id="GUID-19B3111C-B977-5088-B86A-7648F1895FE4" xml:space="preserve">.o 6403c044
+CHUNK at 6403c044 VPTR=f8046b50 AccessCount=1 Owner=6403bb4c
+Full name crash::$DAT
+</codeblock> <p>Using the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-1DED2B2F-E780-50A0-8325-5DA22BC7D3E0">O</xref> command
+gives you more detailed information: </p> <codeblock id="GUID-A4F93D43-5A6C-5D11-8C63-4DB0FAB3C157" xml:space="preserve">.q 6403c044
+CHUNK at 6403c044 VPTR=f8046b50 AccessCount=1 Owner=6403bb4c
+Full name crash::$DAT
+Owning Process 6403bb4c
+Size 2000, MaxSize 200000, Base 00400000
+Attrib 6, StartPos 0
+Type 6, State 2, Home Base 68900000
+Home Region Offset 00000000
+Home Region Base 68900000
+Home Region Size 00100000
+PTE: 0000055e, PDE: 00000021 00000001 00000001
+NumPdes=1, iPdes=61000010, iHomePdes=61001a24
+PdeBitMap=00000001, PageBitMap=6403c0c8
+Domain -1
+</codeblock> <p> <i> The information displayed is memory model dependent.
+It is shown here for the moving memory model.</i>  </p> <p>Notes: </p> <ul>
+<li id="GUID-D1F01CCC-D5E4-5D61-8955-062F52225796"><codeblock id="GUID-DB35CBBC-B0E4-54BB-9F7B-733734D7C2CB" xml:space="preserve">Size 2000, MaxSize 200000, Base 00400000</codeblock> <p>The <codeph>Size</codeph> field shows the current size of the chunk,
+in bytes. </p> <p>The <codeph>MaxSize</codeph> field shows the maximum size
+of the chunk, in bytes. </p> <p>The <codeph>Base</codeph> field shows the
+base address in the run region. </p> </li>
+<li id="GUID-BBC60AE0-64C4-52CC-85BC-CFA59B1EA075"><codeblock id="GUID-C50F4A12-C1C4-5E99-8525-735F369B4A4E" xml:space="preserve">Attrib 6, StartPos 0</codeblock> <p>The <codeph>Attrib</codeph> field shows the attributes of the chunk. </p> <p>The <codeph>StartPos</codeph> field
+shows the offset, in bytes, between the base address and the start of the
+committed area. This is non-zero for double-ended chunks only. </p> </li>
+<li id="GUID-A9312AAA-A917-5E03-8413-8403E3EC2709"><codeblock id="GUID-6E824231-EBF8-5A9E-BEF8-DCD8BB77FB7C" xml:space="preserve">Type 6, State 2, Home Base 68900000</codeblock> <p>The <codeph>Type</codeph> field shows the type of chunk. This corresponds
+to a <codeph>TChunkType</codeph> enum value. </p> <p>The <codeph>State</codeph> field
+shows the current state of the chunk. This corresponds to a <codeph>TChunkState</codeph> enum
+value, which is itself defined within the scope of the Symbian platform internal
+class <codeph>DMemModelChunk</codeph>. </p> <p>The <codeph>Home Base</codeph> field
+is the base address of the chunk in the home region. </p> </li>
+<li id="GUID-BE855CD6-F67F-585E-BA0E-2B50742EE841"><codeblock id="GUID-CA932A12-DA54-5B1E-8566-394D5886761C" xml:space="preserve">Home Region Offset 00000000
+Home Region Base 68900000
+Home Region Size 00100000
+</codeblock> <p>These three lines show the offset, base address and size (the
+reserved size) of the chunk in the home region. </p> </li>
+</ul> </section>
+<section id="GUID-52FF751C-A3D2-50B5-AAEF-433F67B4CDC5"><title>Kernel containers</title> <p>Internally,
+the kernel maintains lists of all current objects, organized by type. Each
+list is a container, a <codeph>DObjectCon</codeph> object, with one for each
+object type. </p> <p>The <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-FB2E24A6-9744-5169-BA90-DDF84DF1D3E5">c</xref> command
+will walk through all objects in a given list. The type of object is identified
+by appending a number after the command. For example, <codeph>DProcess</codeph> objects
+are identified by the number 1, so to walk through all current <codeph>DProcess</codeph> objects
+type: </p> <p><userinput>c1</userinput> </p> <p>The command effectively executes
+a <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-1DED2B2F-E780-50A0-8325-5DA22BC7D3E0">O</xref> command
+on each object in the "processes" container. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-775901A4-0262-4E14-9E9C-C4E37DFCCF2E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-775901A4-0262-4E14-9E9C-C4E37DFCCF2E" xml:lang="en"><title>OS Base Services </title><shortdesc>Describes the platform services related to OS Base Services.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
Binary file Adaptation/GUID-782E8D92-0431-50F5-95A0-5B231EBDF391-master.png has changed
Binary file Adaptation/GUID-782E8D92-0431-50F5-95A0-5B231EBDF391_d0e25767_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-788ECC4B-36B9-493C-A86E-E6C8007074B1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-788ECC4B-36B9-493C-A86E-E6C8007074B1" xml:lang="en"><title>SDIO </title><shortdesc>Describes the Secure Digital Input/Output (SDIO) platform
+service.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-78963104-C2B0-4E19-99E5-FEAEB7EA307A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-78963104-C2B0-4E19-99E5-FEAEB7EA307A" xml:lang="en"><title>IIC SHAI Implementation Layer</title><shortdesc>Describes how to use the IIC SHAI implementation layer.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-795B8649-B6C3-5540-B52A-9B460F35A5B5.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-795B8649-B6C3-5540-B52A-9B460F35A5B5" xml:lang="en"><title>ROM Paging</title><shortdesc>Demand Paging documentation related to ROM demand paging.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-79620372-BADC-4826-A3AC-7FDBCFF98DA9.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-79620372-BADC-4826-A3AC-7FDBCFF98DA9" xml:lang="en"><title>Device Driver Concepts</title><shortdesc>This section describes the Device Driver concepts.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-796CB42C-29AC-5ECC-AC6E-35FC6B8CC84E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-796CB42C-29AC-5ECC-AC6E-35FC6B8CC84E" xml:lang="en"><title>Concepts</title><shortdesc>This section describes the technology and architecture
+of the USB Client Driver. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/><related-links>
+<link href="GUID-142C21E1-2629-5215-9FBD-B507436E17DB.dita"><linktext>Port
+  Implementation Tutorial</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-79B2CF91-FB95-5E7C-81CC-235A6A660D88.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-79B2CF91-FB95-5E7C-81CC-235A6A660D88" xml:lang="en"><title>MMC Controller</title><shortdesc>The MMC Controller provides kernel extensions that manages access
+to the MultiMediaCard hardware on behalf of media drivers or any other device
+driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> This section describes how to create a port of it for your phone hardware. Symbian
+platform provides a generic Platform-Independent part of the Controller. You
+must provide a Platform-Specific part to implement the interface to the MMC
+hardware on your phone. </p>
+</conbody><related-links>
+<link href="GUID-20E09BC9-35CA-594A-BA91-D8D0C928FD98.dita"><linktext>File Systems</linktext>
+</link>
+<link href="GUID-868866C8-E90C-5291-8732-BB4E86D6B43E.dita"><linktext>Local Media
+Subsystem</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-7A50630B-2B44-5D27-AA18-3BEEE1453020.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,82 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-7A50630B-2B44-5D27-AA18-3BEEE1453020" xml:lang="en"><title> The
+Paging Algorithm Technology Guide</title><shortdesc>Describes the paging algorithm used in demand paging.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-0F07152A-5469-463B-8BEE-71170A920B19"><title>Purpose</title> <p>Kernel
+side developers will sometimes need to know the algorithm used to move data
+in and out of paged memory. </p> <p><b>Intended
+Audience:</b> </p> <p>This document is intended to be read by kernel side
+developers. </p> </section>
+<section id="GUID-55C2239D-C351-4081-96F8-CAF1538B4BE3"><title>The algorithm</title> <p><b>Terminology</b> </p> <p>Paged memory (virtual addresses and their contents)
+is called either: </p> <ul>
+<li id="GUID-8533664E-057B-57EF-8A24-4BA7D3B4EC75"><p>'live', meaning present
+in the cache of physical RAM, or </p> </li>
+<li id="GUID-057D65C6-27D2-5BDD-B5CD-081808CCF44D"><p>'dead', meaning stored
+elsewhere in the backing store. </p> </li>
+</ul> <p>Physical RAM not being used to hold paged memory is called the free
+pool. </p> <p>Items of paged memory can be reassigned from 'live' to 'dead'
+and vice versa. 'Live' items are classed as either 'old' or 'young' for this
+purpose. </p> <p><b>Paging
+out memory</b> </p> <p>When more RAM is needed and the pool of free memory
+is empty then RAM is freed up. This means changing an item of paged memory
+from live to dead. The process is called paging out and it involves these
+tasks. </p> <ol id="GUID-20C35CC3-0845-51A8-B3C0-0F542E0570DF">
+<li id="GUID-42AC538A-A676-5A7D-9DE3-FDE880E4A508"><p>The oldest virtual page
+is removed from the cache and physically stored elsewhere </p> </li>
+<li id="GUID-1FBD9975-97D5-50CA-8A2F-864B688C9AE4"><p>The MMU marks the virtual
+page as inaccessible. </p> </li>
+<li id="GUID-F8CDC9C1-C779-5D25-A16C-8BFC4B82B605"><p>The associated page
+of RAM cache is returned to the free pool. </p> </li>
+</ol> <p><b>Paging
+in memory</b> </p> <p>When a program attempts to access dead paged memory,
+the MMU generates a page fault and the executing thread is diverted to the
+Symbian platform exception handler. This performs the following
+tasks. </p> <ol id="GUID-3C52A214-F7FC-55CF-9346-16A4D7E8E37A">
+<li id="GUID-B10392F3-D0CA-5C31-8A88-59E151661821"><p>Obtain a page of RAM
+from the free pool. If the free pool is empty, free up some memory by paging
+out the oldest live page. </p> </li>
+<li id="GUID-EA4E0F16-68D2-564D-B46E-5CB4CB515855"><p>Read the contents of
+the dead paged memory from its actual location (e.g. NAND flash) and write
+them to the page of RAM. </p> </li>
+<li id="GUID-5F9C3CEE-5836-5243-B84D-BA7795D0F056"><p>Update the live list
+described in the next section. </p> </li>
+<li id="GUID-A2A188F0-87EA-5403-8281-652AC52D41C3"><p>The MMU maps the linear
+address of the dead paged memory on to the page of RAM. </p> </li>
+<li id="GUID-F7A50A62-EBAD-50DD-B8F8-DAD42E598D02"><p>Resume program execution. </p> </li>
+</ol> <p><b>The
+paging cache</b> </p> <p>The paging cache is only useful if it is used to
+hold the pages most likely to be required. The paging subsystem provides for
+this by selecting the oldest pages to be paged out making space for new ones
+to be paged in. </p> <p>All live pages are stored in a list called the 'live
+page list'. Live pages are labelled 'young' or 'old' and are stored in two
+sub-lists, one for each type: the item at the start of the young list is the
+youngest item and the one at the end of the old list is the oldest item. The
+MMU makes young pages accessible to programs and old pages inaccessible. However,
+old pages are different from dead pages because their contents are still held
+in RAM. </p> <p>The young and old lists are maintained in accordance with
+these four rules. </p> <ul>
+<li id="GUID-ACB20E61-3467-56B4-8697-6DD6C79203FA"><p>When a dead page is
+paged in (made live) it is added to the start of the young list, becoming
+the youngest item. </p> </li>
+<li id="GUID-6B56324C-3A75-57C4-90E3-527994DAADFF"><p>When a live page must
+be paged out (made dead) to free up RAM, the oldest page is selected. </p> </li>
+<li id="GUID-EB5C43F4-1AC9-541F-8235-4DED9714B6F3"><p>If an old page is accessed
+by a program a page fault results because old pages are marked inaccessible.
+The paging system handles the fault by turning the page into a young page
+('rejuvenating' it). To compensate, the oldest young page is then turned into
+an old page ('aging' it). </p> </li>
+<li id="GUID-366367C8-BBF3-59ED-9122-38112C6EA6FE"><p>Efficient operation
+requires a stable ratio of young to old pages. If the number of young pages
+exceeds a specified ratio of old pages, the oldest young page is turned into
+the youngest old page ('aging' it). </p> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-7AB0C7E2-8B7C-5CC3-BAA5-15AA59F31181.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-7AB0C7E2-8B7C-5CC3-BAA5-15AA59F31181" xml:lang="en"><title>InterpretSIS</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>InterpretSIS is a command-line tool used to install SIS files to
+a data drive image that can be flashed onto a device's <codeph>system
+drive</codeph>. It is either invoked through <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">BUILDROM</xref> while
+creating a data drive image or can be invoked directly. </p>
+<p>For more information on <codeph>system drive</codeph> refer to,
+&gt; Symbian Guide &gt; Kernel and Hardware Services Guide &gt; User Library
+and File Server &gt; File Server &gt; File Server Client Side &gt; The System
+Drive. </p>
+<section id="GUID-64216AE8-5791-5844-9752-C0413D1F8808"><title>Command-line
+syntax</title> <p>The syntax for using <codeph>InterpretSIS</codeph> is as follows: </p> <codeblock id="GUID-72A667CC-9F1B-5C0C-B6F3-66F7B8C10A84" xml:space="preserve">InterpretSIS [-v] [-h] [-w off|error|warn|info [-l &lt;logfile&gt;]] [-d &lt;systemdrive&gt;] -c &lt;dir&gt; -z &lt;dir&gt; -s &lt;filename.sis&gt;[,&lt;filename2.sis&gt;, &lt;dir&gt;, ...]</codeblock> <p>or: </p> <codeblock id="GUID-7C291914-3E14-587F-8826-445ACE0FE555" xml:space="preserve">InterpretSIS -p &lt;filename&gt;</codeblock> <table id="GUID-2A28E178-CB21-57E9-996E-BAF55BA0EBF6">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph> -v</codeph>  </p> </entry>
+<entry><p>Displays verbose output. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-h</codeph>  </p> </entry>
+<entry><p>Displays help. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-w</codeph>  </p> </entry>
+<entry><p>The warning level to report; <codeph>error</codeph> by default. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-l</codeph>  </p> </entry>
+<entry><p>The log file to write to; standard error by default.  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-d</codeph>  </p> </entry>
+<entry><p>The drive letter of the system drive on the target device; <filepath>C:</filepath> by default. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> -c</codeph>  </p> </entry>
+<entry><p>A directory on the PC representing the drive on the target
+device to which files are installed. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> -z</codeph>  </p> </entry>
+<entry><p>A directory on the PC representing the contents of the ROM
+(the <filepath>Z:</filepath> drive). This needs to be specified so
+that <codeph>InterpretSIS</codeph> can check any dependencies are
+met and to prevent invalid eclipsing. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> -s </codeph>  </p> </entry>
+<entry><p>The SIS file(s) to install. Any directory specified will
+be searched for SIS files. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>For example: </p> <codeblock id="GUID-B409DA60-3779-5E58-92AD-CC45403E98C0" xml:space="preserve">interpretsis -d c -c c:\epoc32\winscw\c -z C:\epoc32\release\WINSCW\udeb\Z -s sisfile1.sis, directory1, sisfile2.sis -w info</codeblock> <p>Alternatively, the parameters can be placed in a file, which
+is passed to <codeph>InterpretSIS</codeph> using the <codeph>-p</codeph> option: </p> <codeblock id="GUID-76151F7A-050E-5BDA-827C-D3E47F304D61" xml:space="preserve">InterpretSIS -p &lt;filename&gt;</codeblock> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-7AB51180-7A1A-40C7-B28F-EA46314A6E5B-GENID-1-2-1-9-1-5-1-4-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,54 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-7AB51180-7A1A-40C7-B28F-EA46314A6E5B-GENID-1-2-1-9-1-5-1-4-1" xml:lang="en"><title>Synchronous
+Requests</title><shortdesc>This document describes the use of synchronous requests by device
+drivers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-6C508A3B-B2E6-4D16-9421-03EE1A0B595F-GENID-1-2-1-9-1-5-1-4-1-3-1">       <title><b>Synchronous
+requests</b></title>       <p>Synchronous requests are typically used to set
+or retrieve some information for the device driver. These requests almost
+never need to access the hardware itself, and usually complete relatively
+quickly. They return only after the completion of the request and the user
+side thread is blocked till completion. Synchronous requests are usuallly
+initiated by a call to <xref href="GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066.dita#GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066/GUID-D774DE92-6431-374A-A1F6-1C7045BD4FE5"><apiname>RBusLogicalChannel::DoControl()</apiname></xref>.
+The request is most likely to be executed in the context of the client user-side
+thread.</p> <p>A driver lists its available synchronous requests
+in an enumeration, for example: </p> <codeblock id="GUID-09E42EC9-CF71-59C0-876E-0651F27E591F-GENID-1-2-1-9-1-5-1-4-1-3-1-4" xml:space="preserve">// Synchronous control messages used with DoControl()
+enum TControl 
+    {
+    EControlConfigure, // Configure the device (UART)
+    EControlTransmitData, // Transmit data over the device (UART)    
+    EControlReceiveData,    // Receive the data from the device 
+    ENumRequests, // Number of synchronous control requests
+    AllRequests = (1&lt;&lt;ENumRequests)-1
+    };</codeblock>     </section>
+<section id="GUID-EC33A9C8-CE41-4937-8008-35502C290581-GENID-1-2-1-9-1-5-1-4-1-3-2"><title>Implementation</title><p>Drivers
+generally implement the <xref href="GUID-06C73075-6095-3D8F-AFC9-FD832958A49C.dita"><apiname>DoControl()</apiname></xref> function in the LDD
+to handle the received synchronous messages. The implementation reads the
+request type and other passed arguments, and handles the request appropriately.
+For example, the following handles <codeph>RExDriver::EControlConfigure</codeph> requests: </p> <codeblock id="GUID-1996BA3A-A895-58C8-B394-4219510DF6D3-GENID-1-2-1-9-1-5-1-4-1-3-2-3" xml:space="preserve">TInt DExDriverLogicalChannel::DoControl(TInt aFunction, TAny* a1, TAny* /*a2*/)
+    {
+    switch (aFunction)
+        {
+        case RExDriver::EControlConfigure:
+            memclr(&amp;c, sizeof(c)));
+            TPtr8 cfg((TUint8*)&amp;c, 0, sizeof(c)));
+            r = Kern::ThreadDesRead(iClient,a1,cfg,0,0);
+            if (r==KErrNone)
+                Pdd()-&gt;Configure(&amp;c);
+            break;
+            ...
+        default:
+                r = KErrNotSupported;
+        }
+    return r;
+    }</codeblock></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-7AB51180-7A1A-40C7-B28F-EA46314A6E5B-GENID-1-2-1-9-1-6-1-9-1-5-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,54 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-7AB51180-7A1A-40C7-B28F-EA46314A6E5B-GENID-1-2-1-9-1-6-1-9-1-5-1" xml:lang="en"><title>Synchronous
+Requests</title><shortdesc>This document describes the use of synchronous requests by device
+drivers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-6C508A3B-B2E6-4D16-9421-03EE1A0B595F-GENID-1-2-1-9-1-6-1-9-1-5-1-3-1">       <title><b>Synchronous
+requests</b></title>       <p>Synchronous requests are typically used to set
+or retrieve some information for the device driver. These requests almost
+never need to access the hardware itself, and usually complete relatively
+quickly. They return only after the completion of the request and the user
+side thread is blocked till completion. Synchronous requests are usuallly
+initiated by a call to <xref href="GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066.dita#GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066/GUID-D774DE92-6431-374A-A1F6-1C7045BD4FE5"><apiname>RBusLogicalChannel::DoControl()</apiname></xref>.
+The request is most likely to be executed in the context of the client user-side
+thread.</p> <p>A driver lists its available synchronous requests
+in an enumeration, for example: </p> <codeblock id="GUID-09E42EC9-CF71-59C0-876E-0651F27E591F-GENID-1-2-1-9-1-6-1-9-1-5-1-3-1-4" xml:space="preserve">// Synchronous control messages used with DoControl()
+enum TControl 
+    {
+    EControlConfigure, // Configure the device (UART)
+    EControlTransmitData, // Transmit data over the device (UART)    
+    EControlReceiveData,    // Receive the data from the device 
+    ENumRequests, // Number of synchronous control requests
+    AllRequests = (1&lt;&lt;ENumRequests)-1
+    };</codeblock>     </section>
+<section id="GUID-EC33A9C8-CE41-4937-8008-35502C290581-GENID-1-2-1-9-1-6-1-9-1-5-1-3-2"><title>Implementation</title><p>Drivers
+generally implement the <xref href="GUID-06C73075-6095-3D8F-AFC9-FD832958A49C.dita"><apiname>DoControl()</apiname></xref> function in the LDD
+to handle the received synchronous messages. The implementation reads the
+request type and other passed arguments, and handles the request appropriately.
+For example, the following handles <codeph>RExDriver::EControlConfigure</codeph> requests: </p> <codeblock id="GUID-1996BA3A-A895-58C8-B394-4219510DF6D3-GENID-1-2-1-9-1-6-1-9-1-5-1-3-2-3" xml:space="preserve">TInt DExDriverLogicalChannel::DoControl(TInt aFunction, TAny* a1, TAny* /*a2*/)
+    {
+    switch (aFunction)
+        {
+        case RExDriver::EControlConfigure:
+            memclr(&amp;c, sizeof(c)));
+            TPtr8 cfg((TUint8*)&amp;c, 0, sizeof(c)));
+            r = Kern::ThreadDesRead(iClient,a1,cfg,0,0);
+            if (r==KErrNone)
+                Pdd()-&gt;Configure(&amp;c);
+            break;
+            ...
+        default:
+                r = KErrNotSupported;
+        }
+    return r;
+    }</codeblock></section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-7B0BA327-54A0-4908-B8E3-0C82112EB957-master.png has changed
Binary file Adaptation/GUID-7B0BA327-54A0-4908-B8E3-0C82112EB957_d0e93167_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-7B9D4E46-6AF9-5B77-9BE3-8B1DFAC588BD.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-7B9D4E46-6AF9-5B77-9BE3-8B1DFAC588BD" xml:lang="en"><title>Set Up</title><shortdesc>Set up the source code and project files for an implementation
+of the USB client controller.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This topic describes how to set up the source code and project
+files for an implementation of the USB client controller. </p>
+<p>Another more complicated example is implemented in the OMAP/H4
+platform. This platform has two USB device controllers. The code shows
+how two UDCs can be supported in the same source and build tree. The
+second controller (Fibula) is a High speed USB 2.0 compatible device
+controller, the code demonstrates how to support a USB 2.0 UDC and
+one or more USB 2.0 Client Devices. See the code in <filepath>...\omap-hrp\...</filepath>. </p>
+<p>The suggested steps are as follows: </p>
+<ol id="GUID-4850DC56-9ABA-5B34-8C5B-A314D0DB08B8">
+<li id="GUID-883110DC-0314-590C-B8F9-0A0663615445"><p>Decide where
+to put the source and header files for the platform-specific layer
+. Normally the USB device controller is part of the ASSP, and you
+would put the source files in the ASSP directory. For an external
+USB device controller, you would use the Variant directory instead. </p> </li>
+<li id="GUID-BB60E177-D816-5EE1-BF93-A9DF4CB1BE86"><p>Implement the
+platform-specific Layer within your chosen source and header files. </p> <p>If you have a header file with a name in the shape of <filepath>ASSP.h</filepath>, then you will put USB Device Controller register
+definitions and register bit definitions here. </p> </li>
+<li id="GUID-01DDD063-64F5-57EF-A404-965127E612E2"><p>Define the <filepath>.mmp</filepath> file for the USB client controller (the PDD), and
+put this into your chosen directory. Remember that the platform-specific
+layer is just <i>part</i> of the USB client controller, and the <filepath>.mmp</filepath> file needs to contain a list of <i>all</i> source
+files that need to be compiled. </p> </li>
+<li id="GUID-337F3E69-68C6-5A44-9406-59AFCA681F4E"><p>Add the name
+of the <filepath>.mmp</filepath> file (without the file extension)
+to your ASSP's <filepath>.inf</filepath> file in the <codeph>PRJ_MMPFILES</codeph> section. This must be in the same directory. This tells the <filepath>abld</filepath> tool about the existence of the <filepath>.mmp</filepath> file. </p> </li>
+</ol>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-7BB36477-0FE2-51D5-B4C0-86F7265C1B94.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-7BB36477-0FE2-51D5-B4C0-86F7265C1B94" xml:lang="en"><title>Reference</title><shortdesc>This topic provides a summary of related documentation for the
+Base Starter to which you can refer. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-6610B4DD-9C84-5548-AC5D-657513EF4180"><title>API
+Reference</title> <p>No published APIs. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-7BCC0EFA-0DD5-4879-BECF-C32D04BC8A39.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE reference
+  PUBLIC "-//OASIS//DTD DITA Reference//EN" "reference.dtd">
+<reference id="GUID-7BCC0EFA-0DD5-4879-BECF-C32D04BC8A39" xml:lang="en"><title>SHAI Service</title><shortdesc>A service that it intended to be used only by adaptation
+code, for example, as part of a SHAI implementation. SHAI services
+are rare.</shortdesc><prolog><metadata><keywords/></metadata></prolog><refbody>
+<section id="GUID-B574BEEE-5786-4DBD-943C-A3E63FC0F412"> 			 		</section>
+</refbody></reference>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-7BCDDA55-1460-5411-AFCF-C4640BEB9DE4.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-7BCDDA55-1460-5411-AFCF-C4640BEB9DE4" xml:lang="en"><title>Configuration:
+HAL (Hardware Abstraction Layer)</title><shortdesc>HAL contains a number of attributes that are related to the Digitizer
+Driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>These attributes must be appropriately described in the HAL <filepath>config.hcf</filepath> file
+for your variant. Follow the links to these attribute items for their meaning
+and values. </p>
+<ul>
+<li id="GUID-0577FAB7-4863-5C13-AEC8-4C085C095DED"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-B4BCAA1C-2800-3DA8-AC48-A8326FEFD553"><apiname>HALData::EPen</apiname></xref>  </p> </li>
+<li id="GUID-BFFC98BC-29A5-5357-B0F5-B5B075A13F81"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-F05D680F-345F-3678-B34C-6B3074512EDE"><apiname>HALData::EPenX</apiname></xref>  </p> </li>
+<li id="GUID-6E394598-F1C6-5624-A5A0-CA412E588669"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-97A76637-542D-3478-8CD2-3B2BCD2F0738"><apiname>HALData::EPenY</apiname></xref>  </p> </li>
+<li id="GUID-D5BC15E7-1C6B-5D47-A2A8-18CC1C78F637"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-EE87B796-7E58-34E2-A511-A5FC4B1730AF"><apiname>HALData::EPenState</apiname></xref>  </p> </li>
+<li id="GUID-3616047A-7DCA-5F8D-A835-EF701E0F2BD4"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-079CD0A7-6C36-3A05-8EFA-51FDD649C657"><apiname>HALData::EPenDisplayOn</apiname></xref>  </p> </li>
+<li id="GUID-9DDE9DDE-DDB4-51A1-B82A-7AE1C5E173D1"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-E1002689-F260-3AE8-9B47-87A10A6FB48A"><apiname>HALData::EPenClick</apiname></xref>  </p> </li>
+<li id="GUID-66EFDD61-44C0-58B1-A555-318E17A5DE1C"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-EB7AD3B3-2559-314C-9B77-A8F649F116EF"><apiname>HALData::EPenClickState</apiname></xref>  </p> </li>
+<li id="GUID-BB8DBE25-891A-51EC-A27A-5ADBBEB4A1F5"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-0FB860E8-87DD-34D8-8A2A-8A4203D1AFE8"><apiname>HALData::EPenClickVolume</apiname></xref>  </p> </li>
+<li id="GUID-C6C84C6C-8135-5832-9672-FC71CB5D6945"><p> <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-3D4C939B-AF69-3D2E-A286-2C3EFA20380E"><apiname>HALData::EPenClickVolumeMax</apiname></xref>  </p> </li>
+</ul>
+</conbody><related-links>
+<linklist>
+<link href="GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8.dita"><linktext>User Side
+Hardware Abstraction</linktext></link>
+<link href="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita"><linktext>HAL Attributes
+and Function IDs</linktext></link>
+<link href="GUID-52583CC7-483E-54B5-8094-F0F61BD46B7F.dita"><linktext>Configuration
+Attribute Definition Files</linktext></link>
+</linklist>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-7C064328-8368-4259-9CE1-B8DFE2DF4AAC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-7C064328-8368-4259-9CE1-B8DFE2DF4AAC" xml:lang="en"><title>Fair Scheduling and File Caching</title><shortdesc>This section shows how to enable and configure file caching.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-7C533836-0D27-5519-BC1D-7153AC8BE4C0.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,47 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-7C533836-0D27-5519-BC1D-7153AC8BE4C0" xml:lang="en"><title>Media
+Driver Guide</title><shortdesc>Describes the issues that need to be considered, when writing a
+media device driver for a writable data demand paging environment. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-46C98F8A-1486-4FAD-918D-3FB0E7CA372E"><title>Purpose</title> <p>This
+document explains the points that have to be considered when writing a media
+driver in an environment that uses writable data paging. </p> </section>
+<section id="GUID-1A89843E-B174-49F0-87D8-A8ADBE933A54"><title>Issues to consider</title> <p>The
+main issue to consider when writing a media device driver for a writable demand
+paging environment is to avoid page faults from occurring in DFCs, since this
+can lead to a deadlock condition between the driver and the client process. </p> <p>This
+can be avoided using the following methods: </p> <ul>
+<li id="GUID-76EF65C9-63E8-5C9B-99CD-A8BFBBA9B68C"><p>Use shared chunks. </p> <p>Shared
+chunks are memory areas that are accessible by both kernel-side and user-side
+and they are never paged. </p> <p>This is the best solution for drivers that
+involve fast throughput such as media drivers. </p> </li>
+<li id="GUID-32198DFA-CCF9-5260-A677-88F5B9FBF315"><p>Use synchronous rather
+than asynchronous data transfer </p> <p>This could be done by implementing
+the following steps: </p> <ol id="GUID-8C359B63-D166-5A54-8772-811FC2656E66">
+<li id="GUID-018F2121-A883-5B2F-B70E-C77069B3F1A1"><p>The client requests
+a notification when data is available. </p> </li>
+<li id="GUID-0FC1D31E-4937-572B-BD80-99DDFABCC0BF"><p>The data arrives. </p> </li>
+<li id="GUID-6B47B0FA-8921-5B12-A71C-0E66DD286FD1"><p>The driver writes data
+into an internal buffer and completes the client request. </p> </li>
+<li id="GUID-14E4D83B-7361-5DE4-90BF-B9CEB658FF1D"><p>The client makes a read
+request. </p> </li>
+<li id="GUID-FF2A912E-3FBB-5671-ADBE-090FED1CD873"><p>The driver writes the
+data back to the client in the client thread context. </p> </li>
+</ol> <p>This approach is easy to implement, however it requires the buffering
+of data. </p> </li>
+<li id="GUID-08F4A4BD-699B-5800-BD2D-78A5406C19EB"><p>Use the <xref href="GUID-066868C5-12F8-59A5-A2DE-FEDC4F459771.dita">flexible
+memory model</xref>  </p> <p>This provides the ability for the memory to be
+mapped into a drive's address space as unpaged. </p> <p>This is an alternative
+to the use of shared chunks. </p> <p>However, this is not supported on the
+moving or multiple memory models. </p> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-7D535B68-CA7F-4796-80FB-AE7A27642A88.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,117 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-7D535B68-CA7F-4796-80FB-AE7A27642A88" xml:lang="en"><title>SDIO
+Overview</title><shortdesc>SDIO is an Input/Output interface based on the SD card standard. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The intent behind SDIO is to allow the use of an SD slot for more than
+memory cards. SDIO allows I/O devices such as GPS, camera, Wi-Fi, FM radio,
+Ethernet, barcode readers and Bluetooth to be plugged into such a slot. </p>
+<p>However, with space being limited in modern mobile phones, memory card
+slots are usually microSD slots - which are too small to accept SDIO or miniSDIO
+cards. Also, memory card slots are often internal to the phone which prohibits the
+insertion of SDIO cards. Therefore in Symbian devices, SDIO is typically used
+only as an internal peripheral bus on all but hardware reference platforms.
+Because of its ability to provide high-speed data I/O with low power consumption,
+SDIO can be used to connect components such as Wi-Fi and FM radio peripheral
+chips to the main processor.</p>
+<section id="GUID-82B34422-2F2D-4D1E-860A-556FEB7FF41B"><title>Required background</title><p>You
+must have an understanding of SD card before using SDIO. </p></section>
+<section id="GUID-D5194E78-3B55-40C9-A832-7E24C2CC43D3">       <title>Architecture</title><fig id="GUID-00983E3C-72BE-40EC-9F93-216741F00CD6">
+<title>SDIO Architecture</title>
+<image href="GUID-A819DE06-7B00-4643-9D3E-EFE14132981C_d0e99133_href.png" placement="inline"/>
+</fig>           </section>
+<section id="GUID-CF3292E0-0BF4-4FC2-9253-D052AF89AC1E"><title>Description</title><p>The
+SDIO is divided into key modules described below.</p><ul>
+<li><p><i>Memory card</i> performs the SD or the MMC card operations. It registers
+the card driver, initializes the card, and sets permissions for the read and
+write operations</p></li>
+</ul><ul>
+<li><p><i>SDIO Host controller</i> is the most important module in the SDIO
+architecture. It has a driver that allows card initialization, bus width settings,
+clock frequency setting, sending and receiving of commands and SDIO interrupt
+handling.</p></li>
+</ul><ul>
+<li><p><i>General Card Functions</i> contains functions that are useful during
+the development of other card drivers. The module supplies the read/write
+SDIO/SD/MMC card register operations as well as select/deselect card, read
+card status and reset card procedures.</p></li>
+</ul></section>
+<section id="GUID-19CA14BB-BE60-4063-BB68-E960357D2C96"><title>Key Concepts</title><ul>
+<li><p><b>SDIO Interrupts:</b> SDIO Interrupts are level-sensitive interrupts.
+They communicate with the host through the SDIO line.  The signal is held
+active until the host acknowledges the interrupt through some function unique
+I/O operation.</p></li>
+</ul><ul>
+<li><p><b>SDIO Class Driver:</b> SDIO Driver supports the SDIO Host Controller.
+The driver includes functions such as initialization, bus settings, clock
+frequency setting, sending and receiving of commands, and SDIO interrupt handling.</p></li>
+</ul><ul>
+<li><p><b>SDIO card controller:</b> SDIO card protocol is a super-set of the
+SD card protocol. The SDIO Card Controller shares some of its functionality
+with the SD controller. The Symbian platform SDIO card controller is implemented
+as a set of SDIO card classes, each of which is derived from the corresponding
+SD card classes. The SDIO card controller provides support for SDIO cards
+within the E32 kernel. It manages access to the SDIO card hardware interface
+and provides an API for class drivers to access SDIO card functions. </p> </li>
+</ul></section>
+<section id="GUID-069B6CC3-9811-4BD8-869E-596BC1C0313F"><title>API summary</title><p>This
+API is used by the implementers of the class drivers.</p><table id="GUID-B0DC509E-F1BC-450F-9BBE-C3FFF85AEB06">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top"><p>API names </p></entry>
+<entry valign="top"><p>Description</p></entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p><xref href="GUID-F84A87F1-7DDD-37D7-A936-EB5DEC4F4740.dita"><apiname>DSDIOSTACK</apiname></xref></p></entry>
+<entry><p>The stack can handle multiple outstanding requests simultaneously.
+ It schedules these requests onto the bus, thereby putting the appropriate
+card into transfer state automatically and running the appropriate state machine
+function. </p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-8E2210D1-CCE7-34B3-9D19-B7F79481CD67.dita"><apiname>TSDIOCARD</apiname></xref></p></entry>
+<entry><p>This class owns the I/O function objects. It provides access to
+an I/O function object provided through the <codeph>IOFunction()</codeph>,
+which returns a pointer to the object concerned. </p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-87D13F47-6680-34DD-956E-AB2A8C21AE19.dita"><apiname>DSDIOSESSION</apiname></xref></p></entry>
+<entry><p>This contains functions for setting up a session object to perform
+SDIO specific command sequences such as initialization, scheduling, invoking
+and submitting the session.</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-522BF42B-1A3F-3FF7-B227-39AC1A285C10.dita"><apiname>DSDIOREGINTERFACE</apiname></xref></p></entry>
+<entry><p>This contains the APIs that are used most frequently
+during the implementation of the SDIO class drivers. It contains member functions
+that allow single-byte read or write operations to a given register address
+together with the corresponding ones for multi-byte access</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-7CC8E73B-0656-3ABD-AA70-6C309E74C035.dita"><apiname>TSDIOFUNCTION</apiname></xref></p></entry>
+<entry><p>This contains member functions for access and control of function-specific
+features such as function enable, function ready. It also has the member functions
+for access and control of FBR features such as CSA access and function block
+size. </p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-0CABFFC3-743C-35EB-99E0-1B0452E4A42B.dita"><apiname>TSDIOINTERRUPT</apiname></xref></p></entry>
+<entry><p>This contains the usual interrupt object member functions. It provides
+the abstraction of a per-function interrupt even though each function actually
+shares a single interrupt request signal on the card. </p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-7DDF052C-2520-428D-932D-BDB476344575.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-7DDF052C-2520-428D-932D-BDB476344575" xml:lang="en"><title>Generated
+Events</title><shortdesc>This document describes how kernel events are used in communication
+with the kernel.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-E539DF2B-239A-4B8F-B053-EE2041EA439E">     <p>Drives
+can communicate with the Window Server, and through that to user programs,
+using events. </p> <p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-81C82FED-0E26-351A-901E-806843C808FE"><apiname> Kern::AddEvent()</apiname></xref> adds an event
+to the kernel event queue. This is used typically in drivers such as the keyboard
+driver, which raises key events. </p> <codeblock id="GUID-EC49015D-A9BF-505B-95A3-A2630B36602B" xml:space="preserve">TRawEvent event;
+event.Set(TRawEvent::EKeyDown, EStdKeyBackspace);
+Kern::AddEvent(event);</codeblock> <p>The kernel event queue maintains a circular
+buffer of <xref href="GUID-668CEA36-3933-3BBE-A980-CAB62617B4FD.dita"><apiname>TRawEvent</apiname></xref> objects allocated at system initialization.
+The Windows Server calls <xref href="GUID-9EF04FB9-B36F-3A6F-AF3F-F2238BD181E9.dita#GUID-9EF04FB9-B36F-3A6F-AF3F-F2238BD181E9/GUID-2B008E10-844A-3081-A4CB-B64583E9DBFC"><apiname>UserSvr::CaptureEventHook()</apiname></xref> to
+register itself to receive such events. The Kernel does not permit any process
+other than the Windows Server to register to receive events. </p>        
+  </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-7E357DA2-67AD-403A-B4E1-7CB83E75136F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-7E357DA2-67AD-403A-B4E1-7CB83E75136F" xml:lang="en"><title>SDIO Build Guide</title><shortdesc>Describes what is needed to include the SDIO adaptation
+in a ROM image.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>When building a ROM image, all the processes and data needed to
+execute a build are included in a single file. This file is executed
+by the platform when the hardware is powered up.</p>
+<section id="GUID-72D93CEF-4E7D-473B-B607-ACBC0071DF6D-GENID-1-2-1-10-1-5-1-9-1-1-8-1-6-1-3-2"><title>Requirements</title><ul>
+<li><p>The SDIO hardware must conform to the SDIO standards and that
+the hardware must work correctly.</p></li>
+<li><p>You must be familiar with building a ROM for the Symbian platform.</p></li>
+</ul></section>
+<section id="GUID-D627B27F-CCFE-42A0-856C-7B09E873BAE1-GENID-1-2-1-10-1-5-1-9-1-1-8-1-6-1-3-3"><title>Build
+time implementation details</title><p>None</p></section>
+<section id="GUID-E4423114-056C-4874-8FF2-53EB1FF5F074-GENID-1-2-1-10-1-5-1-9-1-1-8-1-6-1-3-4"><title>Building
+the ROM with SDIO included</title><p>To include the SDIO PIL libraries
+in the final ROM image, the <codeph>USE_SDIO_SD_MMC</codeph> flag
+must be included in the list of buildrom parameters.</p><p>An example
+of the use of this new parameter is:</p><codeblock xml:space="preserve">buildrom h4hrp techview -DUSE_SDIO_SD_MMC</codeblock><p>This example produces a ROM.</p><p>The iby file that specifies
+the SDIO's PSL, must be included in the oby file for the ROM image.</p><p>For more information, refer to <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">BUILDROM</xref> .</p></section>
+<section id="GUID-200C70B4-D9FE-4807-B93E-507FF96D1886"><title>Run-time
+configuration</title><p>Not required</p></section>
+</conbody><related-links>
+<link href="GUID-0ADC2927-5AC9-5461-9A17-382FBB170067.dita"><linktext>ROM
+Tools Overview</linktext></link>
+<link href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita"><linktext>BUILDROM</linktext>
+</link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-7E3BBB18-3113-4312-AD91-897DE87C58BF.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-7E3BBB18-3113-4312-AD91-897DE87C58BF" xml:lang="en"><title>SDIO
+PSU Implementation Tutorial</title><shortdesc>How to implement the platform-specific class for the Power Supply
+Unit of an SDIO-based hardware component.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Power Supply Unit (PSU) functionality is provided by the <xref href="GUID-9BF2FEAC-F6B8-3071-A4AB-976E33354F1D.dita"><apiname>DSDIOPsu</apiname></xref> class.
+To enable power control in the SDIO Controller, you must implement the <codeph>PsuInfo()</codeph> function
+in the derived class of the <xref href="GUID-9BF2FEAC-F6B8-3071-A4AB-976E33354F1D.dita"><apiname>DSDIOPsu</apiname></xref> class. </p>
+<p>The <codeph>iNotLockedTimeOut</codeph> variable
+is used by the "card not locked" functionality and the value is tied to the
+reference board inactivity time-out. The <codeph>iInactivityTimeOut</codeph> variable
+is used to set a time-out value for the sleep mode of the SDIO cards. </p>
+<example><p><codeblock xml:space="preserve">void DMySdioPsu::PsuInfo(TPBusPsuInfo&amp; anInfo)
+	{
+	...
+	// Only for SDIO
+	anInfo.iNotLockedTimeOut = 5;    // Power down after 5 seconds of non-use (no clients registered)
+	anInfo.iInactivityTimeOut = 1;	// Enter Sleep mode within 1 Second of inactivity (clients registered)
+	...
+	return;
+	}
+</codeblock></p></example>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-7ECDCF7B-3B2A-561F-9136-04BC4DAE46E4.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,161 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-7ECDCF7B-3B2A-561F-9136-04BC4DAE46E4" xml:lang="en"><title>ARM
+Exception Types, Fault Status Register Values, and Processor Mode Values</title><shortdesc>Reference for users of the debug monitor tool to ARM exception
+types, fault status register values, and processor mode values. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-567330BE-A308-50CD-9EB8-891E45FA8294"><title>ARM exception
+types</title> <p>The numeric value in the left hand column is the value of
+the <codeph>ExcId</codeph> field displayed as a result of entering an <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-D5F2E0AF-EF03-5150-813B-DF989F12C47B">f</xref> command
+in the debug monitor. </p> <table id="GUID-D87BD88D-734C-571F-A02F-039AB98B3906">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>00000000</codeph>  </p> </entry>
+<entry><p>Prefetch abort </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>00000001</codeph>  </p> </entry>
+<entry><p>Data abort </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>00000002</codeph>  </p> </entry>
+<entry><p>Undefined instruction </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-E55E7DA9-61DC-57D9-9678-05D490FEE604"><title>Fault status
+register values (FSR register)</title> <p>The lowest 4-bits of the FSR register
+indicates the fault generated by the MMU. The FSR register value is displayed
+as a result of entering an <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-D5F2E0AF-EF03-5150-813B-DF989F12C47B">f</xref> command
+in the debug monitor. </p> <table id="GUID-502176DF-8084-5D06-8443-29D64B2BDC33">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>0</codeph>  </p> </entry>
+<entry><p>Vector exception </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>1</codeph>  </p> </entry>
+<entry><p>Alignment fault </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>2</codeph>  </p> </entry>
+<entry><p>Terminal exception </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>3</codeph>  </p> </entry>
+<entry><p>Alignment fault </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>4</codeph>  </p> </entry>
+<entry><p>External abort on linefetch for section translation </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>5</codeph>  </p> </entry>
+<entry><p>Section translation fault (unmapped virtual address) </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>6</codeph>  </p> </entry>
+<entry><p>External abort on linefetch for page translation </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>7</codeph>  </p> </entry>
+<entry><p>Page translation fault (unmapped virtual address) </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>8</codeph>  </p> </entry>
+<entry><p>External abort on non-linefetch for section translation </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>9</codeph>  </p> </entry>
+<entry><p>Domain fault on section translation (i.e. accessing invalid domain) </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>A</codeph>  </p> </entry>
+<entry><p>External abort on non-linefetch for page translation </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>B</codeph>  </p> </entry>
+<entry><p>Domain fault on page translation (i.e. accessing invalid domain) </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>C</codeph>  </p> </entry>
+<entry><p>External abort on first level translation </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>D</codeph>  </p> </entry>
+<entry><p>Permission fault on section (i.e. no permission to access virtual
+address) </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>E</codeph>  </p> </entry>
+<entry><p>External abort on second level translation </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>F</codeph>  </p> </entry>
+<entry><p>Permission fault on page (i.e. no permission to access virtual address) </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-BFA2235C-1598-59E6-9F1F-A8281F13A957"><title>ARM processor
+modes (CPSR register)</title> <p>The 5 least-significant bits of the CPSR
+register indicate the ARM processor mode. The CPSR register value is displayed
+as a result of entering an <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-D5F2E0AF-EF03-5150-813B-DF989F12C47B">f</xref> command
+in the debug monitor. </p> <table id="GUID-6B7CF34F-384D-52BF-9C72-C4D8E8B42633">
+<tgroup cols="3"><colspec colname="col0"/><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p> <b>CPSR[4:0]</b>  </p> </entry>
+<entry><p> <b>Mode</b>  </p> </entry>
+<entry><p> <b>Register set</b>  </p> </entry>
+</row>
+<row>
+<entry><p>10000 </p> </entry>
+<entry><p>User </p> </entry>
+<entry><p>PC, R14..R0, CPSR </p> </entry>
+</row>
+<row>
+<entry><p>10001 </p> </entry>
+<entry><p>FIQ </p> </entry>
+<entry><p>PC, R14_fiq..R8_fiq, R7-R0, CPSR, SPSR_fiq </p> </entry>
+</row>
+<row>
+<entry><p>10010 </p> </entry>
+<entry><p>IRQ </p> </entry>
+<entry><p>PC, R14_irq, R13_irq, R12-R0, CPSR, SPSR_irq </p> </entry>
+</row>
+<row>
+<entry><p>10011 </p> </entry>
+<entry><p>SVC </p> </entry>
+<entry><p>PC, R14_svc, R13_svc, R12-R0, CPSR, SPSR_sv </p> </entry>
+</row>
+<row>
+<entry><p>10111 </p> </entry>
+<entry><p>Abort </p> </entry>
+<entry><p>PC, R14_abt, R13_abt, R12-R0, CPSR, SPSR_abt </p> </entry>
+</row>
+<row>
+<entry><p>11011 </p> </entry>
+<entry><p>Undef </p> </entry>
+<entry><p>PC, R14_und, R13_und, R12-R0, CPSR, SPSR_und </p> </entry>
+</row>
+<row>
+<entry><p>11111 </p> </entry>
+<entry><p>System </p> </entry>
+<entry><p>PC, R14..R0, CPSR </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-80698E62-E310-59CA-A524-5CF44C437BE4.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-80698E62-E310-59CA-A524-5CF44C437BE4" xml:lang="en"><title>Base Starter</title><shortdesc>The Base Starter is a program that runs when the system starts.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> The program completes the initialization of the File Server, then starts
+the System Starter process. You must customize the Base Starter when you create
+a port of Symbian platform to a phone. To customize the Base Starter, you
+change the configuration files and the Base Starter source code. </p>
+<p>The Base Starter has often also been called EStart.</p>
+</conbody><related-links>
+<link href="GUID-F3BD37EC-0CCB-5859-908F-215E22C9FC20.dita#GUID-F3BD37EC-0CCB-5859-908F-215E22C9FC20/GUID-143780ED-4A23-5E72-A923-F605172EC8B5">
+<linktext>File   Server</linktext></link>
+<link href="GUID-AF30D941-BFD8-5260-9588-C5DA6983F558.dita"><linktext>System  
+Starter</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-80E0DB93-A96A-54A8-A201-E11935418BE7.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,236 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-80E0DB93-A96A-54A8-A201-E11935418BE7" xml:lang="en"><title>State
+Machines</title><shortdesc>Description of the structure and operation of state machines.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The MultiMediaCard Controller uses state machines to manage the interactions
+with the MultiMediaCard hardware. </p>
+<p>State machines allows the controller to maintain the state of each submitted
+session – allowing it to schedule a second session when the first becomes
+blocked, for example. </p>
+<p>To handle the complex sequence of bus operations involved, the controller
+implements a state machine stack, allowing a parent state machine function
+to invoke a child state machine function. The state machine stack allows nesting
+of children down to a depth of 10 levels. </p>
+<p>Each session object has its own individual state machine stack because
+each session runs its own sequence of bus operations, with the controller
+managing these multiple sequences. This means that each session object has
+a state machine object, an instance of the <xref href="GUID-022AC0FE-86EE-3908-A9F8-4A33D04A68A5.dita"><apiname>TMMCStateMachine</apiname></xref> class. </p>
+<fig id="GUID-3CD3F1EF-FB6A-5D5D-B806-75536F8DF533">
+<image href="GUID-4592D493-A47C-5622-8C03-F24FABB4381C_d0e19271_href.png" placement="inline"/>
+</fig>
+<p>The state machine remembers the next state and child function name, and
+moves to that state as soon as control returns to the session. </p>
+<p>The stack chooses the next session to be handled and manages the state
+machine through the state machine dispatcher. </p>
+<ul>
+<li id="GUID-76BEBC23-FC9D-5244-A3EA-2A5424FC02D7"><p> <xref href="GUID-80E0DB93-A96A-54A8-A201-E11935418BE7.dita#GUID-80E0DB93-A96A-54A8-A201-E11935418BE7/GUID-44473E52-82B4-55E7-AE85-15AC88CE5BEB">Structure of the state machine stack</xref> </p> </li>
+<li id="GUID-0A56A8B9-65D7-54CB-A584-8C3C9AEFE339"><p> <xref href="GUID-80E0DB93-A96A-54A8-A201-E11935418BE7.dita#GUID-80E0DB93-A96A-54A8-A201-E11935418BE7/GUID-E8FCFD65-4664-52EE-B658-FCABF50D501D">Structure of a state machine function</xref> </p> </li>
+<li id="GUID-85E36E04-60CD-5560-93DE-5C15E8DBDD45"><p> <xref href="GUID-80E0DB93-A96A-54A8-A201-E11935418BE7.dita#GUID-80E0DB93-A96A-54A8-A201-E11935418BE7/GUID-667C5A70-0ABB-525F-A309-58102E380400">Example of a state machine calling sequence</xref> </p> </li>
+</ul>
+<section id="GUID-44473E52-82B4-55E7-AE85-15AC88CE5BEB"><title>Structure of
+the state machine stack</title> <p>The stack itself is represented as an array
+of <xref href="GUID-DDCE8054-1656-34EF-9CBC-53C796BFD5A6.dita"><apiname>TMMCMachineStackEntry</apiname></xref> objects contained within the state
+machine object <xref href="GUID-022AC0FE-86EE-3908-A9F8-4A33D04A68A5.dita"><apiname>TMMCStateMachine</apiname></xref>. </p> <p>The state machine
+maintains a "pointer", <xref href="GUID-022AC0FE-86EE-3908-A9F8-4A33D04A68A5.dita#GUID-022AC0FE-86EE-3908-A9F8-4A33D04A68A5/GUID-5EC9B7D0-A3A9-35DF-A91D-65920372C9A4"><apiname>TMMCStateMachine::iSP</apiname></xref>, to the current
+state entry. This is not a true pointer, but just a value that indexes into
+the array. However, for all practical purposes it has the effect of a pointer.
+Each state entry in the stack is thought of as having a parent-child relationship
+with the other. </p> <p>Each state entry maintains three pieces of information: </p> <ul>
+<li id="GUID-81454E68-4603-5211-8F9F-70F0F2F4B95D"><p>A pointer to the state
+machine function. </p> </li>
+<li id="GUID-B20834EB-3EAE-5D79-8564-8B2A5490A057"><p>A variable containing
+the current state; the value and meaning of the state is defined by the state
+machine function. </p> </li>
+<li id="GUID-32AFB296-0D5F-5FF7-9ECD-C9F798E04542"><p>A bitmask of <xref href="GUID-FF4AB1CF-7A2C-3FC6-B123-D6819E1BCDCA.dita"><apiname>TMMCErr</apiname></xref> defined
+error conditions; these are set by the parent state machine function so that
+it gets the chance to trap those errors if the child state machine function
+returns those errors. Errors are propagated up the stack, and any error conditions
+not trapped at any level in the state machine hierarchy leads to the state
+machine terminating with that error value. </p> </li>
+</ul> <fig id="GUID-064C53DB-6A96-5C6D-B3CD-B40A0251EF66">
+<image href="GUID-D8911BE6-100D-588A-8E5C-A429A72AFCDA_d0e19356_href.png" placement="inline"/>
+</fig> <p>In general, the overall state of the state machine reflects the
+state of the current state entry; for example, <xref href="GUID-E32D6BC3-F8D9-3F7E-94F6-56633B645D6A.dita#GUID-E32D6BC3-F8D9-3F7E-94F6-56633B645D6A/GUID-48F37107-2D11-3550-890B-D79844A97DBF"><apiname>TMMCStatemachine::State()</apiname></xref> returns
+the state held in the current state entry. </p> <p>While the flow of control
+through a stack can be complex, the following diagram shows a short example
+snapshot. Here, the current state in the current stack entry is <codeph>Sn</codeph> and
+is handled by the function <codeph>PF()</codeph>. The code decides to pass
+control to the child function <codeph>CF()</codeph>, but ensures that, on
+completion, the next state in the current stack entry will be <codeph>Sn+1</codeph>. </p> <fig id="GUID-6ACBC49E-14EE-526B-A1A3-426B64BF8476">
+<image href="GUID-D2D41326-BA88-5A02-805B-5EAEC29ADB5D_d0e19383_href.png" placement="inline"/>
+</fig> <p>For example, the <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-F71A4421-2F9E-39FD-A352-97ECAAFE822D"><apiname>DMMCStack::CIMUpdateAcqSM()</apiname></xref> function
+implements the CIM_UPDATE_ACQ macro as defined by the <i>MultiMediaCard System
+Specification</i>, and is a typical state machine function. </p> <p>Most commands
+and macros involve one or more asynchronous operations and while such operations
+are outstanding, a session is blocked. While a session is blocked, its state
+machine dispatch function is not called. As soon an asynchronous event removes
+the blocking condition, control returns to the state machine. </p> </section>
+<section id="GUID-E8FCFD65-4664-52EE-B658-FCABF50D501D"><title>Structure of
+a state machine function</title> <p>State machine functions are defined and
+implemented in the <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita"><apiname>DMMCStack</apiname></xref> class in pairs: one as a static
+function, and the other as a member function. The static variant takes a <codeph>TAny*</codeph> pointer
+that is cast to a <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita"><apiname>DMMCStack</apiname></xref> pointer, and the <codeph>DMMCStack</codeph> member
+function is then called: </p> <codeblock id="GUID-F5EEA20F-2312-5394-84C4-5E568995291A" xml:space="preserve">TMMCErr DMMCStack::FunctionNameSMST( TAny* aPtr )
+    {
+    return( STATIC_CAST(DMMCStack*,aPtr)-&gt;FunctionNameSM() );
+    }
+</codeblock> <codeblock id="GUID-3C01127E-4EBA-59AC-91F8-1F004A74E45B" xml:space="preserve">TMMCErr DMMCStack::FunctionNameSM()
+    {
+    enum states {EStBegin=0, EStNext,…, EStEnd };    // Enumeration of states for this state machine
+    DMMCSession&amp; s = Session();
+
+    SMF_BEGIN
+    // State EStBegin
+    // Actions for state EStBegin
+
+    SMF_STATE( EStNext )
+    // State EStNext
+    // Actions for state EStNext
+
+    SMF_END
+    }
+</codeblock> <p>A state machine function can release control and wait to be
+re-entered by returning zero. If its session is not blocked then that will
+happen immediately. If the state machine function returns non-zero, the session
+will be completed with that error code unless the parent state machine function
+has explicitly intercepted such an error by setting the trap mask. </p> <ul>
+<li id="GUID-BEE3954A-733D-55CE-B09C-4B49304B44E1"><p> <xref href="GUID-80E0DB93-A96A-54A8-A201-E11935418BE7.dita#GUID-80E0DB93-A96A-54A8-A201-E11935418BE7/GUID-901D8456-F8D3-5E92-B3DA-EFE556D8C48B">Important points to note</xref> </p> </li>
+<li id="GUID-DA29FD1E-93EF-56C1-9650-8CE22B655897"><p> <xref href="GUID-80E0DB93-A96A-54A8-A201-E11935418BE7.dita#GUID-80E0DB93-A96A-54A8-A201-E11935418BE7/GUID-DBBA1450-AE5A-50E5-9B8C-F697CEFAD590">Blocking on an asynchronous request</xref> </p> </li>
+</ul> <p id="GUID-901D8456-F8D3-5E92-B3DA-EFE556D8C48B"><b>Important points to note</b> </p> <p>Each
+state machine function must define a list of states that can exist. States
+are defined as an enumeration whose first and last values <i>must</i> be labelled <codeph>EStBegin</codeph> and <codeph>EStEnd</codeph>,
+respectively. <codeph>EStBegin</codeph> must have the value zero. Any other
+intermediate states are program defined. </p> <p>To make the state machine
+functions more readable, a number of macros exist to help with the layout
+of the function code, and to control program flow. The most basic macros are <xref href="GUID-C095E583-3E71-31F3-B092-627357D72958.dita"><apiname>SMF_BEGIN</apiname></xref>, <xref href="GUID-38811BD9-F27C-3408-A04F-053314A2CF84.dita"><apiname>SMF_STATE</apiname></xref> and <xref href="GUID-C1089896-DD68-399C-BF34-2495C51A0CA1.dita"><apiname>SMF_END</apiname></xref> that expand into a switch statement. The above code expands
+to: </p> <codeblock id="GUID-16AE9141-5BE1-5B54-B083-7F60133DD018" xml:space="preserve">TMMCErr DMMCStack::FunctionNameSM()
+{
+enum states {EStBegin=0, EStNext,…, EStEnd };    // Enumeration of states for this state machine
+DMMCSession&amp; s = Session();
+
+TMMCStateMachine&amp; m = Machine();            //SMF_BEGIN
+const TMMCErr err = m.SetExitCode( 0 );        //SMF_BEGIN
+for(;;)                                        //SMF_BEGIN
+    {                                        //SMF_BEGIN
+    switch(m.State())                        //SMF_BEGIN
+        {                                    //SMF_BEGIN
+        case EStBegin:                        //SMF_BEGIN
+            {                                //SMF_BEGIN
+            if(err) (void)0;                //SMF_BEGIN 
+            // State EStBegin
+            // Actions for state EStBegin
+
+            }                                //SMF_STATE
+        case EStNext:                        //SMF_STATE
+            {                                //SMF_STATE
+            // State EStNext
+            // Actions for state EStNext
+
+        case EStEnd:                                                //SMF_END
+            break;                                                    //SMF_END
+            default:                                                //SMF_END
+            DMMCController::Panic(DMMCController::EMMCMachineState);//SMF_END
+        }                                                            //SMF_END
+        break;                                                        //SMF_END
+    }                                                                //SMF_END
+return(m.Pop());                                                    //SMF_END
+}</codeblock> <p>Notes: </p> <ul>
+<li id="GUID-7542D030-2641-5A15-A5AF-A02C491B24BB"><p>be aware that SMF_BEGIN
+generates an open curly bracket while SMF_STATE generates a corresponding
+close bracket, and SMF_END closes the switch statement. </p> </li>
+</ul> <p>You need to be aware of the code that is generated by these macros.
+In particular, some such as SMF_BEGIN generate an opening curly brace, while
+others such as SMF_STATE generate a corresponding close curly brace. Also,
+you need to know whether a macro generates a <codeph>break;</codeph> or a <codeph>return;</codeph> statement.
+Lack of awareness here may cause code to be generated that flows from one
+case statement to another, which may not be your intent. </p> <ul>
+<li id="GUID-7C57CF3E-0EB9-56A4-A07A-86027F5B42BA"><p> <xref href="GUID-C095E583-3E71-31F3-B092-627357D72958.dita"><apiname>SMF_BEGIN</apiname></xref> </p> </li>
+<li id="GUID-9A87EEA6-6D40-53E1-BCEE-F9A20C22D51D"><p> <xref href="GUID-C1089896-DD68-399C-BF34-2495C51A0CA1.dita"><apiname>SMF_END</apiname></xref> </p> </li>
+<li id="GUID-3ADD2CCB-4C83-54EC-80DB-3C8CFDDDCB7A"><p> <xref href="GUID-2BA7F4A7-ECB0-3839-809B-4C32D4F451BA.dita"><apiname>SMF_NEXTS</apiname></xref> </p> </li>
+<li id="GUID-41D972A7-18DE-5CE5-B0D6-039B0126199C"><p> <xref href="GUID-ACD776A5-5439-3BE9-8DD8-B537D8C2C637.dita"><apiname>SMF_CALL</apiname></xref> </p> </li>
+<li id="GUID-87C8FC8C-F810-5B3F-A7CC-99D6515F8F04"><p> <xref href="GUID-3802119E-0FC0-3B7C-9582-21563EC9AF61.dita"><apiname>SMF_CALLWAIT</apiname></xref> </p> </li>
+<li id="GUID-89669A58-5168-508A-AF9F-34C3347F0A69"><p> <xref href="GUID-2B6FA032-F8F9-3205-9CBB-EFB96691ACC9.dita"><apiname>SMF_CALLMYS</apiname></xref> </p> </li>
+<li id="GUID-A6C9952A-223E-5687-B67C-D89D50070BDB"><p> <xref href="GUID-C1D65C79-F781-3E22-AA73-F75BA2516F6F.dita"><apiname>SMF_CALLMEWR</apiname></xref> </p> </li>
+<li id="GUID-7FF0DFC9-D9DC-5E08-B668-4BC62B6E50EC"><p> <xref href="GUID-A143CA61-AA6B-3C5F-9E58-50BAF3786262.dita"><apiname>SMF_INVOKES</apiname></xref> </p> </li>
+<li id="GUID-F02BE381-0BA2-5E9D-AFB7-9064FBADC64C"><p> <xref href="GUID-A73CAEB2-2413-371E-A56F-2757C0723514.dita"><apiname>SMF_INVOKEWAITS</apiname></xref> </p> </li>
+<li id="GUID-A39E56F8-DE55-5EDE-A955-24E198026F39"><p> <xref href="GUID-94214574-2CCD-3BE4-ABD4-6A58328B29A2.dita"><apiname>SMF_WAIT</apiname></xref> </p> </li>
+<li id="GUID-1CB69F09-3BAC-5C41-B20E-5A2896C0E18E"><p> <xref href="GUID-33FBF199-09B8-32C3-BAD6-92D277722DB3.dita"><apiname>SMF_WAITS</apiname></xref> </p> </li>
+<li id="GUID-46D7BB96-3EC7-5207-BEE4-1E3ABB145D6B"><p> <xref href="GUID-B13D0665-AD49-348F-8795-67E8761B0BC8.dita"><apiname>SMF_RETURN</apiname></xref> </p> </li>
+<li id="GUID-A9A4DB91-2648-534D-BEA3-57A23147D750"><p> <xref href="GUID-2BA73A03-7379-394C-B9E8-4525316AF91F.dita"><apiname>SMF_EXIT</apiname></xref> </p> </li>
+<li id="GUID-E75E1BF0-CD8B-5EEA-98EA-13176AE0A308"><p> <xref href="GUID-57CF6330-1EA6-36A9-B2A1-2BB360B1E7FD.dita"><apiname>SMF_EXITWAIT</apiname></xref> </p> </li>
+<li id="GUID-D0617F39-4CF6-5FA7-995C-50688A82E703"><p> <xref href="GUID-6E9EF7EB-A9A2-3FA1-902D-188B4930927F.dita"><apiname>SMF_JUMP</apiname></xref> </p> </li>
+<li id="GUID-83791CBF-298A-5B5F-A9A0-8FB902AE81EB"><p> <xref href="GUID-85E63D6B-521B-309A-A1B1-18FDFCF626A0.dita"><apiname>SMF_JUMPWAIT</apiname></xref> </p> </li>
+<li id="GUID-F657F501-47AE-57D0-BEB6-A051176FC279"><p> <xref href="GUID-BF735A08-6E69-374F-8052-EF6CA101A3C3.dita"><apiname>SMF_GOTONEXTS</apiname></xref> </p> </li>
+<li id="GUID-F7D1B6D8-51A2-5C73-A709-1BB10CD27620"><p> <xref href="GUID-AA215584-34D9-36DA-A05A-8A4DF4636D5E.dita"><apiname>SMF_GOTOS</apiname></xref> </p> </li>
+<li id="GUID-042539CB-3019-57A2-B0AD-F1417756F842"><p> <xref href="GUID-38811BD9-F27C-3408-A04F-053314A2CF84.dita"><apiname>SMF_STATE</apiname></xref> </p> </li>
+<li id="GUID-ADD382E6-32C0-5773-8958-057F440C3FEC"><p> <xref href="GUID-11B9D102-4548-3321-8318-26E940273880.dita"><apiname>SMF_BPOINT</apiname></xref> </p> </li>
+</ul> <p id="GUID-DBBA1450-AE5A-50E5-9B8C-F697CEFAD590"><b> Blocking on an asynchronous
+request</b> </p> <p>The state machine can be made to block. This is done so
+that you can wait for an asynchronous operation to complete. When the operation
+completes, it unblocks the state machine. There are two stages to blocking
+a state machine: </p> <ul>
+<li id="GUID-544A1BE8-2896-5CEB-ADEB-4F63E26389C4"><p>Call <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-E7B38752-F9AB-3A66-8FB6-E321717A63B5"><apiname>DMMCStack::BlockCurrentSession()</apiname></xref> to
+indicate that the state machine associated with the current session is to
+be blocked </p> </li>
+<li id="GUID-BDB03808-C220-5518-B0E7-232845FD0AD6"><p>Execute one of the SMF_xxxWAIT
+macros to return from the current state machine function and wait. </p> </li>
+</ul> <p>Note that the state machine function <i>must</i> return by calling
+one of the SMF_xxxWAIT macros. It must not poll or sit in a loop! The state
+machines are not threaded, and this means that CPU time can only be given
+to other tasks if the function returns. </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-E7B38752-F9AB-3A66-8FB6-E321717A63B5"><apiname>DMMCStack::BlockCurrentSession()</apiname></xref> takes
+an argument describing the type of block. The state machine will only unblock
+when an unblock request with the matching argument is called. In the platform
+specific layer of the MultiMediaCard controller, you should always set the <xref href="GUID-8A9A2DD2-C630-3651-8374-17BCF2A09AC4.dita"><apiname>KMMCBlockOnASSPFunction</apiname></xref> bit
+in the argument passed to <codeph>BlockCurrentSession()</codeph>. </p> <p>To
+unblock the state machine, call <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-E1FEFAD3-CD02-38AF-8E45-41099192D583"><apiname>DMMCStack::UnBlockCurrentSession()</apiname></xref> setting
+the <xref href="GUID-8A9A2DD2-C630-3651-8374-17BCF2A09AC4.dita"><apiname>KMMCBlockOnASSPFunction</apiname></xref> bit in the flags argument passed
+to the function, and also an error code. This will invoke the state machine
+scheduler, which will re-start the state machine. </p> <p>Note that further
+state machine processing must take place in a DFC rather than within the interrupt
+service routine (ISR), and this can be forced by ORing the session status, <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita#GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A/GUID-252B39FE-C203-37AD-82A4-63E9BFFD3473"><apiname>DMMCSession::iState</apiname></xref>,
+with the <xref href="GUID-5CF9ED11-2F3A-3E9B-9BFF-87DBE261F097.dita"><apiname>KMMCSessStateDoDFC</apiname></xref> bit <i>before</i> unblocking
+the session. The bit has the effect of queueing a DFC to resume the state
+machine at some later stage, before returning to the ISR. </p> <p>The following
+code shows the idea: </p> <codeblock id="GUID-C4C8C8EA-4A16-5E9C-A64D-194D7D17403C" xml:space="preserve">TMMCErr DMMCStackAssp::DoSomethingSM()
+    {
+    enum states {EStBegin=0, EStDone,EStEnd };    // enumeration of states for this state machine
+
+    SMF_BEGIN
+    // start the asynchronous operation
+    BlockCurrentSession( KMMCBlockOnASSPFunction );
+    StartAsynchronousOp();
+
+    // block and wait. Go to state EStDone when the asynchronous op is complete
+    SMF_WAITS( EStDone );
+    
+    SMF_STATE( EStDone )
+    // operation is complete, check for errors and return from state machine
+    TInt errors = CheckForHardwareErrors();
+    SMF_RETURN( errors );
+
+    SMF_END
+    }
+</codeblock> <codeblock id="GUID-5CE18C2D-2780-5966-BC26-DD33D31BB5B3" xml:space="preserve">void TMMCInterrupt::Service( TAny* aParam )
+    {
+    Session().iState |= KMMCSessStateDoDFC;
+    UnBlockCurrentSession(KMMCBlockOnASSPFunction, KMMCErrNone);
+    }
+</codeblock> </section>
+<section id="GUID-667C5A70-0ABB-525F-A309-58102E380400"><title>Example of
+a state machine calling sequence</title> <p>This shows the state machine calling
+sequence that implements the reading of a single block on a MultiMediaCard,
+where the card is not yet selected. Note that the lowest level state machine
+function called is <codeph>IssueMMCCommandSM()</codeph>, which is implemented
+by the base port. </p> <fig id="GUID-A67E1B8E-322A-5AC8-9EEA-AC24C8868E81">
+<image href="GUID-A51C3E48-3ED0-519B-A128-C5175D7E175B_d0e19782_href.png" placement="inline"/>
+</fig> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-812DEBEB-84D0-5BD4-A5BB-5AF6B8384CCF.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,47 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-812DEBEB-84D0-5BD4-A5BB-5AF6B8384CCF" xml:lang="en"><title>Entry
+Point Implementation</title><shortdesc>Describes how to implement the entry point function.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The DMA Framework implements its entry point function in the platform-specific
+layer. </p>
+<p>The entry point for a kernel extension is declared by a </p>
+<codeblock id="GUID-92670D2D-AB81-5BEA-8008-5BA7B0D23EF6" xml:space="preserve">DECLARE_STANDARD_EXTENSION()</codeblock>
+<p>statement, followed by the block of code that runs on entry to the DLL.
+The following code is typical for a port of the DMA Framework , and is taken
+from the port for the template reference platform: </p>
+<codeblock id="GUID-ED426309-D8FC-512C-B320-C29B37C74140" xml:space="preserve">DECLARE_STANDARD_EXTENSION()
+//
+// Creates and initializes a new DMA controller object on the kernel heap.
+//
+    {
+    __KTRACE_OPT2(KBOOT, KDMA, Kern::Printf("Starting DMA Extension"));
+
+    return Controller.Create();
+    }
+</codeblock>
+<p>where <codeph>Controller</codeph> is declared as writable static data: </p>
+<codeblock id="GUID-DA2508CF-BB22-5A48-B549-63D973E9EDB7" xml:space="preserve">static TTemplateDmac Controller;</codeblock>
+<p>Create() is a second-phase constructor defined in, and implemented by,
+the concrete class derived from <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref>. DMA channels are
+attributes of this concrete class because only the platform specific layer
+knows what kind of channel to use. This platform specific layer second phase
+constructor must call the platform independent layer second phase constructor, <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-9B0C8C35-F149-3358-90B8-B4670CFE888F"><apiname>TDmac::Create()</apiname></xref>,
+before doing anything else. </p>
+<p> <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-9B0C8C35-F149-3358-90B8-B4670CFE888F"><apiname>TDmac::Create()</apiname></xref> allocates the arrays containing the
+descriptors and descriptor headers using the information passed to it by the
+platform specific layer in the <xref href="GUID-4057074E-2543-3F01-B24A-7FF8A19F79AF.dita"><apiname>SCreateInfo</apiname></xref> struct. This
+includes information such as the number of descriptors to be allocated, whether
+hardware descriptors are supported and their size etc. </p>
+<p>Note that if hardware-specific descriptors are used, they are allocated
+in a hardware chunk. If pseudo-descriptors are used, they are allocated on
+the kernel heap. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-817E0561-6165-5BB1-97F9-AD53CFCDAA56.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,117 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-817E0561-6165-5BB1-97F9-AD53CFCDAA56" xml:lang="en"><title>Impact
+of Data Paging on Kernel-side Code Guide</title><shortdesc>Describes the kernel-side issues that must be considered when writing
+device drivers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-C02ED166-914C-4397-9701-3DFA12BB035F"><title>Purpose</title> <p>This document explains the impact of data
+paging on kernel side code. </p> <p><b>Intended
+Audience:</b> </p> <p>This document is intended for device driver writers. </p> </section>
+<section id="GUID-8B038641-159E-4029-AEA7-952B9F598616"><title>Access to user memory</title> <p>New restrictions on access
+to user memory. </p> </section>
+<section id="GUID-EDAC178D-6B98-4BC2-B9F5-0EB0846702F5"><title>Access to current thread's address space</title> <p>Certain
+exported and internal APIs access the address space of the current thread
+and are subject to restrictions on their use enforced by assertions in the
+code. The restrictions are these: </p> <ul>
+<li id="GUID-BDB0D784-562F-5AE6-A291-A738682C2A53"><p>The APIs may only be
+called from thread context. </p> </li>
+<li id="GUID-37A31C92-C9C7-539F-86B5-066A09D2F53B"><p>They may not be called
+while any mutexes are held. There are two particularly important cases when
+mutexes are often held: </p> <ul>
+<li id="GUID-D8F89EF4-854C-5096-9E52-FA7989C423D3"><p>When publish and subscribe
+is writing large binary properties to user space, and </p> <ul>
+<li id="GUID-9E7C39C8-D1DF-53B4-9596-5E7E6CB1C906"><p>When the multiple memory
+model writes code segments' export directories to user space. </p> </li>
+</ul> </li>
+</ul> </li>
+<li id="GUID-E900614E-D99F-5401-B570-A792300D0E6A"><p>The APIs may not be
+called when the system lock is held. There are two particularly important
+cases when the system lock is often held: </p> <ul>
+<li id="GUID-41D35D8E-1ABC-54A4-9985-F551ACAD4F28"><p>When publish and subscribe
+is writing large binary properties to user space, and </p> </li>
+<li id="GUID-06705F28-00F9-5BBE-A3EF-FC79E4849908"><p>When the multiple memory
+model uses <xref href="GUID-38D1534C-AA01-33AF-9937-CDD818A85F97.dita#GUID-38D1534C-AA01-33AF-9937-CDD818A85F97/GUID-99ECF4EB-8BCD-3968-BDED-E37E41753BEF"><apiname>DThread::FastWrite</apiname></xref> to write to user space. </p> </li>
+</ul> </li>
+</ul> <p>The APIs concerned are these: </p> <ul>
+<li id="GUID-1C237BE6-900B-5F88-B081-140030E42894"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-C154A151-0DF7-345D-9A10-E9B1CF3400D9"><apiname>Kern::KUDesInfo</apiname></xref>  </p> </li>
+<li id="GUID-EC004C04-A5D0-5A52-90BA-56A0DE140A8A"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-B79007D0-FF1F-30E7-986D-7CEBC5E45102"><apiname>Kern::KUDesGet</apiname></xref>  </p> </li>
+<li id="GUID-D5D3D6C4-BB4B-55B1-99B9-000F716C2964"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-CDEA7B22-9520-3DB1-AA04-1289C2287936"><apiname>Kern::KUDesPut</apiname></xref>  </p> </li>
+<li id="GUID-1C330912-EAAC-5020-94F8-89AD09387E42"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-94F2DF65-87A5-32C6-9695-9557E5832ACF"><apiname>Kern::KUDesSetLength</apiname></xref>  </p> </li>
+<li id="GUID-C59D5CDD-06B4-5931-BE86-E3F5727B456D"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-FAFAA120-AA28-32FD-9202-1534C3148026"><apiname>Kern::InfoCopy</apiname></xref>  </p> </li>
+<li id="GUID-A93205E5-2BBF-568A-84C1-FA95BA8A5EBC"><p> <xref href="GUID-F5136CAF-B66F-388D-A610-D0153CAF7E23.dita"><apiname>umemget()</apiname></xref>, <xref href="GUID-B56A34CD-E5B5-3E3E-A2EE-3BC9D248B210.dita"><apiname>kumemget()</apiname></xref>, <xref href="GUID-B55573FC-B21C-384A-8B1E-A6A4301310E9.dita"><apiname>umemget32()</apiname></xref>, <xref href="GUID-15B62FF1-5D59-3A84-9648-EB0DBFE17232.dita"><apiname>kumemget32()</apiname></xref>  </p> </li>
+<li id="GUID-C4FCA083-9C65-5F24-B65C-0C8B62A9E89E"><p> <xref href="GUID-371860F0-36BF-340D-BEF6-1763EF9874AE.dita"><apiname>umemput()</apiname></xref>, <xref href="GUID-C7AB0391-99D5-31A2-91D4-A7F195546FC3.dita"><apiname>kumemput()</apiname></xref>, <xref href="GUID-B2DF3520-01CE-3D2C-8137-746ADBCBAE80.dita"><apiname>umemput32()</apiname></xref>, <xref href="GUID-D141C3C4-F2F6-37DF-BDF6-63DDE9052FA0.dita"><apiname>kumemput32()</apiname></xref>  </p> </li>
+<li id="GUID-93854B1F-3593-56FA-992B-D9965958FC17"><p> <xref href="GUID-16048974-7407-3778-9BD3-B8417E3F795A.dita"><apiname>umemset()</apiname></xref>, <xref href="GUID-B51F91FF-E5CD-3D5F-8BB3-B18E58761B62.dita"><apiname>kumemset()</apiname></xref>  </p> </li>
+<li id="GUID-2099129C-21A4-504F-BD33-9B1F3C84ECCE"><p> <xref href="GUID-A9CDD270-DDEB-3E58-9A31-2567985958DB.dita"><apiname>SafeRead()</apiname></xref>, <xref href="GUID-FE09CB97-F853-3939-ADB1-2FBE4EDF50CE.dita"><apiname>KUSafeRead()</apiname></xref>  </p> </li>
+<li id="GUID-24C2001F-2759-566C-B7C1-7CA677123C6F"><p> <xref href="GUID-97393047-A896-3F93-90CE-9C30BF19AF10.dita"><apiname>SafeWrite()</apiname></xref>, <xref href="GUID-145B354F-1F60-3A1B-8FA3-E873C6D133A5.dita"><apiname>KUSafeWrite()</apiname></xref>  </p> </li>
+<li id="GUID-85EE234D-34BA-542B-B43F-E178DECA1CFD"><p> <xref href="GUID-7463E352-F6CE-3749-902A-0F3D9C699ADF.dita"><apiname>KUSafeInc()</apiname></xref>  </p> </li>
+<li id="GUID-26D29EEE-7FC6-556B-BCC0-27F0011B926A"><p> <xref href="GUID-7C924E07-84AD-36AC-A6D0-09C47A170FFC.dita"><apiname>KUSafeDec()</apiname></xref>  </p> </li>
+</ul> </section>
+<section id="GUID-6487F5DB-DB07-458C-A97D-9D26BBC35E0A"><title>Access to another thread's address space</title> <p>Certain
+exported and internal APIs access the address space of another thread and
+are subject to restrictions on their use enforced by assertions in the code.
+The restrictions are these: </p> <ul>
+<li id="GUID-38E41386-9179-500D-92BB-043042E3C957"><p>The APIs may not be
+called when any mutexes are held. One particularly important case of this
+is when undertakers are completed and handles written to user space. </p> </li>
+</ul> <p>The APIs concerned are these: </p> <ul>
+<li id="GUID-76DF8E52-6330-5549-A10F-810FFC1236BC"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-904A42A8-8077-3FC6-BEF2-29619F079842"><apiname>Kern::ThreadRawRead()</apiname></xref>  </p> </li>
+<li id="GUID-DFD8AEC8-172E-582E-9AC2-742F3C538B16"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-182C88F4-326C-376E-9FBE-889E3CB9B68A"><apiname>Kern::ThreadRawWrite()</apiname></xref>  </p> </li>
+<li id="GUID-A4826184-4CDD-5339-9971-AE1894B3678E"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-C505206F-F54F-3760-BA7D-2DB52AB4E0B3"><apiname>Kern::ThreadDesRead()</apiname></xref>  </p> </li>
+<li id="GUID-73B032E1-8733-5E59-8028-812179CE2A81"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-FA321582-6D75-37A1-8DAB-D50638F76593"><apiname>Kern::ThreadDesWrite()</apiname></xref>  </p> </li>
+<li id="GUID-FD22484A-2418-5A1D-A68A-27090623085D"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-1DE210A5-B7A2-3F52-9003-439CA3DD4715"><apiname>Kern::ThreadGetDesLength()</apiname></xref>  </p> </li>
+<li id="GUID-CA931109-D50C-580A-9A0B-770355FA24C0"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-A5E20DB7-9DB4-350C-B636-95E2148DCC6F"><apiname>Kern::ThreadGetDesMaxLength()</apiname></xref>  </p> </li>
+<li id="GUID-AE500BC7-A230-5EE5-BA7F-643A47DEEFB9"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-22DD7D90-B4B5-3450-82BF-C3CC3A43430A"><apiname>Kern::ThreadGetDesInfo()</apiname></xref>  </p> </li>
+<li id="GUID-D2287795-C6BA-5746-87B5-E2260A1389AB"><p> <xref href="GUID-38D1534C-AA01-33AF-9937-CDD818A85F97.dita#GUID-38D1534C-AA01-33AF-9937-CDD818A85F97/GUID-876D7459-E09E-33B7-A35D-48A96F9E78C8"><apiname>DThread::FastWrite()</apiname></xref>  </p> </li>
+</ul> </section>
+<section id="GUID-CF741107-AEC0-4CAD-9F59-BD4EC8C7BA26"><title>Client request completion</title> <p>In non-paged code it
+is usual for a thread to have an asynchronous request outstanding and to complete
+it by calling <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-D720BB4C-5E31-3213-BB16-859AA325FE98"><apiname>Kern::RequestComplete()</apiname></xref>. This technique is
+not safe in data paged code as it involves writing a status value back into
+the thread's address space, but this memory might be paged out and violate
+the thread's performance guarantees or cause a mutex order violation. </p> <p>Instead,
+you should use the <xref href="GUID-4CB67E92-6092-316B-BBDC-B428F4242A76.dita"><apiname>TClientRequest</apiname></xref> object to write the request
+status within the context of the client thread in the following way. </p> <ol id="GUID-2379DB5B-9E06-56D4-A561-C55E77A5A570">
+<li id="GUID-A74F8DB4-154B-5CC3-980E-6A248819BB08"><p>Create a <xref href="GUID-4CB67E92-6092-316B-BBDC-B428F4242A76.dita"><apiname>TClientRequest</apiname></xref> object
+by calling <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-C526F279-6BCF-3373-A869-37DB22695809"><apiname>Kern::CreateClientRequest()</apiname></xref>. </p> </li>
+<li id="GUID-1B09ED45-55C2-5A57-8921-FD8FFE10819F"><p>Call the <xref href="GUID-E0687C90-7742-3C5C-96EF-187415584E31.dita"><apiname>SetStatus()</apiname></xref> function
+of the <xref href="GUID-4CB67E92-6092-316B-BBDC-B428F4242A76.dita"><apiname>TClientRequest</apiname></xref> object to set the client's request
+status. </p> </li>
+<li id="GUID-5A047136-5848-5F43-A88A-E0BF9625BFEE"><p>Call <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-DE0CF5BD-B166-3C5B-9E27-F95710322F21"><apiname>Kern::QueueRequestComplete()</apiname></xref> to
+signal the client thread that the request has been queued for completion. </p> </li>
+<li id="GUID-F481D0FF-6A8F-5462-97C9-DCA9EABB1E25"><p>When the client thread
+next runs, the <xref href="GUID-E0B34F3E-D4C4-3232-B8B1-7DB35B454646.dita"><apiname>TRequestStatus</apiname></xref> value is written back to
+it. </p> </li>
+<li id="GUID-A37194A0-599A-584E-BD38-333B0E5DFD70"><p>The <xref href="GUID-E0B34F3E-D4C4-3232-B8B1-7DB35B454646.dita"><apiname>TRequestStatus</apiname></xref> can
+now be reused, or destroyed by a call to <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-A67030E5-B84C-3CFF-B0B9-68F2F0E488A6"><apiname>Kern::DestroyRequest()</apiname></xref>. </p> </li>
+</ol> </section>
+<section id="GUID-4E440670-4ED5-4BA8-81A2-3A260EDDDFD1"><title>IPC message delivery</title> <p>In non-paged code it is common
+for a client thread to send a message to a server and write it into the address
+space of the server. When data paging is enabled, this creates the same risk
+of page faults as the completion of asynchronous requests and can be mitigated
+by the same techniques as above. In addition, descriptor information (type,
+length and maximum length) is read by temporarily switching to the client's
+address space, creating additional risk of page faults. </p> <p>When data
+paging is enabled, messages to servers must be pre-parsed and their type,
+length and maximum length stored in the message structure. This involves change
+to the kernel code but does not impact on user-side code. </p> </section>
+<section id="GUID-2727EA5C-0820-4DA4-BEC8-E6E830919A63"><title>Kernel event queue</title> <p>The kernel maintains a queue
+of user-input events which is read by the window server. The introduction
+of data paging involved a change to the kernel code which responds to the
+user-side API <xref href="GUID-8BB2609C-5F76-3B47-AA9E-1453F8F2AD55.dita#GUID-8BB2609C-5F76-3B47-AA9E-1453F8F2AD55/GUID-D3526836-5EB4-3EBC-87FF-B0DD2E74CAF3"><apiname>UserSver::RequestEvent()</apiname></xref>. No change to user-side
+code is involved. </p> </section>
+</conbody><related-links>
+<link href="GUID-E21E7992-607A-5A49-B022-189ECA9E76D1.dita"><linktext>Code Paging
+Overview</linktext></link>
+<link href="GUID-BDB847A2-557A-5902-AA6D-C1AE10D8E493.dita"><linktext>Code Paging
+Guide</linktext></link>
+<link href="GUID-B35A70D2-1BC8-51DE-95BF-F315DB394582.dita"><linktext>Demand Paging
+Overview</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-81C69779-27AE-55E0-ACCF-E4F3E6657427.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-81C69779-27AE-55E0-ACCF-E4F3E6657427" xml:lang="en"><title>Concepts</title><shortdesc> describes the technology, architecture, and behaviour of the DMA
+Framework. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/><related-links>
+<link href="GUID-3F47E907-975A-5739-9B03-042CB90D675D.dita"><linktext>Port Implementation
+  Tutorial</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-81DD805C-90B5-5227-B62B-F2413855BD9A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-81DD805C-90B5-5227-B62B-F2413855BD9A" xml:lang="en"><title>LCD Extension Reference</title><shortdesc>This topic provides a summary of related documentation
+for the LCD Extension to which you can refer. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-33192330-84D6-5A53-AF6E-CA213B3A632F"><title>API
+Reference</title> <p><b>Kernel Architecture </b> </p> <table id="GUID-D8D192FC-9E29-5809-9828-05CE90294D07">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Item</b>  </p> </entry>
+<entry><p> <b>Header</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-05C7D9A2-630F-339B-B4E1-45E38FF3B941.dita"><apiname>SRectOpInfo</apiname></xref>  </p> </entry>
+<entry><p> <filepath>videodriver.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C4712A78-6C58-39ED-AF84-11038DB8571D.dita"><apiname>TVideoInfoV01</apiname></xref>  </p> </entry>
+<entry><p> <filepath>videodriver.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-40C5D7F4-48E8-35A7-8329-380AAF14070A.dita"><apiname>TVideoInfoV01Buf</apiname></xref>  </p> </entry>
+<entry><p> <filepath>videodriver.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-BB011D9B-105F-345C-9FC0-39B0BA509394.dita"><apiname>TDisplayHalFunction</apiname></xref>  </p> </entry>
+<entry><p> <filepath>u32hal.h</filepath>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+</conbody><related-links>
+<link href="GUID-0C3A4156-E5CF-55F9-91A0-A7961FDEE030.dita"><linktext>LCD
+Extension Architecture</linktext></link>
+<link href="GUID-8DF46A11-874A-52E5-9298-C083EA633BA0.dita"><linktext>Implementing
+Dynamic DSA Allocation</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-834781AF-D202-5752-B81A-A51D12A4D1EC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-834781AF-D202-5752-B81A-A51D12A4D1EC" xml:lang="en"><title> Code Organisation</title><shortdesc>This topic describes the USB Client Driver code.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This topic describes the USB Client Driver code that Symbian platform
+provides. </p>
+<p>USB client driver LDD: </p>
+<ul>
+<li id="GUID-DDF56973-A6D9-5698-8B2D-39D3D47689C4"><p>is implemented
+in <filepath>USBC.LDD</filepath>  </p> </li>
+<li id="GUID-08689166-0432-5E2E-B8EF-2EDD78DE8EAD"><p>has its source
+code located in <filepath>...\e32\drivers\usbc\d_usbc.cpp</filepath>  </p> </li>
+<li id="GUID-6599A2F7-0D77-563F-AB18-7276984E61D8"><p>has its project
+file located in <filepath>...\e32\drivers\usbc\usbc.mmp</filepath>. </p> </li>
+</ul>
+<p>USB client controller PDD: </p>
+<ul>
+<li id="GUID-351F33E5-752B-5A48-85F5-2F5447F38ED4"><p>The interface <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita"><apiname>DUsbClientController</apiname></xref> is defined in <filepath>...\e32\include\drivers\usbc.h</filepath>. </p> </li>
+</ul>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-84D56A30-1E97-40AE-BFB0-E33495E95AAC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-84D56A30-1E97-40AE-BFB0-E33495E95AAC" xml:lang="en"><title>Base Porting Details</title><shortdesc>Describes the base port implementation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This is a section that contains the detail for specific porting
+activities. You will normally access this material via links from
+the section on the <xref href="GUID-5CCF303A-B7D5-570D-9BE8-29DFBE184995.dita">Porting Overview</xref>. However, this is a good place
+to look if you need to review specific activities. </p>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-85332468-292D-589B-891B-0E7ACBADC7BA-master.png has changed
Binary file Adaptation/GUID-85332468-292D-589B-891B-0E7ACBADC7BA_d0e11000_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-8552E66E-73D6-51DA-8F53-DDF437186CD6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-8552E66E-73D6-51DA-8F53-DDF437186CD6" xml:lang="en"><title>Validation</title><shortdesc>Describes the DMA test code to validate the port of DMA framework.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The same set of source code is used to build two different DMA test harnesses: </p>
+<ol id="GUID-57C2BE90-6771-5C69-804F-CC08AEB43E88">
+<li id="GUID-778D3856-4605-5156-826F-9B4FCEC296CE"><p>It builds: <filepath>T_DMASIM.EXE</filepath>, <filepath>D_DMASIM.LDD</filepath>,
+and <filepath>DMASIM.DLL</filepath>. This is a software-simulated implementation
+of DMA. This harness is used mainly for debugging and validating the PIL (platform-independent
+layer) as it simulates every kind of DMA controller. The DMA simulator and
+associated PSL (platform-specific layer) is in <filepath>...\e32test\dma\dmasim.cpp</filepath>. </p> </li>
+<li id="GUID-69027EF2-66D9-56C3-B63C-269D729382D5"><p>It builds: <filepath>T_DMA.EXE</filepath>, <filepath>D_DMA.LDD</filepath>.
+The source code for building these executables is in <filepath>...\e32test\dma\t_dma.cpp</filepath> and <filepath>...\e32test\dma\d_dma.cpp</filepath> respectively </p> </li>
+</ol>
+<p> <filepath>T_DMA.EXE</filepath> is a user-side harness, and is an automatic
+test included in the E32TEST suite. It assumes that the underlying DMA controller
+supports memory to memory transfers. This executable delegates most of the
+work to D_DMA.LDD (built from base\e32test\dma\d_dma.cpp), a logical device
+driver that acts as a client for the DMA Framework. D_DMA.LDD links statically
+against DMA.DLL, the DMA Framework kernel extension and as such must be built
+from the variant. </p>
+<p> <filepath>T_DMA.EXE</filepath> delegates most of the work to <filepath>D_DMA.LDD</filepath>,
+which is a logical device driver that acts as a client for the DMA Framework. <filepath>D_DMA.LDD</filepath> links
+statically against <filepath>DMA.DLL</filepath>, the DMA Framework kernel
+extension, and as such must be built from the variant. In practice, this means
+that <filepath>D_DMA.LDD</filepath> must be specified in the test <filepath>bld.inf</filepath> for
+the variant being ported. See <filepath>...\template_variant\test\bld.inf</filepath> for
+an example. </p>
+<p> <filepath>D_DMA.LDD</filepath> calls the <codeph>DmaTestInfo()</codeph> function
+in the PSL to discover the capacities of the PSL: number of channels, maximum
+transfer size, etc. This is the template implementation: </p>
+<codeblock id="GUID-AB52EDB6-B76A-5362-B8F6-64DBF7E39460" xml:space="preserve">TDmaTestInfo TestInfo =
+    {
+    0,
+    0,
+    0,
+    0,
+    NULL,
+    0,
+    NULL,
+    0,
+    NULL
+    };
+
+</codeblock>
+<codeblock id="GUID-8A365AA3-9D88-5A62-9DE8-F5D7DFDEBAC4" xml:space="preserve">EXPORT_C const TDmaTestInfo&amp; DmaTestInfo()
+//
+//
+//
+    {
+    return TestInfo;
+    }
+
+</codeblock>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-857F981E-711B-5CA8-AB37-5C700A6140FA.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,93 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-857F981E-711B-5CA8-AB37-5C700A6140FA" xml:lang="en"><title>HAL Groups
+and Handlers</title><shortdesc> List of HAL groups and the location of their associated handlers. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Some of the handlers are part of Symbian platform generic code and do not
+require porting.</p>
+<table id="GUID-EE794194-6D85-5EBB-89AE-C7725B637E9F">
+<tgroup cols="4"><colspec colname="col0"/><colspec colname="col1"/><colspec colname="col2"/><colspec colname="col3"/>
+<tbody>
+<row>
+<entry><p> <b>HAL group</b>  </p> </entry>
+<entry><p> <b>Location</b>  </p> </entry>
+<entry><p> <b>Customizable?</b>  </p> </entry>
+<entry><p> <b>Explicit registration required?</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-D60C5503-A176-354A-A655-22BE371178AE.dita"><apiname>EHalGroupVariant</apiname></xref>  </p> </entry>
+<entry><p>Variant </p> </entry>
+<entry><p>Yes. It needs to be implemented as the <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita#GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D/GUID-825726CE-F200-3E26-B2F2-4C756BB45B1B"><apiname>Asic::VariantHal()</apiname></xref> function
+defined by the <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita"><apiname>Asic</apiname></xref> class. </p> <p>See the template port: <filepath>...\template\template_variant\specific\variant.cpp</filepath>  </p> </entry>
+<entry><p>No. It is done automatically as part of the kernel initialization. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-FB85CE22-DDFF-37E6-A6CE-7F70A994D371.dita"><apiname>EHalGroupPower</apiname></xref>  </p> </entry>
+<entry><p>Power model </p> </entry>
+<entry><p>Yes. It needs to be implemented when implementing the power model. </p> <p>See
+the template port: <filepath>...\template\template_variant\specific\power.cpp</filepath>  </p> </entry>
+<entry><p>No. It is done automatically as part of the kernel initialization. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-7F299BFC-D8A5-3A5A-B8DA-39BF42C99DC6.dita"><apiname>EHalGroupDisplay</apiname></xref>  </p> </entry>
+<entry><p>LCD driver </p> </entry>
+<entry><p>Yes, when porting the LCD driver. </p> <p>See the template port: <filepath>...\template\template_variant\specific\lcd.cpp</filepath>. </p> </entry>
+<entry><p>Yes, during initialization of the driver. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-E22F7F41-C578-36B4-A7AB-AE0AEF520A69.dita"><apiname>EHalGroupDigitiser</apiname></xref>  </p> </entry>
+<entry><p>Digitiser </p> </entry>
+<entry><p>Yes, when porting the digitiser. </p> <p>See the template port: <filepath>...\template\template_variant\specific\xyin.cpp</filepath>. </p> </entry>
+<entry><p>Yes, during initialization of the driver. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-7B4133F2-3BDC-3388-AC63-CD0EC6F73917.dita"><apiname>EHalGroupKeyboard</apiname></xref>  </p> </entry>
+<entry><p>Keyboard driver </p> </entry>
+<entry><p>Yes, when porting the keyboard driver. </p> <p>See the template
+port: <filepath>...\template\template_variant\specific\keyboard.cpp</filepath>. </p> </entry>
+<entry><p>Yes, during initialization of the driver. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-F10DCE1F-756C-318D-B0D1-8C8F5255959E.dita"><apiname>EHalGroupKernel</apiname></xref>  </p> </entry>
+<entry><p>Kernel </p> </entry>
+<entry><p>No. It is part of Symbian platform generic code. </p> </entry>
+<entry><p>No. It is done automatically as part of the kernel initialization. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-48EEA57D-56A8-3C5E-8DF0-75C051D86EAE.dita"><apiname>EHalGroupMedia</apiname></xref>  </p> </entry>
+<entry><p>Media Driver </p> </entry>
+<entry><p>No. This is in the media driver LDD; this is a kernel extension
+and is implemented by Symbian platform. </p> </entry>
+<entry><p>Yes, during initialization of the driver/extension. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B510C3F5-E11A-3107-B972-7FDEDB445BBA.dita"><apiname>EHalGroupEmulator</apiname></xref>  </p> </entry>
+<entry><p>Emulator </p> </entry>
+<entry><p>No. The emulator is a port of Symbian platform maintained by Symbian. </p> </entry>
+<entry><p>Yes, during 3rd phase initialization of the emulator variant. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-E0A646D1-9EF3-30E3-BB91-11318C0DEC47.dita"><apiname>EHalGroupSound</apiname></xref>  </p> </entry>
+<entry><p>Sound driver </p> </entry>
+<entry><p>Unlikely—the only example is in the sound driver maintained for
+backwards compatibility with pre-Symbian hardware. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-537AA230-18EF-3CDC-B708-CF3BE13AF34A.dita"><apiname>EHalGroupMouse</apiname></xref>  </p> </entry>
+<entry><p>Emulator </p> </entry>
+<entry><p>Unlikely—the only example is in the emulator, which is a port of
+Symbian platform maintained by Symbian. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table></conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-85C18DAF-DB76-51C6-B38D-A802E314F4D1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,159 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE task
+  PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
+<task id="GUID-85C18DAF-DB76-51C6-B38D-A802E314F4D1" xml:lang="en"><title>Performance
+Guarantee Tutorial </title><shortdesc>Describes how to maintain performance guarantees when writing a
+software package on a data paged platform. </shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody>
+<context id="GUID-067EBD71-74FF-5C3C-BBFE-792895383980"><p>Data paging can
+affect performance guarantees. When writing software for a data paged platform,
+you need to perform an impact assessment on the components of your application.
+To do so, you perform the following analyses and implement the appropriate
+mitigation for the impacts you discover: </p> <ul>
+<li id="GUID-902266C8-BC97-5C0A-9C61-13F252CE3DC8"><p>Static analysis, </p> </li>
+<li id="GUID-70E2A254-1799-5A1E-A440-6E7F30EC3337"><p>Use case analysis, and </p> </li>
+<li id="GUID-B5A5134E-CD51-59BA-9F05-0DFA2E200660"><p>IPC analysis. </p> </li>
+</ul> </context>
+<steps-unordered id="GUID-5AECEB9A-F5AC-5D72-A216-F31C8E024453">
+<step id="GUID-B5C885F6-8703-5E43-8979-72A2D11007AB"><cmd>Perform a static
+analysis of the impact of data paging on your code. </cmd>
+<substeps id="GUID-31FA74DF-5D4D-5DE5-96D4-A1978187E40D">
+<substep id="GUID-C9722F09-D534-5CC3-AC25-238C0C101DC7"><cmd/>
+<info>List all the executables in your package, indicating their size and
+pageability. </info>
+</substep>
+<substep id="GUID-6193E0A0-AFB1-5641-973F-0D27F721983F"><cmd/>
+<info>For each item in the list identify its static dependencies, indicating
+their size and pageability. </info>
+</substep>
+<substep id="GUID-509636D1-3B7C-546D-8EC4-A7AE515B904E"><cmd/>
+<stepxmp>For each item in the list identify its dynamic dependencies, indicating
+their size and pageability. </stepxmp>
+<info>For instance, note whether the component is a plug-in to a framework
+or is itself a framework. </info>
+</substep>
+</substeps>
+<stepresult>The purpose of collecting this information is to identify which
+executables are most likely to be impacted by data paging. </stepresult>
+</step>
+<step id="GUID-469BB5C7-9BC7-5E3B-9717-B5558D2F6859"><cmd>Perform a use case
+analysis of the impact of data paging on your code. It is good practice to
+distinguish between use cases involving real time and performance critical
+performance guarantees. You do not need to cover use cases which do not involve
+guarantees of this kind. </cmd>
+<substeps id="GUID-CC4B31C6-85B3-53FA-AEB1-4713B0F7E51C">
+<substep id="GUID-4251C5AC-9F23-5850-A9C3-E086B00E45D9"><cmd>List all the
+use cases for the component which involve real time performance guarantees. </cmd>
+<info>Real time use cases are those having very strict response time guarantees
+and also those involving an acceptable user perception of behaviour. </info>
+<info><ul>
+<li id="GUID-F24C5888-773A-5F17-911F-1424D5381616"><p>Video playback, </p> </li>
+<li id="GUID-2C9B272C-265A-5A82-B9A0-A0CB5D2CC165"><p>VoIP phone calls, and </p> </li>
+<li id="GUID-20D52A34-F21E-565E-9698-8E0A169B7E3F"><p>File download over USB. </p> </li>
+</ul> </info>
+<stepresult>Examples of use cases involving acceptable user perception are: </stepresult>
+</substep>
+<substep id="GUID-702A77F3-ACE4-5047-825E-267747AF4E70"><cmd>List all the
+use cases for the component which involve performance critical guarantees.
+This means the bench-marked use cases by which the performance of the operating
+system is measure. </cmd>
+<stepxmp>Examples of use cases having a strict response time are: </stepxmp>
+<info><ul>
+<li id="GUID-C2CAE80F-F20F-5464-9A5D-77858D26572C"><p>Standard boot time, </p> </li>
+<li id="GUID-379EF955-B1D2-5A4F-A9CA-295BCDA6D84C"><p>Application start-up
+time, and </p> </li>
+<li id="GUID-5111E2E5-9411-5BD6-BC60-B1E64A3DBE57"><p>Camera image capture
+time. </p> </li>
+</ul> </info>
+</substep>
+<substep id="GUID-C6089DA1-C2A8-5D57-8F1C-B5D94D01CD31"><cmd>Identify compound
+cases involving both real time and performance critical guarantees. </cmd>
+<info>An example of a compound case is receiving a text message while playing
+MP3 audio. </info>
+</substep>
+</substeps>
+</step>
+<step id="GUID-13DE4D82-D318-5C1B-A9A0-9C8D60C7A6B7"><cmd>Perform an IPC analysis
+of the impact of data paging on your code. </cmd>
+<substeps id="GUID-C53DD02E-D670-5608-9293-663495544410">
+<substep id="GUID-14395B5D-B0C1-5380-B6D4-A9A5D5FA5A16"><cmd>Identify all
+performance critical or real time servers which the component interacts with. </cmd>
+</substep>
+<substep id="GUID-B4429AD3-5B5F-5E10-A220-724BA9693D29"><cmd>List each case
+where these servers read paged data from a client's address space. In this
+case, paged data includes: </cmd>
+<info><ul>
+<li id="GUID-02F9AD09-BFEB-59D3-98C6-471A2D842F32"><p>Paged heaps and stacks, </p> </li>
+<li id="GUID-BEA351B7-27C8-54F4-A2A9-F0314153D1F8"><p>RAM-loaded code, and </p> </li>
+<li id="GUID-AE1A2E25-C84A-5CCB-AC03-40017B1E5EEF"><p>Read only XIP data structures
+including </p> <ul>
+<li id="GUID-A61629A2-6782-52E6-A64B-41825F454B1B"><p>bitmaps, </p> </li>
+<li id="GUID-B5657762-F2E1-5521-AB33-E95547BA154B"><p>constant descriptors, </p> </li>
+<li id="GUID-0A667519-6532-52C4-BCCD-022A44F701D6"><p>constant data arrays
+in code, </p> </li>
+<li id="GUID-E8C94651-CAA0-5EFE-8E87-6B7A7B7A8785"><p>data files accessed
+through a pointer, and </p> </li>
+<li id="GUID-CD319825-B44F-5EF3-A9CC-2B3391F2D9A8"><p>exported DLL data. </p> </li>
+</ul> </li>
+</ul> </info>
+</substep>
+<substep id="GUID-CB118001-AC5E-5C39-81C1-EB9DEFA2F16E"><cmd>Identify all
+cases of custom architectures where one thread reads from another thread's
+address space. </cmd>
+</substep>
+</substeps>
+</step>
+<step id="GUID-009892B8-88B2-5ACA-BB98-B88ECF49A983"><cmd>Take steps to mitigate
+the impacts of data paging which you have identified, as appropriate to each
+case. </cmd>
+
+<substeps id="GUID-63086536-F2DB-5F4A-926F-C0328FD8D854">
+<substep id="GUID-F2821854-2A7D-5FB4-8D75-63841CDD26F7"><cmd>Protect the real
+time and performance critical code paths. These paths will have been identified
+in the static analysis of the component. There are two ways of protecting
+them. </cmd>
+<info><ul>
+<li id="GUID-5CA87396-D31D-5AC2-B524-0405129AEC23"><p>For all use cases, ensure
+that the minimum paging cache size is large enough to accommodate both the
+protected code path and any other paged data required at the same time. </p> <p>This
+method of protection may not always be practical, because compound use cases
+may involve unpredictable amounts of data which exceed the size of the paging
+cache. </p> </li>
+<li id="GUID-A702633C-A6DB-5DB2-9FA0-20F8FF4A285E"><p>Make the protected code
+path unpaged. Mark the code itself as unpaged, and either mark whole regions
+of memory as unpaged or pin memory to ensure that it is unpaged. </p> </li>
+</ul> </info>
+</substep>
+<substep id="GUID-9486786D-191D-597F-9BCE-09CB3A74A165"><cmd>Redesign the
+component architecture to isolate areas where data paging impacts on performance.
+Examples of this are: </cmd>
+<info><ul>
+<li id="GUID-76E2623B-9B76-5424-9C40-3BC027C449A2"><p>Separating the data
+plane and the control plane, and </p> </li>
+<li id="GUID-26906CC5-1D1B-5EED-A9F8-CBBE6F441369"><p>Splitting a monolithic
+library into paged and unpaged parts. </p> </li>
+</ul> </info>
+</substep>
+<substep id="GUID-438E7745-76B3-533D-891E-93B8EA53F342"><cmd>Use code paging
+or XIP ROM paging to mitigate the impact of paging. </cmd>
+
+<info>For instance, a monolithic library with static dependences may only
+need to be partially loaded, and some dependencies may not need to be loaded
+at all. </info>
+</substep>
+<substep id="GUID-DD1D6948-8F9A-57D6-9156-C9C2E377D2FD"><cmd/>
+<info>Mitigate the impact of data paging on IPC using the techniques set out
+in the document <xref href="GUID-E7C55048-5B7A-5BF2-B7F4-4D731659B88C.dita">Device
+Driver Writing Technology Tutorial</xref>  </info>
+</substep>
+</substeps>
+</step>
+</steps-unordered>
+</taskbody></task>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-86082C0C-B0EE-5E7C-85B4-4A509066012F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-86082C0C-B0EE-5E7C-85B4-4A509066012F" xml:lang="en"><title>MMC Porting
+Implementation Tutorial</title><shortdesc>Describes the steps to implement a port of the MMC Controller. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/><related-links>
+<link href="GUID-9573F7B9-76E9-5DCB-A498-C0DE59606911.dita"><linktext>Concepts</linktext>
+</link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-862CA4C4-C6E8-4D60-8DD0-F3590C92E15D.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-862CA4C4-C6E8-4D60-8DD0-F3590C92E15D" xml:lang="en"><title>Interrupt Client Interface</title><shortdesc>Describes the client interface of the Interrupt platform
+service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-86737CAB-2A4A-4424-8856-67E0804BCD60.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-86737CAB-2A4A-4424-8856-67E0804BCD60" xml:lang="en"><title>Time Overview</title><shortdesc>Provides a basic idea about the Time platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-0F45D51D-6C83-458A-B787-7D7A6A5F2E64-GENID-1-2-1-10-1-5-1-10-1-1-3-1-3-1"><title>What
+is Time platform service</title>             <p>Time platform service
+starts during device start up. It is responsible for maintaining a
+queue of all system-wide alarms. It allows clients to query the status
+of alarms, set alarms, remove alarms and perform other utility functions.</p>         </section>
+<section id="GUID-0F45D51D-6C83-458A-B787-7D7A6A5F2E64-GENID-1-2-1-10-1-5-1-10-1-1-3-1-3-2"><title>Need
+for Time platform service</title>             <p>Time platform service
+is required to manage the alarm in the system and system
+state manager utility plug-in specifically RTC adaptation plug-in.</p>         </section>
+<section id="GUID-0F45D51D-6C83-458A-B787-7D7A6A5F2E64-GENID-1-2-1-10-1-5-1-10-1-1-3-1-3-3"><title>For
+whom does Time platform service matter to?</title>             <p>Time platform service matters to all the Real time clock and alarm
+implementations to fulfill the requirements set by the RTC adaptation
+plug-in interface that is introduced beside of a System State Manager.
+The SSM Adaptation Server contains a RTC Adaptation plug-in.</p> 
+       </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-86C21C9B-9F08-579F-84E9-CBE46F756373-master.png has changed
Binary file Adaptation/GUID-86C21C9B-9F08-579F-84E9-CBE46F756373_d0e10964_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-877EEB52-40C8-4880-87A0-9736A625F85F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,76 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-877EEB52-40C8-4880-87A0-9736A625F85F" xml:lang="en"><title>TDmaChannel Derived Class Implementation</title><shortdesc>Describes how to write a class describing a DMA channel.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref> class is part of the PSL implementation.
+It is an abstract class with pure virtual functions which you must
+derive in order to implement it. The implementation of a DMA channel
+involves hardware-specific decisions such as the choice of DMA mode</p>
+<p>The purpose of DMA is to transfer data such as streaming audio
+produced by a client application. A typical transfer involves passing
+the data from user side to kernel side via a shared chunk and then
+a transfer from one memory location to another by DMA over a buffer.
+If the amount of data to be transferred exceeds the maximum transfer
+size supported by the controller or involves non-contiguous physical
+memory, the data is fragmented and transmitted in a sequence of transfers
+in one of three modes. </p>
+<ul>
+<li><p>In single buffer mode the hardware controller provides a single
+set of transfer registers used alternately to perform an active transfer
+and to set up a pending one: however this mode incurs overhead in
+the form of significant periods of time when the driver is idle during
+the pending phase. </p></li>
+<li><p>In double buffer mode the hardware controller provides two
+sets of transfer registers, one set for the active transfer and one
+for the pending transfer.. </p></li>
+<li><p>In scatter-gather mode, a single procedure call sequentially
+writes data from multiple buffers to a single data  stream or from
+a data stream to multiple buffers.</p></li>
+</ul>
+<p> The PIL supplies three derived classes corresponding to the DMA
+modes:</p>
+<ul>
+<li><p><xref href="GUID-A8B4AD1B-770C-363E-A0DE-C78A9786CBDC.dita"><apiname>TDmaSbChannel</apiname></xref></p> for a single-buffer channel,</li>
+<li><p><xref href="GUID-FD76AF08-6250-3054-8A06-16343E385B23.dita"><apiname>TDmaDbChannel </apiname></xref></p> for a double-buffer channel,
+and</li>
+<li><p><xref href="GUID-2D4CFBB1-8D64-3CF5-B6F0-B24D16D5BAD4.dita"><apiname>TDmaSgChannel</apiname></xref></p> for a scatter-gather channel.</li>
+</ul>
+<p>These three classes are defined in <filepath>dma_v1.h</filepath>. </p>
+<p> You may simply use one of these classes or derive further classes
+from them and implement those. For example, the template scatter-gather
+implementation defines a <xref href="GUID-45CDD48A-6BB4-3409-AC03-E2E0D2B73592.dita"><apiname>TTemplateSgChannel</apiname></xref> class
+derived from <xref href="GUID-2D4CFBB1-8D64-3CF5-B6F0-B24D16D5BAD4.dita"><apiname>TDmaSgChannel</apiname></xref> for storing data when
+appending new descriptors to a running channel: </p>
+<codeblock xml:space="preserve">class TTemplateSgChannel : public TDmaSgChannel
+    {
+public:
+    TDmaDesc* iTmpDes;
+    TPhysAddr iTmpDesPhysAddr;
+    };
+</codeblock>
+<p>In general, design decisions are made at the level of implementation
+in hardware and are subsequently reflected in the structure of the
+derived classes.</p>
+<p>There are two ways of extending the DMA Framework:</p>
+<ul>
+<li><p>to provide platform-specific functionality on a per-channel
+basis, and</p></li>
+<li><p>to provide platform-specific functionality on a channel independent
+basis</p></li>
+</ul>
+<p>In the first case, <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-2CF7498E-F5D2-3C4A-8E98-47504F9FC404"><apiname>TDmaChannel::Extension()</apiname></xref> calls <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-D6D011E9-9D75-3881-87D8-1986FFBBA106"><apiname>TDmac::Extension()</apiname></xref> and the PSL provides an implementation
+of the virtual function <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-D6D011E9-9D75-3881-87D8-1986FFBBA106"><apiname>TDmac::Extension()</apiname></xref>. The
+default implementation just returns <xref href="GUID-F89DA3F0-2A48-3F9B-8F08-29350E92D0E4.dita"><apiname>KErrNotSupported</apiname></xref>. In the second case, <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-75562653-1F27-39D3-96D8-55A94BA9B68B"><apiname>TDmaChannel::StaticExtension()</apiname></xref> calls <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita#GUID-176B8E0D-0422-341B-A134-7C85432E1303/GUID-C733B302-4269-3391-8ADE-617CFF198B56"><apiname>DmaChannelMgr::StaticExtension()</apiname></xref> and the
+PSL provides an implementation of the static function <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita#GUID-176B8E0D-0422-341B-A134-7C85432E1303/GUID-C733B302-4269-3391-8ADE-617CFF198B56"><apiname>DmaChannelMgr::StaticExtension()</apiname></xref>. The template PSL implementation just returns <xref href="GUID-F89DA3F0-2A48-3F9B-8F08-29350E92D0E4.dita"><apiname>KErrNotSupported</apiname></xref>. </p>
+</conbody><related-links>
+<link href="GUID-C649DB97-F138-4C90-B177-16590F2E3F19-GENID-1-2-1-9-1-6-1-8-1-7-1-3-1.dita"><linktext>DMA
+Channels</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-8798F896-E0CB-4B9B-8F88-3C8B58574213.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-8798F896-E0CB-4B9B-8F88-3C8B58574213" xml:lang="en"><title>The
+Physical Channel</title><shortdesc>This document describes how a logical device communicates with
+a physical device over a physical channel.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-A759AA8D-945A-4150-822A-C22DFAE8F5C9">           <p>The
+physical channel defines the interface between the logical device and the
+physical device. Typically, this interface is different for each device family
+and, therefore, the device driver framework does not require a particular
+type of interface. The only requirement is that the physical channel class
+is derived from <xref href="GUID-4FCB6127-84F3-38F6-8AD2-FC3B94D67DA3.dita"><apiname>DBase</apiname></xref>. It is up to the driver writer to
+define the physical channel class. </p> <fig id="GUID-8C470617-1743-546F-A0A4-A20B1480539D">
+<title>                 Device driver physical channel classes           
+   </title>
+<image href="GUID-F8A32666-5003-5B14-A700-C6E6388D2D38_d0e63938_href.png" placement="inline"/>
+</fig>     </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-892931C3-E560-54AA-A9CB-2820BF025E52.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,70 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-892931C3-E560-54AA-A9CB-2820BF025E52" xml:lang="en"><title>Fault
+Information Commands</title><shortdesc>Describes how to use the <codeph>f</codeph> command to get information
+about the fault type. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There are two possibilities: </p>
+<ul>
+<li id="GUID-3929E483-85B8-5382-8467-632E4601281B"><p> <xref href="GUID-892931C3-E560-54AA-A9CB-2820BF025E52.dita#GUID-892931C3-E560-54AA-A9CB-2820BF025E52/GUID-02C96922-6987-50B3-9759-8F591ECA5C1B">an unhandled exception has occurred</xref>  </p> </li>
+<li id="GUID-EAA3FE0B-A66F-5505-BDE6-C5E9E6AB1370"><p> <xref href="GUID-892931C3-E560-54AA-A9CB-2820BF025E52.dita#GUID-892931C3-E560-54AA-A9CB-2820BF025E52/GUID-16FEDD9F-2E27-5FB8-AAD3-E61589FC3CC1">a panic has occurred</xref>  </p> </li>
+</ul>
+<p>To start, use the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-D5F2E0AF-EF03-5150-813B-DF989F12C47B">f</xref> command.
+You will see something like this: </p>
+<codeblock id="GUID-05D1AE94-2DA3-50EE-8EB8-E3C5645E5329" xml:space="preserve">Fault Category: Exception  Fault Reason: 10000000
+ExcId 00000001 CodeAddr f800415c DataAddr 00000000 Extra 00000005
+Exc 1 Cpsr=60000013 FAR=00000000 FSR=00000005
+ R0=64007328  R1=00000000  R2=00000000  R3=00000001
+ R4=64007328  R5=640074c0  R6=00000000  R7=f8047ba4
+ R8=64006f80  R9=64006fec R10=00000013 R11=64006ec4
+R12=00000001 R13=000029b4 R14=0000016c R15=f800415c
+R13Svc=64006ea8 R14Svc=f8002b2c SpsrSvc=600000ff
+</codeblock>
+<p>The <i>Fault Category</i> field shows the type of fault, in this case an
+exception. </p>
+<section id="GUID-02C96922-6987-50B3-9759-8F591ECA5C1B"><title> Unhandled
+exceptions</title> <p>If the <i>Fault Category</i> is <i>Exception</i>, then
+the fault is caused by an unhandled processor exception. You can get further
+information on the type of exception by looking at the first three lines of
+the generated output: </p> <codeblock id="GUID-C294FEB9-EFAE-56E9-B882-1CA4B0A3D9FB" xml:space="preserve">Fault Category: Exception  Fault Reason: 10000000
+ExcId 00000001 CodeAddr f800415c DataAddr 00000000 Extra 00000005
+Exc 1 Cpsr=60000013 FAR=00000000 FSR=00000005</codeblock> <p>The <codeph>CodeAddr</codeph> and <codeph>DataAddr</codeph> fields
+show the address of the instruction that caused the exception and, depending
+on the type of exception and instruction, the address of the data the instruction
+was trying to access. You can use the <codeph>CodeAddr</codeph> value to find
+the function which was being executed by <xref href="GUID-DA62FD4F-2E74-5B2F-B703-4A40DF5F01CA.dita">using
+the MAKSYM tool</xref>. </p> <p>The number after <codeph>ExcId</codeph> is
+the type of exception, in hexadecimal, and is one of the <xref href="GUID-7ECDCF7B-3B2A-561F-9136-04BC4DAE46E4.dita#GUID-7ECDCF7B-3B2A-561F-9136-04BC4DAE46E4/GUID-567330BE-A308-50CD-9EB8-891E45FA8294">ARM exception types</xref>. The meaning of the numbers depends on the type
+of processor. </p> <ul>
+<li id="GUID-7EA2C471-63B5-5D22-A8EE-A24ADFB326DE"><p>If the exception is
+a prefetch abort, then the code address is invalid. </p> </li>
+<li id="GUID-F04A8010-64F7-5D52-8066-3A446DF0C645"><p>A data abort means that
+the code address is invalid. </p> </li>
+</ul> <p>The number after <codeph>FAR</codeph> is the fault address register;
+this is the address that caused the fault. </p> <p>The number after FSR is
+the <xref href="GUID-7ECDCF7B-3B2A-561F-9136-04BC4DAE46E4.dita#GUID-7ECDCF7B-3B2A-561F-9136-04BC4DAE46E4/GUID-E55E7DA9-61DC-57D9-9678-05D490FEE604">fault
+status register value</xref> and shows why the MMU raised an exception. </p> <p>The
+number after CPSR is the value of the CPU's CPSR register when the exception
+occurred. The 5 least-significant bits of the CPSR register indicate the <xref href="GUID-7ECDCF7B-3B2A-561F-9136-04BC4DAE46E4.dita#GUID-7ECDCF7B-3B2A-561F-9136-04BC4DAE46E4/GUID-BFA2235C-1598-59E6-9F1F-A8281F13A957">ARM
+processor modes (CPSR register)</xref>. </p> </section>
+<section id="GUID-16FEDD9F-2E27-5FB8-AAD3-E61589FC3CC1"><title>Panics</title> <p>If
+the <i>Fault Category</i> is not <i>Exception</i>, then the fault is due to
+a panic. In this case the only other valid field is the <i>Fault reason</i>;
+the values of all other fields are meaningless. </p> <p>The panic number is
+the low 16-bits of the fault reason, shown in hexadecimal. </p> <p>For example,
+a KERN 27 panic would generate: </p> <codeblock id="GUID-F1335B4B-F7AB-5502-8C3C-E1CB6774E1B4" xml:space="preserve">Fault Category: KERN  Fault Reason: 0000001b
+ExcId ffffee5e CodeAddr ffff99a9 DataAddr bfff3e54 Extra fffec4cd
+</codeblock> <p>If the panic is KERN 4, then a thread or process marked as
+protected has panicked. For other panics, kernel side code has panicked; this
+code is either in the kernel itself or in a device driver. </p> <p>See <xref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita">Kernel State Information
+Commands</xref> to find out which process and thread were running at the time
+of the panic. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-898704CF-26A1-50F5-BEFE-1E29D85064AA.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-898704CF-26A1-50F5-BEFE-1E29D85064AA" xml:lang="en"><title>Reference</title><shortdesc>This section describes the command and syntax for ROM building
+tools and input files. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-89BCF9A5-ABBD-5523-BA76-FDB00B806A30.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,237 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-89BCF9A5-ABBD-5523-BA76-FDB00B806A30" xml:lang="en"><title>Fair Scheduling and File Caching</title><shortdesc>Describes how to implement and configure the fair scheduling
+and file caching features for file systems implementations.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-450D57A3-928B-5389-B941-595DB20A7CEA"><title>Enabling
+fair scheduling</title><p>The <codeph>MExtendedFileInterface</codeph> API enables fair scheduling. The FAT, FAT32 and LFFS file systems
+support <codeph>MExtendedFileInterface</codeph>, this API allows requests
+to be split into one or more segments with the <codeph>aOffset</codeph> parameter. Support has been built in for large files by changing
+the file’s position parameter (<codeph>aPos</codeph>) from a <xref href="GUID-7A2A43EC-6125-3BFE-834B-23C37F7B40D5.dita"><apiname>TInt</apiname></xref> to a <xref href="GUID-AAE85115-A8AA-3F6C-BA8C-69F5A23B0D90.dita"><apiname>TInt64</apiname></xref>. </p> <p>To enable
+fair scheduling, the file system mounted on a particular drive must
+support <xref href="GUID-63DF657C-434D-353D-A536-8AF9D97C8260.dita#GUID-63DF657C-434D-353D-A536-8AF9D97C8260/GUID-E57D0ED6-C351-37F4-8E80-5A64144B6655"><apiname>CFileCB::MExtendedFileInterface</apiname></xref>. The object
+returned by <xref href="GUID-0012B043-9FC4-3953-928E-CB6107E0486A.dita#GUID-0012B043-9FC4-3953-928E-CB6107E0486A/GUID-EFDD2A6C-1319-30FC-9FC6-9653E0A2F827"><apiname>CFileSystem::NewFileL()</apiname></xref> must be derived
+from <codeph>CFileCB</codeph> and <codeph>CFileCB::MExtendedFileInterface</codeph>. The file server determines whether this is the case by calling <xref href="GUID-63DF657C-434D-353D-A536-8AF9D97C8260.dita#GUID-63DF657C-434D-353D-A536-8AF9D97C8260/GUID-D3628A6F-8E6D-39CA-8D36-EB3BC4154DF2"><apiname>CFileCB::GetInterface</apiname></xref>. </p> <p>The <xref href="GUID-63DF657C-434D-353D-A536-8AF9D97C8260.dita#GUID-63DF657C-434D-353D-A536-8AF9D97C8260/GUID-E57D0ED6-C351-37F4-8E80-5A64144B6655"><apiname>CFileCB::MExtendedFileInterface</apiname></xref> interface is as follows: </p><codeblock id="GUID-27EC7D5D-7BB6-5427-9EF0-71561F7AB847" xml:space="preserve">class MExtendedFileInterface
+{
+public:
+    virtual void ReadL(TInt64 aPos, TInt&amp; aLength, TDes8* aDes, const RMessagePtr2&amp; aMessage, TInt aOffset) = 0;
+    virtual void WriteL(TInt64 aPos, TInt&amp; aLength, const TDesC8* aDes, const RMessagePtr2&amp; aMessage, TInt aOffset) = 0;
+    virtual void SetSizeL(TInt64 aSize) = 0;
+};</codeblock> <p>The file system indicates its support for <codeph>MExtendedFileInterface</codeph> by intercepting the <xref href="GUID-63DF657C-434D-353D-A536-8AF9D97C8260.dita#GUID-63DF657C-434D-353D-A536-8AF9D97C8260/GUID-F13F53A3-502A-38E4-B8E3-4099DC44EEC0"><apiname>CFileCB::EExtendedFileInterface</apiname></xref> enumeration in the <xref href="GUID-63DF657C-434D-353D-A536-8AF9D97C8260.dita#GUID-63DF657C-434D-353D-A536-8AF9D97C8260/GUID-CBCFC605-C942-3D4E-8ABA-2EF454E5A44B"><apiname>CFileCB::GetInterface()</apiname></xref> method
+as in the following example: </p><codeblock id="GUID-714AB83B-0A24-5E81-92B8-CB425002B426" xml:space="preserve">TInt CFatFileCB::GetInterface(TInt aInterfaceId, TAny*&amp; aInterface, TAny* aInput)
+    {
+    switch(aInterfaceId)
+        {
+        case EExtendedFileInterface:
+            ((CFileCB::MExtendedFileInterface*&amp;) aInterface) = this;
+            return KErrNone;
+
+        //etc.
+
+        default:
+            return CFileCB::GetInterface(aInterfaceId, aInterface, aInput);
+        }
+    }</codeblock> </section>
+<section id="GUID-719C7E0C-790B-5C61-9EA8-E2687397340F"><title>Enabling
+read and write caching</title><p>To enable caching, the file system
+must support reads and writes to local buffers, which are buffers
+created and owned by the file server itself rather by a client of
+the file server. </p><p>The local media subsystem already supports
+local messages, but the file system and any file system extensions
+need to be examined carefully to ensure that they do not call any <xref href="GUID-78E0DEDD-C020-3174-AD0A-E4C18C4C9213.dita"><apiname>RMessagePtr2</apiname></xref> methods, otherwise a panic results. </p> <p>The file server calls <xref href="GUID-FADDE053-CC1C-39BC-A52D-27093041BE20.dita#GUID-FADDE053-CC1C-39BC-A52D-27093041BE20/GUID-239159E5-1A98-3FE1-9A0D-803BEDB99DCE"><apiname>CMountCB::LocalBufferSupport()</apiname></xref> to find out whether the file system and all file system extensions
+mounted on a particular drive fully support local buffers before it
+enables caching. The file system handles the <xref href="GUID-FADDE053-CC1C-39BC-A52D-27093041BE20.dita#GUID-FADDE053-CC1C-39BC-A52D-27093041BE20/GUID-87F36D0F-CAA5-35ED-9E99-BB8F7B9564C2"><apiname>CMountCB::ELocalBufferSupport</apiname></xref> enumeration in its <xref href="GUID-FADDE053-CC1C-39BC-A52D-27093041BE20.dita#GUID-FADDE053-CC1C-39BC-A52D-27093041BE20/GUID-CABEF8F6-637C-3223-80C6-FBC8B7247030"><apiname>CMountCB::GetInterface()</apiname></xref> method
+and passes the request on to the first proxy drive, as in the following
+example: </p><codeblock id="GUID-969BBBAE-5C1F-5032-831D-3C17E58285AE" xml:space="preserve">TInt CFatMountCB::GetInterface(TInt aInterfaceId, TAny*&amp; aInterface, TAny* /*aInput*/) 
+    {
+    TInt r= KErrNone;
+    switch(aInterfaceId)
+        {
+        // file caching supported, so pass query on to first proxy drive
+        case CMountCB::ELocalBufferSupport:
+            r = LocalDrive()-&gt;LocalBufferSupport();
+            break;
+        default:
+            r=KErrNotSupported;
+        }
+    return r;
+    }</codeblock> <p>If no file system extensions are loaded, then
+the query is eventually handled by <xref href="GUID-F47F56E4-3754-365B-B529-53C1D2A29503.dita#GUID-F47F56E4-3754-365B-B529-53C1D2A29503/GUID-7C0145B1-531A-367C-92DF-61EBB46F01CB"><apiname>CLocalProxyDrive::GetInterface()</apiname></xref>, which returns <codeph>KErrNone</codeph> to indicate that <xref href="GUID-32659A02-6541-3D15-AB88-B70FBD7DF9B0.dita"><apiname>TBusLocalDrive</apiname></xref> and the local media sub-system support local
+buffers. </p> <p>If there are any file system extensions, they must
+handle the <xref href="GUID-B0BD0F3D-9081-3DBE-8375-F5000D6D39ED.dita#GUID-B0BD0F3D-9081-3DBE-8375-F5000D6D39ED/GUID-53AC960F-9EE3-3410-9DD6-1BAC08C7B8E8"><apiname>CProxyDrive::ELocalBufferSupport</apiname></xref> enumeration,
+as in the following example: </p><codeblock id="GUID-67D3FAA1-9FC3-5653-B21D-73BC13AA36AE" xml:space="preserve">TInt CBitExtProxyDrive::GetInterface(TInt aInterfaceId, TAny*&amp; aInterface, TAny* aInput)
+    {
+    switch(aInterfaceId)
+        {
+        // file caching supported, so pass query on to next proxy drive
+        case ELocalBufferSupport:
+            return CBaseExtProxyDrive::LocalBufferSupport();
+
+        default:
+            return CBaseExtProxyDrive::GetInterface(aInterfaceId, aInterface, aInput);
+        }       
+    }</codeblock> </section>
+<section id="GUID-020006B9-1A1E-523B-9CFA-927CDE5D5058"><title>Configuring
+caching</title><p>The global and drive-specific cache property defaults
+are defined in <filepath>f32\sfile\sf_file_cache_defs.h</filepath>. They may be overridden for a particular drive by appropriate entries
+in the Base Starter component's <filepath>ESTART.TXT</filepath> configuration
+file. The format of this file has been enhanced to support the<codeph> .ini</codeph> file style syntax: </p><codeblock id="GUID-E0DBF04F-8F7E-55E4-8210-D5697A5B3FDB" xml:space="preserve">C: 0  ELOCAL FAT  0       FS_FORMAT_COLD,FS_SYNC_DRIVE     # IRAM
+D: 1  ELOCAL FAT  0       FS_SCANDRIVE                     # MMC (textshell)
+I: 2  ELOCAL FAT  0       FS_FORMAT_CORRUPT                # NAND - USER DATA
+K: 8  ELFFS  LFFS 0       FS_FORMAT_CORRUPT                # LFFS 
+
+[DriveD]
+FileCacheSize 256
+FairSchedulingLen 128
+FileCacheRead ON
+FileCacheReadAhead ON
+FileCacheWrite ON
+ClosedFileKeepAliveTime 3000
+DirtyDataFlushTime 3000
+FileCacheReadAsync ON
+
+[DriveI]
+FileCacheWrite ENABLED
+
+[DriveK]
+FileCacheWrite ENABLED
+
+[FileCache]
+GlobalCacheEnabled ON
+GlobalCacheSize 32768
+GlobalCacheMaxLockedSize 1024
+LowMemoryThreshold 10</codeblock> <p>In this example, write caching
+is enabled on drives I and K and has been turned on by default on
+drive D.</p><note>Most of the properties in the example are set to
+their default values: the definitions are redundant but are shown
+for illustrative purposes. </note> <p>For details, see <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita">Base Starter Technology</xref>. </p> <p id="GUID-16751410-EFC2-55B8-8BC0-ED5F97F98EBB"><b>Global
+cache settings</b> </p><p>The following table holds the global caching
+properties: </p><table id="GUID-4CBAD2A4-52DE-5BA1-98CC-0B1F6BFC54E1">
+<tgroup cols="4"><colspec colname="col0"/><colspec colname="col1"/>
+<colspec colname="col2"/><colspec colname="col3"/>
+<tbody>
+<row>
+<entry><p> <b>Property</b>  </p> </entry>
+<entry><p> <b>Type</b>  </p> </entry>
+<entry><p> <b>Comments</b>  </p> </entry>
+<entry><p> <b>Default value</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-91B81C0D-72F9-3226-BEEF-2E8153104102.dita"><apiname>GlobalCacheEnabled</apiname></xref>  </p></entry>
+<entry><p>boolean </p></entry>
+<entry><p>on or off</p></entry>
+<entry><p>on</p></entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-BAC3ED91-7A3A-3255-B22E-6B6C0CB266E0.dita"><apiname>GlobalCacheSize</apiname></xref>  </p></entry>
+<entry><p>integer </p> </entry>
+<entry><p>Size of disconnected chunk shared by all files in kilobytes.</p></entry>
+<entry><p>32768K (32MB) </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-BEE48B25-B374-3348-B97C-BA2D634E0330.dita"><apiname>GlobalCacheMaxLockedSize</apiname></xref>  </p></entry>
+<entry><p>integer </p> </entry>
+<entry><p>Maximum amount of locked RAM for all files in kilobytes.</p></entry>
+<entry><p>1024K (1 MB) </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-36596759-4ABC-3F8E-A09E-97464094A58A.dita"><apiname>LowMemoryThreshold</apiname></xref>  </p></entry>
+<entry><p>integer </p></entry>
+<entry><p>Low memory threshold expressed as a percentage of total
+RAM. If the amount of RAM drops below this value, attempts to allocate
+memory for file caching fails.</p></entry>
+<entry><p>10% </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-E7F45784-14F2-505C-B21C-0A8010B0B232"><b>File
+cache settings</b> </p><p>The properties <xref href="GUID-9278B920-FFEF-3710-8080-B33D028B7A12.dita"><apiname>FileCacheRead</apiname></xref>, <xref href="GUID-33E32FCF-9E02-3254-A9DA-3A6D0B1A52B5.dita"><apiname>FileCacheReadAhead</apiname></xref> and <xref href="GUID-C869ED9F-7F9D-33BC-A1C2-5E21B50A6BFC.dita"><apiname>FileCacheWrite</apiname></xref> may each be in one of 3 states: </p><ul>
+<li id="GUID-71396310-22E1-564A-A094-3EED4721688D"><p> <codeph>OFF</codeph> - file caching is permanently off and cannot be turned on.</p> </li>
+<li id="GUID-032E8EB7-4291-5276-852E-BD910CEC8633"><p> <codeph>ENABLED</codeph> - file caching is off by default but may be turned on using an appropriate
+file open mode, such as <xref href="GUID-4310DC20-300C-3FEB-B1A5-DBA37D5FC940.dita"><apiname>EFileReadBuffered</apiname></xref>  </p> </li>
+<li id="GUID-2644023A-855F-5BDE-8A43-57A534E3367A"><p> <codeph>ON</codeph> - file caching is on by default but may be turned off using an appropriate
+file open mode, such as <xref href="GUID-449D6D3A-3F00-35F6-BDFB-DF957F98CA8B.dita"><apiname>EFileReadDirectIO</apiname></xref>. </p> </li>
+</ul><p>See <xref href="GUID-3FEEFC4D-19B5-502A-8310-40646B9C34BC.dita">Run time cache settings</xref>. </p><p>If <xref href="GUID-7F7B7C49-5F60-3B10-A241-98306795A768.dita"><apiname>FileCacheReadAsync</apiname></xref> is set, media driver reads on this drive are asynchronous. This
+results in read ahead requests being issued before completing a client
+read request. However, if <codeph>FileCacheReadAsync</codeph> is OFF,
+then media driver reads on this drive are synchronous. So, issuing
+a read ahead is likely to block any client thread that is normally
+running at lower priority than the media driver's thread. In this
+case read ahead requests only happen during periods of inactivity
+to improve latency. </p><table id="GUID-B022918E-9335-5D44-B029-D48B36E45937">
+<tgroup cols="4"><colspec colname="col0"/><colspec colname="col1"/>
+<colspec colname="col2"/><colspec colname="col3"/>
+<tbody>
+<row>
+<entry><p> <b>Property</b>  </p> </entry>
+<entry><p> <b>Type</b>  </p> </entry>
+<entry><p> <b>Comments</b>  </p> </entry>
+<entry><p> <b>Default value</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-3B777E89-8E4C-3540-958F-C621741895C8.dita"><apiname>FileCacheSize</apiname></xref>  </p> </entry>
+<entry><p>integer </p> </entry>
+<entry><p>Maximum amount of locked or unlocked RAM per file.</p></entry>
+<entry><p>128K </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-23E2F01D-BD7B-39D3-B7B2-F23E20D273C5.dita"><apiname>FairSchedulingLen</apiname></xref>  </p> </entry>
+<entry><p>integer </p> </entry>
+<entry><p>Read &amp; write requests greater than this length are split
+up into 2 or more requests.</p></entry>
+<entry><p>128K </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-9278B920-FFEF-3710-8080-B33D028B7A12.dita"><apiname>FileCacheRead</apiname></xref>  </p></entry>
+<entry><p>string </p></entry>
+<entry><p>OFF, ENABLED or ON.</p></entry>
+<entry><p>ENABLED </p></entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-33E32FCF-9E02-3254-A9DA-3A6D0B1A52B5.dita"><apiname>FileCacheReadAhead</apiname></xref>  </p></entry>
+<entry><p>string </p></entry>
+<entry><p>OFF, ENABLED or ON.</p></entry>
+<entry><p>ON </p></entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C869ED9F-7F9D-33BC-A1C2-5E21B50A6BFC.dita"><apiname>FileCacheWrite</apiname></xref>  </p></entry>
+<entry><p>string </p></entry>
+<entry><p>OFF, ENABLED or ON.</p></entry>
+<entry><p>ENABLED </p></entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-7F7B7C49-5F60-3B10-A241-98306795A768.dita"><apiname>FileCacheReadAsync</apiname></xref>  </p> </entry>
+<entry><p>boolean </p> </entry>
+<entry><p>ON or OFF. If set, media driver reads on this drive are
+asynchronous.</p></entry>
+<entry><p>OFF </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A91BE0A1-A79D-3828-9E86-7850839BBFE9.dita"><apiname>ClosedFileKeepAliveTime</apiname></xref>  </p> </entry>
+<entry><p>integer </p> </entry>
+<entry><p>Time after which a file is removed from the closed file
+queue, in milliseconds. </p></entry>
+<entry><p>3000ms (3 secs) </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-78907F25-9D0F-3B76-BDB0-514FC22CAECA.dita"><apiname>DirtyDataFlushTime</apiname></xref>  </p> </entry>
+<entry><p>integer </p> </entry>
+<entry><p>Time after which a file containing dirty data is flushed,
+in milliseconds.</p></entry>
+<entry><p>3000ms (3 secs) </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+</conbody><related-links>
+<link href="GUID-5B24741C-7CE0-58E8-98C9-1D1CACCD476F.dita"><linktext>Fair
+Scheduling and File Caching Background</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-8A1B6104-4B13-5200-AF3D-64B3929707BB-master.png has changed
Binary file Adaptation/GUID-8A1B6104-4B13-5200-AF3D-64B3929707BB_d0e14531_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-8A5EC98B-E9AD-5496-9909-7C3B35610785.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,64 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-8A5EC98B-E9AD-5496-9909-7C3B35610785" xml:lang="en"><title>Demand
+Paging Deadlock Guide</title><shortdesc>Describes deadlocks in the context of demand paging and how to
+prevent them from occurring. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-F44CAA63-0225-566F-836C-F5348C0591BD"><title>Introduction</title> <p>A
+deadlock is when two or more processes have some resources, but not all of
+the resources required to execute. The resources that are required are held
+by the other processes, which in turn want the resources that are held by
+the initial processes. In this state, no process can execute. </p> <p>The
+classic sign that a deadlock has occurred is that a collection of processes
+just appear to never do anything i.e. 'just hang'. </p> <p>In the context
+of demand paging, the resource is a page of RAM that can be paged in or out.
+If one process wants data in a page of RAM that is paged-in or out by another
+process, then a potential deadlock condition can occur. </p> <p>Deadlocks
+are only likely to occur if you are altering or interacting with one of the
+components used in paging in and out, such as media drivers or the paging
+sub-system. The majority of user-side code does not need to worry about deadlocks
+from paging. </p> <p>This guide is most applicable to device side writers
+and other engineers writing kernel-side code. </p> </section>
+<section id="GUID-7C628F1C-132F-4327-8248-D018083392E0"><title>Deadlock features</title><p>        For a deadlock to occur,
+four necessary conditions must occur:  </p><p> Mutual exclusion condition
+ </p><p>  A resource cannot be used by more than one process at a time.  </p><p> Hold
+and wait condition  </p><p>One process is holding one resource, but needs
+another before it can   finish. </p><p>No preemption condition  </p><p> The
+resources can only be relinquished by the process holding it.  </p><p>Circular
+wait condition </p><p> One process is holding a resource and wants another
+resource that is  held by another process, which in turn wants access to the
+resource held by the  initial process.</p> </section>
+<section id="GUID-5758274B-83B1-400D-A0E4-993094066769"><title>Deadlock Prevention</title><p>      Since the cause of deadlocks
+(as far as demand paging is concerned) is  due to the paging in and out of
+RAM, the following points have to be        considered:  </p><ul>
+<li><p> Make sure all kernel-side components are always unpaged. </p></li>
+<li><p> Pinning; new APIs have been added that allows a process to over-ride
+  the demand paging rules as regards to how RAM pages are paged in and out
+the phone's memory. The name comes from that fact that the RAM page is fixed
+in the phone's RAM (as if a pin had been stuck into it) until a detached command
+is  executed (unpinned). This is implemented by using the new  <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita#GUID-A3CC1D95-4681-3349-A67C-F113A614041D/GUID-0DCAB25E-5A99-35EB-9F75-E9C275EE9E17"><apiname>DLogicalChannel::SendMsg()</apiname></xref> method. </p></li>
+<li><p>Mutex use in device drivers - if the nesting order is violated then
+deadlock can occur. To overcome this, make sure that all device driver operations
+that could cause a page fault don't use mutexes. In other words, any  access
+to paged memory while holding a mutex has the potential to cause a deadlock.</p></li>
+<li><p>Code running in DFC Thread 1 must not access user memory. This DFC
+thread is used by the implementation of the system timer functionality, hence
+paging RAM in or out of the system by this thread could cause serious performance
+problems or a deadlock.   </p></li>
+<li><p> For media drivers, make sure that when the media driver services page-in
+requests, that the thread that the driver runs in does not also make   requests
+to page-in RAM pages. Because, if this was to occur, then the media  driver
+will not be able to service the page in request and a dead lock would occur. </p></li>
+</ul> </section>
+</conbody><related-links>
+<link href="GUID-ACB79CEF-CA4D-5C96-AFCD-6AD7C7C26C53.dita"><linktext>Thrashing
+Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-8A78D678-D1C8-4A4E-9BF1-81C7019815C3-master.png has changed
Binary file Adaptation/GUID-8A78D678-D1C8-4A4E-9BF1-81C7019815C3_d0e94711_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-8B7E2A72-B793-5E70-87F0-92AA0A482F23.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,165 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-8B7E2A72-B793-5E70-87F0-92AA0A482F23" xml:lang="en"><title>Interrupt::Bind()
+and Interrupt::Unbind() </title><shortdesc>Describes two types of configuration used in the implementation
+of bind and unbind functions.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The functions <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-4E3CB472-3525-32F8-9BC4-8ECFEE931E7B"><apiname>Interrupt::Bind()</apiname></xref> and <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-CCC9A397-608C-3EAF-830F-A59800C2E8E5"><apiname>Interrupt::Unbind()</apiname></xref> provide
+device drivers with a way of binding ISRs to interrupt sources, and unbinding
+ISRs from interrupt sources. The implementation of these functions follows
+a standard pattern that can be re-used in most cases. </p>
+<p>The implementation can be different if there is a single Variant DLL, or
+if there is also an ASSP extension. </p>
+<section id="GUID-D6F47DE3-7320-4C3A-A7BB-96B57DFF40DA"><title>Variant DLL only configuration</title> <p>The following example
+implementation of <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-4E3CB472-3525-32F8-9BC4-8ECFEE931E7B"><apiname>Interrupt::Bind()</apiname></xref> assumes that all ISRs
+in the ISR table have been bound, by default, to the <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-9D98586F-AD1D-5C50-9AD8-F81D72135382">spurious interrupts</xref> handler function as done in <xref href="GUID-423537D5-2C8A-5C26-8D7B-60446E95F681.dita">initialising
+the table</xref>. To bind an interrupt source, the spurious interrupts handler
+is replaced with the provided ISR. The implementation prevents an ISR from
+being bound to an interrupt source that is already bound, by assuming that
+an unbound interrupt source is bound to the spurious interrupts handler. </p> <p>The
+implementation shows the basic idea but may need to be extended, especially
+where <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-9026A4AC-57AF-545D-887C-AF43E0B37EDC">chained
+interrupts</xref> and/or <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-ED6F2F47-7A16-5AE6-8E5B-B2475F6EDEAA">multiple
+interrupt sources and pseudo interrupt sources</xref> are involved. </p> <codeblock id="GUID-EF5B6524-6070-5563-919B-881039629E2B" xml:space="preserve">EXPORT_C TInt Interrupt::Bind(TInt aId, TIsr aIsr, TAny* aPtr)
+    {
+       TInt r = KErrNone;
+    If(TUint(aId)&gt;=TUint(KInterruptSourceCount))
+        {
+        r = KErrArgument; // Illegal interrupt number
+        }
+       else 
+        {
+           SInterruptHandler&amp; h = IsrHandlers[aId];
+        TInt irq = NKern::DisableAllInterrupts();
+        if (h.iIsr != &amp;SpuriousHandler)
+            {
+            r = KErrInUse; // Already bound to an ISR
+            }
+           else
+            {
+            h.iPtr = aPtr; // The ISR parameter
+            h.iIsr = aIsr; // Pointer to the ISR
+            }
+        NKern::RestoreInterrupts(irq);
+        }
+    return r;
+    }
+</codeblock> <p> <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-CCC9A397-608C-3EAF-830F-A59800C2E8E5"><apiname>Interrupt::Unbind()</apiname></xref> is the logical opposite
+of <codeph>Bind()</codeph>, replacing the ISR with the spurious handler function.
+The following code is the matching example implementation. </p> <codeblock id="GUID-B3240465-BF03-5977-B73C-9FF61B209F5C" xml:space="preserve">EXPORT_C TInt Interrupt::Unbind(TInt aId)
+    {
+       TInt r = KErrNone;
+       if (TUint(aId) &gt;= TUint(KInterruptSourceCount))
+        {
+        r = KErrArgument;    // Illegal interrupt number
+        }
+       else
+        {
+        SInterruptHandler&amp; h = IsrHandlers[aId];
+        TInt irq = NKern::DisableAllInterrupts();
+        if (h.iIsr == &amp;SpuriousHandler)
+            {
+            r = KErrGeneral; // Already unbound
+            }
+        else
+            {
+            h.iPtr =(TAny*)aId;
+            h.iIsr = SpuriousHandler;  // Replace with spurious handler
+            // NOTE: at this point it may be wise to
+            // force the hardware interrupt source to disabled.
+            }
+        NKern::RestoreInterrupts(irq);
+        }
+    return r;
+       }
+</codeblock> <p>Note that functions in the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita"><apiname>Interrupt</apiname></xref> class
+can be called from anywhere in kernel-side code, including ISRs, DFCs and
+IDFCs, and kernel threads. You need to ensure that if you are manipulating
+the ISR table, or any other structure that is shared, you need to <i>disable</i> interrupts
+to prevent corruption of the data. Interrupts are disabled and re-enabled
+using <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-8C251C65-FDE7-3161-8D2B-61401FB6487F"><apiname>NKern::DisableAllInterrupts()</apiname></xref> and <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-2D328082-3A9F-3467-81CF-B1C68866E163"><apiname>NKern::RestoreInterrupts()</apiname></xref>. </p> </section>
+<section id="GUID-883CCAD1-8339-4D95-A05C-AC2AFA2786F7"><title>ASSP Extension and Variant DLL configuration</title> <p>When
+a common ASSP extension is used, the Variant DLL may have to implement extra
+interrupt binding and dispatch functions for the device-specific interrupts. </p> <p>The
+following code is an example of an implementation of <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-4E3CB472-3525-32F8-9BC4-8ECFEE931E7B"><apiname>Interrupt::Bind()</apiname></xref> in
+the ASSP layer, where negative Interrupt IDs represent device specific interrupts. </p> <codeblock id="GUID-B1FF5AEC-30D2-5A4F-8677-5757906C629B" xml:space="preserve">EXPORT_C TInt Interrupt::Bind(TInt aId, TIsr aIsr, TAny* aPtr)
+    {
+    TInt r = KErrNone;
+    if(aId &lt; 0 )
+        {
+        return MyAsic-&gt;VariantBind( aId, aIsr, aPtr ); // Device specific ID, call variant
+        }
+    else if (aId &gt;= KInterruptSourceCount)
+            {
+            r = KErrArgument; // Illegal interrupt number
+            }
+        else
+            {
+            SInterruptHandler&amp; h = IsrHandlers[aId];
+            TInt irq = NKern::DisableAllInterrupts();
+            if (h.iIsr != SpuriousHandler)
+                {
+                r = KErrInUse; // Already bound to an ISR
+                }
+            else
+                {
+                h.iPtr = aPtr;
+                h.iIsr = anIsr;
+                }
+            NKern::RestoreInterrupts(irq);
+            }
+    return r;
+    }</codeblock> <p>The default device specific implementation of the <codeph>VariantBind()</codeph> function
+might be as follows: </p> <codeblock id="GUID-99850E43-605F-5FA0-95B3-3E472CA6FD56" xml:space="preserve">TInt TMyAsic::VariantBind( TInt aId, TIsr aIsr, TAny* aPtr )
+    // Default implementation when device specific layer does not override
+    // and this is therefore an illegal aId.
+    {
+    return KErrArgument;
+    }
+</codeblock> <p>The device specific implementation of <codeph>VariantBind()</codeph> would
+follow the same general pattern as for the <codeph>Interrupt::Bind()</codeph> function
+in the ASSP layer. The main difference is that the code refers to the device
+specific ISR table, <codeph>VariantHandlers[]</codeph>, defined within the
+device specific layer, and the interrupt ID is converted to a positive number
+so that it can be used as an index into this table: </p> <codeblock id="GUID-547FA8BB-F5BB-56A4-AC8F-7FCA07C7BD9A" xml:space="preserve">SInterruptHandler VariantHandlers[KNumVariantInts];</codeblock> <codeblock id="GUID-7D86B6BA-6FED-52F7-9DB8-4EF21A734CE1" xml:space="preserve">EXPORT_C TInt TMyVariant::VariantBind(TInt aId, TIsr aIsr, TAny* aPtr)
+    {
+    TInt r = KErrNone;
+    aId = (-aId)-1;    // convert to positive number &gt;=0
+    If (aId &gt;= KInterruptSourceCount || aId &lt; 0)
+        {
+        r = KErrArgument; // Illegal interrupt number
+        }
+    else
+        {
+        SInterruptHandler&amp; h = VariantHandlers[aId];
+        TInt irq = NKern::DisableAllInterrupts();
+        if (h.iIsr != VariantSpuriousHandler)
+            {
+            r = KErrInUse; // Already bound to an ISR
+            }
+        else
+            {
+            h.iPtr = aPtr;
+            h.iIsr = anIsr;
+            }
+        NKern::RestoreInterrupts(irq);
+        }
+    return r;
+    }</codeblock> <p>Now you need a way of dispatching the interrupts and
+since this is really a chained interrupt, the dispatch function can be packaged
+as an ISR and bound to the core interrupt source it chains from. See <xref href="GUID-8B8CAEED-A89D-53B3-A311-51CF45B334B1.dita">IRQ and FIQ Dispatchers</xref> in
+general and <xref href="GUID-8B8CAEED-A89D-53B3-A311-51CF45B334B1.dita#GUID-8B8CAEED-A89D-53B3-A311-51CF45B334B1/GUID-3F0D4E4E-8D9C-51FD-A701-65C29D54AB94">Dealing
+with chained interrupts</xref> in particular. </p> </section>
+</conbody><related-links>
+<link href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-A87DE0F9-2095-5CA6-BE88-3A2EAABB0D33">
+<linktext>Interrupts in the                 split ASSP/Variant Configuration</linktext>
+</link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-8B8CAEED-A89D-53B3-A311-51CF45B334B1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,178 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-8B8CAEED-A89D-53B3-A311-51CF45B334B1" xml:lang="en"><title>IRQ
+and FIQ Dispatchers</title><shortdesc>The ASSP must supply two dispatcher functions, one for IRQ interrupts,
+and one for FIQ interrupts.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> The following example code is a simple dispatcher for IRQ interrupts.
+It assumes a simplistic interrupt controller that provides 32 interrupt sources,
+and has a 32-bit pending-interrupt register where a 'one' bit indicates a
+pending interrupt and all ones are cleared when the register is read. </p>
+<codeblock id="GUID-1603305D-1509-5E80-89C1-B3998B557216" xml:space="preserve">void IrqDispatch()
+    {
+    TUint32 pendingIrqs = TheAssp::IrqPendingRegister();
+    // for the purposes of this example we assume that reading
+    // this register also clears the pending flags
+
+    TInt index = 0;
+    while( pendingIrqs )
+        {
+        // while there is at least one pending IRQ
+        if( pendingIrqs &amp; 1 )
+            {
+            // the next interrupt is pending - dispatch it
+            (IsrHandlers[index].iIsr)(IsrHandlers[index].iPtr);
+            }
+        ++index;
+        pendingIrqs &gt;&gt;= 1;
+        }
+    }
+</codeblock>
+<p>The code assumes that the interrupt source represented by the low order
+bit in the pending-interrupt register is represented by interrupt ID number
+0 etc. </p>
+<p>When implementing the dispatcher it is usual to write it in C++ initially,
+but once you have it working you would probably want to rewrite it in assembler
+to gain maximum efficiency for what is a time-critical section of code. </p>
+<section id="GUID-3F0D4E4E-8D9C-51FD-A701-65C29D54AB94"><title>Dealing with
+chained interrupts</title> <p>There are two considerations when dealing with <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-9026A4AC-57AF-545D-887C-AF43E0B37EDC">chained
+interrupts</xref>: </p> <ol id="GUID-DB84BE88-14E8-5124-9D43-4FC523311B65">
+<li id="GUID-DA20FB18-6949-5CDC-B44B-65A43283558A"><p>how to identify interrupts
+on the lower priority chained controllers </p> </li>
+<li id="GUID-17C8A3C8-CCC5-574F-B7E2-C72CC2685569"><p>how to handle the dispatch
+of a chained interrupt. </p> </li>
+</ol> <p>The first point is a question of allocating locations in your <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-77E83634-BBF6-5190-9434-9FB700547CD0">ISR
+table</xref> for the secondary controllers so that the <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-8E58F4C9-0290-55E0-A4FD-B6C2361BE205">interrupt ID</xref> identifies which hardware controller the interrupt is
+on. For example, if each interrupt controller handles 32 interrupt sources,
+you could make the first 32 IDs refer to the highest-level controller, the
+next 32 refer to one of the second-level controllers etc. </p> <p>There is
+no need to change the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-4E3CB472-3525-32F8-9BC4-8ECFEE931E7B"><apiname>Interrupt::Bind()</apiname></xref> and <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-CCC9A397-608C-3EAF-830F-A59800C2E8E5"><apiname>Interrupt::Unbind()</apiname></xref> functions,
+although you may need to consider extending the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-BB169E6E-D8F9-3762-899D-6DBA4B29CF87"><apiname>Interrupt::Enable()</apiname></xref> and <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-2D14E023-E6ED-39BF-8B31-6FA510957A8A"><apiname>Interrupt::Disable()</apiname></xref> functions
+to enable and disable the chain interrupt in a higher-level interrupt controller,
+if necessary. </p> <p>There are at least two ways of dispatching a chained
+interrupt: </p> <p><b>Dispatching a chained interrupt (1)</b> </p> <p>One
+way of dispatching a chained interrupt is simply to make it a special case
+in the main interrupt dispatcher. For example: </p> <codeblock id="GUID-189585CD-03BF-5E1F-ACD0-4AE2578D061B" xml:space="preserve">void IrqDispatch()
+    {
+    TUint32 pendingIrqs = TheAssp::IrqPendingRegister();
+
+    TInt index = 0;
+    while( pendingIrqs )
+        {
+        if( pendingIrqs &amp; 1 )
+            {
+            if( index == EMainIntChainIrq )
+                {
+                // second-level controller is signalling
+                SecondLevelIrqDispatch();
+                }
+            else
+                {
+                // call ISR
+                (IsrHandlers[index].iIsr)(IsrHandlers[index].iPtr);
+                }
+            }
+        ++index;
+        pendingIrqs &gt;&gt;= 1;
+        }
+    }
+</codeblock> <p>This approach works for a simple case, for example, where
+there is only a main and secondary interrupt controller. It is does not scale
+well because the special cases in the dispatcher become an overhead on the
+dispatch of normal, unchained interrupts as the number and depth of the chaining
+increases. </p> <p><b>Dispatching a chained interrupt (2)</b> </p> <p>A better
+way of handling chained interrupts is to bind an ISR to the interrupt source
+in the main interrupt controller and use it to dispatch the chained interrupt.
+This is far more scalable because you can bind any number of ISRs without
+having to add special cases to any of the interrupt dispatchers. </p> <p>The
+dispatcher code could then be re-implemented as: </p> <codeblock id="GUID-3B8BE593-C391-5D1F-BE94-5386306F773B" xml:space="preserve">void IrqDispatch()
+    // MAIN IRQ DISPATCHER, FIRST-LEVEL INTERRUPT
+    {
+    TUint32 pendingIrqs = TheAssp::IrqPendingRegister();
+
+    TInt index = 0;
+    while( pendingIrqs )
+        {
+        if( pendingIrqs &amp; 1 )
+            {
+            (IsrHandlers[index].iIsr)(IsrHandlers[index].iPtr);
+            }
+        ++index;
+        pendingIrqs &gt;&gt;= 1;
+        }
+    }
+</codeblock> <codeblock id="GUID-D38C0DE2-3171-59AB-AEE2-7CC5E26C4E17" xml:space="preserve">void SecondLevelIrqDispatch( TAny* /* aParam */ )
+    {
+    TUint32 pendingIrqs = TheAssp::SecondLevelIrqPendingRegister();
+ 
+    TInt index = EStartOfSecondLevelIntId;
+    while( pendingIrqs )
+        {
+        if( pendingIrqs &amp; 1 )
+            {
+            (IsrHandlers[index].iIsr)(IsrHandlers[index].iPtr);
+            }
+        ++index;
+        pendingIrqs &gt;&gt;= 1;
+        }
+    }
+</codeblock> <codeblock id="GUID-87385945-E0DB-5396-A8EB-8B8F2B2EA80F" xml:space="preserve">void InitialiseSecondLevelDispatch()
+    // Bind and enable the second-level dispatcher
+    {
+    Interrupt::Bind(EMainIntChainIrq,SecondLevelIrqDispatch,NULL);
+    Interrupt::Enable( EMainIntChainIrq );
+    }
+</codeblock> <fig id="GUID-4109B9AA-BAE7-5454-9556-DC6D40AC75B9">
+<title>Interrupt sources</title>
+<image href="GUID-970EC5A9-8ED3-53C5-93A3-2EC1A7B6F25F_d0e13980_href.png" placement="inline"/>
+</fig> <ul>
+<li id="GUID-7257146C-52C7-5C2F-B6F6-B32B558A0620"><p>The second level dispatcher, <codeph>SecondLevelIrqDispatch()</codeph>,
+is itself an ISR, and takes a <xref href="GUID-6D079976-9119-31FA-8E21-C3B815F94648.dita"><apiname>TAny</apiname></xref> * parameter, but is
+not needed in this specific example. It reads the interrupt pending register
+of the second-level interrupt controller. Note, however, that the <xref href="GUID-6D079976-9119-31FA-8E21-C3B815F94648.dita"><apiname>TAny</apiname></xref> *
+parameter may be useful when the second level dispatcher is in the variant
+as opposed to the ASSP. In that case you have separate interrupt IDs for variant
+level interrupts and separate ISR tables. The <xref href="GUID-6D079976-9119-31FA-8E21-C3B815F94648.dita"><apiname>TAny</apiname></xref> * parameter
+can point to the appropriate ISR table. Alternatively the <xref href="GUID-6D079976-9119-31FA-8E21-C3B815F94648.dita"><apiname>TAny</apiname></xref> *
+can point to a data block containing IO addresses - especially useful if you
+have many I/O devices mapped as hardware chunks. See the code in <filepath>...\assabet\specific\variant.cpp</filepath>. </p> </li>
+<li id="GUID-7ACA87E5-136F-56C2-855C-2F0C7486C13F"><p>The index count starts
+at offset <codeph>EStartOfSecondLevelIntId</codeph> into the ISR table, where
+the second-level interrupt ISRs are located. In this example, this symbol
+would equate to 32. </p> </li>
+<li id="GUID-0CDF7519-D979-5F49-ABBB-C3DC55426065"><p> <codeph>EMainIntChainIrq</codeph> is
+the interrupt ID of the chained interrupt source to the main interrupt controller. </p> </li>
+</ul> </section>
+<section id="GUID-BE4C910E-5FC7-4F83-AFF9-1070464FDA59"><title>Dealing with multiple interrupt sources</title> <p>The case
+where multiple peripherals are connected to the same interrupt source can
+be handled through the technique of pseudo interrupt sources. This involves
+assigning pseudo-interrupt IDs in the ISR table to correspond to each of the
+peripherals that is attached to the interrupt line, i.e. ISRs are bound to
+these pseudo-interrupt sources. </p> <p>Dealing with pseudo interrupt sources
+is, in essence, a special case of <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-9026A4AC-57AF-545D-887C-AF43E0B37EDC">Chained
+interrupts</xref>. </p> <p>The dispatcher can do one of two things: </p> <ul>
+<li id="GUID-152A4626-FE77-5EED-9648-6ED1B08C04E8"><p>examine the peripheral
+hardware to determine which of the interrupts are pending, and then call the
+appropriate ISR </p> </li>
+<li id="GUID-320CC5CC-A60D-5681-92AD-922DE1F97D95"><p>call all the ISRs and
+leave them to determine whether their peripheral is actually signalling an
+interrupt. </p> </li>
+</ul> <p>As usual, it is entirely up to you to choose the ID numbers for these
+pseudo-interrupts. </p> <p>There should be no need to alter the implementations
+of <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-4E3CB472-3525-32F8-9BC4-8ECFEE931E7B"><apiname>Interrupt::Bind()</apiname></xref> or <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-CCC9A397-608C-3EAF-830F-A59800C2E8E5"><apiname>Interrupt::Unbind()</apiname></xref> but
+you will need some special handling in <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-BB169E6E-D8F9-3762-899D-6DBA4B29CF87"><apiname>Interrupt::Enable()</apiname></xref> to
+enable the true interrupt source, and <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-2D14E023-E6ED-39BF-8B31-6FA510957A8A"><apiname>Interrupt::Disable()</apiname></xref> to
+disable this interrupt source. </p> <p>Dispatching the interrupt can be done
+in either of the two ways described in dealing with <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-9026A4AC-57AF-545D-887C-AF43E0B37EDC">chained interrupts</xref>. Making use of a special case in the main interrupt
+dispatcher is acceptable for simple cases, but for more complicated cases
+with large numbers of pseudo-interrupts or a combination of chained and pseudo-interrupts,
+it is better to use an ISR dispatcher bound to the true interrupt source. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,454 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D" xml:lang="en"><title>Base
+Starter Technology</title><shortdesc>This topic describes the purpose of the Base Starter, and which
+parts of it can be customised by phone developers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The purpose of the Base Starter is to: </p>
+<ul>
+<li id="GUID-D6418767-A7E8-5C3F-A12D-57B038D6DDEA"><p>Define a handset's local
+drives </p> </li>
+<li id="GUID-2611D5AC-D6FD-5957-A359-11D5A7200B2F"><p>Define what file systems
+(<filepath>.FSY</filepath>) and file extensions (<filepath>.FXT</filepath>)
+are to be mounted on those drives </p> </li>
+<li id="GUID-96772B04-8CC5-5248-A015-48809163B6EA"><p>Associate drive letters
+with drives </p> </li>
+<li id="GUID-36BFBCDC-0A12-53E0-8DF6-97606089A996"><p>Modify drive start-up
+behaviour </p> </li>
+<li id="GUID-C8914C2A-4FEA-5367-9C8C-5BD1B8926416"><p>Enable <xref href="GUID-89BCF9A5-ABBD-5523-BA76-FDB00B806A30.dita">fair
+scheduling and file caching</xref> on a drive by drive basis. </p> </li>
+</ul>
+<p>Handset manufacturers need to customise the Base Starter as part of the
+process of porting Symbian platform to a new device. <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-BF793E4E-8303-5C94-A297-52C5AD781B6B">Mapping local drives</xref> is the most important part of this process, but <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-89ED1556-60A5-5030-8946-7156656B7771">customisation
+using TFSStartup</xref> is also possible. </p>
+<p>Note that there are some <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-AC49186C-F69B-5D5B-8515-3CF8CD91EAF4">activities
+that the Base Starter does not do</xref>  </p>
+<section id="GUID-BF793E4E-8303-5C94-A297-52C5AD781B6B"><title>Mapping local
+drives</title> <p>There are two ways to do this: </p> <ul>
+<li id="GUID-F9A1D807-DFF0-563E-B792-0C7AE29F16CA"><p> <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-2B95B775-1BD1-5256-86D3-CD3FA12447B9">Create local drive mapping files</xref>  </p> </li>
+<li id="GUID-23B391A9-70B1-54F6-A891-422B5C6274DE"><p> <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-A195BD51-80C7-5D87-ABA2-8878CC509B84">Use automatic local drive mapping</xref>. </p> </li>
+</ul> <p id="GUID-2B95B775-1BD1-5256-86D3-CD3FA12447B9"><b>Create local drive mapping
+files</b> </p> <p>A local drive mapping file is an ASCII text file that explicitly
+defines the drive letter, file system, and file extension to be associated
+with a drive. The file contains a set of records, one for each drive, that
+specifies this information. Records are also referred to as drive mappings. </p> <p>The
+file is created as part of your hardware variant's source tree, but is copied
+into a standard location in your ROM filing system when you build the ROM. </p> <p>A
+drive mapping file has a formal structure; the main rules are: </p> <ul>
+<li id="GUID-2F5C4942-D39B-5F80-8E31-CAB8E7411554"><p>the file can contain
+a maximum of 16 different drive mappings </p> </li>
+<li id="GUID-BA8CB9C2-F3D7-5A06-9385-6FE7B3472B6C"><p>each drive mapping is
+represented by a separate record; each record occupies one line; each line
+is separated by the new line character <codeph>\n</codeph>  </p> </li>
+<li id="GUID-D1A6514F-3A2C-5B2E-818B-9933CA98BC1F"><p>information is represented
+by items separated by at least one blank character </p> </li>
+<li id="GUID-A6F6AD8B-361F-5DAC-8151-467164281CBD"><p>comments can occupy
+a whole line or can be added onto the end of a record (i.e. at the end of
+line). They are marked by a <codeph>#</codeph> character that must precede
+the start of the comment text. </p> </li>
+</ul> <p>A record, or drive mapping, has the following items, each separated
+by at least one blank character. Each item must appear in the order described: </p> <codeblock id="GUID-EC69C9D7-C7C3-5687-AB75-2157ABF012D5" xml:space="preserve">&lt;drive_letter&gt; &lt;drive_number&gt; &lt;file_system_filename&gt; &lt;file_system&gt; &lt;file_extension_filename&gt; &lt;flags&gt;</codeblock> <table id="GUID-D09A4483-1819-56A5-96C5-167D59C79E45">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph> &lt;drive_letter&gt;</codeph>  </p> </entry>
+<entry><p>A single character between <codeph>A</codeph> and <codeph>Z</codeph> followed
+by a colon. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> &lt;drive_number&gt;</codeph>  </p> </entry>
+<entry><p>The local drive number associated with the drive letter . </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>&lt;file_system_filename&gt;</codeph>  </p> </entry>
+<entry><p>The filename of the file system that is to be mounted on the drive.
+This should be the filename without the <filepath>.FSY</filepath> extension.
+If it is necessary to omit a file system file name for any reason, then this
+item should contain the null character: <codeph>0</codeph>. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> &lt;file_system&gt;</codeph>  </p> </entry>
+<entry><p>The name of the file system as implemented by <codeph>&lt;file_system_filename&gt;</codeph>. </p> <p>If
+the file system name is the same as the file name, as represented by the <codeph>&lt;file_system_filename&gt;</codeph> item,
+then supply the null character <codeph>0</codeph>. [Internally, the file system
+name is sometimes referred to as the object name.] </p> <p>Symbian platform
+supplies the following file systems: </p> <ul>
+<li id="GUID-BB05125F-DEAA-5881-8B5D-27CF2735598E"><p> <codeph> FAT</codeph>  </p> </li>
+<li id="GUID-F9CAA425-F382-5131-A2CE-A8813EC2844C"><p> <codeph> ROFS</codeph> -
+read/only file system </p> </li>
+<li id="GUID-1C9ED727-60A6-5835-B10B-BC5DF0C11763"><p> <codeph>LFFS</codeph> -
+logging flash file system </p> </li>
+<li id="GUID-B175831B-3633-5B56-AD5A-76218DFA6032"><p> <codeph> COMP</codeph> -
+composite file system (but see the description of the <codeph>FS_COMPOSITE</codeph> flag
+below) </p> </li>
+</ul> <p>Handset manufacturers may supply other file systems. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> &lt;file_extension_filename&gt;</codeph>  </p> </entry>
+<entry><p>The filename of the file extension that is to be mounted on the
+drive. This should be the filename without the <filepath>.FXT</filepath> extension.
+If it is necessary to omit a file extension file name for any reason, then
+this item should contain the null character: <codeph>0</codeph>. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>&lt;flags&gt;</codeph>  </p> </entry>
+<entry><p>A set of <i>mount</i> flags that modify the start-up behaviour of
+the local drive. More than one flag can be specified, each separated by a
+comma, with no intervening blank characters. If no flags apply, then the null
+character: <codeph>0</codeph> must be coded. </p> <p><table id="GUID-E1FCA3ED-EF56-5C3E-9596-CBBD7DF53AE1">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>FS_FORMAT_ALWAYS</codeph>  </p> </entry>
+<entry><p>Formats the drive as soon as it has been mounted. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>FS_FORMAT_COLD</codeph>  </p> </entry>
+<entry><p>Formats the drive as soon as it has been mounted if the device is
+performing a cold boot. This is generally required for internal RAM drives. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> FS_FORMAT_CORRUPT </codeph>  </p> </entry>
+<entry><p>Formats the drive, if it is found to be corrupt when mounted. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> FS_DISMNT_CORRUPT</codeph>  </p> </entry>
+<entry><p>Dismounts the drive, if it is found to be corrupt when mounted.
+The local drive mapping remains unaltered and the associated file system file
+is not unloaded. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> FS_SWAP_CORRUPT-&lt;drv&gt;</codeph>  </p> </entry>
+<entry><p>Dismounts the drive, if it is found to be corrupt when mounted,
+and swaps the mappings for this drive with the alternative drive <codeph>&lt;drv&gt;</codeph>,
+and remounts both. </p> <p>The alternative drive <codeph>&lt;drv&gt;</codeph> must
+be specified, and must follow a '<codeph>-</codeph>' character, which follows
+the <codeph>FS_SWAP_CORRUPT</codeph> symbol. </p> <p>For example, to swap
+with drive <filepath>Y:</filepath>, specify: </p> <codeblock id="GUID-9CC3B772-73D6-5F12-959A-54090AEE7EB1" xml:space="preserve">FS_SWAP_CORRUPT-Y</codeblock> <p>This
+option is commonly used when handling corrupt flash user-data drives on <filepath>C:</filepath>.
+The corrupt drive is mapped to another drive letter – allowing data to be
+extracted from it. The <filepath>C:</filepath> drive is replaced by a RAM
+disk – providing a temporary work disk for the OS, while the main one is restored.
+Note that a mapping file must not specify more than one drive for swapping,
+i.e. there can only be one occurrence of <codeph>FS_SWAP_CORRUPT</codeph> flag
+per mapping file. </p> <p>Both drives involved in the swap must be internal
+drives. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>FS_SYNC_DRIVE</codeph>  </p> </entry>
+<entry><p>Mounts this drive as a synchronous drive. This means that requests
+are handled in the main file server thread rather than in a dedicated drive
+thread. This option is normally only specified for internal RAM drives. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> FS_SCANDRIVE</codeph>  </p> </entry>
+<entry><p>Runs <filepath>Scandrive</filepath>, once mounted, but only if the
+rugged file system is enabled. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>FS_COMPOSITE</codeph>  </p> </entry>
+<entry><p>Marks the drive as contributing to the composite file system. The
+composite file system allows multiple local drives to be overlaid with each
+other, and with the core OS ROM image, and to make them appear as one drive. </p> <p>Files
+in one drive can add to, replace, or hide (i.e. logically remove) files in
+another drive </p> <p>There are number of rules: </p> <ul>
+<li id="GUID-73C84D80-12E4-5EB2-9661-6F802696F4E8"><p>the drive letter must
+always be Z: </p> </li>
+<li id="GUID-B8BA7BF4-5451-5B14-80F7-44E37DB08B23"><p>if the file system is
+omitted, i.e. both <codeph>&lt;file_system_filename&gt;</codeph> and <codeph>&lt;file_system&gt;</codeph> are
+set to '0', then the the ROFS file system is assumed, and this can be the <i>only</i> drive
+marked with <codeph>FS_COMPOSITE</codeph> in a mapping file. </p> </li>
+<li id="GUID-E64061B1-C789-57D4-BDD2-32548AC9A97B"><p>if the file system is
+explicitly specified, i.e. <codeph>&lt;file_system_filename&gt;</codeph> and <codeph>&lt;file_system&gt;</codeph> are
+set, then more than one drive can be marked with <codeph>FS_COMPOSITE</codeph>.
+However, adding a drive that uses a file system other than ROFS is <i>strongly
+discouraged</i> for performance reasons. </p> </li>
+<li id="GUID-2B4F9A89-9907-5417-91B3-94E02F212E42"><p>the order of the records
+is important, as this defines the search order when Symbian platform is working
+out which files will contribute to the final ROM. The core OS ROM file system
+(containing the kernel, kernel extensions, media drivers, the file server,
+file systems and the Base Starter executable) is searched first, followed
+by the last drive in the mapping file marked with <codeph>FS_COMPOSITE</codeph>,
+followed by the next last drive marked with <codeph>FS_COMPOSITE</codeph> etc. </p> </li>
+</ul> <p>Note: the use of <codeph>COMP</codeph> as a <codeph>&lt;file_system&gt;</codeph> seems
+to contradict the use of this flag. <codeph>COMP</codeph> was used to specify
+a composite file system that allowed a <i>single</i> drive to be combined
+with the ROM file system. For compatibility purposes, and to ensure consistency
+of syntax, you can still specify <codeph>COMP</codeph> with <codeph>FS_COMPOSITE</codeph> on
+a drive mapping, but you cannot have any other drive mappings marked as <codeph>FS_COMPOSITE</codeph>.
+If you specify <codeph>COMP</codeph>, then the underlying file system associated
+with that drive is assumed to be <codeph>ROFS</codeph>. </p> <p>See <xref href="GUID-E55EE9B5-AC5B-5C67-A23C-DDB3F40D174A.dita">Mounting multiple ROM images
+as a single ROM drive</xref> for more detail. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> FS_NO_MOUNT</codeph>  </p> </entry>
+<entry><p>Loads the file specified file system and the specified file extension,
+and maps the drive as specified, but does not mount the drive. This is often
+used in conjunction with <codeph>FS_SWAP_CORRUPT</codeph>. It allows the configuration
+for the alternative drive involved in a swap to be specified – but for the
+drive not to be mounted and accessible in normal operation. If the drive is
+involved in a swap with another, then the <codeph>FS_NO_MOUNT</codeph> state
+is ignored and the drive is mounted normally. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>FS_ALLOW_REM_ACC</codeph>  </p> </entry>
+<entry><p>This is reserved for future use. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> FS_NOT_RUGGED</codeph>  </p> </entry>
+<entry><p>Marks the mount as not rugged. Mounting the drive without the rugged
+file system means that <codeph>FS_SCANDRIVE</codeph> is not supported. If <codeph>FS_SCANDRIVE</codeph> is
+also defined, it is ignored. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> FS_SYSTEM_DRIVE</codeph>  </p> </entry>
+<entry><p>Assigns this drive as the system drive. Applications store user
+data on the system drive, and call <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>RFs::GetSystemDriveChar()</apiname></xref> to
+discover the drive letter. </p> <p>A mapping file can only specify one drive
+as the system drive. </p> <p>See <xref href="GUID-629AB2C9-BEDD-5166-8B09-F8DFF7527C03.dita">the
+system drive</xref>. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-A195BD51-80C7-5D87-ABA2-8878CC509B84"><b>Use automatic local drive
+mapping</b> </p> <p>If no drive mapping file exists or is unavailable, the
+Base Starter decides which file system to mount on each local drive by interrogating
+the capabilities of those drives. This is known as auto-detection. </p> <p>Internally,
+the Base Starter holds a table containing entries for every known supported
+local drive configuration. This table is known as the auto-configuration table.
+The information supplied by each entry in the table resembles that supplied
+by a <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-2B95B775-1BD1-5256-86D3-CD3FA12447B9">local
+drive mapping file</xref>, and contains the following information: </p> <ul>
+<li id="GUID-0713E2D9-B47F-552D-B4BB-D2B587534F86"><p>The filename of the
+file system for this configuration (the <filepath>.FSY</filepath>). The filename
+corresponds to the <codeph>&lt;file_system_filename&gt;</codeph> item in a drive
+mapping file entry. </p> </li>
+<li id="GUID-A27734C1-04DC-5741-8C9F-E28DAAC12E9B"><p>The object name of the
+file system for this configuration. The object name corresponds to the <codeph> &lt;file_system&gt;</codeph> item
+in a drive mapping file entry. </p> </li>
+<li id="GUID-1B40A8A4-C883-5385-8255-023DAA42FD24"><p>The filename of the
+file server extension for this configuration, if applicable. The filename
+corresponds to the <codeph>                   &lt;file_system&gt;</codeph> item
+in a drive mapping file entry. </p> </li>
+<li id="GUID-D50A002B-A6F5-5CE0-95A8-5327F5D43F2E"><p>The set of mount flags;
+these correspond to the <codeph>&lt;flags&gt;</codeph> items in a drive mapping
+file entry. There is one exception - <codeph>FS_SWAP_CORRUPT</codeph> is not
+supported, because it is impossible to auto-detect which drive is to be swapped. </p> </li>
+<li id="GUID-1F79E6A1-FEC3-57A7-8C50-DDC7296610C5"><p>A file system identification
+function that is used to decide whether the designated file system is really
+suitable for this drive. Each function is an internal part of the generic
+Base Starter code. </p> </li>
+</ul> <p>The Base Starter uses the following default mapping of drive letters
+to drive numbers: </p> <table id="GUID-861EC91F-CB71-5E7F-A58F-F14A890C2EC1">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b> Local drive number</b>  </p> </entry>
+<entry><p> <b> Drive letter</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>0</codeph>  </p> </entry>
+<entry><p>C</p> </entry>
+</row>
+<row>
+<entry><p> <codeph>1</codeph>  </p> </entry>
+<entry><p>D</p> </entry>
+</row>
+<row>
+<entry><p> <codeph>2</codeph>  </p> </entry>
+<entry><p>E</p> </entry>
+</row>
+<row>
+<entry><p> <codeph>3</codeph>  </p> </entry>
+<entry><p>F</p> </entry>
+</row>
+<row>
+<entry><p> <codeph>4</codeph>  </p> </entry>
+<entry><p>G</p> </entry>
+</row>
+<row>
+<entry><p> <codeph>5</codeph>  </p> </entry>
+<entry><p>H</p> </entry>
+</row>
+<row>
+<entry><p> <codeph>6</codeph>  </p> </entry>
+<entry><p>I</p> </entry>
+</row>
+<row>
+<entry><p> <codeph>7</codeph>  </p> </entry>
+<entry><p>J</p> </entry>
+</row>
+<row>
+<entry><p> <codeph>8</codeph>  </p> </entry>
+<entry><p>K</p> </entry>
+</row>
+<row>
+<entry><p> <codeph>9</codeph>  </p> </entry>
+<entry><p>L</p> </entry>
+</row>
+<row>
+<entry><p> <codeph>10</codeph>  </p> </entry>
+<entry><p>M</p> </entry>
+</row>
+<row>
+<entry><p> <codeph>11</codeph>  </p> </entry>
+<entry><p>N</p> </entry>
+</row>
+<row>
+<entry><p> <codeph>12</codeph>  </p> </entry>
+<entry><p>O</p> </entry>
+</row>
+<row>
+<entry><p> <codeph>13</codeph>  </p> </entry>
+<entry><p>P</p> </entry>
+</row>
+<row>
+<entry><p> <codeph>14</codeph>  </p> </entry>
+<entry><p>Q</p> </entry>
+</row>
+<row>
+<entry><p> <codeph>15</codeph>  </p> </entry>
+<entry><p>R</p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-89ED1556-60A5-5030-8946-7156656B7771"><title>Customisation
+using TFSStartup</title> <p>Most of the functionality provided by the Base
+Starter is provided by the class <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartup</apiname></xref>.
+This contains a number of virtual functions with default Symbian implementations.
+A handset manufacturer can create a customised version of the Base Starter,
+which overrides these functions. </p> <ul>
+<li id="GUID-49B2FC6B-E0BF-548C-9537-FE02B420EE7A"><p> <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-9B842CF3-D1A2-5BC7-8979-42EC7CD9A523">Disabling drive auto-detection</xref>  </p> </li>
+<li id="GUID-90090D6E-2788-590C-8595-4E4423E51F5B"><p> <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-4AB5A9C6-6D33-58E9-A372-033C1595DB9E">Customising for multiple hardware states</xref>  </p> </li>
+<li id="GUID-1D7344CC-0876-5973-8E57-E2619E4D8B32"><p> <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-7098B073-430F-5CA6-91C6-BCF267B33BF3">Overriding the default drive mapping</xref>  </p> </li>
+<li id="GUID-9399A990-84B2-553B-900A-DBBD7EC8C04F"><p> <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-904D8CCE-9E16-5A60-B141-9C838B1B8B44">Customising mount flags</xref>  </p> </li>
+<li id="GUID-ED7B2E26-4147-553C-9DCF-06143EEEF2ED"><p> <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-905BFBD9-AD40-5E11-AFED-F791389F1450">Customising the drive initialisation sequence</xref>  </p> </li>
+<li id="GUID-4C6122EB-9898-5874-AB65-900F739DC611"><p> <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-B93875C5-1B35-5993-89C4-B2CA5F502450">Customising Loadlocale</xref>  </p> </li>
+<li id="GUID-95C61E12-EE0B-57B8-B5FA-EB476471D93C"><p> <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-0B60FAF0-5D2F-5A0F-984C-DFB35BC09ED2">Customising the restart mode</xref>  </p> </li>
+<li id="GUID-1A1EDBF0-92B4-5369-9077-210842CA13C6"><p> <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-4E9AFD2A-57DE-528A-8F41-C79EBE44B2A0">Customising other behaviour</xref>  </p> </li>
+</ul> <p id="GUID-9B842CF3-D1A2-5BC7-8979-42EC7CD9A523"><b>Disabling drive auto-detection</b> </p> <p>The
+most common customisation is to use the supplied version of the Base Starter
+and to create one or more local drive mapping files . In this case, savings
+in code space can be made by removing the code that deals with auto-detection.
+This is achieved by adding the following line to the <filepath>MMP</filepath> file
+describing the Base Starter, and then rebuilding it. </p> <codeblock id="GUID-4D382A63-638C-5AF2-9535-88C7E3AB0869" xml:space="preserve">MACRO AUTODETECT_DISABLE</codeblock> <p id="GUID-4AB5A9C6-6D33-58E9-A372-033C1595DB9E"><b>Customising for multiple
+hardware states</b> </p> <p>If the state of your hardware varies, and it requires
+different mapping files for different states, then it is still possible to
+use the local drive mapping scheme. Examples of hardware state variations
+might be differences in the state of a switch or jumper setting, or the presence
+or absence of a hardware feature. In this situation, the ROM can be built
+with more than one mapping file. A custom version of the Base Starter provides
+its own version of the virtual function <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartUp::LocalDriveMappingFileName()</apiname></xref>;
+this checks the appropriate settings, and returns the name of the appropriate
+local drive mapping file. The returned name is the full path name. </p> <p id="GUID-7098B073-430F-5CA6-91C6-BCF267B33BF3"><b>Overriding the default drive
+mapping</b> </p> <p>To override the default mapping of drive letters to drive
+numbers on a drive by drive basis, a custom version of the Base Starter provides
+its own version of the virtual function <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartUp::DefaultLocalDrive()</apiname></xref>. </p> <p>To
+override the auto-configuration table used by the automatic local drive mapping
+scheme, for example to add support for a new <filepath>.FSY</filepath>, a
+custom version of the Base Starter provides its own version of the virtual
+function <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartUp::GetNextStandardFSInfoEntry()</apiname></xref>. </p> <p id="GUID-904D8CCE-9E16-5A60-B141-9C838B1B8B44"><b>Customising mount flags</b> </p> <p>Whether
+you use the automatic local drive mapping scheme or an explicit local drive
+mapping file, you can provide support for additional mount flags. A custom
+version of the Base Starter provides its own version of the virtual functions: </p> <ul>
+<li id="GUID-8F1D6582-946C-5D25-AEE7-95563233BDDF"><p> <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartUp::ParseCustomMountFlags()</apiname></xref>  </p> </li>
+<li id="GUID-C65F29D7-8BFD-5B84-B184-57C734F3D5EF"><p> <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartUp::HandleCustomMountFlags()</apiname></xref>  </p> </li>
+</ul> <p id="GUID-905BFBD9-AD40-5E11-AFED-F791389F1450"><b>Customising the drive initialisation
+sequence</b> </p> <p>To override the entire local drive initialisation sequence
+provided by the generic version of the Base Starter, a custom version of the
+Base Starter provides its own version of the virtual function <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartUp::LocalDriveInit()</apiname></xref>. </p> <p id="GUID-B93875C5-1B35-5993-89C4-B2CA5F502450"><b>Customising Loadlocale</b> </p> <p> <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>User::UTCOffset()</apiname></xref> is called within the <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>LoadLocale()</apiname></xref> function. Customise <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartup::LoadLocale()</apiname></xref> so
+that the offset behaviour is correct for your time zone. </p> <p>Setting the <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>User::UTCOffset()</apiname></xref> is required within EStart
+to provide backward compatibility and because it provides the system time
+to components before the timezone/locale services are initialised. </p> <p>See <xref href="GUID-15E048BA-E158-508D-9DB4-C9DF9A546090.dita">setting the universal time
+offset</xref>. </p>  <p id="GUID-0B60FAF0-5D2F-5A0F-984C-DFB35BC09ED2"><b>Customising the restart
+mode</b> </p> <p> <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartup::GetStartupMode()</apiname></xref> and <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartup::GetStartupModeFromFile()</apiname></xref> must be
+implemented to get the restart mode at start-up. </p> <p>Symbian platform
+does not define any meaning to restart mode values. It is for the use of the
+device manufacturer. </p> <p>The restart mode is defined by the HAL attribute <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>EPersistStartupM</apiname></xref>. This is a <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TAttribute</apiname></xref> enum
+value defined in class <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>HALData</apiname></xref> in <filepath>..\hal\inc\hal_data.h</filepath>. </p> <p>To
+use this attribute, define it in your variant’s <filepath>config.hcf</filepath> file
+and set an initial value in your variant’s <filepath>values.hda</filepath> file.
+The template port defines the attribute as settable using the following definition
+in the <filepath>config.hcf</filepath> file. </p> <codeblock id="GUID-DCB65835-DB05-5092-B4D0-5ABA551773F8" xml:space="preserve">EPersistStartupModeKernel : set = ProcessPersistStartupMode</codeblock> <p>The value can be changed using <codeph>HAL::Set()</codeph>. <codeph>ProcessPersistStartupMode</codeph> is
+the name of a function internal to Symbian platform. If you choose to make
+the attribute settable, you must use this definition. </p> <p>Calls to <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>HAL::Get()</apiname></xref> are routed to the function <codeph>Template::VariantHal()</codeph> in
+your variant's <filepath>variant.cpp</filepath> file, and handled by the <codeph>EVariantHalGetPersistedStartupMode</codeph> case. </p> <p>Calls
+to <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>HAL::Set()</apiname></xref> are routed to the function <codeph>Template::VariantHal()</codeph> in
+your variant's <filepath>variant.cpp</filepath> file, and handled by the <codeph>EVariantHalPersistStartupMode</codeph> case. </p> <p>You
+need to do the following: </p> <ul>
+<li id="GUID-1B0499AB-4320-598D-B4FD-89B610C8CC2D"><p>If you choose to make
+the custom startup mode settable (in Symbian platform terminology, the attribute
+is said to be derived), you need to implement <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartup::GetStartupMode()</apiname></xref>.
+Derived attributes are saved when the system is closed down. The function <codeph>GetStartupMode()</codeph> is
+called before the file server starts. </p> </li>
+<li id="GUID-EB91080D-1321-52B1-9EEA-718B02413928"><p>If you choose to make
+the custom startup mode non-settable (in Symbian platform terminology, the
+attribute is said to be non-derived), you need to implement <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartup::GetStartupModeFromFile()</apiname></xref>.
+Non-derived attributes are read from file, and this function is called after
+the file server has started. </p> </li>
+<li id="GUID-8C418384-C30C-59E2-9E2A-542701C4D0DF"><p>You need to provide
+an implementation for your <codeph>Template::VariantHal()</codeph> function
+in your <filepath>variant.cpp</filepath> file. </p> </li>
+</ul> <p>The example below is the OMAP H4 variant implementation of <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>GetStartupModeFromFile()</apiname></xref> and <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>GetStartupMode()</apiname></xref> found
+in <filepath>...\dev1\omap_hrp\h4estart\estartmain.cpp</filepath>. </p> <codeblock id="GUID-8BD6A664-7A7E-580E-AD33-46C7B6AB4FB5" xml:space="preserve">TInt TH4FSStartup::GetStartupModeFromFile()
+    {
+    if (iStartupMode != EStartupModeUndefined)
+        {
+        TInt r = ReadAndReset();
+        return r;
+        }
+    return KErrNone;
+    }
+
+TInt TH4FSStartup::GetStartupMode()
+    {
+    TInt r = ReadAndReset();
+    return r;
+    }
+
+TInt TH4FSStartup::ReadAndReset()
+    {
+    TInt value;
+    TInt r = HAL::Get(HALData::EPersistStartupModeKernel, value);
+    if (r == KErrNone)
+        {
+        iStartupMode = value;
+        }
+    r = HAL::Set(HALData::EPersistStartupModeKernel, EStartupModeUndefined);
+    return r;
+    }</codeblock> <p>See <xref href="GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8.dita#GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8/GUID-4DA41221-40B9-5BC7-B2C6-7C6EB4522508">User-Side
+Hardware Abstraction</xref>. </p> <p id="GUID-4E9AFD2A-57DE-528A-8F41-C79EBE44B2A0"><b>Customising other behaviour</b> </p> <p>You
+can change other default behaviour. For example, to add additional functionality
+related to File Server initialisation, or the initialisation of other base
+related components, then the following virtual functions can also be customised.
+Follow the links to the individual functions for more detail: </p> <ul>
+<li id="GUID-DF81E0C5-3404-50BA-B91D-D57CA5B0C08C"><p> <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartup::Init()</apiname></xref>  </p> </li>
+<li id="GUID-3D245F97-00D2-561E-A752-2ACC2EFBEC92"><p> <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartup::Run()</apiname></xref>  </p> </li>
+<li id="GUID-F700923A-3E2C-5BE0-8EBB-911C7A8C1D56"><p> <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartup::InitialiseHAL()</apiname></xref>  </p> </li>
+<li id="GUID-D60B9ADD-EB13-5FB1-A632-488383D89289"><p> <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartup::StartSystem()</apiname></xref>  </p> </li>
+<li id="GUID-93DD7CF9-77BA-56E2-8BB6-617EC6CF3865"><p> <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartup::Close()</apiname></xref>  </p> </li>
+</ul> </section>
+<section id="GUID-AC49186C-F69B-5D5B-8515-3CF8CD91EAF4"><title>Activities
+that the Base Starter does not do</title> <p>The Base Starter is responsible
+for mapping local drives to drive letters and for loading the appropriate
+file systems on local drives. It does <i>not</i> install media drivers, and
+is not responsible for deciding which local drive a media driver will register
+with. This is done by the individual media drivers and peripheral controllers
+when they are initialised. </p> <p>See <xref href="GUID-A70A01D2-467E-5BA8-A01D-6182558F3F52.dita#GUID-A70A01D2-467E-5BA8-A01D-6182558F3F52/GUID-4A8DEEAB-32C4-5431-8226-5623E2BD9098">Registering
+the media driver</xref> for information about how to register a media driver. </p> <p>See
+also <xref href="GUID-5C223AD5-4676-58B4-B3A5-066F6B69AA4D.dita#GUID-5C223AD5-4676-58B4-B3A5-066F6B69AA4D/GUID-868866C8-E90C-5291-8732-BB4E86D6B43E">Local
+Media Subsystem</xref>. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-8C22AF20-EE0E-5AD2-BEFD-FED5A7DBB09B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-8C22AF20-EE0E-5AD2-BEFD-FED5A7DBB09B" xml:lang="en"><title>LCD
+Extension</title><shortdesc>The LCD Extension is a kernel extension that manages the
+screen hardware. This section describes how to create a port of it
+for your phone hardware. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The user-side interface to the LCD Extension is defined
+by the <codeph>EHalGroupDisplay</codeph> group of HAL functions defined
+by the User-Side Hardware Abstraction (HAL). The LCD Extension implements
+a handler for this group of functions. </p>
+</conbody><related-links>
+<link href="GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8.dita#GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8/GUID-4DA41221-40B9-5BC7-B2C6-7C6EB4522508">
+<linktext>User-Side Hardware   Abstraction</linktext></link>
+<link href="GUID-8DF46A11-874A-52E5-9298-C083EA633BA0.dita"><linktext>Implementing
+Dynamic DSA Allocation</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-8C9F26BC-2579-545C-9A86-9C45E06679F0-master.png has changed
Binary file Adaptation/GUID-8C9F26BC-2579-545C-9A86-9C45E06679F0_d0e32265_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-8D237BD6-9759-4180-B190-F1624594017F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,76 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-8D237BD6-9759-4180-B190-F1624594017F" xml:lang="en"><title>Time Client Interface Tutorial — Using the Interface</title><shortdesc>Provides examples of how the Time client interface is used.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Time client interface methods can be executed independently.
+The following examples show the Time client interface functions being
+used along with an explanation.</p>
+<section id="GUID-98F7B0DE-CBA6-430C-972D-02F9AB444E1B"><title>Using
+the <xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita#GUID-CC79A63E-15DF-3437-983B-9A90966B3004/GUID-AC7C2EFB-BE71-301A-9C03-A15BDC0EF310"><apiname>MRtcAdaptation::ValidateRtc()</apiname></xref> function</title><p>An example of the use of this function is:</p><codeblock xml:space="preserve">MRtcAdaptation* rtcAdaptation = NewRtcAdaptationL();
+TPckgBuf&lt;TBool&gt; boolPckg;
+TRequestStatus status;
+
+rtcAdaptation-&gt;ValidateRtc(boolPckg, status);
+</codeblock><p>The first three lines define the instance of the <xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita"><apiname>MRtcAdaptation</apiname></xref> class and the variables that are to be used.</p><p>The fifth line invokes the <xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita#GUID-CC79A63E-15DF-3437-983B-9A90966B3004/GUID-AC7C2EFB-BE71-301A-9C03-A15BDC0EF310"><apiname>MRtcAdaptation::ValidateRtc()</apiname></xref> method. The first parameter will return the validity of the Real
+Time Clock (RTC) as a boolean value. The second parameter returns
+the completion status of the request. If the RTC clock is valid, then
+this would be <codeph>KErrNone</codeph>.</p></section>
+<section id="GUID-3D0DD0AB-4F3F-4411-B5E8-9199AB71F1A6"><title>Using
+the <xref href="GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9.dita#GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9/GUID-2D7976BE-F6D5-3FC4-8253-C34A592A63D3"><apiname>ASIC::SetSystemTimeCalibration()</apiname></xref> function</title><p>An example of the use of this function is:</p><codeblock xml:space="preserve">Asic Asic_class;
+TInt r;
+r = Asic_class::SetSystemTimeCalibration(30);</codeblock><p>In the
+above example, the RTC is being set with a time calibration value
+of 30ppm (parts per million). This means that the RTC can lose up
+to one second every 30 million seconds.</p><p>The value returned by
+this function is either <codeph>KErrNone</codeph> or a system wide
+error code if something went wrong.</p></section>
+<section id="GUID-813CB223-3385-4293-9D1C-8C712B031E8F"><title>Using
+the <xref href="GUID-C82E90BC-451B-3BB4-83E0-243061BCFA14.dita#GUID-C82E90BC-451B-3BB4-83E0-243061BCFA14/GUID-611E6535-9CCA-39E3-8236-654FF280B7CD"><apiname>MRtcAdaption::SetWakeUpAlarm()</apiname></xref> function</title><p>An example of the use of this function is:</p><codeblock xml:space="preserve"> TPckgC &lt;TTime&gt; timePckg(testTime);
+ rtcAdaptation-&gt;SetWakeupAlarm(timePckg, status); </codeblock><p>In
+the above example, the first line declares the variable to be used
+and initializes it. The second line is used to set the wake-up alarm
+time.</p></section>
+<section id="GUID-DE156EC7-759F-4BFC-BCAA-FE0E84CC83D9"><title>Using
+the <xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita#GUID-CC79A63E-15DF-3437-983B-9A90966B3004/GUID-C2A7DE1F-6354-31D6-A397-5CE690C4C67E"><apiname>MRtcAdaptation::UnsetWakeUpAlarm()</apiname></xref> function</title><p>An example of the use of this function is:</p><codeblock xml:space="preserve">TRequestStatus status;
+rtcAdaptation-&gt;UnsetWakeupAlarm(status);
+</codeblock><p>The first line declares the variable that is to be
+used. The second line deletes the current device wake-up alarm time.</p></section>
+<section id="GUID-1111CFEA-D85C-4107-BB14-618C6A5A0B3F"><title>Using
+the <xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita#GUID-CC79A63E-15DF-3437-983B-9A90966B3004/GUID-ADC7041A-23F0-319F-A163-29E8BB261D0B"><apiname>MRtcAdaptation::Cancel()</apiname></xref> function</title><p>An example of the use of this function is:</p><codeblock xml:space="preserve">rtcAdaptation-&gt;Cancel();
+</codeblock><p>In the above example, the last request made to the
+instance of the <xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita"><apiname>MRtcAdaptation</apiname></xref> class, defined as <codeph>rtcAdaptation</codeph> in the above example, will be deleted.</p></section>
+<section id="GUID-2EE46E01-006D-431E-B6C0-CAEBDDE5D53A"><title>Using
+the <xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita#GUID-CC79A63E-15DF-3437-983B-9A90966B3004/GUID-C44E98E9-6568-3628-9A7E-85379C4298FD"><apiname>MRtcAdaptation::Release()</apiname></xref> function</title><p>An example of the use of this function is:</p><codeblock xml:space="preserve">rtcAdaptation-&gt;Release();
+</codeblock><p>In the above example, a call to the destructor in the
+instance of the <xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita"><apiname>MRtcAdaptation</apiname></xref> class, defined as <codeph>rtcAdaptation</codeph> in the above example, is made.</p></section>
+<section id="GUID-C69C0225-1779-4FFC-B071-D18B71C18A74"><title>Using
+the <xref href="GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9.dita#GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9/GUID-EE99A729-F30E-3B3A-BCA2-0F10B383AB6C"><apiname>ASIC::SystemTimeInSecondsFrom2000()</apiname></xref> function</title><p>An example of the use of this function is:</p><codeblock xml:space="preserve">Asic Asic_class;
+TInt hwrtc = 0;
+Asic_class::SystemTimeInSecondsFrom2000(hwrtc);
+</codeblock><p>The first and second lines declare and initialize the
+variables and classes that are to be used. The third line calls the <xref href="GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9.dita#GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9/GUID-EE99A729-F30E-3B3A-BCA2-0F10B383AB6C"><apiname>ASIC::SystemTimeInSecondsFrom2000()</apiname></xref> function. The number
+of seconds since the start of the year 2000 is placed in the variable
+that has been passed as a parameter.</p><p>The value returned by this
+function is either <codeph>KErrNone</codeph> or a system wide error
+code (if something went wrong).</p></section>
+<section id="GUID-1BFBAEE5-AE48-4624-BD34-3D6B936C8C3B"><title>Using
+the <xref href="GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9.dita#GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9/GUID-C6983BB7-6496-3863-8109-6845F5DA62CF"><apiname>ASIC::SetSystemTimeInSecondsFrom2000()</apiname></xref> function</title><p>An example of the use of this function is:</p><codeblock xml:space="preserve">Asic Asic_class;
+TInt r=0;
+r = Asic_class::SetSystemTimeInSecondsFrom2000(0);</codeblock><p>The
+first and second lines declare and initialize the variables and classes
+that are to be used. The third line sets the RTC to be zero seconds
+from the start of the year 2000.</p><p>The value returned by this
+function is either <codeph>KErrNone</codeph> or a system wide error
+code (if something went wrong).</p></section>
+</conbody><related-links>
+<link href="GUID-10D79C75-6AB9-4717-87EF-057F19CB8283.dita"><linktext>Time
+Implementation Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-8D7ED882-C61E-4B4F-8483-A323C60BFC57.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,112 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-8D7ED882-C61E-4B4F-8483-A323C60BFC57" xml:lang="en"><title>Register Access Interface Overview</title><shortdesc>Provides a summary of the Register Access platform service
+interface.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Register Access platform service is provided by functions of
+the <xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita"><apiname>AsspRegister</apiname></xref> class. The <xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita"><apiname>AsspRegister</apiname></xref> class is defined in the <filepath>os/kernelhwsrv/kernel/eka/include/kernel/arm/assp.h</filepath> file. The functions defined in the AsspRegister class must be implemented
+in the baseport variant to allow device drivers and other kernel side
+code to access registers.</p>
+<section id="GUID-771DD532-171E-4F14-9704-EB040E5F6E67">         
+   <title>Register read functions</title>             <table id="GUID-17C79765-D70E-4739-BC15-7131F39EE1ED">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-A47E7A93-8180-38BA-8FAD-27ADA0E86EF7"><apiname>AsspRegister::Read8(TLinAddr aAddr)</apiname></xref></entry>
+<entry>Read the contents of an 8 bit register</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-41AA4058-4528-3AB7-9084-AA6053AF0656"><apiname>AsspRegister::Read16(TLinAddr aAddr)</apiname></xref></entry>
+<entry>Read the contents of a 16bit register</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-E637527E-537A-367D-91C2-A3BB3AA0A587"><apiname>AsspRegister::Read32(TLinAddr aAddr)</apiname></xref></entry>
+<entry>Read the contents of a 32 bit register</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-05FADA8D-5B77-39C6-A939-5EB1B209DD53"><apiname>AsspRegister::Read64(TLinAddr aAddr)</apiname></xref></entry>
+<entry>Read the contents of a 64 bit register</entry>
+</row>
+</tbody>
+</tgroup>
+</table>        </section>
+<section id="GUID-5E3A1EC0-C992-4C9C-B860-13B0F8F2A57B"><title>Register
+write functions</title><table id="GUID-E09626C9-EAC4-49A9-841D-FC901C303DE1">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-CB85C4D4-3652-311E-808A-048A43F49F3E"><apiname>AsspRegister::Write8(TLinAddr aAddr, TUint8 aValue)</apiname></xref></entry>
+<entry>Store a new value in an 8 bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-C20B9119-AAC8-354B-902A-B4349AEFC00E"><apiname>AsspRegister::Write16(TLinAddr aAddr, TUint16 aValue)</apiname></xref></entry>
+<entry>Store a new value in a 16 bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-E18C1674-47EA-3B70-9BEE-55302D58F83B"><apiname>AsspRegister::Write32(TLinAddr aAddr, TUint32 aValue)</apiname></xref></entry>
+<entry>Store a new value in a 32 bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-99D3233D-8F1C-3A65-BC1F-F10998728EB8"><apiname>AsspRegister::Write64(TLinAddr aAddr, TUint64 aValue)</apiname></xref></entry>
+<entry>Store a new value in a 64 bit register.</entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-8A50A6F0-3DF6-4CD6-8F08-63A87892EA2C"><title>Register
+modify functions</title><p>The difference between write and modify
+functions is that the modify function allows the client to change
+partial contents of a register using masks.</p><table id="GUID-309EC00D-9718-4114-BE12-253F5CE93C6E">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-3E66E373-E7DB-3F59-B6B1-3577AAD9FBF0"><apiname>AsspRegister::Modify8(TLinAddr aAddr, TUint8 aClearMask,
+TUint8 aSetMask)</apiname></xref></entry>
+<entry>Modify the contents of an 8 bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-9A6FF0D8-1136-3188-8D85-43EF8919FA7C"><apiname>AsspRegister::Modify16(TLinAddr aAddr, TUint16 aClearMask,
+TUint16 aSetMask)</apiname></xref></entry>
+<entry>Modify the contents of a 16 bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-035D2133-037A-36C5-B47C-A6FD00FEE3BA"><apiname>AsspRegister::Modify32(TLinAddr aAddr, TUint32 aClearMask,
+TUint32 aSetMask)</apiname></xref></entry>
+<entry>Modify the contents of a 32 bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-7127519C-305D-3727-898F-860023CE586A"><apiname>AsspRegister::Modify64(TLinAddr aAddr, TUint64 aClearMask,
+TUint64 aSetMask)</apiname></xref></entry>
+<entry>Modify the contents of a 64 bit register</entry>
+</row>
+</tbody>
+</tgroup>
+</table><p>The header file for the Registry Access platform service
+can be found <xref href="http://developer.symbian.org/xref/oss/xref/MCL/sf/os/kernelhwsrv/kernel/eka/include/kernel/arm/assp.h.dita#http://developer.symbian.org/xref/oss/xref/MCL/sf/os/kernelhwsrv/kernel/eka/include/kernel/arm/assp.h/AsspRegister">here</xref>.</p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-8D9A9283-6E55-4AC8-89CE-DD2B55D05067.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-8D9A9283-6E55-4AC8-89CE-DD2B55D05067" xml:lang="en"><title>Time Technology Guide</title><shortdesc>Describes the technology involved in the Time platform
+service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-8A45CBEB-7BE8-4AA6-B574-6C6AE0412096"><title>Real-time
+clock</title>             <p>A real-time clock is a chip that keeps
+track of elapsed time. It is more accurate and consumes less power
+than computing time from elapsed execution cycles.</p>         </section>
+<section id="GUID-0153E75E-3FA0-440A-8F71-5D040275FC1B"><title>Alarms</title><p>The real-time clock can generate interrupts at specific times.
+This provides a reliable alarm mechanism.</p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-8DC12024-7599-52E8-BCF1-D9D765EC7B9B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-8DC12024-7599-52E8-BCF1-D9D765EC7B9B" xml:lang="en"><title>Dynamic Behaviour</title><shortdesc>Describes the  behaviour of the Sound Driver for and record operations.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,809 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7" xml:lang="en"><title>Basic
+APIs</title><shortdesc>Accessing APIs and basic functions in kernel-side programs.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Device drivers, like user-side programs, need to use APIs for basic tasks
+such as managing buffers and arrays. However, the EKA2 architecture does not
+allow kernel-side programs such as drivers to link and use the User Library
+(<filepath>euser.dll</filepath>) that provides these APIs to user-side programs.
+This means kernel side code <i>cannot use the majority</i> of classes and
+functions that are available to user side code. </p>
+<p>However, some classes are available for use on both the user side and the
+kernel side. The first section of this document, <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-2CE47F55-D160-50A3-B05E-318569FDEF1F">Available EUSER functionality</xref>, explains what these are. In other cases,
+there are alternative Kernel-specific APIs or techniques that you can use.
+The second section, <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-6AE21206-A29D-5CB6-83E9-69C2E7DA566A">Coding
+techniques to replace EUSER functionality</xref>, describes these. </p>
+<p>The detailed contents are given below: </p>
+<p><b>Contents </b> </p>
+<ul>
+<li id="GUID-F2669D60-00E3-520C-BACA-E363BFEDD487"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-2CE47F55-D160-50A3-B05E-318569FDEF1F">Available EUSER functionality</xref>  </p> <ul>
+<li id="GUID-AB9D2617-556C-556B-81F2-A9E0E3CA2A60"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-1A26C8D7-E915-5280-BA1E-0B837E296EE4">8-bit descriptors</xref>  </p> </li>
+<li id="GUID-2D0B05B0-BEBB-5A71-A6CA-1FFC5848D80B"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-F8164DF1-8875-5C83-9165-9902EB51A97C">Arrays</xref> </p> </li>
+<li id="GUID-962C0A1C-5A7B-5201-956D-F38BDF59C836"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-0BC2B8B1-F797-5B65-9EE7-36A2EC5C9BC5">Character representation</xref>  </p> </li>
+<li id="GUID-36D2B096-181D-51E5-B502-E385565E7693"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-682EF1C2-4756-5E5A-B4E9-00AABD5D4CE2">Basic utility functions and classes</xref>  </p> </li>
+<li id="GUID-F9264F5E-2D3D-551D-B9DD-DCECC027021D"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-331E0310-69A3-58A6-B932-F2B44201530D">The Package Buffers API</xref>  </p> </li>
+<li id="GUID-293A58CA-F57E-5323-9B1B-A8F51D351AA2"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-5707529F-6145-58C3-A0A9-8789FF8F1C93">The UID manipulation APIs</xref>  </p> </li>
+<li id="GUID-022766DC-6F40-55BE-B02A-6544A213141B"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-E9F32C01-5C4F-5706-B992-A4F8B01171FD">Version handling API</xref>  </p> </li>
+<li id="GUID-5CA1160C-8EEC-5795-853D-C568D519534F"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-E67B4238-3CFF-5448-B711-FCD14D8D3C10">TRequestStatus</xref> </p> </li>
+<li id="GUID-AE09C566-0664-5341-9D8D-386D9CE3DFBA"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-0CA35DBF-C10D-5C35-90CD-24C53AEA41BF">TIpcArgs</xref> </p> </li>
+<li id="GUID-EE77EAFA-50E6-58E4-B64E-4E7AB5FCAEF2"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-111081C5-5BDA-516B-9B3D-9D24FAD31E5D">Basic graphic classes</xref>  </p> </li>
+</ul> </li>
+<li id="GUID-7772333C-EB62-58E1-B1FD-64B500567C9D"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-6AE21206-A29D-5CB6-83E9-69C2E7DA566A">Coding techniques to replace EUSER functionality</xref> </p> <ul>
+<li id="GUID-EF0FA499-7F16-54D6-B1BA-A0AB3071CFB5"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-CA520DD3-3601-5774-87F2-D5BA4DA2BF8E">Buffers: replacing HBufC8 with HBuf</xref>  </p> </li>
+<li id="GUID-6CAA6B7F-7F07-5047-82CE-CCAF960880AF"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-310ADB7F-A03C-5994-A918-634B7BAB7DD8">Buffers: replacing HBufC8 with C style pointers</xref>  </p> </li>
+<li id="GUID-8858CFAA-EF27-54B0-8083-74A990C5E614"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-586DD3B4-69DB-564B-AB8D-B3A02607CE02">Handling 16-bit data items</xref>  </p> </li>
+<li id="GUID-AA63211F-E5AD-554A-AAFC-3FB1336553D5"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-77C88D19-50C3-5D69-8084-BE750F100BA0">Replacing CBase with DBase</xref>  </p> </li>
+<li id="GUID-E264271B-64F3-59A3-AD65-56C9ACEB5ABF"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-585EE1D8-6080-5B37-A3BD-278B8731B7F9">Replacing User::QueryVersionSupported() with Kern::QueryVersionSupported()</xref>  </p> </li>
+</ul> </li>
+</ul>
+<section id="GUID-2CE47F55-D160-50A3-B05E-318569FDEF1F"><title>Available EUSER
+functionality</title> <p>This is a list of USER side classes, types and APIs
+that can still be used on the kernel side. However, a subset of the class
+member functions may not be available. </p> <ul>
+<li id="GUID-81D6F170-FAB0-5DE6-93BC-0027CF8E382F"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-1A26C8D7-E915-5280-BA1E-0B837E296EE4">8-bit descriptors</xref>  </p> </li>
+<li id="GUID-BF477CD1-6079-5C60-A658-0DD64111081F"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-F8164DF1-8875-5C83-9165-9902EB51A97C">Arrays</xref> </p> </li>
+<li id="GUID-63E56F9D-B261-58E7-B9F9-ED9726C7F16F"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-0BC2B8B1-F797-5B65-9EE7-36A2EC5C9BC5">Character representation (TChar)</xref>  </p> </li>
+<li id="GUID-6F9BC926-0367-57DC-8356-29A2D29D60B8"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-682EF1C2-4756-5E5A-B4E9-00AABD5D4CE2">Basic utility functions and classes</xref>  </p> </li>
+<li id="GUID-17051C1E-21DE-567C-ADB4-11D18314B0FC"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-331E0310-69A3-58A6-B932-F2B44201530D">The Package Buffers API</xref>  </p> </li>
+<li id="GUID-3BCFE3A4-9B93-5D2D-BA1E-71F2544028AC"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-5707529F-6145-58C3-A0A9-8789FF8F1C93">The UID manipulation APIs</xref>  </p> </li>
+<li id="GUID-4C2730C0-D22F-5855-9D11-8049B1BDEF5E"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-E9F32C01-5C4F-5706-B992-A4F8B01171FD">Version handling API</xref>  </p> </li>
+<li id="GUID-44CEA8AD-36B9-59DF-9469-9A905A600ED4"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-E67B4238-3CFF-5448-B711-FCD14D8D3C10">TRequestStatus</xref> </p> </li>
+<li id="GUID-A867EDC0-DD2E-5E6D-ABC8-E57CECDA6158"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-0CA35DBF-C10D-5C35-90CD-24C53AEA41BF">TIpcArgs</xref> </p> </li>
+<li id="GUID-D0E83441-2258-5660-99F1-5BCBB799DEA8"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-111081C5-5BDA-516B-9B3D-9D24FAD31E5D">Basic graphic classes</xref>  </p> </li>
+</ul> <p id="GUID-1A26C8D7-E915-5280-BA1E-0B837E296EE4"><b>8-bit descriptors</b> </p> <p>The
+following classes, defined in <filepath>e32des8.h</filepath>, <i>can</i> be
+used on the kernel side. </p> <p>For some classes, the kernel side can use
+the same member functions that are available to the user side. However, for
+other classes, the kernel side is restricted to using a subset of functions;
+where this is the case, the functions are listed </p> <table id="GUID-CCC5A82F-8A1B-52F2-8B0A-036801F68C68">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Classes available </b>  </p> </entry>
+<entry><p> <b>Public member functions that are available to kernel side code</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-FB97E0A3-352A-316F-97C6-69E4741A8120.dita"><apiname>TDesC8</apiname></xref>  </p> </entry>
+<entry><p> <codeph>TInt operator&lt;(const TDesC8 &amp;aDes) const;</codeph>  </p> <p> <codeph>TInt
+operator&lt;=(const TDesC8 &amp;aDes) const;</codeph>  </p> <p> <codeph>TInt
+operator&gt;(const TDesC8 &amp;aDes) const;</codeph>  </p> <p> <codeph>TInt operator&gt;=(const
+TDesC8 &amp;aDes) const;</codeph>  </p> <p> <codeph>TInt operator==(const
+TDesC8 &amp;aDes) const;</codeph>  </p> <p> <codeph>TInt operator!=(const
+TDesC8 &amp;aDes) const;</codeph>  </p> <p> <codeph> const TUint8 &amp;operator[](TInt
+anIndex) const;</codeph> </p> <p> <codeph>TInt Length() const;</codeph>  </p> <p> <codeph>TInt
+Size() const;</codeph>  </p> <p> <codeph>const TUint8 *Ptr() const;</codeph>  </p> <p> <codeph>TInt
+Compare(const TDesC8 &amp;aDes) const;</codeph>  </p> <p> <codeph>TInt Match(const
+TDesC8 &amp;aDes) const;</codeph>  </p> <p> <codeph>TInt MatchF(const TDesC8
+&amp;aDes) const;</codeph>  </p> <p> <codeph>TInt MatchC(const TDesC8 &amp;aDes)
+const;</codeph>  </p> <p> <codeph>TInt Locate(TChar aChar) const;</codeph>  </p> <p> <codeph>TInt
+LocateReverse(TChar aChar) const;</codeph>  </p> <p> <codeph>TInt Find(const
+TDesC8 &amp;aDes) const;</codeph>  </p> <p> <codeph>TInt Find(const TUint8
+*pS,TInt aLenS) const;</codeph>  </p> <p> <codeph>TPtrC8 Left(TInt aLength)
+const;</codeph>  </p> <p> <codeph>TPtrC8 Right(TInt aLength) const;</codeph>  </p> <p> <codeph>TPtrC8
+Mid(TInt aPos) const;</codeph>  </p> <p> <codeph>TPtrC8 Mid(TInt aPos,TInt
+aLength) const;</codeph>  </p> <p> <codeph>TInt CompareF(const TDesC8 &amp;aDes)
+const;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-445B19E5-E2EE-32E2-8D6C-C7D6A9B3C507.dita"><apiname>TDes8</apiname></xref>  </p> </entry>
+<entry><p> <codeph>TDes8&amp; operator=(const TUint8 *aString);</codeph>  </p> <p> <codeph>TDes8&amp;
+operator=(const TDesC8 &amp;aDes);</codeph>  </p> <p> <codeph>TDes8&amp; operator=(const
+TDes8 &amp;aDes);</codeph>  </p> <p> <codeph>TInt MaxLength() const;</codeph>  </p> <p> <codeph>TInt
+MaxSize() const;</codeph>  </p> <p> <codeph>const TUint8 &amp;operator[](TInt
+anIndex) const;</codeph>  </p> <p> <codeph>TUint8 &amp;operator[](TInt anIndex);</codeph>  </p> <p> <codeph>TDes8
+&amp;operator+=(const TDesC8 &amp;aDes);</codeph>  </p> <p> <codeph>void Zero();</codeph>  </p> <p> <codeph>void
+SetLength(TInt aLength);</codeph>  </p> <p> <codeph>void SetMax();</codeph>  </p> <p> <codeph>void
+Copy(const TDesC8 &amp;aDes);</codeph>  </p> <p> <codeph>void Copy(const TUint8
+*aBuf,TInt aLength);</codeph>  </p> <p> <codeph>void Copy(const TUint8 *aString);</codeph>  </p> <p> <codeph>void
+Copy(const TDesC16 &amp;aDes);</codeph>  </p> <p> <codeph>void Append(TChar
+aChar);</codeph>  </p> <p> <codeph>void Append(const TDesC8 &amp;aDes);</codeph>  </p> <p> <codeph>void
+Append(const TDesC16 &amp;aDes);</codeph>  </p> <p> <codeph>void Append(const
+TUint8 *aBuf,TInt aLength);</codeph>  </p> <p> <codeph>void Fill(TChar aChar);</codeph>  </p> <p> <codeph>void
+Fill(TChar aChar,TInt aLength);</codeph>  </p> <p> <codeph>void FillZ();</codeph>  </p> <p> <codeph>void
+FillZ(TInt aLength);</codeph>  </p> <p> <codeph>void Num(TInt64 aVal);</codeph>  </p> <p> <codeph> void
+Num(TUint64 aVal, TRadix aRadix);</codeph>  </p> <p> <codeph>void NumFixedWidth(TUint
+aVal,TRadix aRadix,TInt                      aWidth);</codeph>  </p> <p> <codeph>void
+AppendNum(TInt64 aVal);</codeph>  </p> <p> <codeph>void AppendNum(TUint64
+aVal, TRadix aRadix);</codeph>  </p> <p> <codeph>void AppendNumFixedWidth(TUint
+aVal,TRadix aRadix,TInt                      aWidth);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6DF731E4-5691-31C4-BEE0-03A3873F15EC.dita"><apiname>TPtrC8</apiname></xref>  </p> </entry>
+<entry><p>Same as for user side code. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C0D29B11-1535-3D11-B318-B18D30A6120B.dita"><apiname>TPtr8</apiname></xref>  </p> </entry>
+<entry><p>Same as for user side code. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-5B1CA2E7-E3A7-3AF8-9EB0-662E130C45DA.dita"><apiname>TBufC8</apiname></xref>  </p> </entry>
+<entry><p>Same as for user side code. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-78E993D5-A845-32B4-B41A-947ABEF16AA0.dita"><apiname>TBuf8</apiname></xref>  </p> </entry>
+<entry><p>Same as for user side code. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6A13E649-D15A-3BD7-B5C2-4DC23211F276.dita"><apiname>TDes8Overflow</apiname></xref>  </p> </entry>
+<entry><p>Same as for user side code. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A188447C-9DAA-3963-B6F2-893910450FC7.dita"><apiname>TLitC8</apiname></xref>  </p> </entry>
+<entry><p>Same as for user side code. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-F8164DF1-8875-5C83-9165-9902EB51A97C"><b>Arrays</b> </p> <p>The
+following classes, defined in <filepath>e32cmn.h</filepath>, <i>can</i> be
+used on the kernel side. </p> <p>For some classes, the kernel side can use
+the same member functions that are available to the user side. However, for
+other classes, the kernel side is restricted to using a subset of functions;
+where this is the case, the functions are listed </p> <table id="GUID-858768C2-7159-5AF9-9704-C95F6FB14204">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Classes available </b>  </p> </entry>
+<entry><p> <b>Public member functions that are available to kernel side code</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-FAEBF321-6B08-3041-A01F-B1E7282D0707.dita"><apiname> RArray</apiname></xref> &lt;class T&gt; </p> </entry>
+<entry><p> <codeph>RArray();</codeph>  </p> <p> <codeph>RArray(TInt aGranularity);</codeph>  </p> <p> <codeph>RArray(TInt
+aGranularity, TInt aKeyOffset);</codeph>  </p> <p> <codeph>RArray(TInt aMinGrowBy,
+TInt aKeyOffset, TInt                      aFactor);</codeph>  </p> <p> <codeph>void
+Close(); inline TInt Count() const;</codeph>  </p> <p> <codeph>const T&amp;
+operator[](TInt anIndex) const;</codeph>  </p> <p> <codeph>T&amp; operator[](TInt
+anIndex);</codeph>  </p> <p> <codeph>TInt Append(const T&amp; anEntry);</codeph>  </p> <p> <codeph>TInt
+Insert(const T&amp; anEntry, TInt aPos);</codeph>  </p> <p> <codeph>void Remove(TInt
+anIndex);</codeph>  </p> <p> <codeph>void Compress();</codeph>  </p> <p> <codeph>void
+Reset();</codeph>  </p> <p> <codeph>TInt Find(const T&amp; anEntry) const;</codeph>  </p> <p> <codeph>TInt
+Find(const T&amp; anEntry,                      TIdentityRelation&lt;T&gt; anIdentity)
+const;</codeph>  </p> <p> <codeph>TInt FindInSignedKeyOrder(const T&amp; anEntry)
+                     const;</codeph>  </p> <p> <codeph> TInt FindInUnsignedKeyOrder(const
+T&amp; anEntry)                      const;</codeph>  </p> <p> <codeph>TInt
+FindInOrder(const T&amp; anEntry,                      TLinearOrder&lt;T&gt;
+anOrder) const;</codeph>  </p> <p> <codeph>TInt FindInSignedKeyOrder(const
+T&amp; anEntry, TInt&amp;                      anIndex) const;</codeph>  </p> <p> <codeph>TInt
+FindInUnsignedKeyOrder(const T&amp; anEntry,                      TInt&amp;
+anIndex) const;</codeph>  </p> <p> <codeph>TInt FindInOrder(const T&amp; anEntry,
+TInt&amp; anIndex,                      TLinearOrder&lt;T&gt; anOrder) const;</codeph>  </p> <p> <codeph>TInt
+SpecificFindInSignedKeyOrder(const T&amp; anEntry,                      TInt
+aMode) const;</codeph>  </p> <p> <codeph>TInt SpecificFindInUnsignedKeyOrder(const
+T&amp; anEntry,                      TInt aMode) const;</codeph>  </p> <p> <codeph>TInt
+SpecificFindInOrder(const T&amp; anEntry,                      TLinearOrder&lt;T&gt;
+anOrder, TInt aMode) const;</codeph>  </p> <p> <codeph>TInt SpecificFindInSignedKeyOrder(const
+T&amp; anEntry,                      TInt&amp; anIndex, TInt aMode) const;</codeph>  </p> <p> <codeph>TInt
+SpecificFindInUnsignedKeyOrder(const T&amp; anEntry,                     
+TInt&amp; anIndex, TInt aMode) const;</codeph>  </p> <p> <codeph>TInt SpecificFindInOrder(const
+T&amp; anEntry, TInt&amp;                      anIndex, TLinearOrder&lt;T&gt;
+anOrder, TInt aMode) const;</codeph>  </p> <p> <codeph>TInt InsertInSignedKeyOrder(const
+T&amp; anEntry);</codeph> </p> <p> <codeph>TInt InsertInUnsignedKeyOrder(const
+T&amp;                      anEntry);</codeph>  </p> <p> <codeph>TInt InsertInOrder(const
+T&amp; anEntry,                      TLinearOrder&lt;T&gt; anOrder);</codeph>  </p> <p> <codeph>TInt
+InsertInSignedKeyOrderAllowRepeats(const T&amp;                      anEntry);</codeph>  </p> <p> <codeph>TInt
+InsertInUnsignedKeyOrderAllowRepeats(const T&amp;                      anEntry);</codeph>  </p> <p> <codeph>TInt
+InsertInOrderAllowRepeats(const T&amp; anEntry,                      TLinearOrder&lt;T&gt;
+anOrder);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-FAEBF321-6B08-3041-A01F-B1E7282D0707.dita"><apiname>RArray</apiname></xref> &lt;TInt&gt; </p> </entry>
+<entry><p> <codeph>RArray();</codeph>  </p> <p> <codeph>RArray(TInt aGranularity);</codeph>  </p> <p> <codeph>RArray(TInt
+aMinGrowBy, TInt aFactor);</codeph>  </p> <p> <codeph>void Close();</codeph>  </p> <p> <codeph>TInt
+Count() const;</codeph>  </p> <p> <codeph>const TInt&amp; operator[](TInt
+anIndex) const;</codeph>  </p> <p> <codeph>TInt&amp; operator[](TInt anIndex);</codeph>  </p> <p> <codeph>TInt
+Append(TInt anEntry);</codeph>  </p> <p> <codeph>TInt Insert(TInt anEntry,
+TInt aPos);</codeph>  </p> <p> <codeph>void Remove(TInt anIndex);</codeph>  </p> <p> <codeph>void
+Compress();</codeph>  </p> <p> <codeph>void Reset();</codeph>  </p> <p> <codeph>TInt
+Find(TInt anEntry) const;</codeph>  </p> <p> <codeph>TInt FindInOrder(TInt
+anEntry) const;</codeph>  </p> <p> <codeph>TInt FindInOrder(TInt anEntry,
+TInt&amp; anIndex) const;                      </codeph>  </p> <p> <codeph>TInt
+SpecificFindInOrder(TInt anEntry, TInt aMode)                      const;</codeph>  </p> <p> <codeph>TInt
+SpecificFindInOrder(TInt anEntry, TInt&amp; anIndex,                     
+TInt aMode) const;</codeph>  </p> <p> <codeph>TInt InsertInOrder(TInt anEntry);</codeph>  </p> <p> <codeph>TInt
+InsertInOrderAllowRepeats(TInt anEntry);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-FAEBF321-6B08-3041-A01F-B1E7282D0707.dita"><apiname>RArray</apiname></xref> &lt;TUint&gt; </p> </entry>
+<entry><p> <codeph>RArray();</codeph>  </p> <p> <codeph>RArray(TInt aGranularity);</codeph>  </p> <p> <codeph>RArray(TInt
+aMinGrowBy, TInt aFactor);</codeph>  </p> <p> <codeph>void Close();</codeph>  </p> <p> <codeph>TInt
+Count() const;</codeph>  </p> <p> <codeph>const TUint&amp; operator[](TInt
+anIndex) const;</codeph>  </p> <p> <codeph>TUint&amp; operator[](TInt anIndex);</codeph>  </p> <p> <codeph>TInt
+Append(TUint anEntry);</codeph>  </p> <p> <codeph>TInt Insert(TUint anEntry,
+TInt aPos);</codeph>  </p> <p> <codeph>void Remove(TInt anIndex);</codeph>  </p> <p> <codeph>void
+Compress();</codeph>  </p> <p> <codeph>void Reset();</codeph>  </p> <p> <codeph>TInt
+Find(TUint anEntry) const;</codeph>  </p> <p> <codeph>TInt FindInOrder(TUint
+anEntry) const;</codeph>  </p> <p> <codeph>TInt FindInOrder(TUint anEntry,
+TInt&amp; anIndex) const;                      </codeph>  </p> <p> <codeph>TInt
+SpecificFindInOrder(TUint anEntry, TInt aMode)                      const;</codeph>  </p> <p> <codeph>TInt
+SpecificFindInOrder(TUint anEntry, TInt&amp;                      anIndex,
+TInt aMode) const;</codeph>  </p> <p> <codeph>TInt InsertInOrder(TUint anEntry);</codeph>  </p> <p> <codeph>TInt
+InsertInOrderAllowRepeats(TUint anEntry);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-AAA13D1F-1BD7-3331-BB8C-11FA2795B53F.dita"><apiname>RPointerArray</apiname></xref> &lt;class T&gt; </p> </entry>
+<entry><p> <codeph>RPointerArray();</codeph>  </p> <p> <codeph>RPointerArray(TInt
+aGranularity);</codeph>  </p> <p> <codeph>RPointerArray(TInt aMinGrowBy, TInt
+aFactor);</codeph>  </p> <p> <codeph>void Close();</codeph>  </p> <p> <codeph>TInt
+Count() const;</codeph>  </p> <p> <codeph>T* const&amp; operator[](TInt anIndex)
+const;</codeph>  </p> <p> <codeph>T*&amp; operator[](TInt anIndex);</codeph>  </p> <p> <codeph>TInt
+Append(const T* anEntry);</codeph>  </p> <p> <codeph>TInt Insert(const T*
+anEntry, TInt aPos);</codeph>  </p> <p> <codeph>void Remove(TInt anIndex);</codeph>  </p> <p> <codeph>void
+Compress();</codeph>  </p> <p> <codeph>void Reset();</codeph>  </p> <p> <codeph>void
+ResetAndDestroy();</codeph>  </p> <p> <codeph>TInt Find(const T* anEntry)
+const;</codeph>  </p> <p> <codeph>TInt Find(const T* anEntry, TIdentityRelation&lt;T&gt;
+                     anIdentity) const;</codeph>  </p> <p> <codeph>TInt FindInAddressOrder(const
+T* anEntry) const;</codeph>  </p> <p> <codeph>TInt FindInOrder(const T* anEntry,
+TLinearOrder&lt;T&gt;                      anOrder) const;</codeph>  </p> <p> <codeph>TInt
+FindInAddressOrder(const T* anEntry, TInt&amp;                      anIndex)
+const;</codeph>  </p> <p> <codeph>TInt FindInOrder(const T* anEntry, TInt&amp;
+anIndex,                      TLinearOrder&lt;T&gt; anOrder) const;</codeph>  </p> <p> <codeph>TInt
+SpecificFindInAddressOrder(const T* anEntry, TInt                      aMode)
+const;);</codeph>  </p> <p> <codeph>TInt SpecificFindInOrder(const T* anEntry,
+                     TLinearOrder&lt;T&gt; anOrder, TInt aMode) const;</codeph>  </p> <p> <codeph>TInt
+SpecificFindInAddressOrder(const T* anEntry,                      TInt&amp;
+anIndex, TInt aMode) const;</codeph>  </p> <p> <codeph>TInt SpecificFindInOrder(const
+T* anEntry, TInt&amp;                      anIndex, TLinearOrder&lt;T&gt; anOrder,
+TInt aMode) const;</codeph>  </p> <p> <codeph>TInt InsertInAddressOrder(const
+T* anEntry);</codeph>  </p> <p> <codeph>TInt InsertInOrder(const T* anEntry,
+                     TLinearOrder&lt;T&gt; anOrder);</codeph>  </p> <p> <codeph>TInt
+InsertInAddressOrderAllowRepeats(const T*                      anEntry);</codeph>  </p> <p> <codeph>TInt
+InsertInOrderAllowRepeats(const T* anEntry,                      TLinearOrder&lt;T&gt;
+anOrder);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-E75F040A-CEC6-3751-8F96-F16AEDC209A3.dita"><apiname>TIdentityRelation </apiname></xref> &lt;class T&gt; </p> </entry>
+<entry><p>Same as for user side code. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C028C373-CE25-3832-855E-17FB738721CF.dita"><apiname>TLinearOrder</apiname></xref> &lt;class T&gt; </p> </entry>
+<entry><p>Same as for user side code. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-0BC2B8B1-F797-5B65-9EE7-36A2EC5C9BC5"><b>Character representation</b> </p> <p>The
+following class, defined in <filepath>e32cmn.h</filepath>, <i>can</i> be used
+on the kernel side. </p> <p>For some classes, the kernel side can use the
+same member functions that are available to the user side. However, for other
+classes, the kernel side is restricted to using a subset of functions; where
+this is the case, the functions are listed </p> <table id="GUID-F24ABED3-1122-5FE2-8E00-87B610F7E2A6">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Classes available </b>  </p> </entry>
+<entry><p> <b>Public member functions that are available to kernel side code</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-CDCFA2A5-EA8A-3B39-B90F-77AC41571E2D.dita"><apiname>TChar</apiname></xref>  </p> </entry>
+<entry><p> <codeph>TChar();</codeph>  </p> <p> <codeph>TChar(TUint aChar);</codeph>  </p> <p> <codeph>TChar&amp;
+operator-=(TUint aChar);</codeph>  </p> <p> <codeph>TChar&amp; operator+=(TUint
+aChar);</codeph>  </p> <p> <codeph>TChar operator-(TUint aChar);</codeph>  </p> <p> <codeph>TChar
+operator+(TUint aChar);</codeph>  </p> <p> <codeph>operator TUint() const;</codeph>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-682EF1C2-4756-5E5A-B4E9-00AABD5D4CE2"><b>Basic utility
+functions and classes</b> </p> <p>The following global utility functions and
+classes, defined in <filepath>e32cmn.h</filepath>, <i>can</i> be used on the
+kernel side. </p> <table id="GUID-1754BDC5-BFB7-5E32-A956-2289FDB1C172">
+<tgroup cols="1"><colspec colname="col0"/>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-5391E485-A019-358F-85D2-3B55BA439BD1.dita"><apiname>TRefByValue</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>TInt Lim(TInt aVal,TUint aLimit);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>TInt LimX(TInt aVal,TUint aLimit);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p>template &lt;class T&gt; <codeph>T Min(T aLeft,T aRight);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p>template &lt;class T&gt; <codeph>T Min(T aLeft,TUint              
+       aRight);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p>template &lt;class T&gt; <codeph>T Max(T aLeft,T aRight);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p>template &lt;class T&gt; <codeph>T Max(T aLeft,TUint              
+       aRight);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p>template &lt;class T&gt; <codeph>T Abs(T aVal);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p>template &lt;class T&gt; <codeph>TBool Rng(T aMin,T aVal,T        
+             aMax);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p>template &lt;class T,class S&gt; <codeph>T* PtrAdd(T* aPtr,S      
+               aVal);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p>template &lt;class T,class S&gt; <codeph>T* PtrSub(T* aPtr,S      
+               aVal);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p>template &lt;class T&gt; <codeph>T Align2(T aValue);</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p>template &lt;class T&gt; <codeph>T Align4(T aValue);</codeph>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-331E0310-69A3-58A6-B932-F2B44201530D"><b>The Package
+Buffers API</b> </p> <p>The package buffers API, represented by classes defined
+in <filepath>e32cmn.h</filepath>, <i>can</i> be used on the kernel side. </p> <table id="GUID-CE1782C9-E59A-567C-8F6F-DA5AE7C50476">
+<tgroup cols="1"><colspec colname="col0"/>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-C7A094BD-846F-3ED2-8CCE-C0743DB3712A.dita"><apiname>TPckgBuf</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-36B29964-420D-38D0-AF08-4DA70BED8B6E.dita"><apiname>TPckgC</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-4DFB8E64-81FF-3D3B-9694-CE51B11DA69A.dita"><apiname>TPckg</apiname></xref>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-5707529F-6145-58C3-A0A9-8789FF8F1C93"><b>The UID manipulation
+APIs</b> </p> <p>The UID manipulation APIs, represented by classes defined
+in <filepath>e32cmn.h</filepath> can be used on the kernel side. However,
+only a <i>subset</i> of functions are available. See the detailed notes in
+the following table. </p> <table id="GUID-4E17CB02-80F9-5D3A-A3F0-0C6208D759F5">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-530281E6-29FC-33F2-BC9B-610FBA389444.dita"><apiname>TUid</apiname></xref>  </p> </entry>
+<entry><p>Only the two inline functions can be used: </p> <ul>
+<li id="GUID-1FA84853-4983-500F-B38E-AA82BB5456D6"><p> <xref href="GUID-530281E6-29FC-33F2-BC9B-610FBA389444.dita#GUID-530281E6-29FC-33F2-BC9B-610FBA389444/GUID-65B526E7-8629-3DEC-970B-1D48263D7AFD"><apiname>TUid::Uid</apiname></xref>  </p> </li>
+<li id="GUID-B588EEC3-4DB9-51D3-9DCA-DAF822006C4B"><p> <xref href="GUID-530281E6-29FC-33F2-BC9B-610FBA389444.dita#GUID-530281E6-29FC-33F2-BC9B-610FBA389444/GUID-B7F5CA42-157B-3D74-BA2E-00B290F71345"><apiname>TUid::Null()</apiname></xref>  </p> </li>
+</ul> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B6D6B0AD-B15C-339A-8540-40540885089A.dita"><apiname>TUidType</apiname></xref>  </p> </entry>
+<entry><p>None of the member functions can be used; however, the <codeph>iUid</codeph> data
+member is declared as public on the kernel side. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-1FB6F0D5-96F9-3D31-8508-9CE731A2E8E4.dita"><apiname>TUidName</apiname></xref>  </p> </entry>
+<entry><p>This will only ever be an 8-bit type descriptor. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-E9F32C01-5C4F-5706-B992-A4F8B01171FD"><b>Version handling
+API</b> </p> <p>The version handling API, represented by the <xref href="GUID-D82DEC7A-71C2-3004-BFC2-C82C009A2715.dita"><apiname>TVersion</apiname></xref> class
+defined in <filepath>e32cmn.h</filepath> can be used on the kernel side. </p> <p id="GUID-E67B4238-3CFF-5448-B711-FCD14D8D3C10"><b>TRequestStatus</b> </p> <p>The <xref href="GUID-E0B34F3E-D4C4-3232-B8B1-7DB35B454646.dita"><apiname>TRequestStatus</apiname></xref> class
+representing the completion status of an asynchronous request, and defined
+in <filepath>e32cmn.h</filepath> can be used on the kernel side. </p> <p id="GUID-0CA35DBF-C10D-5C35-90CD-24C53AEA41BF"><b>TIpcArgs</b> </p> <p>The <xref href="GUID-4AD02F14-1142-372F-9D11-224595932034.dita"><apiname>TIpcArgs</apiname></xref> class, which is part of the Version2 client/server APIs,
+and defined in <filepath>e32cmn.h</filepath>, can be used on the kernel side.
+However, the <codeph>Set()</codeph> and <codeph>Type()</codeph> member functions
+that take 16-bit descriptors are not available. </p> <p id="GUID-111081C5-5BDA-516B-9B3D-9D24FAD31E5D"><b>Basic
+graphic classes</b> </p> <p>The basic graphic classes <xref href="GUID-339EC4C5-89DC-3972-9579-6DD38D418317.dita"><apiname>TPoint</apiname></xref> and <xref href="GUID-938244B2-5E1A-39F7-8ACA-E6DE4C44A313.dita"><apiname>TSize</apiname></xref> are
+defined on the kernel side. However, only the public data members are defined
+- the member functions are not defined, and are not available for use. </p> </section>
+<section id="GUID-6AE21206-A29D-5CB6-83E9-69C2E7DA566A"><title>Coding techniques
+to replace EUSER functionality</title> <ul>
+<li id="GUID-19997154-7682-5FA8-85EA-2E24683398D5"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-CA520DD3-3601-5774-87F2-D5BA4DA2BF8E">Buffers: replacing HBufC8 with HBuf</xref>  </p> </li>
+<li id="GUID-DBAA1CE6-9A00-5A97-8954-C2B3E4DC8B3C"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-310ADB7F-A03C-5994-A918-634B7BAB7DD8">Buffers: replacing HBufC8 with C style pointers</xref>  </p> </li>
+<li id="GUID-44A25AD2-1970-5D1E-8B51-B92232F14E6F"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-586DD3B4-69DB-564B-AB8D-B3A02607CE02">Handling 16-bit data items</xref>  </p> </li>
+<li id="GUID-E9549A58-6921-5521-ACCA-E74DD962FFBC"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-77C88D19-50C3-5D69-8084-BE750F100BA0">Replacing CBase with DBase</xref>  </p> </li>
+<li id="GUID-BC1219A8-4F8F-5E91-ABE9-E8D89F904D58"><p> <xref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita#GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7/GUID-585EE1D8-6080-5B37-A3BD-278B8731B7F9">Replacing User::QueryVersionSupported() with Kern::QueryVersionSupported()</xref>  </p> </li>
+</ul> <p id="GUID-CA520DD3-3601-5774-87F2-D5BA4DA2BF8E"><b>Buffers: replacing
+HBufC8 with HBuf</b> </p> <p>In EKA2, the heap descriptor buffer, <xref href="GUID-2A528453-0279-3E47-838C-F8A8D29B88F1.dita"><apiname>HBufC8</apiname></xref> is
+not available. However, the kernel side defines and implements an equivalent
+(kernel) heap descriptor buffer: <xref href="GUID-1E0F353F-2532-3FF2-9992-06EC687C3998.dita"><apiname>HBuf8</apiname></xref>. <xref href="GUID-1E0F353F-2532-3FF2-9992-06EC687C3998.dita"><apiname>HBuf8</apiname></xref> is
+behaves in a similar way to <xref href="GUID-2A528453-0279-3E47-838C-F8A8D29B88F1.dita"><apiname>HBufC8</apiname></xref>, so nearly all of your
+code can be reused, but note the following points: </p> <ul>
+<li id="GUID-409FC5CB-F502-54ED-972E-D00AF311180C"><p>If your code uses the
+typedef <xref href="GUID-A103FB19-60B3-3E45-97A5-1F295934ACA1.dita"><apiname>HBufC</apiname></xref>, then you need to change it to <xref href="GUID-5BEA9976-B969-3949-B855-E657FFF38EE2.dita"><apiname>HBuf</apiname></xref>. </p> </li>
+<li id="GUID-889793AE-1F58-5FAE-9C58-04E3549526F9"><p>On the kernel side,
+there is no explicit support for 16-bit buffers, which means that there is
+no class called HBuf16. In practice, this means that, <xref href="GUID-5BEA9976-B969-3949-B855-E657FFF38EE2.dita"><apiname>HBuf</apiname></xref> is
+always the same as <xref href="GUID-1E0F353F-2532-3FF2-9992-06EC687C3998.dita"><apiname>HBuf8</apiname></xref>. </p> </li>
+<li id="GUID-58F6F261-69EA-5D2E-BAF1-9EF844F13B5A"><p>Unlike <xref href="GUID-2A528453-0279-3E47-838C-F8A8D29B88F1.dita"><apiname>HBufC8</apiname></xref>, <xref href="GUID-1E0F353F-2532-3FF2-9992-06EC687C3998.dita"><apiname>HBuf8</apiname></xref> is
+a modifiable type descriptor. It has <xref href="GUID-445B19E5-E2EE-32E2-8D6C-C7D6A9B3C507.dita"><apiname>TDes8</apiname></xref> in its derivation
+hierarchy, and this means that you can manipulate the descriptor's data (using
+the <xref href="GUID-445B19E5-E2EE-32E2-8D6C-C7D6A9B3C507.dita"><apiname>TDes8</apiname></xref> member functions). </p> </li>
+<li id="GUID-3D649264-94C6-598A-9F90-5ED6988A3B66"><p>The number of functions
+available to create an <xref href="GUID-1E0F353F-2532-3FF2-9992-06EC687C3998.dita"><apiname>HBuf8</apiname></xref> object is more limited than
+for <xref href="GUID-2A528453-0279-3E47-838C-F8A8D29B88F1.dita"><apiname>HBufC8</apiname></xref> - there are only three variants - although in
+practice this is not a problem: </p> <ul>
+<li id="GUID-3B3B2A9D-13E0-57D4-A9F9-F308580B8F28"><p> <codeph>HBuf8::New(TInt
+aMaxLength)</codeph> to allocate a heap descriptor buffer (on the kernel heap)
+and set its length to zero; this behaves the same as the user side <codeph>HBufC8::New(TInt
+aMaxLength)</codeph>  </p> </li>
+<li id="GUID-213F8721-16E5-5E64-9D0A-E84E75831FB5"><p> <codeph>HBuf8::New(const
+TDesC8&amp; aDes)</codeph> to allocate a heap descriptor buffer (on the kernel
+heap) and initialise it by copying an existing descriptor's data into it. </p> </li>
+<li id="GUID-EBC5B863-9671-52C8-B22A-D303AA963697"><p> <codeph>HBuf8::ReAlloc(TInt
+aNewMax)</codeph> to re-allocate (i.e. to resize) a heap descriptor buffer
+(on the kernel heap); this behaves the same as the user side <codeph>HBufC8::New(TInt
+aMaxLength)</codeph>  </p> </li>
+</ul> </li>
+<li id="GUID-67068834-2B86-5901-9BB7-C8E0158BBDA5"><p>There are no "leaving"
+variants of these functions - if you have NewL(), NewLC(), and other "leaving"
+variants, then you will need to change your code to explicitly check the return
+code to make sure that the creation, or the reallocation of the heap descriptor
+buffer has worked. </p> </li>
+<li id="GUID-D6FE65EF-A142-5B19-9F6E-718C9844B04B"><p>As the descriptor is
+modifiable, there is no need for, and there is no equivalent of the function <xref href="GUID-2A528453-0279-3E47-838C-F8A8D29B88F1.dita#GUID-2A528453-0279-3E47-838C-F8A8D29B88F1/GUID-155C7682-B1C4-38D0-9542-3829DF383050"><apiname>HBufC8::Des()</apiname></xref>;
+you just use the base class <xref href="GUID-445B19E5-E2EE-32E2-8D6C-C7D6A9B3C507.dita"><apiname>TDes8</apiname></xref> functions. </p> </li>
+<li id="GUID-28F7E8E5-4E78-5175-93B2-CA8365978A10"><p>If your code uses the
+assignment operators (i.e. the <codeph>=</codeph> operator), you don't need
+to change your code; the compiler will use the operators implemented in the <xref href="GUID-445B19E5-E2EE-32E2-8D6C-C7D6A9B3C507.dita"><apiname>TDes8</apiname></xref> base
+class, which will do the right thing. </p> </li>
+<li id="GUID-2909D8CE-D267-5EB7-9870-5253438F7E98"><p>The descriptor function <xref href="GUID-FB97E0A3-352A-316F-97C6-69E4741A8120.dita#GUID-FB97E0A3-352A-316F-97C6-69E4741A8120/GUID-FF9F5F8C-A240-354E-BBD3-44772AE5C4A4"><apiname>TDesC8::Alloc()</apiname></xref> is
+no longer available on the kernel side, so you cannot create a heap descriptor
+buffer from a general descriptor. </p> </li>
+</ul> <p>The following code fragments show code that is approximately equivalent
+between EKA1 and EKA2. The fragments are a little artificial, and make assumptions
+that would not necessarily be made in real code, but nevertheless still show
+the essential differences. </p> <table id="GUID-C5338045-8A9C-5605-AB94-04D2770183E0">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>EKA1</b>  </p> </entry>
+<entry><p> <b>EKA2</b>  </p> </entry>
+</row>
+<row>
+<entry><p>This is a function that allocates a heap descriptor buffer (<xref href="GUID-2A528453-0279-3E47-838C-F8A8D29B88F1.dita"><apiname>HBufC8</apiname></xref>),
+puts data into it, changes its size, replaces the data, deletes a part of
+the data, and then deletes it. </p> <codeblock id="GUID-DEA8F91F-DE46-5DCF-BF06-9F4E89C5F366" xml:space="preserve">_LIT8(KTxSmall,"abcdef");
+_LIT8(KTxBig,"ghijklmnopqrstuvwxyz");
+
+void X::FunctionL()
+    {
+    // Create a buffer big enough to contain
+    // the text "abcdef".
+    // This uses the "leaving" variant, and leaves
+    // if there is insufficient memory.
+    HBufC8* pBuf = HBufC8::NewL(KTxSmall().Length());
+
+    // Copy the text "abcdedf" into it
+    *pBUf = KTxSmall;
+        
+    // Make the buffer bigger...
+    // ... and check that it worked OK
+    // Note that we are using the non-leaving version.
+    // We could use the leaving version, but we would
+    // need to handle the cleanup of pBuf 
+    HBuf8* pNewBuf = pBuf-&gt;ReAlloc(KTxBig().Length());;
+
+    if (pNewBuf)
+        {
+        pBuf = pNewBuf;
+        }
+     else
+        {
+        delete pBuf;
+        User::Leave(KErrNoMemory);
+        }
+
+    // Replace content of the descriptor with 
+    // the text "ghijkl......"
+    *pBuf = KTxBig;
+
+    // Need to use the Des() function to create 
+    // a modifiable descriptor before we can make
+    // changes to the text in the descriptor.
+    TPtr8 pDesPtr;
+    pDesPtr = pBuf-&gt;Des();
+
+    // Delete the 1st two characters.
+    PDesPtr.Delete(0,2)
+     
+    delete pBUf;
+
+    return;
+    }</codeblock> </entry>
+<entry><p>A similar function, but it uses <xref href="GUID-1E0F353F-2532-3FF2-9992-06EC687C3998.dita"><apiname>HBuf8</apiname></xref> instead. </p> <codeblock id="GUID-927B0A0C-D65B-5E5C-811D-285437C473BE" xml:space="preserve">_LIT8(KTxSmall,"abcdef");
+_LIT8(KTxBig,"ghijklmnopqrstuvwxyz");
+
+TInt X::Function()
+    {
+    // Create a buffer big enough to contain
+    // the text "abcdef", and copy the text
+    // from its source into the buffer.
+    //
+    // You need to check explicitly that this
+    // has worked.
+    HBuf8* pBuf = HBuf8::New(KTxSmall);
+    if (!pBuf)
+        {
+        return KErrNoMemory;
+        }
+        
+    // Make the buffer bigger...
+    // .. and check that it worked OK
+    HBuf8* pNewBuf = pBuf-&gt;ReAlloc(KTxBig().Length());
+
+    if (pNewBuf)
+        {
+        pBuf = pNewBuf;
+        }
+     else
+        {
+        delete pBuf;
+        return KErrNoMemory;
+        }
+
+    // You can still use the =operator to replace 
+    // the content of the heap descriptor !
+    // Replace content with 
+    // the text "ghijkl......"
+    *pBuf = KTxBig;
+
+
+    // Can now use use the TDes8 functions
+    // directly.
+    // This deletes the 1st two characters.
+    pBuf-&gt;Delete(0,2);
+
+    // delete the heap descriptor
+    delete pBUf;
+
+    return KErrNone;
+    }</codeblock> </entry>
+</row>
+<row>
+<entry><p>A small code fragment that uses <xref href="GUID-FB97E0A3-352A-316F-97C6-69E4741A8120.dita#GUID-FB97E0A3-352A-316F-97C6-69E4741A8120/GUID-FF9F5F8C-A240-354E-BBD3-44772AE5C4A4"><apiname>TDesC8::Alloc()</apiname></xref> to
+create an <xref href="GUID-2A528453-0279-3E47-838C-F8A8D29B88F1.dita"><apiname>HBufC8</apiname></xref> heap descriptor buffer from an existing
+descriptor. </p> <codeblock id="GUID-7545CD6E-8849-5CE0-88A8-975F141A7877" xml:space="preserve">HBufC8* X::Function(const TDesC8&amp; aDes)
+    {
+    // Returns NULL if creation
+    // of the heap descriptor buffer fails.
+
+    return aDes.Alloc();
+    }</codeblock> <p>or possibly: </p> <codeblock id="GUID-0E01D617-B83F-558A-8C6B-BF9BD8B2E449" xml:space="preserve">HBufC8* X::FunctionL(const TDesC8&amp; aDes)
+    {
+    // Leaves if creation of the heap
+    // descriptor buffer fails, otherwise it 
+    // returns a valid pointer.
+
+    return(aDes.AllocL());
+    }</codeblock> </entry>
+<entry><p>An equivalent code fragment that creates an <xref href="GUID-1E0F353F-2532-3FF2-9992-06EC687C3998.dita"><apiname>HBuf8</apiname></xref> heap
+descriptor buffer. </p> <codeblock id="GUID-EA7187B6-8365-5F77-941A-CCCC359BF5D0" xml:space="preserve">HBuf8* X::Function(const TDesC8&amp; aDes)
+    {
+    // Returns NULL if creation
+    // of the heap descriptor buffer fails.
+   
+    return (HBuf8::New(aDes));
+    }</codeblock> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-310ADB7F-A03C-5994-A918-634B7BAB7DD8"><b>Buffers: replacing
+HBufC8 with C style pointers</b> </p> <p>Instead of replacing <xref href="GUID-2A528453-0279-3E47-838C-F8A8D29B88F1.dita"><apiname>HBufC8</apiname></xref> with <xref href="GUID-5BEA9976-B969-3949-B855-E657FFF38EE2.dita"><apiname>HBuf</apiname></xref>,
+it may be more suitable to replace your heap descriptor buffers with C style
+pointers - effectively managing your buffers in open code or as part of the
+implementation of your own purpose written classes. </p> <p>You allocate memory
+from the kernel heap using <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-DCB1C323-54D4-3C43-849A-503C19075C18"><apiname>Kern::Alloc()</apiname></xref> or <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-25A2BC43-08AB-34E8-93B4-AD4B82A98666"><apiname>Kern::AllocZ()</apiname></xref> and
+track the pointers to that memory. The following code fragments show how the
+use of HBufC8 translates to the direct use of these functions. </p> <p>Although
+the EKA2 code here uses <xref href="GUID-E2C25A1E-46B4-3697-A939-613CA366D87A.dita"><apiname>memcpy()</apiname></xref>, and <xref href="GUID-AC5005AE-EDC0-36EE-B877-2F91B09B0068.dita"><apiname>memmove()</apiname></xref>,
+you will also find the functions <xref href="GUID-5F6B1E3D-4F68-3870-96E2-8EA88D70C888.dita"><apiname>memclr()</apiname></xref>, <xref href="GUID-5A95E126-A82F-3F29-9810-FA1CD35E8B19.dita"><apiname>memset()</apiname></xref>, <xref href="GUID-9A49DF44-1742-32CF-8C13-AF732C3971A6.dita"><apiname>wordmove()</apiname></xref> and <xref href="GUID-57B71C3A-3F1E-3304-AA6C-EF53CD6682AD.dita"><apiname>memcompare()</apiname></xref> useful in your code. </p> <table id="GUID-A6F83848-EEE6-5656-BBD9-6CA8CC986AAD">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>EKA1</b>  </p> </entry>
+<entry><p> <b>EKA2</b>  </p> </entry>
+</row>
+<row>
+<entry><p>This is a function that allocates a heap descriptor buffer (<xref href="GUID-2A528453-0279-3E47-838C-F8A8D29B88F1.dita"><apiname>HBufC8</apiname></xref>),
+puts data into it, changes its size, replaces the data, deletes a part of
+the data, and then deletes the whole buffer. </p> <codeblock id="GUID-7541F426-A84A-5496-A75D-A5235DD0B45E" xml:space="preserve">_LIT8(KTxSmall,"abcdef");
+_LIT8(KTxBig,"ghijklmnopqrstuvwxyz");
+
+void X::FunctionL()
+    {
+    // Create a buffer big enough to contain
+    // the text "abcdef".
+    // This uses the "leaving" variant, and leaves
+    // if there is insufficient memory.
+    HBufC8* pBuf = HBufC8::NewL(KTxSmall().Length());
+
+    // Copy the text "abcdedf" into it
+    *pBUf = KTxSmall;
+        
+    // Make the buffer bigger...
+    // ... and check that it worked OK
+    // Note that we are using the non-leaving version.
+    // We could use the leaving version, but we would
+    // need to handle the cleanup of pBuf 
+    HBuf8* pNewBuf = pBuf-&gt;ReAlloc(KTxBig().Length());;
+
+    if (pNewBuf)
+        {
+        pBuf = pNewBuf;
+        }
+     else
+        {
+        delete pBuf;
+        User::Leave(KErrNoMemory);
+        }
+
+    // Replace content of the descriptor with 
+    // the text "ghijkl......"
+    *pBuf = KTxBig;
+
+    // Need to use the Des() function to create 
+    // a modifiable descriptor before we can make
+    // changes to the text in the descriptor.
+    TPtr8 pDesPtr;
+    pDesPtr = pBuf-&gt;Des();
+
+    // Delete the 1st two characters.
+    PDesPtr.Delete(0,2)
+     
+    delete pBUf;
+
+    return;
+    }</codeblock> </entry>
+<entry><p>A similar function, but allocates memory on the kernel heap explicitly,
+and manages its own pointers instead. Note the use of the nanokernel utility
+function: <xref href="GUID-E2C25A1E-46B4-3697-A939-613CA366D87A.dita"><apiname>memcpy()</apiname></xref>, and <xref href="GUID-AC5005AE-EDC0-36EE-B877-2F91B09B0068.dita"><apiname>memmove()</apiname></xref>  </p> <codeblock id="GUID-DB644074-0F80-58CE-9FE9-D5C5AF521849" xml:space="preserve">_LIT8(KTxSmall,"abcdef");
+_LIT8(KTxBig,"ghijklmnopqrstuvwxyz");
+
+TInt X::Function()
+    {
+    // Create a buffer big enough to contain
+    // the text "abcdef", and copy the text
+    // from its source into the buffer.
+    //
+    // Steps.
+    // 1. work out the size of buffer needed
+    // 2. Get the buffer.
+    // 3. Copy the source.
+
+    TInt lengthInBuffer = 0;
+     
+    // 1.
+    TInt Smallsize;
+    SmallSize = KTxSmall().Length();
+    lengthInBuffer = SmallSize;
+
+    // 2.
+    TUint8* pBuf;
+    pBuf = Kern::Alloc(SmallSize);
+    if (!pBuf)
+        {
+        return KErrNoMemory;
+        }
+
+    // 3.
+    memcpy(pBuf,KTxSmall().Ptr(),SmallSize));
+
+
+    // Make the buffer bigger.
+    // If it works ok, then copy the data
+    // to the new buffer, delete the old buffer
+    TInt BiggerSize;
+    TUint8* pNewBuf;
+
+    BiggerSize = KTxBig().Length();
+    pNewBuf = Kern::Alloc(BiggerSize);
+    if (pNewBuf)
+        {
+        memcpy(pNewBuf, pBuf, SmallSize);
+        Kern::Free(pBuf);
+        pBuf = pNewBuf;       
+        }
+     else
+        {
+        Kern::Free(pBuf);
+        return KErrNoMemory;
+        }
+     lengthInBuffer = BiggerSize;
+
+    // Replace content with 
+    // the text "ghijkl......"
+    memcpy(pNewBuf, KTxBig().Ptr(), BiggerSize);
+   
+
+    // Delete 1st two characters 
+    memmove(pNewBuf, pNewBuf+2, lengthInBuffer;
+    lengthInBuffer -= 2;
+   
+    Kern::Free(pBuf);
+
+    return KErrNone;
+    }</codeblock> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-586DD3B4-69DB-564B-AB8D-B3A02607CE02"><b>Handling 16-bit
+data items</b> </p> <p>If you need to handle 16-bit items on the kernel side,
+then you can still use 8-bit heap descriptor buffers. You just need to be
+aware that the data is 16 bit and cast accordingly. The following code fragments
+are simplistic, but show you the basic idea. </p> <table id="GUID-65BA6847-9FC7-53B2-B9F6-2D649D4B75AE">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>EKA1</b>  </p> </entry>
+<entry><p> <b>EKA2</b>  </p> </entry>
+</row>
+<row>
+<entry><p>This is a function which is passed a 16-bit descriptor containing
+16-bit wide characters. </p> <codeblock id="GUID-52B25979-B624-5D89-8D38-ADEDF3F27BED" xml:space="preserve">void X::FunctionL(const TDes16&amp; aDes)
+    {
+    HBuf16* pBuf = aDes.AllocL();
+
+    TInt     noOfCharacters;
+    TUint16* pointerToData;
+
+    noOfCharacters = pBuf-&gt;Length();
+    pointerToData  = pBuf-&gt;Ptr();
+
+    ...
+    }</codeblock> </entry>
+<entry><p>This is a similar function which is also passed 16-bit wide characters.
+The function needs slight changes as it can only receive data through an 8-bit
+descriptor. </p> <codeblock id="GUID-DD5720C2-1132-5991-B2E1-71B1BECAC15C" xml:space="preserve">TInt X::Function(const TDes8&amp; aDes)
+    {
+    HBuf8* pBuf = HBuf8::New(aDes);
+    if (!pBuf)
+       {
+       return KErrNoMemory;
+       }
+
+    TInt     noOfCharacters;
+    TUint16* pointerToData;
+     
+    noOfCharacters = ((pBuf-&gt;Length()) &gt;&gt; 1);
+    pointerToData  = (TUint16*)(pBuf-&gt;Ptr());
+
+    ...
+
+    return KErrNone;
+    }</codeblock> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-77C88D19-50C3-5D69-8084-BE750F100BA0"><b>Replacing CBase
+with DBase</b> </p> <p>The <xref href="GUID-4FCB6127-84F3-38F6-8AD2-FC3B94D67DA3.dita"><apiname>DBase</apiname></xref> class is the kernel-side
+equivalent of the user-side <xref href="GUID-8F6FE089-E2A8-30F4-B67E-10F286347681.dita"><apiname>CBase</apiname></xref> class. It provides zero-filling
+of memory prior to object construction and a virtual destructor in a similar
+way to <xref href="GUID-8F6FE089-E2A8-30F4-B67E-10F286347681.dita"><apiname>CBase</apiname></xref>. </p> <p>If you have a class derived from <xref href="GUID-8F6FE089-E2A8-30F4-B67E-10F286347681.dita"><apiname>CBase</apiname></xref>,
+then all you need to do is: </p> <ul>
+<li id="GUID-B5ABF979-A6E0-5733-AFB2-DAC8FC132BA0"><p>change your class definition
+so that it is derived from <xref href="GUID-4FCB6127-84F3-38F6-8AD2-FC3B94D67DA3.dita"><apiname>DBase</apiname></xref>. </p> </li>
+<li id="GUID-03B04EF1-32FE-5B37-A67C-AE57F8902F8E"><p>Remember to include
+the <filepath>klib.h</filepath> header file. </p> </li>
+</ul> <p>you should not need to do anything else. </p> <p>One additional feature
+provided by <xref href="GUID-4FCB6127-84F3-38F6-8AD2-FC3B94D67DA3.dita"><apiname>DBase</apiname></xref> that is not available in <xref href="GUID-8F6FE089-E2A8-30F4-B67E-10F286347681.dita"><apiname>CBase</apiname></xref> is
+the function <xref href="GUID-4FCB6127-84F3-38F6-8AD2-FC3B94D67DA3.dita#GUID-4FCB6127-84F3-38F6-8AD2-FC3B94D67DA3/GUID-40C0DEE0-7E6F-3D28-9B33-77A3CCC4E66E"><apiname>DBase::AsyncDelete()</apiname></xref>. This allows you to delete
+an instance of a <xref href="GUID-4FCB6127-84F3-38F6-8AD2-FC3B94D67DA3.dita"><apiname>DBase</apiname></xref> derived class asynchronously, and
+is useful if you need to delete a <xref href="GUID-4FCB6127-84F3-38F6-8AD2-FC3B94D67DA3.dita"><apiname>DBase</apiname></xref> derived object
+in time-critical code. </p> <p>Internally, asynchronous deletion works by
+placing the object to be deleted onto a queue, and then triggering a DFC,
+which runs in the context of the supervisor thread. This means that only a
+small amount of code is executed by your (the calling) thread, and the actual
+deletion is done by the supervisor thread. </p> <p>Its use is straightforward. </p> <codeblock id="GUID-1C283AE2-391A-5687-BA56-D8C1DD4E7745" xml:space="preserve">class DMyObject : public DBase
+    {
+    ...
+    }</codeblock> <codeblock id="GUID-20E2CA1A-06EE-5ADE-8B5B-14A3CE47ABDB" xml:space="preserve">DMyObject pPtr;
+    ...
+    pPtr = new DMyObject;
+    ...
+    pPtr-&gt;AsyncDelete();
+    ...</codeblock> <p id="GUID-585EE1D8-6080-5B37-A3BD-278B8731B7F9"><b>Replacing
+User::QueryVersionSupported() with Kern::QueryVersionSupported()</b> </p> <p> <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-B68B3E85-D58E-31FD-8BD2-A4F346BF416F"><apiname>User::QueryVersionSupported()</apiname></xref> is
+replaced by <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-A28757CC-B89B-3F63-AD39-9955FBE7533B"><apiname>Kern::QueryVersionSupported()</apiname></xref> on the kernel
+side. </p> <p>The parameters passed to these functions are the same, both
+in type and meaning. The behaviour of both functions is also the same. This
+means that all you need to do is replace <codeph>User::</codeph> with <codeph>Kern::</codeph> in
+your code. </p> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-8F78705E-CD82-5039-A7CB-7C963F7FBA83-master.png has changed
Binary file Adaptation/GUID-8F78705E-CD82-5039-A7CB-7C963F7FBA83_d0e69457_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-8FA1B2B0-5842-4D5D-BD61-C2D79B56ADC6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-8FA1B2B0-5842-4D5D-BD61-C2D79B56ADC6" xml:lang="en"><title>Interrupt Service Routine (ISR)</title><shortdesc>This document describes interrupt service routines as used by device
+drivers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>An ISR is a static function that will be executed when an interrupt occurs
+on the interrupt source bound to the ISR. </p>
+<codeblock id="GUID-E8416619-9314-5420-8EC1-F8BF804230DF" xml:space="preserve">// Interrupt service routines
+static void UartIsr(TAny* aParam);
+</codeblock>
+<p>An ISR performs the actions necessary to service the event of the peripheral
+that generated the interrupt and to remove the condition that caused it to
+interrupt. It queues a DFC to do the required processing. It disables the
+interrupts and FIQs on ARM, if required, to handle the interrupt, and enables
+them before leaving. It can also disable the source of the interrupt that
+it is servicing. </p>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-904C9C5A-5FDB-5978-88CF-E30D6C0DBB61-master.png has changed
Binary file Adaptation/GUID-904C9C5A-5FDB-5978-88CF-E30D6C0DBB61_d0e8869_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-90B5FDD9-7D59-5035-BF53-2B177655DCD6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,119 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-90B5FDD9-7D59-5035-BF53-2B177655DCD6" xml:lang="en"><title>Migration
+Tutorial: Demand Paging and Internal MMC Cards</title><shortdesc>Explains how to change the MMC media driver for when demand paging
+is used.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Demand paging is a change made from Symbian platform v9.3 to how the Kernel
+uses RAM and storage media. This topic </p>
+<p>For general information on migrating media drivers, see <xref href="GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3.dita">Migration
+Tutorial: Demand Paging and Media Drivers</xref>. </p>
+<section id="GUID-D99E59FE-2515-49F5-9C55-580D1F2AD6A8"><title>PSL changes</title> <p>ROM and code paging can be enabled
+for a Multi Media Card (MMC) provided the card is non-removable. Removing
+a card would result in a kernel fault whenever the next page-in request is
+issued. </p> <p>As the MMC media driver is entirely generic, a way of returning
+the paging related information contained in <i>variantmedia.def</i> to the
+generic part of the MMC stack is required. This is achieved by modifying the
+Platform Specific Layer (PSL) of the MMC stack to implement the <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-7DAC0CF1-4AFE-3F68-8488-632535783A80"><apiname>DMMCStack::MDemandPagingInfo</apiname></xref> interface
+method: </p> <codeblock id="GUID-7B1FA673-641B-54C7-BC6B-DCDBE25297B8" xml:space="preserve">class DMMCStack : public Dbase
+    {
+public:
+    // etc…
+    };
+
+/** 
+Demand paging support 
+@see KInterfaceDemandPagingInfo
+*/
+
+class TDemandPagingInfo
+    {
+public:
+    const TInt* iPagingDriveList;
+    TInt  iDriveCount;
+    TUint iPagingType;
+    TInt  iReadShift;
+    TUint iNumPages;
+    TBool iWriteProtected;
+    TUint iSpare[3];
+    };
+
+class MDemandPagingInfo
+    {
+public:
+    virtual TInt DemandPagingInfo(TDemandPagingInfo&amp; aInfo) = 0;
+    // etc…
+    };</codeblock> <p>This example is taken from the H4 HRP <i>VariantMedia.def</i> changes: </p> <codeblock id="GUID-DD8297C4-6033-5AB1-838C-F0DFE1C7C749" xml:space="preserve">// Variant parameters for the MMC Controller (EPBUSMMC.DLL)
+#define MMC_DRIVECOUNT 1
+#define MMC_DRIVELIST 1
+#define MMC_NUMMEDIA 1
+#define MMC_DRIVENAME "MultiMediaCard0" 
+
+#define MMC_PAGING_TYPE    DPagingDevice::ERom | DPagingDevice::ECode
+#define MMC_PAGEDRIVELIST    1            // code paging from User Data
+#define    MMC_PAGEDRIVECOUNT     1
+#define MMC_NUM_PAGES        8</codeblock> <p>This example is from H4 MMC
+stack class definition: </p> <codeblock id="GUID-FC2E902E-E98C-5E0E-9337-D3D5BB14FBB6" xml:space="preserve">class DDemandPagingInfo : public DMMCStack::MDemandPagingInfo
+    {
+public:
+    virtual TInt DemandPagingInfo(DMMCStack::TDemandPagingInfo&amp; aInfo);
+    };
+
+
+class DOmapMMCStack : public DCardStack
+    {
+public:
+    virtual void GetInterface(TInterfaceId aInterfaceId, MInterface*&amp; aInterfacePtr);
+    // etc…
+private:
+    DDemandPagingInfo* iDemandPagingInfo;
+    // etc…
+    };</codeblock> <p>This example is from H4 MMC stack class implementation: </p> <codeblock id="GUID-824160DE-295D-5BA2-B2BE-A5590301B9EA" xml:space="preserve">TInt DOmapMMCStack::Init()
+    {
+    if((iDemandPagingInfo = new DDemandPagingInfo()) == NULL)
+        return KErrNoMemory;
+    // etc…
+    }
+
+void DOmapMMCStack::GetInterface(TInterfaceId aInterfaceId, MInterface*&amp; aInterfacePtr)
+    {
+    if (aInterfaceId == KInterfaceDemandPagingInfo)
+        aInterfacePtr = (DMMCStack::MInterface*) iDemandPagingInfo;    
+    // etc…
+    }
+
+TInt DDemandPagingInfo::DemandPagingInfo(DMMCStack::TDemandPagingInfo&amp; aDemandPagingInfo)    
+    {
+    static const TInt pagingDriveNumbers[MMC_PAGEDRIVECOUNT] = {MMC_PAGEDRIVELIST};
+
+    aDemandPagingInfo.iPagingDriveList = pagingDriveNumbers;
+    aDemandPagingInfo.iDriveCount = MMC_PAGEDRIVECOUNT;
+    aDemandPagingInfo.iPagingType = MMC_PAGING_TYPE;
+    aDemandPagingInfo.iReadShift = 9;
+    aDemandPagingInfo.iNumPages = MMC_NUM_PAGES;
+    return KErrNone;
+    }</codeblock> </section>
+<section id="GUID-6389CCE7-339D-4F41-B875-4636C5993C6C"><title>Preparing an internal MMC card for ROM paging - MMCLoader</title> <p>To
+support ROM paging from an internal card, the MMCLoader utility is used to
+write the ROM image to the card. MMCLoader can be found in <filepath>e32utils/mmcloader</filepath>. </p> <p>The
+paged image is written as a normal file under the FAT file system. For paging
+to work however, the images file’s clusters must all be contiguous so, before
+doing anything else, MMCLoader formats the card. It then writes the paged
+part of the ROM to a file and checks that the file’s clusters are contiguous,
+which is normally the case as the card has just been formatted. A pointer
+to the image file is stored in the boot sector. When the board is rebooted
+the MMC/SD media driver reads the boot sector and uses this pointer to determine
+where the image file starts so that it can begin to satisfy paging requests. </p> <p>MMCLoader
+takes the filename of the original ROM image file as an input. It then splits
+the given file into unpaged and paged files. The following code fragment shows
+the syntax: </p> <codeblock id="GUID-0CFE9814-4FEA-5FF1-9027-82E207596C68" xml:space="preserve">Syntax: mmcloader &lt;RomSrcFileName&gt; &lt;UnPagedRomDstFileName&gt; &lt;PagedRomDstFileName&gt;
+Eg:     mmcloader z:\\core.img d:\\sys$rom.bin d:\\sys$rom.pag</codeblock> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-9173EEBA-CC84-51D9-9C8D-A75F7F494D62-master.png has changed
Binary file Adaptation/GUID-9173EEBA-CC84-51D9-9C8D-A75F7F494D62_d0e9004_href.png has changed
Binary file Adaptation/GUID-91958EA5-9444-5895-B4B8-F2C670B81CD7-master.png has changed
Binary file Adaptation/GUID-91958EA5-9444-5895-B4B8-F2C670B81CD7_d0e11017_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-919E48BE-6AA1-54CC-8B70-3A4B3A9C6CF1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,65 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE task
+  PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
+<task id="GUID-919E48BE-6AA1-54CC-8B70-3A4B3A9C6CF1" xml:lang="en"><title>Writing
+a Class Driver Tutorial</title><shortdesc>This document set provides step-by-step instructions that will
+enable a user to use the USB LDD interface to create a simple class driver. </shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody>
+<prereq id="GUID-923C4B75-0133-5767-A5FB-A5E5F88BAE56"><p>Before you start,
+you must: </p> <ul>
+<li id="GUID-600BA31A-AAE3-5BA5-97AF-5B8387080988"><p>Understand <xref href="GUID-796CB42C-29AC-5ECC-AC6E-35FC6B8CC84E.dita">USB</xref>, </p> </li>
+<li id="GUID-64C9DD6A-55DC-551E-9456-A8BABEB312C1"><p>Understand <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita">Shared
+Chunks</xref>. </p> </li>
+</ul> </prereq>
+<context id="GUID-069D5F41-EBCC-5E3D-8C95-4BA6BF6A3582"><p>It is recommended
+that shared chunks are used for speed of transfer when transmitting a large
+amount of data. This approach is not recommended when transmitting smaller
+amounts of data infrequently. </p><p>Complete the tasks listed below to create
+a class driver that
+ interfaces with the USB LDD using shared chunks. 
+</p> </context>
+<steps id="GUID-E16188A1-0CC1-56F9-A222-B347DB63684D">
+<step id="GUID-B1B58168-E7E5-5E28-ABB9-885412F61676"><cmd/>
+<info> <xref href="GUID-FDAED7A7-3D93-5B57-9879-DF8BDBE8A9BD.dita">Load and Open
+a USB Channel</xref>, </info>
+</step>
+<step id="GUID-BEED87E3-F887-575A-98B7-26F0CE8506AB"><cmd/>
+<info> <xref href="GUID-18DD4FE5-6641-5A0E-A00E-DC0C00639CE4.dita">Set the Configuration
+Descriptors</xref>, </info>
+</step>
+<step id="GUID-630D21D4-6D02-5B2E-82AA-F5310D046FD2"><cmd/>
+<info> <xref href="GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita">Set the Interface
+Descriptors</xref>, </info>
+</step>
+<step id="GUID-7B2013DA-4DD7-5E58-AF1A-480091BFF164"><cmd/>
+<info> <xref href="GUID-0A9C35DA-DF54-5885-AFE0-F4D5B3E49941.dita">Allocate Resources
+for Endpoints</xref> - this task is optional, </info>
+</step>
+<step id="GUID-459E6FC2-0392-558E-819A-4E3C7BA44D1B"><cmd/>
+<info> <xref href="GUID-9597DB22-D932-5A58-9C3C-4E5FCA244253.dita">Re-Enumerate</xref>, </info>
+</step>
+<step id="GUID-9048BEE7-D276-5A42-96AE-D72DEB9E2438"><cmd/>
+<info> <xref href="GUID-6E89E787-749D-5AC5-957D-967B4B9ACD74.dita">Using the BIL
+Interface</xref> - this task is optional, but recommended, </info>
+</step>
+<step id="GUID-65769466-7E64-5961-B991-C318F2B03B83"><cmd/>
+<info> <xref href="GUID-4C4515EA-A5DD-56B4-94B0-EE48D66013F7.dita">Read Data from
+USB using Shared Chunks</xref>, </info>
+</step>
+<step id="GUID-E185BEF9-3C79-52C3-991F-9FECB0837BC4"><cmd/>
+<info> <xref href="GUID-0C80F447-B82E-5586-9B02-4BC0D365FFD6.dita">Write Data to
+USB using Shared Chunks</xref>, </info>
+</step>
+<step id="GUID-BF9C04EB-8632-5B00-A7AB-FDF910414771"><cmd/>
+<info> <xref href="GUID-BE73CFE6-D48D-5B92-AF49-E2D967ADF0EC.dita">Close and Unload
+the Driver</xref>. </info>
+</step>
+</steps>
+</taskbody></task>
\ No newline at end of file
Binary file Adaptation/GUID-921AF7A3-C711-5979-877B-4B6D977888E8-master.png has changed
Binary file Adaptation/GUID-921AF7A3-C711-5979-877B-4B6D977888E8_d0e5006_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-922E4771-C1FD-5C88-9C11-57499684DB97.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,80 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-922E4771-C1FD-5C88-9C11-57499684DB97" xml:lang="en"><title>SPITOOL</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>SPITOOL is a utility for creating static plug-in information (SPI)
+files, which contain registration data for ROM-based plug-ins. </p>
+<p>The tool is normally invoked by <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">BUILDROM</xref>,
+though it can be used independently (for example, for test purposes). </p>
+<section id="GUID-E67FF051-D423-4DBC-A3AB-24155F7743D3"> </section>
+<section id="GUID-C173E1BC-BEDD-5843-B395-2DF6123D5F18"><title>SPITOOL
+command syntax</title> <codeblock id="GUID-06FB9E43-C48E-5CCF-862A-1D709DC905AD" xml:space="preserve">spitool [options] files directories</codeblock> <p>The tool creates an SPI file by concatenating the specified input
+files, using the options specified. </p> <p>You can specify the input
+files by specifying the full path to each file, or by specifying a
+directory name, in which case all files from that directory are included. </p> <p> <codeph>options</codeph> can be one or more of the following: </p> <table id="GUID-704075C3-49BD-5305-A2B5-4D8C4523EE48">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>-t&lt;SPIFileName&gt; </p> </entry>
+<entry><p> <codeph>&lt;SPIFileName&gt;</codeph> is the name for the produced
+SPI file (e.g. <filepath>ecom.spi</filepath>) </p> </entry>
+</row>
+<row>
+<entry><p>-d&lt;TargetDir&gt; </p> </entry>
+<entry><p> <codeph>&lt;TargetDir&gt;</codeph> is the directory where
+the SPI file should be created. The directory name should end with
+a <codeph>\</codeph>. </p> </entry>
+</row>
+<row>
+<entry><p>-i&lt;Existing&gt; </p> </entry>
+<entry><p> <codeph>&lt;Existing&gt;</codeph> is the path of an existing
+SPI file to which to concatenate the specified input files. </p> <p>If this option is used, then the specified file is used as a base
+for the new output file. The output file will contain the contents
+of the existing file with new input files appended. The location of
+the output file is still specified using the <codeph>-d</codeph> and <codeph>-t</codeph> options. </p> </entry>
+</row>
+<row>
+<entry><p>-uid[1 | 2 | 3]=&lt;UIDValue&gt; </p> </entry>
+<entry><p>Specifies that input files should be filtered by their UID
+values. </p> <p>This option can be used multiple times, so a list
+of valid UID1 values can be specified, and similarly for UID2 and
+UID3 values. The UIDs of each input file are compared with this list,
+and if a UID value matches a relevant value in the UID lists, then
+that file is included in the SPI file. If the file does not match
+any values, it is excluded. </p> <p>Use 1, 2, or 3 in the option keyword
+to specify to which of the three UIDs the filter should apply. <codeph>&lt;UIDValue&gt;</codeph> should be a UID value in decimal or hexadecimal
+(0x....). </p> </entry>
+</row>
+<row>
+<entry><p>-existinguid[1 | 2 | 3]=&lt;UIDValue&gt; </p> </entry>
+<entry><p>Test that files concatenated in an existing SPI file use
+the specified UID value. This allows the possibility of checking that
+the correct type of files are being concatenated together. </p> <p>Use 1, 2, or 3 in the option to specify to which of the three UIDs
+the test should apply. <codeph>&lt;UIDValue&gt;</codeph> should be a
+UID value in decimal or hexadecimal (0x....). </p> </entry>
+</row>
+<row>
+<entry><p>-existinguidcrc=&lt;CRCValue&gt; </p> </entry>
+<entry><p>Test that files concatenated in an existing SPI file use
+the specified CRC checksum value. A file's CRC is generated from all
+three of its UIDs. </p> <p> <codeph>&lt;CRCValue&gt;</codeph> should
+be a value in decimal or hexadecimal (0x....). </p> </entry>
+</row>
+<row>
+<entry><p>-hide &lt;ResourceFileNames&gt; </p> </entry>
+<entry><p>Marks a resource file as hidden in the SPI file. </p> <p>&lt;ResourceFileNames&gt; is a list of resource file names separated
+by a space or comma, which need to be marked as hidden in the SPI
+file. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-93DA75DE-096F-5E40-A47E-5A1A94C3145A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-93DA75DE-096F-5E40-A47E-5A1A94C3145A" xml:lang="en"><title>Source Code Organisation</title><shortdesc>This topic describes the Base Starter source code that
+Symbian platform provides.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody><table id="GUID-17670D90-42B1-5F0E-855B-E1C73C9E00F5">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <filepath>sf/os/kernelhwsrv/userlibandfileserver/fileserver/estart/estart.h</filepath> </p> </entry>
+<entry><p>Header file containing the definition for the class <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartup</apiname></xref>, and other required structs, typedefs etc. </p> <p>You do <i>not</i> make changes to the contents of this file. </p> </entry>
+</row>
+<row>
+<entry><p> <filepath>                 sf/os/kernelhwsrv/userlibandfileserver/fileserver/estart/estart.cpp</filepath>  </p> </entry>
+<entry><p>Contains generic code and default versions of the <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartup</apiname></xref> virtual functions. This file also contains the
+code involved in auto-detection. </p> <p>You do <i>not</i> make changes
+to the contents of this file. </p> <p>See <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-A195BD51-80C7-5D87-ABA2-8878CC509B84">Use automatic local drive mapping</xref>. </p> </entry>
+</row>
+<row>
+<entry><p> <filepath>                 sf/os/kernelhwsrv/userlibandfileserver/fileserver/estart/estartmain.cpp</filepath>  </p> </entry>
+<entry><p>Contains the entry point to the Base Starter. If you need
+to customize the Base Starter, then you do it to a <i>copy</i> of
+this file. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table></conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-9573F7B9-76E9-5DCB-A498-C0DE59606911.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-9573F7B9-76E9-5DCB-A498-C0DE59606911" xml:lang="en"><title>Concepts</title><shortdesc>Describes the technology, architecture, and behaviour of the MMC
+Controller. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/><related-links>
+<link href="GUID-44738D45-9193-53E8-B01C-01C017009DAD.dita"><linktext>MMC   Tutorials</linktext>
+</link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-9595FD6F-1EDE-51A8-B00D-029CFDFE0F38.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-9595FD6F-1EDE-51A8-B00D-029CFDFE0F38" xml:lang="en"><title>Boot Table</title><shortdesc>Describes the boot table.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The boot table consists of a linear array of 4-byte entries whose index
+positions are defined by the <codeph>TBootTableEntry</codeph> enumeration
+in <filepath>os/kernelhwsrv/kernel/eka/include/arm/bootdefs.h</filepath>. </p>
+<p>The entries in the array are divided into two groups, one whose index positions
+are defined by the enumerator names <codeph>BTF_*</codeph> and the other group
+defined by the enumerator names <codeph>BTP_*</codeph>. </p>
+<p>Entries in the first group specify addresses of <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita">Boot
+Table Functions</xref>. </p>
+<p>Entries in the second group specify <xref href="GUID-C92CC81A-35A1-5860-AA08-C8C08B39804C.dita">Boot
+Table MMU Permission and Cache Attribute Definitions</xref> to be used for
+certain standard memory and I/O areas. </p>
+<p>A boot table entry is the offset of the function from the beginning of
+the bootstrap code but, since the bootstrap is linked for a base address of
+zero and is position independent, bare function addresses can be used. </p>
+<p>Use <codeph>DCD</codeph> to place a function in the boot table, for example: </p>
+<codeblock id="GUID-F36DF0E5-E337-5B1B-B098-64D78C3B0339" xml:space="preserve">DCD function-name</codeblock>
+<p>In the Template port, available in <filepath>os/kernelhwsrv/bsptemplate/asspandvariant/template_variant/bootstrap/template.s</filepath>,
+the boot table is defined by the label <codeph>BootTable</codeph>, followed
+by <codeph>DCD</codeph> entries for every boot table function, like in the
+following example: </p>
+<codeblock id="GUID-28F3F4E0-E196-50E4-8AFF-6672BA982FB4" xml:space="preserve">BootTable
+        DCD    DoWriteC        ; output a debug character
+        DCD    GetRamBanks    ; get list of RAM banks
+        DCD    SetupRamBank    ; set up a RAM bank
+        DCD    GetRomBanks    ; get list of ROM banks
+        DCD    SetupRomBank    ; set up a ROM bank
+        ...</codeblock>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-9597DB22-D932-5A58-9C3C-4E5FCA244253.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept xml:lang="en" id="GUID-9597DB22-D932-5A58-9C3C-4E5FCA244253"><title>Re-Enumerate </title><shortdesc>A short description of how to perform a Re-Enumeration. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody><section id="GUID-04B32E9C-A11A-5F6B-B5B6-E346C9CD333D"><title>Introduction</title> <p>If any interface settings have been changed then a re-enumeration must be forced by calling <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-C0D95A6D-350E-3569-BBA1-074CC2D027AA"><apiname>RDevUsbcScClient::ReEnumerate()</apiname></xref>. A re-enumeration involves the device initiating a bus disconnection and re-connection. </p> </section> <section><title>Re-enumerate</title> <p> <codeph>ReEnumerate()</codeph> is an asynchronous operation that completes when the controller is successfully configured by the host. Because it is not known if the operation has failed, set up a timer to complete after approximately 5 seconds. It can be assumed that if the operation has not completed in this time then it will not complete. When the request is completed <codeph>status</codeph> contains the result of the re-enumeration. See <xref href="GUID-E0B34F3E-D4C4-3232-B8B1-7DB35B454646.dita"><apiname>TRequestStatus</apiname></xref>. </p> <codeblock id="GUID-E040F056-770F-5925-94E2-07FC6C4BEAB9" xml:space="preserve">TRequestStatus status;
+gPort.ReEnumerate(status);
+User::WaitForRequest(status);</codeblock> <p>If the re-enumeration has not completed within the expected time period then use <xref href="GUID-B1E32178-3B7C-3B00-A0AF-62ECE40E8598.dita#GUID-B1E32178-3B7C-3B00-A0AF-62ECE40E8598/GUID-1B12CD44-4ABA-323B-AA85-5B30A02AFB57"><apiname>RDevUsbcClient::ReEnumerateCancel()</apiname></xref> to cancel the request. <b>Note</b>: this function does not undo the re-enumeration. </p> <p>If alternate interface settings have been set up enquire which interface has been selected following a re-enumeration by using <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-B641E598-3F10-3376-B14C-87E0718F8687"><apiname>RDevUsbcScClient::GetAlternateSetting()</apiname></xref>. </p> </section> <section><p>After you have forced a re-enumeration you can use your USB class driver to <xref href="GUID-4C4515EA-A5DD-56B4-94B0-EE48D66013F7.dita">Read Data from USB using Shared Chunks</xref> or <xref href="GUID-0C80F447-B82E-5586-9B02-4BC0D365FFD6.dita">Write Data to USB using Shared Chunks</xref> or if you wish to use the Buffer Interface Layer (recommended) then go to <xref href="GUID-6E89E787-749D-5AC5-957D-967B4B9ACD74.dita">Using the BIL Interface</xref>. </p> </section> </conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-95A33491-17AC-4F12-948E-A1352ADDA483.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,85 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-95A33491-17AC-4F12-948E-A1352ADDA483" xml:lang="en"><title>DMA Implementation Guide</title><shortdesc>Explains how to implement the DMA Platform Specific Layer
+(PSL) for your platform.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The DMA Framework is made of a PIL and a PSL. You have to write
+a new Platform specific implementation code whenever your hardware
+changes, but the PIL and the platform service API do not change. </p>
+<section id="GUID-C443CD88-0894-444D-BC7D-E65698AF46E4"><title>Prerequisites</title><p>You should be familiar with the <xref href="GUID-4E3C086B-25BE-4DAC-9E21-CFC4F8B792A5.dita">DMA Technology Guide</xref> and with the specifications of your hardware DMA controller.</p></section>
+<section id="GUID-F8827A6B-234A-4358-9720-15AD7ABE4AC9"><title>Architecture</title><p>In the diagram below, the classes in green provide the platform
+service API and the classes in blue implement the Platform-specific
+functions (PSL).</p><fig id="GUID-61388066-2B2B-4DEF-8FEC-D07D71E4DFAF">
+<title>PSL class diagram</title>
+<image href="GUID-F7ABA3C6-60DD-4AE1-916B-BE2BCF6285CE_d0e91217_href.png" placement="inline"/>
+</fig></section>
+<section id="GUID-1460340B-DF92-45A4-AC7A-7238CBD63199"><title>Implementation
+files</title><p>The following table lists the important files of the
+DMA Framework and what you should do with each of them.<table id="GUID-54A82958-4168-42CD-81DE-466CEA0FEEFC-GENID-1-2-1-10-1-5-1-5-1-1-8-1-4-1-3-4-2-1">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">File</entry>
+<entry valign="top">Usage</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><filepath>/os/kernelhwsrv/kernel/eka/include/drivers/dma.h</filepath></entry>
+<entry><p>This file is the main header file for DMA. </p><p>Include
+it in the PSL implementation.</p></entry>
+</row>
+<row>
+<entry><filepath>/os/kernelhwsrv/kernel/eka/include/drivers/dma_v1.h</filepath></entry>
+<entry><p>This file contains the definitions of the PSL classes. </p><p>Refer to this file for the signature of the PSL functions. </p></entry>
+</row>
+<row>
+<entry><filepath>/os/kernelhwsrv/kernel/eka/drivers/dma/dmapil.cpp</filepath></entry>
+<entry>This file is for information only: it contains the source code
+for the generic implementation.</entry>
+</row>
+<row>
+<entry><filepath>/os/kernelhwsrv/kernel/eka/drivers/dma/dma_lib.mmp</filepath></entry>
+<entry><p>This file is the MMP for the PIL. </p><p>Use it to build
+the .LIB file for the PIL.</p></entry>
+</row>
+<row>
+<entry><filepath>/os/kernelhwsrv/bsptemplate/asspandvariant/template_assp/dmapsl.cpp</filepath></entry>
+<entry><p>This file contains the template code for the PSL implementation. </p><p>Copy it to your variant directory and modify it.</p></entry>
+</row>
+<row>
+<entry><filepath>/os/kernelhwsrv/bsptemplate/asspandvariant/template_assp/dma.mmp</filepath></entry>
+<entry><p>This file is the template MMP for the PSL implementation. </p><p>Copy it to your variant directory and modify it. </p><p>Use the
+new file to build the DMA Framework (PIL and PSL).</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></p></section>
+<section id="GUID-04C86903-0899-4A0F-8A38-777DD7D71D8F"><title>Implementation
+process</title><p>To write the PSL for the DMA Framework, do the following:<ol>
+<li id="GUID-A9CAA850-23C5-4F3C-8FDF-2041CDF432A2"><p>Copy the template
+listed in the above section to your own variant directory (at chip
+level or at board level depending on where the DMA hardware is located).</p></li>
+<li id="GUID-BB62C00E-1B93-4771-AA18-0AB1188279AF"><p>Implement the <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita"><apiname>DmaChannelMgr</apiname></xref> functions.</p></li>
+<li id="GUID-65626C78-F06B-4694-A819-5C1BAD7AB467"><p>Derive the <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> class and implement its controller-specific functions.</p></li>
+<li id="GUID-D427EEA9-A434-4012-B680-0B2F70B0122D"><p>If necessary,
+derive the <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref> class or one of its sub-classes
+to store channel-specific data.</p></li>
+<li id="GUID-1587F0CF-1A85-4C9E-8AAB-4D05E5CDC8EA"><p>Test the PSL
+implementation.</p></li>
+
+</ol></p></section>
+</conbody><related-links>
+<link href="GUID-D5ED62EB-744D-42EB-B8CF-D5623BDA5B38.dita"><linktext>DMA
+Client Interface Guide</linktext></link>
+<link href="GUID-C2114C7B-705C-4527-836A-C6E72227111A.dita"><linktext>DMA
+Testing Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-95BD3650-08CB-407D-969E-DFDB39B2FEFC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,155 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-95BD3650-08CB-407D-969E-DFDB39B2FEFC" xml:lang="en"><title>What is a Platform Service?</title><shortdesc>A platform service is an interface designed to make it
+quick, easy and inexpensive to integrate hardware into a mobile device.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-F3ACE06A-E619-416A-BC4B-4AA4771404D2"><title>Platform
+Service</title>       <p>A platform service is a set of defined functionality,
+usually providing an abstraction or encapsulation for functionality
+provided by hardware.</p><p>For example, a platform service may provide
+a standard interface for using a serial bus to send commands and data
+between integrated circuits on the base board. Another example would
+be providing a standard interface for Direct Memory Access (DMA) hardware
+for moving blocks of data from one block of memory locations to another
+or from a block of memory to a hardware device.</p><p>The platform
+service separates the functionality required by kernel, device driver
+and application processes from the specific hardware implementation.
+This means, for example, that a device driver can be written for a
+platform service that uses the published APIs, without needing to
+know the specifics of the actual hardware device/chipset.</p><fig id="GUID-D1D306BB-EFDD-4365-8259-39A4F4EB6AE3">
+<title>Platform service</title>
+<image href="GUID-99637158-DE86-4BB4-98D4-3A3E64AB768F_d0e87314_href.png" placement="inline"/>
+</fig><p>The platform service is a consistent hardware interface at
+the bottom of the operating system platform software stack. In the
+past much of the logic and configuration required to enable a new
+piece of hardware was higher up in the operating system stack and
+that made it difficult to support new or variant hardware. The platform
+service architecture separates out the hardware specific interfaces
+and encapsulates them behind a standard set of platform service (client
+interface) APIs. </p><p>The platform service consists of :</p><ul>
+<li><p>Client Interface/Platform service APIs </p></li>
+<li><p>Implementation of the APIs:</p><ul>
+<li><p>Platform Independent Layer (PIL)/Framework/Generic implementation</p></li>
+<li><p>SHAI interface</p></li>
+<li><p>Platform Specific Layer (PSL)/SHAI Implementation/Hardware
+implementation</p></li>
+</ul></li>
+</ul><p>The PIL contains all the common functionality code such as
+maintaining a list of available channels for communication or holding
+the pending list of memory transfers to be processed by DMA when the
+hardware becomes available. Usually the PIL provides the implementation
+of the Client Interface APIs. This is sometimes referred to as the
+Framework.</p><p>The interface between the framework code and the
+PSL code is known as the Symbian Hardware Adaptation Interface (SHAI).
+The SHAI interface specifies how the PIL and PSL talk to each other
+(APIs, shared memory areas etc.)</p><p>The PSL consists of the specific
+code required to work with a particular piece of hardware. This means
+that supporting a new or variant chipset only requires the PSL to
+be amended or to have detection code to handle a particular piece
+of hardware. </p><p>Some Platform Services, such as GPIO, provide
+APIs that directly address the hardware, and so the PSL provides the
+client interface API implementation directly. For example, there is
+no GPIO PIL/framework.</p></section>
+<section id="GUID-15BD58D5-12D7-4871-9A98-940F39B95182"><title>Variations
+on platform service</title><p>Not all platform services are as simple
+as the diagram above suggests. Some platform services do not talk
+to hardware directly or at all, but provide a higher-level abstraction,
+often with further low-level platform services below them in the OS
+stack. For example, the Power Manager Policy platform service, provides
+APIs to control power management policy, but does not interface with
+any hardware directly. In these cases there is either no PSL, or the
+PSL provides configuration specific responses to a generic PIL. For
+example, if a handset can be built in two variants, one with a hardware
+graphics accelerator and one without but with a software emulated
+graphics accelerator, then the PSL would be responsible for directing
+graphics requests either to the hardware, or to the software and returning
+the results back through the PIL to the client.</p><p>Some plaftorm
+services, for example TV-Out, may use additional platform services
+to output sound as well as providing hardware support for the TV-Out
+chipset.</p><p>Some platform services may share a piece of hardware,
+such as a radio chip. The chip may provide cellular telephony, WiFi,
+FM radio transmission and other features all on one chip, but there
+may be several separate platform services, each exposing an API for
+one particular technology.</p><p>Both the PIL and PSL may make calls
+to other OS components, including other platform services, for information
+such as Hardware Configuration, power status, and the availability
+of other services.</p></section>
+<section id="GUID-1D50AC84-89A3-4BA3-BB7F-032FF499E56D"><title>Why
+have a platform service</title><p>Platform services
+benefit both device creators and third party hardware/chipset developers
+since they specify a standard software interface between the operating
+system and standard functionality provided by hardware.</p><p>This
+means that it is possible for a device creator to easily integrate
+the best hardware for their device, and allows hardware creators to
+work to a standard interface that can be used across multiple devices
+and multiple customers.</p><p>As the platform service interface provides
+a consistent interface to functionality, it allows the device creator
+to concentrate on the core functionality and not worry about how the
+hardware will provide it. And since the interface is standard for
+each type of hardware component, each manufacturer can provide the
+information or code for the PSL comparatively easily for each additional
+variant they produce. So this means less code required from hardware
+manufacturers per hardware component, and a larger market as each
+new mobile device, from any device creator, can use that compliant
+hardware.</p><p>The platform services abstraction for hardware adaptation
+also means more common code that can be shared across the Symbian
+Foundation member community. This includes sharing PSL code with other
+hardware providers, and sharing code for device drivers and other
+higher-level components that need to use the platform services APIs.
+For example, if a device driver for a particular piece of hardware
+also needs to use a serial inter-IC bus (IIC) to send commands to
+that hardware, then it can use the IIC platform service APIs and re-use
+code that other components have already tested for using the IIC client
+interface APIs.</p><p>Platform services also allow the use of standardized
+test tools and test suites. Each new piece of hardware in a particular
+category (for example, camera, Bluetooth radio) has to comply with
+the SHAI interface (PIL/PSL interface). This means that an existing
+test suite that works with another camera module can be used to test
+that this new piece of hardware works. This reduces the time taken
+for testing and increases speed to market.</p></section>
+<section id="GUID-173DF644-98BC-415C-8DA5-5428FF560622"><title>Who
+uses the Platform Service?</title><ul>
+<li><p>Application developers, who need to use the functionality of
+a hardware device, but do not need to know the specific details of
+the hardware/hardware implementation. They use the client interface
+and need to know what the APIs are, and what order they must be called
+in and so on.</p></li>
+<li><p>Framework developers, who need to know how to implement each
+of the client interface APIs , and a description of the functionality
+required within the framework.</p></li>
+<li><p>Hardware Developers, who need to understand the hardware interface,
+and have to write or update the hardware implementation (PSL) to support
+their particular chipset/hardware.</p></li>
+</ul></section>
+<section id="GUID-84DAC762-23F9-4756-8D3A-EB03280E93CA"><title>Platform
+service client interface APIs</title><p>In general these are function
+calls, and associated enumerations. There are two main types of function
+call:<ul>
+<li><p>Synchronous</p></li>
+<li><p>Asynchronous</p></li>
+</ul></p><p>A synchronous function call from the client/device-driver
+waits for the platform service to process it and make any return value.
+The client thread waits for the synchronous call to complete.</p><p>An asynchronous function call asks the platform service to do something,
+but then execution of the client continues immediately. For example,
+this would be the case of any function that starts a long data transmission
+or receive process, such as streaming video. One of the standard components
+of an asynchronous function call is a way for the result to be communicated
+back to the client. Often this is done by a “callback function” where
+the client specifies a pointer to a function (and parameters) during
+the original call, and the platform service puts the callback on the
+Delayed Function Call (DFC) queue for the client when the platform
+service has completed the request. This may indicate “transfer completed”
+or “transfer failed, error code 123”, it may release a lock or other
+functionality defined by the author of the client.</p></section>
+</conbody><related-links>
+<link href="http://developer.symbian.org/wiki/index.php/Prop/SHAI.dita">
+<linktext>Symbian Foundation SHAI page</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-95CE7187-66B2-581A-A5B8-6359AD431E87.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-95CE7187-66B2-581A-A5B8-6359AD431E87" xml:lang="en"><title>Reference</title><shortdesc>Summary of file formats, tools command line syntax, and related
+documentation for the User-Side Hardware Abstraction (HAL) component. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/><related-links>
+<link href="GUID-F162E58E-0B20-5E31-974E-A6A99DD61E41.dita"><linktext>API Reference:
+User-Side Hardware   Abstraction</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-970EC5A9-8ED3-53C5-93A3-2EC1A7B6F25F-master.png has changed
Binary file Adaptation/GUID-970EC5A9-8ED3-53C5-93A3-2EC1A7B6F25F_d0e13980_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-97F97D7B-D5A3-5471-A359-77B805ED198C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-97F97D7B-D5A3-5471-A359-77B805ED198C" xml:lang="en"><title>Design</title><shortdesc>Describes different modes of operations of the DMA Framework .</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Some DMA controllers provide several modes of operation. For example, one
+ASSP provides both single-buffer mode and scatter-gather mode transfers. </p>
+<p>There are two options: </p>
+<ul>
+<li id="GUID-EAFDBEFC-1524-55C4-BBD3-AF4CD88ADEF1"><p>Select a single mode
+of operation. </p> </li>
+<li id="GUID-ED15AB92-3A9B-5968-A5C9-E49309F14EE1"><p>Select a multiple mode
+of operation, and split the physical DMA controller into several logical controllers,
+one for each mode to be supported. If this option is chosen, the PSL must
+include one concrete controller class per logical controller; a controller
+class is derived from <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref>. </p> <p>If the DMA controller
+supports more than one mode of operation, implement the simplest one first.
+Implementing single-buffer mode first allows most of the the PSL (platform-specific
+layer) to be debugged before you start to implement the more complex scatter-gather
+functionality. </p> </li>
+</ul>
+<p>One reference implementation adopts a mixed strategy; the mode of operation
+is selectable at build-time by defining the macro <codeph>__DESFETCHMODE__</codeph> to
+exercise and demonstrate two different modes of operation. </p>
+<p>Scatter-gather support is essentially a superset of single-buffer support
+because a scatter-gather list is an ordered set of variable sized buffers,
+and means that code shown here demonstrates the implementation of a scatter-gather
+DMA controller. </p>
+<p>Almost all modern MCUs use scatter-gather capable DMA controllers. Note
+that we refer to descriptor fetch mode synonymously with scatter-gather mode,
+as scatter-gather is implemented by passing the DMA controller a linked list
+of descriptors describing the buffers to be transferred. Non–descriptor mode
+requires that the DMA controller registers are programmed by software to describe
+the buffer transfer required. Since each transfer must be handled by an interrupt
+service routine triggered when the DMA controller has completed the transfer,
+non-descriptor mode is not capable of performing transfers past buffer boundaries. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-98210124-0B65-4679-BB3A-E94B9999365C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,143 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-98210124-0B65-4679-BB3A-E94B9999365C" xml:lang="en"><title>IIC Client Interface Guide</title><shortdesc>This document explains how to use the IIC client interface
+API.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-1C12EB58-E364-4536-A6FB-FFAC4B4AF81E"><title>Introduction</title><p>This guide describes how to use the IIC client interface API.</p></section>
+<section id="GUID-5C79175E-3193-48B8-8000-7AA20BECD440"><title>Channels</title><p>In this document, a channel is a multi-wire bus with a two or
+more devices connected to it. At least one of the devices can act
+as the master.</p></section>
+<section id="GUID-9CD79528-826C-4433-87C2-4158B4112660"><title>Modes
+of operation</title><p>There are three possible modes that a device
+can be in as regards to the IIC client interface API (regardless of
+the underlying two-wire bus that is being used ):</p><table id="GUID-9CBF7001-A4E1-4A93-B900-444AB06B97A4">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top"><p><b>Mode</b></p></entry>
+<entry valign="top"><p><b>Description</b></p></entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p>Master</p></entry>
+<entry><p>The device is responsible for initializing and terminating
+the data transfer.</p></entry>
+</row>
+<row>
+<entry><p>Slave</p></entry>
+<entry><p>The device carries out the transfer initialized by a another
+device acting as a master.</p></entry>
+</row>
+<row>
+<entry><p>MasterSlave</p></entry>
+<entry><p>The device can perform both master and slave roles.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-F04D5138-0B76-425B-AB7F-EAF9B49AE385"><title>Transactions</title><p>A single exchange of data in one direction is known as a transfer.</p><p>A list of transfers is known as a transaction.</p><p>Transactions
+can be performed in half-duplex, or , full-duplex (if the underlying
+bus supports it).</p></section>
+<section id="GUID-4B44C99C-5C16-45DD-BDCE-A275ADFF2EE6"><title>Transaction
+preamble</title><p>In certain instances, some pre-processing might
+be required by the devices before a transaction can occur.</p><p>This
+can be done by the transaction preamble functionality, which executes
+immediately before the transaction is performed. This takes the form
+of a function.</p><p><note> the following restrictions apply to this
+function:</note></p><ul>
+<li><p>No spin locks are to be used.</p></li>
+<li><p>There are no block or waiting on a fast mutex operations.</p></li>
+<li><p>There are no calls to code that either uses spin locks, waits
+or blocks a fast mutex.</p></li>
+</ul><p>This is for a device that is in master mode.</p></section>
+<section id="GUID-254408BF-3797-4E82-B05D-EA8B99CB1EC8"><title>Extended
+transactions</title><p>This is where a number of separate transactions
+are linked together. It is used, for example, in situations where
+it is not known in advance how big  the transaction will be. </p><p>This is for a device that is in master mode.</p></section>
+<section id="GUID-9F62C005-AD6E-4AB3-8481-1834E5C8FB5F"><title>Controller
+and controller-less operation</title><p>Added to the above functionality,
+the IIC platform service API has two modes of operation:</p><ul>
+<li><p>With-controller and</p></li>
+<li><p>Controller-less</p></li>
+</ul><p>Controller operation is used in a situation where multiple
+device drivers can communicate with multiple channels. In controller-less
+operation, the link between a device driver and a channel is fixed.</p><p>In controller-less operation, the mode of the channel is set at
+build time, buy using the following macros in the relevant mmp files:</p><table id="GUID-01CC4575-6FCD-446B-AB39-0A97D7E698D2">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry align="left" valign="top"><p><b>Macro</b></p></entry>
+<entry align="left" valign="top"><p><b>Description</b></p></entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p>MASTER_MODE</p></entry>
+<entry><p>Specifies that the device is to act as a master.</p></entry>
+</row>
+<row>
+<entry><p>SLAVE_MODE</p></entry>
+<entry><p>Specifies that the device is to act as a slave.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><fig id="GUID-B72C9F84-4D55-4973-9D97-BD764F4CBBEA">
+<title>IIC with-controller operation</title>
+<image href="GUID-F67AFC0F-5245-48DE-8901-79461FB6EADE_d0e94068_href.png" placement="inline"/>
+</fig><fig id="GUID-E0227554-01E6-47CE-AA42-B45832D6F36C">
+<title>IIC controller-less operation</title>
+<image href="GUID-3CB74FE6-272E-4176-BC51-E36103CADB09_d0e94075_href.png" placement="inline"/>
+</fig></section>
+<section id="GUID-B7D17B8B-78AA-46AE-870B-C848CA2F8B08"><title>Interface
+classes</title><p>The class that is used for the client interface
+depends on whether the IIC controller is to be used or not.</p><p>If the IIC Controller is to be used, then the client interface API
+class is:</p><table id="GUID-DD881644-9306-4900-A66C-5737D487DABE">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top"><p><b>Name</b></p></entry>
+<entry valign="top"><p><b>Description</b></p></entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p><xref href="GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF.dita"><apiname>IicBus</apiname></xref></p></entry>
+<entry><p>Client interface API for the IIC component.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p>If the IIC controller is not to be used, then the client
+interface API classes are:</p><table id="GUID-2A6EAA19-F725-447C-8041-F60B5EFA32C5">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top"><p><b>Name</b></p></entry>
+<entry valign="top"><p><b>Description</b></p></entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p><xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita"><apiname>DIicBusChannelMaster</apiname></xref></p></entry>
+<entry><p>Client interface API for the master channel operation.</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita"><apiname>DIicBusChannelSlave</apiname></xref></p></entry>
+<entry><p>Client interface API for the slave channel operation.</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-26DBC836-03F1-31C4-BBFF-1F406E2BAEDB.dita"><apiname>DIicBusChannelMasterSlave</apiname></xref></p></entry>
+<entry><p>Client interface API for the master slave channel operation.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-984C2A0D-36BE-5A99-9D65-3F8791C669FF.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,65 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-984C2A0D-36BE-5A99-9D65-3F8791C669FF" xml:lang="en"><title>ASSP/Variant Architecture</title><shortdesc>A base port must provide a software layer called the ASSP/Variant.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The ASSP/Variant layer provides two main functions. First, it implements
+a small number of hardware-specific functions that are used by the
+Kernel. Second, it implements common peripheral control functions
+that other extensions and device drivers can use. </p>
+<p id="GUID-95C34114-F986-5428-9D40-5CF64429CDBD">  The most important
+of these functions is interrupt dispatching. During initialisation
+the ASSP/Variant must specify a dispatch function to be called for
+all hardware interrupts. </p>
+<p>In general, the ASSP/Variant provides control functions for hardware
+which is shared between multiple devices. For example it is often
+not possible to do a read-modify-write on a GPIO port in order to
+change the state of an individual output line. This may be either
+because an output port register is write-only or because reading the
+port register reads the actual logic levels on the pins, not the last
+value written to the register, and the pin level typically lags the
+written value due to capacitive loading. In this case, the ASSP/Variant
+could provide a function to set and clear individual port bits, keeping
+a RAM copy of the last value written to the port register. </p>
+<p>The simplest implementation is put all the code in a single DLL,
+called the Variant DLL (<filepath>ecust.dll</filepath>). For hardware
+architectures based on an ASSP, you can allow multiple types of phones
+that use the same ASSP to share the common code. To do this, the common
+ASSP code is implemented in a kernel extension, and the Variant DLL
+implements the code that is specific to the phone type. </p>
+<fig id="GUID-A42AFED6-372D-54A3-BC9D-FA99725464EF">
+<image href="GUID-71271D1C-C385-5687-8A90-46E8B590BB1E_d0e1517_href.png" placement="inline"/>
+</fig>
+<p>In the Base Porting Guide, we refer to the ASSP layer and the Variant
+Layer, where the ASSP layer contains the source code tailored to a
+range of different microprocessors (e.g. ARM720/920/SA1/Xscale), and
+the Variant layer contains the source code associated with off-chip
+hardware (same CPU, different peripherals). </p>
+<p>For example, the standard Symbian port for the template reference
+board is split into a core layer (in directory <filepath>...\template_assp\...</filepath>) and code specific to the template board (in directory <filepath>...\template_variant\...</filepath>). The <filepath>.mmp</filepath> file for the ASSP layer is <filepath>...\template_assp\katemplate.mmp</filepath>, and the <filepath>.mmp</filepath> file for the Variant layer is <filepath>...\template_variant\vtemplate.mmp</filepath>. </p>
+<section id="GUID-C05E021D-6DD6-5169-947B-192026A4364F"><title>The
+Asic class</title> <p>The heart of the ASSP/Variant is the <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita"><apiname>Asic</apiname></xref> class, defined in <filepath>..\e32\include\kernel\arm\assp.h</filepath>. This is a class that contains a number of pure virtual functions
+that must be implemented. </p> <p>Where there is an ASSP/Variant split,
+the ASSP layer should derive a concrete implementation from the <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita"><apiname>Asic</apiname></xref> class. The most convenient way of implementing the
+Variant layer is to further derive from this ASSP class. Only the
+Variant DLL is declared as ‘variant’ in the ROM – the ASSP is declared
+as an extension. If there is no ASSP/Variant split, then the Variant
+is simply a concrete implementation of the <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita"><apiname>Asic</apiname></xref> class. </p> <p>The ASSP layer can, itself, define additional functions
+to be implemented in the Variant layer. For example, the ASSP layer
+defines the pure virtual function <codeph>VideoRamSize()</codeph> which
+the Variant layer provides to map the video frame buffer. </p> <p>The template reference board port has the ASSP/Variant split. The
+ASSP layer is implemented by the <codeph>TemplateAssp</codeph> class,
+and the Variant layer is implemented by the <codeph>Template</codeph> class. </p> <p>For reference: the template port ASSP layer implementation's <filepath>.mmp</filepath> file is at <filepath>...\template_assp\katemplate.mmp</filepath>, and the Variant layer implementation's <filepath>.mmp</filepath> file is at <filepath>...\template_variant\vtemplate.mmp</filepath>. </p> <p>Note that one of the source files that forms the ASSP layer
+must have the <codeph>DECLARE_STANDARD_ASSP()</codeph> declaration.
+See <filepath>...\template_assp\assp.cpp</filepath>. </p> </section>
+</conbody><related-links>
+<link href="GUID-E0DCBDCF-C056-53E5-A375-778327F848E4.dita"><linktext>Asic
+Class                 Tutorial</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-99637158-DE86-4BB4-98D4-3A3E64AB768F-master.png has changed
Binary file Adaptation/GUID-99637158-DE86-4BB4-98D4-3A3E64AB768F_d0e87314_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-9986DCC6-EE73-59FB-BDAC-9B09DC64FBCE.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,84 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-9986DCC6-EE73-59FB-BDAC-9B09DC64FBCE" xml:lang="en"><title>Client of Master Channel Tutorial</title><shortdesc>Describes a simple implementation of a client using the
+master channel functionality.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This document describes a simple implementation of an IIC client
+using the master channel functionality. </p>
+<section id="GUID-A16020C1-28AC-4B14-9ADD-EEDD9C8EC65D"><title>Purpose</title> <p>This tutorial explains how to use the IIC platform service API
+as a master and to communicate with a peripheral using half-duplex. </p> <p><b>Intended Audience</b> </p> <p>Device driver writers. </p> <p><b>Required Background</b> </p> <p>Before you start, you must: </p> <ul>
+<li id="GUID-E339C63B-A5B2-535A-9EEB-E42F5913695F"><p>Have installed
+the platform specific implementation of IIC channels that is required
+to support the IIC platform service API. </p> </li>
+<li id="GUID-BF87DA07-52AD-5B46-BA69-61AB6E23CA38"><p>Include the <filepath>IIC.dll</filepath> in the <filepath>kernel.iby</filepath> file. </p> </li>
+<li id="GUID-DE66833F-6DE6-5068-BE7B-A748ABFE9915"><p>Include the <filepath>iic.h</filepath> and <filepath>iic_channel.h</filepath> header files. </p> </li>
+</ul> <p> <note>  The code example fragments are for synchronous operation.
+For asynchronous operation, the buffers must be allocated on the heap. </note></p> </section>
+<section id="GUID-420879EF-296C-4AB3-9B89-0C5BF6781206"><title>Implementing
+the IIC platform service</title> <p>The Following tasks will be covered
+in this tutorial: </p> <ul>
+<li id="GUID-FF0DF82E-6D88-5C58-844C-2E1036816FAD"><p>Performing read/write
+operations. </p> </li>
+</ul> <p><b>Basic Procedure</b> </p> <p><note> The implementation
+on which the following code examples are based is implemented IIC
+via a SPI bus. On hardware with dedicated IIC ports, the IIC port
+would be specified and the header data type would be TConfigIICV01.</note></p><p>The high level steps to performing read/write operations are
+shown here: </p> <ol id="GUID-0080AB2C-6DC5-5128-B2FB-7E1D81859F7B">
+<li id="GUID-3C607C4B-20B8-5ED7-8A82-BF75CC2C5286"><p>First set the
+bus type, the channel number and the slave address. </p> <p>An example
+of this is : </p> <codeblock id="GUID-A66F8DD0-A870-5210-9AAB-D3B837D0E831" xml:space="preserve">// Configure the port.
+    busId.SetBusType(DIicBusChannel::ESpi);        // Specify which multi-wire bus is to be used. in this example, SPI.
+    busId.SetChanNum(0);                           // Set the channel number.
+    busId.SetSlaveAddr(13);                        // Set the slave address. </codeblock> </li>
+<li id="GUID-27D5A0ED-818B-51AE-BB48-32929DB3E134"><p>Configure the
+channel. </p> <p>An example of which, is : </p> <codeblock id="GUID-43A34CF2-6324-5026-BC9E-28CE4B8D95A6" xml:space="preserve">// create header - this configures a SPI port.
+    const TConfigSpiV01 TestHeader =
+        {
+        ESpiWordWidth_8,                            // Set the word width. In this example, 8 bits.
+        260000,                                     // Set the clock speed of the port. In this example, 260KHz.
+        ESpiPolarityLowRisingEdge,                  // Set the clock mode value. In this example, Active high, odd edges.
+        500,                                        // Set the timeout period. In this example, 500msec.
+        EBigEndian,                                 // Set which endian is to be used. In this example, BigEndian is used.
+        EMsbFirst,                                  // Set which bit order is to be used. In this example, the Msb is first.
+        0,                                          // Set the number of transaction wait cycles. In this example, 0.
+        ESpiCSPinActiveLow                          // Set the Chip select active mode. In this example, chip select is active low.
+        };</codeblock> </li>
+<li id="GUID-6748A0B1-6A37-50AB-9D93-A230F419059A"><p>Make linked
+lists of the transfers that are to be carried out. </p> <p>An example
+of this is : </p> <codeblock id="GUID-C112BD53-C69C-595B-8452-82826AEC37B3" xml:space="preserve">// Set the transaction header.
+    TPckgBuf&lt;TConfigSpiV01&gt; header(TestHeader);
+
+    // Set up a transmit transaction.
+    // This txTransfer buffer acts as the start of the transaction linked list.
+    TIicBusTransfer txTransfer(TIicBusTransfer::EMasterWrite, 8, &amp;txTransferBuf);
+
+    // Set up a receive transaction.
+    TIicBusTransfer rxTransfer(TIicBusTransfer::EMasterRead, 8, &amp;rxTransferBuf);
+
+    // Add to the receive transaction to the transaction linked list.
+    txTransfer.LinkAfter(&amp;rxTransfer);
+
+    // Create a transaction using header and the transaction linked list.
+    TIicBusTransaction transaction(&amp;header, &amp;txTransfer);</codeblock> </li>
+<li id="GUID-B750A2D0-CFE2-584F-B2CF-5F19293B88BC"><p>Use the <xref href="GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF.dita#GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF/GUID-A1E7014A-6554-3D10-85E8-0DA839779800"><apiname>IicBus::QueueTransaction()</apiname></xref> method, specifying the configuration
+of the port and the start location of the transaction linked lists.
+This queues the transactions on to the selected IIC channel. </p> <p>An example of this is : </p> <codeblock id="GUID-5F929F5F-D8B3-5471-B65A-86D5D9DC8D7C" xml:space="preserve">// Queue the transaction.
+ // Once this command has been executed, the value of r should be KErrNone.
+    r = IicBus::QueueTransaction(busId.GetConfig(), &amp;transaction);</codeblock> </li>
+</ol> </section>
+</conbody><related-links>
+<link href="GUID-F461CBB3-F8D1-5961-AD51-5741143A1CB1.dita"><linktext>Client
+ of Slave Channel Tutorial</linktext></link>
+<link href="GUID-B2F86F54-EF50-56DB-ADF7-15325AC9324D.dita"><linktext>IIC
+Concepts</linktext></link>
+<link href="GUID-3A30DA16-ECA8-5639-A9DC-6BE2AD55420B.dita"><linktext>I2C
+Technology Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-99C4FCCC-9E8B-51CC-85F8-F03BE18DF19E-master.png has changed
Binary file Adaptation/GUID-99C4FCCC-9E8B-51CC-85F8-F03BE18DF19E_d0e82580_href.png has changed
Binary file Adaptation/GUID-99F7E70F-2733-57B2-94F5-A0C0FF9219FE-master.png has changed
Binary file Adaptation/GUID-99F7E70F-2733-57B2-94F5-A0C0FF9219FE_d0e10765_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-99FC067C-0AED-5373-AF63-8DB7FF5C1F7E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-99FC067C-0AED-5373-AF63-8DB7FF5C1F7E" xml:lang="en"><title>SPI Technology Guide</title><shortdesc>This document describes the Serial Peripheral Interface
+(SPI) technology. The SPI devices are used for fast data exchange
+between two or more peripherals. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+
+<section id="GUID-B3154A94-3117-5427-BAAD-C402F41AF217"><title>Introduction</title> <p>The SPI is a synchronous serial interface. The SPI supports full
+duplex communication channel for the devices that use SPI interface.
+The devices and peripherals that use the SPI interface are described
+as SPI devices in this document. </p> </section>
+<section id="GUID-6FAE8B3E-904C-567B-A6CC-5558D417BA66"><title>Architecture</title> <p>In the SPI bus one of the node must be a master device and one
+or more slave devices. There can be only one slave active at a time.
+The master device initiates and terminates communication between the
+SPI devices. The SPI is a full duplex serial data communication. In
+full duplex communication the data can be transferred between the
+master and the slave devices simultaneously. </p> <p>The SPI devices
+can be configured as master or slave. The SPI bus contain four wires.
+The first one is the serial clock signal sent by the master device
+to the slave device. The clock signal is used for synchronisation.
+The Master Output / Slave Input (<codeph>MOSI</codeph>) is used to
+send data from the master to the slave. The Slave Output / Master
+Input (<codeph>SOMI</codeph>) is used by the master device to read
+data from the slave device. The fourth line is the Slave Select (<codeph>SS</codeph>) that is used by the master to select a slave to initiate
+the communication. </p> <fig id="GUID-E7B96ED2-9814-5B75-8051-48337121F985-GENID-1-2-1-10-1-5-1-6-1-1-6-1-5-1-3-2-4">
+<title>              SPI Bus            </title>
+<image href="GUID-2AE438CC-F2E4-5FCB-971F-CFFAE5EF81E4_d0e93636_href.png" placement="inline"/>
+</fig> </section>
+<section id="GUID-6931A479-BF67-4BF7-8593-712D1770B402"><title>Communication</title> <p>The master device is the node on the SPI bus that initiates and
+terminates the communication. The master must provide the configuration
+to the slave devices. The configuration includes the details like
+the channel number and the data length. The SPI devices uses 4 and
+8 bit words to communicate. If a slave device or a channel is not
+available the appropriate error is returned to the master. </p> </section>
+<section id="GUID-B9575A06-1A72-529D-9023-FAC1ED895A34"><title>Advantages</title> <p>The following are the advantages of the SPI interface: </p> <ul>
+<li id="GUID-5FFFECEF-BCEA-5A8A-83F1-52E24019B22C"><p>Full duplex
+synchronous communication </p> </li>
+<li id="GUID-358181F9-4831-582F-B6F3-06AD09724BCB"><p>Low power requirements
+compared to the I2C devices </p> </li>
+<li id="GUID-701BDE22-3306-55EC-96FF-4E8F241CFFD6"><p>Less space compared
+to the parallel bus </p> </li>
+<li id="GUID-97E797F6-9228-58AA-984A-D872CCFDD812"><p>Slave devices
+do not require unique address assigned </p> </li>
+</ul> </section>
+<section id="GUID-8EF6A8EA-E813-5EF9-AE61-9ACD7FF8625E"><title>SPI
+devices</title> <p>Typically the SPI devices are used for data transfers
+where a delay in the time taken to send the data is acceptable. The
+clients of the SPI interface are device drivers running on the application
+specific integrated circuits (ASIC). Some of the peripherals that
+use SPI interface are: </p> <ul>
+<li id="GUID-D72EE2AE-A335-53FA-8A5E-DB110D4DDB2A"><p>Touch screens </p> </li>
+<li id="GUID-E60C872B-5B0B-5973-81FA-F93585859037"><p>Codecs </p> </li>
+<li id="GUID-4332DFC4-A2BF-5533-8704-6F56EF76C161"><p>Real Time Clocks </p> </li>
+<li id="GUID-DDFD3CB6-9696-504C-B23F-698873FA075E"><p>Built-in cameras </p> </li>
+<li id="GUID-DA624D60-DEDD-56F0-BC77-13FCBDB0D959"><p>Flash memory
+like MMC and SD cards </p> </li>
+</ul> </section>
+</conbody><related-links>
+<link href="GUID-B2F86F54-EF50-56DB-ADF7-15325AC9324D.dita"><linktext>IIC
+Concepts</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,228 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413" xml:lang="en"><title>User-Side
+Hardware Abstraction Technology</title><shortdesc>Description of HAL types and interfaces.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The User-Side Hardware Abstraction (HAL) component provides a platform-independent
+way to access and control many device specific features, and to hide hardware-specific
+functionality. For example, HAL can be used to find out if a screen backlight
+is present or not, or to set the display contrast. This topic </p>
+<section id="GUID-174A663C-3943-5D36-B507-D97A687C168C"><title>Attributes</title> <p>Specific
+items of hardware related information are referred to as <i>attributes</i>.
+Symbian platform defines two types of attribute: </p> <ul>
+<li id="GUID-3A220CC5-7D56-5FB8-A69A-EFAAC0159561"><p>Non-derived attribute.
+This is an attribute where the information it represent is simply a value
+that is stored in, and retrieved from, the HAL. </p> </li>
+<li id="GUID-934EFFE7-4768-5919-8900-6DE6915E3195"><p>Derived attribute. This
+is an attribute that requires a software call to obtain and set its value.
+The software component is, ultimately provided by a driver, kernel extension
+or by the kernel itself. The drivers or kernel extensions normally need porting. </p> </li>
+</ul> <p>Attributes are identified by the enumeration values of the enumerator <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-1959915A-BA99-3F94-AFD4-FD1AA540BFBF"><apiname>HALData::TAttribute</apiname></xref> defined
+in <filepath>...\hal\inc\hal_data.h</filepath> and is exported to <filepath>...\epoc32\include\</filepath>. </p> <p>To
+maintain backwards compatibility, the numbers identifying HAL attributes are
+allocated strictly increasing consecutive values, and that a given HAL attribute
+always has the same enumeration number on all implementations of Symbian platform.
+This means that new HAL attributes can only be added by Symbian. This also
+means that the addition of custom HAL attributes is not possible. </p> </section>
+<section id="GUID-F1F21DDA-DEA0-502E-83DB-84DDCFA5CBF8"><title>User-side interface</title> <p>Symbian
+platform provides the following static functions to get and set information
+about specific hardware features: </p> <ul>
+<li id="GUID-75ADEAE6-3BA5-55AA-9F6D-B91491CD1B7B"><p> <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-573C49D6-7763-37AE-B2B2-4C8FB1327E21"><apiname>HAL::Get()</apiname></xref>  </p> </li>
+<li id="GUID-A11EFEFE-D480-5557-965E-FEC524B7C5A9"><p> <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-9454F1B2-D525-3D6D-A872-C6457CACD4FC"><apiname>HAL::Set()</apiname></xref>  </p> </li>
+<li id="GUID-CD26D10D-84EB-56D4-AC70-86C2E65734E6"><p> <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-EF03B832-E9AA-32CF-903F-DFFA63A3E9AB"><apiname>HAL::GetAll()</apiname></xref>  </p> </li>
+</ul> <p>The <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita"><apiname>HAL</apiname></xref> class is defined in the source tree header
+file <filepath>...\hal\inc\hal.h</filepath>, and is exported to <filepath>...\epoc32\include\</filepath>.
+The functions are exported from the HAL DLL, which is built as part of the
+Variant. </p> <p> <codeph>Get()</codeph> and <codeph>Set()</codeph> take an <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-174A663C-3943-5D36-B507-D97A687C168C">attribute</xref> to
+identify specific hardware functionality. </p> <p> <codeph>GetAll()</codeph>,
+as its name implies gets all available hardware information, but is rarely
+used. See <xref href="GUID-124AC7EE-E227-5358-A755-628FFE257250.dita#GUID-124AC7EE-E227-5358-A755-628FFE257250/GUID-D75D3A65-590D-5716-84A7-0195DFCD1656">Dealing
+with the HAL::GetAll() function</xref> for more information. </p> <p> <codeph>Get()</codeph> and <codeph>Set()</codeph> each
+have a variation that allows a device number to be specified. The device number
+allows more than one set of attributes to be used. Each set is associated
+with a different device number. This is motivated by the need to support multiple
+display screens where each screen is identified as a separate device of the
+same 'type'. The idea of a device can be extended other hardware, and indeed
+the underlying implementation assumes a device number. If a device number
+is not specified and has no meaning, then a default device number of 0 is
+assumed for compatibility with the underlying implementation. </p> <p>For
+example, on return from code such as: </p> <codeblock id="GUID-D512D36F-C94A-50C2-9245-569C6386E559" xml:space="preserve">...
+TInt xpixels;
+HAL::Get(EDisplayXPixels, xpixels);
+...</codeblock> <p> <codeph> xpixels</codeph> contains the horizontal size
+of the display screen in terms of the number of pixels. If you have more than
+one screen, i.e. more than one device, then you would use the API variant
+that takes a device number. </p> </section>
+<section id="GUID-79BE4534-B9C6-5D64-8CB0-E3EEDE8AD293"><title>HAL handler
+interface</title> <p>A request for fetching and setting information about
+hardware is dealt with by an entity called a HAL handler on the kernel side.
+This section describes the types and concepts used to implement a HAL handler. </p> </section>
+<section id="GUID-FBA183CB-E9D5-4E70-B65F-A496853D614B"><title>HAL groups and function-ids</title><p>It is useful to group
+together requests for information about related hardware features so that
+they can be dealt with by a single HAL handler. As an example, all the HAL
+screen attributes are in the display group and are handled by the screen (i.e.
+video or LCD) driver. This means that a HAL group has a one-to-one association
+with a HAL handler. </p> <p>A HAL group has an associated set of function-ids,
+which identify requests for different pieces of information to the HAL handler. </p> <p>Symbian
+platform identifies HAL groups by a number defined by the <xref href="GUID-66A851A0-2A0C-3624-AEC1-22F6629FABF7.dita"><apiname>THalFunctionGroup</apiname></xref> enum
+in <filepath>u32hal.h</filepath>, which is exported to <filepath>...\epoc32\include</filepath>.
+For example, the <xref href="GUID-7F299BFC-D8A5-3A5A-B8DA-39BF42C99DC6.dita"><apiname>EHalGroupDisplay</apiname></xref> enum value identifies
+the group associated with the HAL screen attributes. </p> <p>The function-ids
+associated with each HAL group are also defined in <filepath>u32hal.h</filepath>.
+Each set of function-ids is defined by an enum; for example the enum <xref href="GUID-BB011D9B-105F-345C-9FC0-39B0BA509394.dita"><apiname>TDisplayHalFunction</apiname></xref> defines
+the function-ids associated with the HAL group <xref href="GUID-7F299BFC-D8A5-3A5A-B8DA-39BF42C99DC6.dita"><apiname>EHalGroupDisplay</apiname></xref>. </p> <p>The
+idea of the HAL group is what allows HAL handling functionality to be implemented
+in the Variant, rather than in the kernel. </p> <p>Up to 32 groups can be
+defined. Often, a HAL group is concerned with mode settings for a particular
+piece of hardware; for example there are standard HAL groups for keyboard,
+digitiser and display. However, some groups are concerned with some overall
+aspect of the platform which extends across all devices; for example, there
+is a group to handle emulation parameters on emulator platforms. </p> <p>An <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-174A663C-3943-5D36-B507-D97A687C168C">attribute</xref> maps
+to a HAL group/function-id pair, although the mapping is not necessarily a
+one-to-one relationship. For example, the calls: </p> <codeblock id="GUID-FB9CB26C-3DEF-5E8B-A564-40ECC68AD2FD" xml:space="preserve">TInt xPixels, yPixels;
+...
+HAL::Get(HALData::EDisplayXPixels,xPixels);
+HAL::Get(HALData::EDisplayYPixels,yPixels);
+...</codeblock> <p>both result in calls to the screen (i.e. video or LCD)
+HAL handler, as represented by the HAL group number <xref href="GUID-66A851A0-2A0C-3624-AEC1-22F6629FABF7.dita#GUID-66A851A0-2A0C-3624-AEC1-22F6629FABF7/GUID-950EA0D3-747F-305E-92EA-1579023A111E"><apiname>THalFunctionGroup::EHalGroupDisplay</apiname></xref>,
+using the same function-id <xref href="GUID-BB011D9B-105F-345C-9FC0-39B0BA509394.dita#GUID-BB011D9B-105F-345C-9FC0-39B0BA509394/GUID-FD814550-9B59-3196-827C-5C1A87E09D77"><apiname>TDisplayHalFunction::EDisplayHalScreenInfo</apiname></xref>. </p> <p>However,
+there are HAL group/function-id pairs for which there are no corresponding
+generic attributes. In these cases, the hardware attributes represented by
+the HAL group/function-id pair are used internally, and can only be accessed
+using the kernel side function <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-DA115709-A225-3E2A-BCCD-6E2BB15979B9"><apiname>Kern::HalFunction()</apiname></xref> **. </p> <p>The
+following picture shows the general idea: </p> <fig id="GUID-95743ED4-8CEC-5BAD-A5C2-9FD16D0485FA">
+<image href="GUID-F50E1C81-E80F-5692-996B-3AC2BE995425_d0e39862_href.png" placement="inline"/>
+</fig> <p>**Technically, the user side function <codeph>UserSvr::HalFunction()</codeph> will
+achieve the same thing, but this is <i>internal to Symbian</i> and is <i>not
+intended for general use</i>. </p></section>
+<section id="GUID-F28BA77B-D7AA-4D27-8ADF-029F42F800E4"><title>HAL handler implementation</title><p>Most HAL handlers are
+implemented as part of a driver, a kernel extension, the Variant or the kernel
+itself. Some will need porting. See <xref href="GUID-857F981E-711B-5CA8-AB37-5C700A6140FA.dita">Groups
+and the location of their HAL handlers</xref>. </p> <p>An extension or a device
+driver <i>must register</i> a handler for HAL group. It does so by calling <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-8C8DCE9D-0094-3909-8FDA-2F3134D0BC88"><apiname>Kern::AddHalEntry()</apiname></xref>,
+specifying the group number. It is important to note that it is the extension
+or driver's responsibility to do this; in other words, the kernel cannot know
+what entity within a final ported Symbian platform is going to be the HAL
+handler until it is explicitly told by registration. One point to note is
+that the HAL handlers for the groups: <xref href="GUID-F10DCE1F-756C-318D-B0D1-8C8F5255959E.dita"><apiname>EHalGroupKernel</apiname></xref>, <xref href="GUID-D60C5503-A176-354A-A655-22BE371178AE.dita"><apiname>EHalGroupVariant</apiname></xref> and <xref href="GUID-FB85CE22-DDFF-37E6-A6CE-7F70A994D371.dita"><apiname>EHalGroupPower</apiname></xref> are not explicitly registered - they are registered internally by the kernel
+itself. </p> <p>Internally, pointers to the HAL handler are stored in the
+array <codeph>K::HalFunction[]</codeph>, and this is indexed by the group
+number. </p> <p>On the template board, for example, the HAL handler for the
+display group is part of the screen driver. The screen driver source can be
+found in <filepath>...\template_variant\specific\lcd.cpp</filepath>. The HAL
+handler itself is the function: </p> <codeblock id="GUID-C7272D10-F603-5DF6-8C0B-EE18EDDAF32E" xml:space="preserve">LOCAL_C TInt halFunction(TAny* aPtr, TInt aFunction, TAny* a1, TAny* a2)
+    {
+    DLcdPowerHandler* pH=(DLcdPowerHandler*)aPtr;
+    return pH-&gt;HalFunction(aFunction,a1,a2);
+    }</codeblock> <p>The following code, implemented in the Create() function
+of the main class, does the registration. </p> <codeblock id="GUID-2B8BFFC5-8FC5-5220-BE9D-F02003C41275" xml:space="preserve">TInt DLcdPowerHandler::Create()
+    {
+    ...
+    // install the HAL function
+    r=Kern::AddHalEntry(EHalGroupDisplay,halFunction,this);
+    if (r!=KErrNone)
+        return r;
+    ...
+    }</codeblock> <p>Security is the responsibility of the HAL handler. If
+necessary, it needs to check the capability of the caller's process. Each
+information item, as identified by the function-id, can have an associated
+capability. </p> <p>Each function-id defined in <filepath>u32hal.h</filepath> is
+documented with the required capability. If no capability is listed, then
+no specific capability is required. </p> <p>See <xref href="GUID-124AC7EE-E227-5358-A755-628FFE257250.dita">Implementing
+HAL handlers</xref> for details. </p> </section>
+<section id="GUID-042A8840-2260-5951-8951-E6E2A83F378E"><title>Kernel-side
+interface</title> <p>Code such as device drivers that runs on the kernel side
+need not use the generic interface provided by the HAL class functions. The <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-DA115709-A225-3E2A-BCCD-6E2BB15979B9"><apiname>Kern::HalFunction()</apiname></xref> API
+is provided to access HAL information. </p> <p>Unlike the HAL class functions, <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-DA115709-A225-3E2A-BCCD-6E2BB15979B9"><apiname>Kern::HalFunction()</apiname></xref> uses
+the group number and function-ids to identify hardware related information.
+This means that kernel side code does not use attributes to identify hardware
+related information. The implication here is that you <i>may</i> have to make
+changes to your kernel side code when porting to another platform. In practice,
+no changes may be needed, but at the very least you need to check. </p> </section>
+<section id="GUID-43324161-56E6-40A7-A4C4-D3D8435D3568"><title>Config and Values files define attributes</title><p>Although
+an <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-174A663C-3943-5D36-B507-D97A687C168C">attribute</xref> is
+generic, some attributes may not have meaning on some platforms. In addition,
+each platform needs to define whether an attribute is either: </p> <ul>
+<li id="GUID-5D6B46DF-FAE7-5097-832D-F8FD33A3DB53"><p> <i>non-derived</i>,
+i.e. has a value that is simply stored in the HAL, </p> </li>
+</ul> <p>or: </p> <ul>
+<li id="GUID-B40D5AE3-13E7-50B0-8926-5B3461496DD2"><p> <i>derived</i>, i.e.
+requires a call to a software entity to get and set the value. </p> </li>
+</ul> <p>This is the role of the <i>Config file</i>. </p> <p>The Config file
+contains a list of all the attributes that have meaning on a platform, and
+uses the symbols defined in the enum <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita#GUID-8BE90160-2C60-3582-82C8-4A108C7C0317/GUID-1959915A-BA99-3F94-AFD4-FD1AA540BFBF"><apiname>HALData::TAttribute</apiname></xref> to
+identify them. Using a simple syntax, an attribute can be defined as being
+derived by associating the attribute symbol with the name of a function. This
+function is known as the <i>accessor function</i>. </p> <p>There is also a
+file known as the <i>Values file</i> that defines the initial values for all
+of the non-derived attributes, i.e. those attributes that are simply stored
+in, and retrieved from, the HAL. </p> <p>The Config and Values files are text
+files that, for a specific implementation of the HAL, reside in the <filepath>...\variant\hal</filepath> directory.
+The MMP file also resides there, and the HAL is built as part of the Variant.
+As part of the build process, the Config and Values files are passed to a
+Perl script, <filepath>halcfg.pl</filepath>, which translates the contents
+into C++ source files. The resulting binaries are linked in as part of the
+resulting HAL DLL. </p> <p>In effect, these C++ source files implement the
+static data arrays defined by the <codeph>HalInternal</codeph> class. As its
+name suggests, <b>this class is internal to Symbian platform</b>, and is only
+discussed here to help with understanding. </p> <codeblock id="GUID-35660653-5519-59B9-A8D1-1BC18EA5E46D" xml:space="preserve">class HalInternal
+    {
+    ...
+    static const TUint8 Properties[HAL::ENumHalAttributes];
+       ...
+    static const TInt InitialValue[HAL::ENumHalAttributes];
+    static const THalImplementation Implementation[HAL::ENumHalAttributes];
+    ...
+    }</codeblock> <p>The data member <codeph>Implementation[]</codeph> is
+an array of pointers to the accessor functions </p> <p>See <xref href="GUID-52583CC7-483E-54B5-8094-F0F61BD46B7F.dita">Creating
+the Config &amp; Values files</xref> for detailed syntax. </p></section>
+<section id="GUID-35FF9B50-7503-4F8E-B7A7-91287FDB57AB"><title>Derived attributes require accessor functions</title><p>Each
+derived attribute has a corresponding accessor function. For example, <codeph>ProcessDisplayContrast()</codeph>. </p> <p>All
+accessor functions are implemented in <filepath>...\hal\src\userhal.cpp</filepath>,
+and are provided by Symbian platform because of the 'connection' to attributes
+which are themselves defined as part of the generic platform. </p> <p>Generally
+there is one accessor function per derived attribute, although there is nothing
+to prevent an accessor function dealing with more than one attribute. The
+attribute number is used to route calls made to <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-573C49D6-7763-37AE-B2B2-4C8FB1327E21"><apiname>HAL::Get()</apiname></xref> and <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-9454F1B2-D525-3D6D-A872-C6457CACD4FC"><apiname>HAL::Set()</apiname></xref> forward
+to the correct accessor function. Internally, Symbian platform routes calls
+to Get() and Set() for an attribute to the same accessor function, distinguishing
+between the two by a boolean value. </p> <p>A new implementation of an accessor
+function should rarely, if ever, be needed as all likely accessor functions
+are already defined and implemented by Symbian platform in <filepath>...\hal\src\userhal.cpp</filepath>. </p> <p>See <xref href="GUID-A7ECF51F-F96A-5251-A71F-2F269C8C0664.dita">Writing accessor functions
+for derived attributes</xref>. </p></section>
+<section id="GUID-0561268F-C0D0-4E33-85A7-D90F3099E5D1"><title>Accessor functions call UserSvr::HalFunction()</title><p>Typically,
+an accessor function implementation calls <xref href="GUID-9EF04FB9-B36F-3A6F-AF3F-F2238BD181E9.dita#GUID-9EF04FB9-B36F-3A6F-AF3F-F2238BD181E9/GUID-7F07C14C-E69A-3277-8BFF-0CE2A820166D"><apiname>UserSvr::HalFunction()</apiname></xref>,
+specifying a group number, as defined in <xref href="GUID-66A851A0-2A0C-3624-AEC1-22F6629FABF7.dita"><apiname>THalFunctionGroup</apiname></xref>,
+and a function-id that is related to the attribute, but is <i>not</i> the
+attribute number as defined in <xref href="GUID-72B0351E-E8D1-3990-9673-A6713F923BC9.dita"><apiname>TAttribute</apiname></xref>. Function numbers
+are published in <filepath>u32hal.h</filepath>, and exported into <filepath>...\epoc32\include</filepath>;
+for example, the enumerators of the enum <codeph>TDigitiserHalFunction</codeph>. </p> <p>This
+means that it is the accessor function, which is part of Symbian platform
+generic code, that decides which HAL handler is to deal with a request (as
+identified by the attribute). </p> <p>The kernel uses the HAL group number
+as an index to dispatch the call to the correct HAL handler. </p> <p>Note
+that there may be cases where access to a HAL attribute may be handled through
+a device driver or server. </p></section>
+<section id="GUID-14E8EB8B-35FD-4780-8096-249742595207"><title>UserSvr::HalFunction() calls ExecHandler::HalFunction()</title><p>The
+static function <codeph>UserSvr::HalFunction()</codeph>, which is <i>internal</i> to
+Symbian platform, is the user side point of access. It takes a <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-366CC4B8-C6BD-5DCC-B55D-6D87CD5C8E64">HAL group</xref> to identify a set of related hardware features. In addition,
+it takes a function-id to identify specific hardware functionality within
+the HAL group, for example, one of the <codeph>TDisplayHalFunction</codeph> enumerators. </p> <p>A
+call to this function results in a call to the kernel side function <codeph>exechandler::HalFunction()</codeph>,
+passing the group number and the function-id. This, in turn, finds the appropriate <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-1B59A40C-D023-5555-8E5E-DF18D653D321">HAL
+handler</xref> function in the internal array <codeph>K::HalFunction[]</codeph>,
+using the group number as the index. </p> <p> <codeph>UserSvr::HalFunction()</codeph> is
+exported from <filepath>euser.dll</filepath>, and is therefore accessible
+from the user side. However, it is <i>not intended for general third party
+use</i>. </p> <p>For information purposes, the <codeph>UserSvr</codeph> class
+is defined in the source tree header file <filepath>...\e32\include\e32svr.h</filepath>,
+which is exported to <filepath>...\epoc32\include\</filepath>. </p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-9B52E0C3-9EBB-44C6-A1BF-2F95711FFBA4.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-9B52E0C3-9EBB-44C6-A1BF-2F95711FFBA4" xml:lang="en"><title>Template
+Source Code</title><shortdesc>This document discusses the template code from which device drivers
+are created.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-2AE61413-CECE-4E72-86AA-0DD4FFC60EC3">       <title>Template
+source code</title>       <p>To help enable a base port be produced quickly,
+Symbian platform provides template source code for drivers for most peripherals.
+The template implements a framework and protocols for the type of peripheral;
+the base port implementer then supplies additional implementation for the
+particular hardware device. For example, for the UART driver, the PDD template
+implements the standard hardware abstraction interfaces for serial communication,
+such as the <codeph>DComm</codeph> class. It leaves some sections marked as
+"TBD", which are specific to the device. Driver developers can start with
+these templates and fill in the "TBD" functions to create a basic driver.
+If required, additional functionality can then be added to this. </p> <p>The
+template drivers are located in the <filepath>sf\os\kernelhwsrv\bsptemplate\asspandvariant\template_variant</filepath> source
+directory. The <filepath>template</filepath> directory provides a variant
+base port that includes all the drivers required to do the minimal base port
+for any variant. </p> <p>Details of the templates for particular drivers are
+discussed in the relevant sections of the <i>Base Porting Guide</i>. This
+tutorial presents an additional example device driver. </p>     </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-9B66387C-B6CF-41D9-BEFC-F79E30C70F52.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-9B66387C-B6CF-41D9-BEFC-F79E30C70F52" xml:lang="en"><title>Interrupt Build Guide</title><shortdesc>Describes how to build Interrupt platform service</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Interrupt platform service is implemented as a part of the
+ASSP variant layer and hence included in the baseport. For more information,
+refer to <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">ROM
+Building</xref> guides.</p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-9BBDFF77-5E2C-4E13-BEB3-716CC80B3375.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,71 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-9BBDFF77-5E2C-4E13-BEB3-716CC80B3375" xml:lang="en"><title>SDIO Implementation Guide</title><shortdesc>How to port the SDIO Controller for your platform to provide
+the SDIO adaptation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The SDIO implementation shares most of its functionality with the
+Secure Digital (SD) Controller, which in turn extends the MultiMedia
+Card (MMC) Controller. SDIO adds support for data transfer between
+Input/Output hardware included on SDIO peripherals. The SDIO Controller
+initializes SDIO peripherals and provides an API so that class drivers
+can access the SDIO services.</p>
+<p>Providing an SDIO adaptation for your platform means porting the
+SDIO Controller. This is done by providing platform specific implementations
+of the SDIO SHAI interface functions.</p>
+<section id="GUID-64516BCF-2245-46DF-9E7F-FFC18AC7F691"><title>Prerequisites</title><p>SDIO depends on SD and MMC: the SDIO protocol is a super-set of
+the SD protocol (and of the MMC protocol). Therefore, in addition
+to the SDIO standard, you need to know about the following:<ul>
+<li><p>SD (Secure Digital)</p></li>
+<li><p>MMC (MultiMedia Card)</p></li>
+</ul></p>     </section>
+<section id="GUID-A6598353-0AC5-4DB0-82AD-C2F397CB5CD0"><title>Architecture</title><p>The following diagram illustrates the implementation of the SDIO
+extension for the MMC Controller. The classes in green provide the
+hardware interface and the classes in blue implement the platform-specific
+functions.</p><fig id="GUID-AA66D99B-9EF2-4803-8D43-A3BDA180C9C9">
+<title>SDIO Controller classes</title>
+<image href="GUID-D5030CC5-1FC1-40F3-9D68-4A454B25C58B_d0e103563_href.png" placement="inline"/>
+</fig></section>
+<section id="GUID-20DF01A9-64AF-45E6-8F22-2E384F4177EA"><title>Implementation</title>The Platform-Independent Layer (PIL) of the SDIO Controller is made
+up from three sets of files described in the following table:<p><table id="GUID-54A82958-4168-42CD-81DE-466CEA0FEEFC-GENID-1-2-1-10-1-5-1-9-1-1-8-1-5-1-3-5-2-1">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">Standard</entry>
+<entry valign="top">Source code location</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry>MMC</entry>
+<entry><p><filepath>os/kernelhwsrv/kernel/eka/drivers/pbus/mmc</filepath></p><p>See also <xref href="GUID-40F2BC43-5022-5F4E-B445-56FEF43FEB8B.dita">Code Organization</xref> in the MMC section.</p></entry>
+</row>
+<row>
+<entry>SD</entry>
+<entry><filepath>os/kernelhwsrv/kernel/eka/drivers/pbus/mmc/sdcard/sdcard3c/</filepath><p>Also see <xref href="GUID-E194A923-99E7-5DC1-BB78-D050A4793A60.dita#GUID-E194A923-99E7-5DC1-BB78-D050A4793A60/GUID-59DA32AA-97F3-4001-9B6F-887E986C633D">Source Code</xref> in the SD section.</p></entry>
+</row>
+<row>
+<entry>SDIO</entry>
+<entry><filepath>os/kernelhwsrv/kernel/eka/drivers/pbus/mmc/sdcard/sdcard3c/sdio/</filepath></entry>
+</row>
+</tbody>
+</tgroup>
+</table></p><p>The Platform-Specific Layer (PSL) should be located
+in a variant directory and have a similar folder hierarchy to the
+PIL. It should provide the following implementations:<ul>
+<li><p>Stack</p></li>
+<li><p>Power Supply Unit (PSU)</p></li>
+</ul> These implementations are discussed in the tutorials:<ul>
+<li><p><xref href="GUID-2344B900-5EC5-4467-BEAD-AB55C88CE63E.dita">SDIO
+Stack Implementation Tutorial</xref></p></li>
+<li><p><xref href="GUID-7E3BBB18-3113-4312-AD91-897DE87C58BF.dita">SDIO
+PSU Implementation Tutorial</xref></p></li>
+</ul></p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-9C05C157-D58E-4C43-87E4-82B4F310AEA9.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,50 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-9C05C157-D58E-4C43-87E4-82B4F310AEA9" xml:lang="en"><title>DmaChannelMgr Implementation</title><shortdesc>Describes how to write the hardware-specific functions
+of the <codeph>DmaChannelMgr</codeph> class.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita"><apiname>DmaChannelMgr</apiname></xref> class is already defined in
+the DMA header file but it belongs to the PSL implementation: opening
+and closing channels require hardware-specific operations. </p>
+<p>When implementing the PSL, you need to provide at least one function:<codeblock xml:space="preserve">TDmaChannel* DmaChannelMgr::Open(TUint32 aOpenId)</codeblock></p>
+<p>This function opens a DMA channel and returns the object controlling
+this channel.</p>
+<p>How the channel is allocated is hardware-dependent. The call to
+the <codeph>Open()</codeph> function specifies which channel to open
+through the <codeph>aOpenId</codeph> parameter. The format of the
+parameter is not part of the DMA platform service and depends on an
+agreement between the PSL implementation and the driver using DMA.
+The example section below shows a static method, but the allocation
+could also be completely or partially dynamic. </p>
+<p>If you want to perform a hardware-specific operation when closing
+the channel, you also need to update <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita#GUID-176B8E0D-0422-341B-A134-7C85432E1303/GUID-909D795A-7303-3A76-9C8E-3B07A97DD716"><apiname>DmaChannelMgr::Close()</apiname></xref>. It is usually not necessary: in the template source code, it is
+implemented as doing nothing.</p>
+<p/>
+<example><title>Open() example</title><p>This example illustrates
+a simple allocation scheme where <codeph>aOpenId</codeph> represents
+the index of the requested channel in the channel array (<codeph>Controller.iChannels</codeph>).<codeblock xml:space="preserve">
+TDmaChannel* DmaChannelMgr::Open(TUint32 aOpenId)
+	{
+	__DMA_ASSERTA(aOpenId &lt; static_cast&lt;TUint32&gt;(KChannelCount));
+	TDmaChannel* pC = Controller.iChannels + aOpenId;
+	if (pC-&gt;IsOpened())
+		pC = NULL;
+	else
+		{
+		pC-&gt;iController = &amp;Controller;
+		pC-&gt;iPslId = aOpenId;
+		}
+      return pC;
+}</codeblock></p></example>
+</conbody><related-links>
+<link href="GUID-D5ED62EB-744D-42EB-B8CF-D5623BDA5B38.dita"><linktext>DMA
+Client Interface Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-9CC514E9-85C2-5F4B-9F3B-F9FA1F4CB20A-master.png has changed
Binary file Adaptation/GUID-9CC514E9-85C2-5F4B-9F3B-F9FA1F4CB20A_d0e14358_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-9CF985F1-C100-5999-9410-58B7865A1E18.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-9CF985F1-C100-5999-9410-58B7865A1E18" xml:lang="en"><title>Obey Files</title><prolog><metadata><keywords/></metadata></prolog><conbody><p>OBEY files are standard text files containing statements that are used to control the operation of the ROM building tools. <xref href="GUID-003D2C5B-09DC-5BD1-AF45-A0FCB56F567B.dita">ROMBUILD</xref>An obey file has a <filepath>.oby</filepath> extension, and any files included by the OBEY file have a <filepath>.iby</filepath> extension. </p> <p> <xref href="GUID-003D2C5B-09DC-5BD1-AF45-A0FCB56F567B.dita">ROMBUILD</xref> and <xref href="GUID-BF04B68E-7F77-5D99-A0F6-2842758EFD4D.dita">ROFSBUILD</xref> understand a different subset of the complete set of OBEY file statements. Many statements are only understood by one tool, and a number of statements are common to both tools. In addition, some specific keywords are understood by <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">BUILDROM</xref> only. BUILDROM typically converts them into statements that are understood by ROMBUILD, ROFSBUILD or both. </p> </conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-9D26E38F-5C7B-5330-A54B-8F97D0F204D0-GENID-1-2-1-8-1-1-7-1-1-5-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,90 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-9D26E38F-5C7B-5330-A54B-8F97D0F204D0-GENID-1-2-1-8-1-1-7-1-1-5-1" xml:lang="en"><title>Performance
+Logging</title><shortdesc>Symbian platform provides macros that you can use in device driver
+and kernel extension programs to write a trace log. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>You can use the trace log to test the performance of the programs. </p>
+<section id="GUID-C332215D-B9E8-415B-8246-27D69F6A6E74-GENID-1-2-1-8-1-1-7-1-1-5-1-3-2"><title>Perfomance macros</title> <p>There are three macros that you
+can insert into your code. They only differ with respect to the optional data
+that you can add to the trace record. All are defined in <filepath>kernperfloger.h</filepath>  </p> <ul>
+<li id="GUID-FB5EA9F3-4236-504C-B5A7-9FC1803A0DB8-GENID-1-2-1-8-1-1-7-1-1-5-1-3-2-3-1"><p> <xref href="GUID-0CBE2ABA-A508-3E26-88FE-E4DAAE945D5E.dita"><apiname>PERF_LOG0</apiname></xref> <codeph>(aSubCategory)</codeph>  </p> </li>
+<li id="GUID-3B115481-BB41-55E3-AD33-225EB3B5A91C-GENID-1-2-1-8-1-1-7-1-1-5-1-3-2-3-2"><p> <xref href="GUID-226FB57A-414A-3DC8-BFD7-6B93B55CD4B1.dita"><apiname>PERF_LOG1</apiname></xref> <codeph>(aSubCategory,aUserData)</codeph> </p> </li>
+<li id="GUID-FCBBFB1A-7DC9-5857-A0E0-050EA5C48FED-GENID-1-2-1-8-1-1-7-1-1-5-1-3-2-3-3"><p> <xref href="GUID-78D928F5-0ADA-31BE-A71D-0542A9B6E3D6.dita"><apiname>PERF_LOG2</apiname></xref> <codeph>(aSubCategory,aUserData,aUserData2)</codeph> </p> <p>Note:
+the <xref href="GUID-02CF31A2-562D-3E8B-9A12-4C93D1B8DD19.dita"><apiname>PERF_LOG</apiname></xref> macro is identical to <xref href="GUID-78D928F5-0ADA-31BE-A71D-0542A9B6E3D6.dita"><apiname>PERF_LOG2</apiname></xref>. </p> </li>
+</ul> <p>You must specify an the 8-bit integer subcategory value in the <codeph>aSubCategory</codeph> argument.
+You can also supply one or two (or zero) 32-bit values; you are free to decide
+on the meaning of such values. </p> <p>The macros wrap around the standard <codeph>BTrace***</codeph> macros.
+All trace records generated by these macros are given a category of <xref href="GUID-5BF17780-AD31-30CF-AFD9-915CBDA74441.dita#GUID-5BF17780-AD31-30CF-AFD9-915CBDA74441/GUID-E0E36933-0D01-35A9-9CCE-015F28E7E386"><apiname>BTrace::EKernPerfLog</apiname></xref>. </p> <p>The
+generation and capture of trace information is implemented as a kernel extension.
+This means that it is loaded and activated at an early stage in the startup
+process of the device. </p> </section>
+<section id="GUID-AD31830B-ED00-436F-9B36-EB3B3B0BFE4F-GENID-1-2-1-8-1-1-7-1-1-5-1-3-3"><title>Performance macro output format</title> <p>The following table
+shows which fields of a trace record are generated by each of the macros <xref href="GUID-0CBE2ABA-A508-3E26-88FE-E4DAAE945D5E.dita"><apiname>PERF_LOG0</apiname></xref>, <xref href="GUID-226FB57A-414A-3DC8-BFD7-6B93B55CD4B1.dita"><apiname>PERF_LOG1</apiname></xref>,
+and <xref href="GUID-78D928F5-0ADA-31BE-A71D-0542A9B6E3D6.dita"><apiname>PERF_LOG2</apiname></xref>: </p> <table id="GUID-B409B220-479A-5999-A746-33787F764B6C-GENID-1-2-1-8-1-1-7-1-1-5-1-3-3-3">
+<tgroup cols="4"><colspec colname="col0"/><colspec colname="col1"/><colspec colname="col2"/><colspec colname="col3"/>
+<tbody>
+<row>
+<entry><p> <b>Field</b>  </p> </entry>
+<entry><p> <b>PERF_LOG0</b>  </p> </entry>
+<entry><p> <b>PERF_LOG1</b>  </p> </entry>
+<entry><p> <b>PERF_LOG2</b>  </p> </entry>
+</row>
+<row>
+<entry><p>Fast Counter Timestamp </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p>Context Id </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p>PC value </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p>the 32-bit integer value passed as aUserData </p> </entry>
+<entry><p>NO </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p>the 32-bit integer value passed as aUserData2 </p> </entry>
+<entry><p>NO </p> </entry>
+<entry><p>NO </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p>Tick Count as returned from a call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-CAE58268-9553-37B3-9669-EACD32A1A662"><apiname>NKern::TickCount()</apiname></xref>  </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-70DA77F8-2B90-41B3-9373-7AE902FDE0EA-GENID-1-2-1-8-1-1-7-1-1-5-1-3-4"><title>How to use the macros</title> <p>To use the macros: </p> <ul>
+<li id="GUID-4A92EAE7-B042-524B-B007-7828ECC99EC5-GENID-1-2-1-8-1-1-7-1-1-5-1-3-4-3-1"><p>Include the header file <filepath>kernperfloger.h</filepath> in
+your source code. </p> </li>
+<li id="GUID-A7A4BEED-F4D5-5D08-A4CB-0C088336FE37-GENID-1-2-1-8-1-1-7-1-1-5-1-3-4-3-2"><p>Link to <codeph>btrace.lib</codeph> in
+your project </p> </li>
+<li id="GUID-BF42F248-7D2B-5BE3-87CD-5CEEDBF0B3A5-GENID-1-2-1-8-1-1-7-1-1-5-1-3-4-3-3"><p>Call the <codeph>PERF_LOG***</codeph> macros
+at appropriate points in your code. </p> <p>For examples, see the test code
+for the macros in <filepath>...\e32test\group\d_perflogger_test_ldd.mmp</filepath> and <filepath>...\e32test\group\t_perflogger.mmp</filepath>  </p> </li>
+<li id="GUID-B3C6CA8D-7257-59B8-8F96-D7F848F76223-GENID-1-2-1-8-1-1-7-1-1-5-1-3-4-3-4"><p>Rebuild your project </p> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-9D26E38F-5C7B-5330-A54B-8F97D0F204D0-GENID-1-2-1-9-1-8-1-19-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,90 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-9D26E38F-5C7B-5330-A54B-8F97D0F204D0-GENID-1-2-1-9-1-8-1-19-1" xml:lang="en"><title>Performance
+Logging</title><shortdesc>Symbian platform provides macros that you can use in device driver
+and kernel extension programs to write a trace log. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>You can use the trace log to test the performance of the programs. </p>
+<section id="GUID-C332215D-B9E8-415B-8246-27D69F6A6E74-GENID-1-2-1-9-1-8-1-19-1-3-2"><title>Perfomance macros</title> <p>There are three macros that you
+can insert into your code. They only differ with respect to the optional data
+that you can add to the trace record. All are defined in <filepath>kernperfloger.h</filepath>  </p> <ul>
+<li id="GUID-FB5EA9F3-4236-504C-B5A7-9FC1803A0DB8-GENID-1-2-1-9-1-8-1-19-1-3-2-3-1"><p> <xref href="GUID-0CBE2ABA-A508-3E26-88FE-E4DAAE945D5E.dita"><apiname>PERF_LOG0</apiname></xref> <codeph>(aSubCategory)</codeph>  </p> </li>
+<li id="GUID-3B115481-BB41-55E3-AD33-225EB3B5A91C-GENID-1-2-1-9-1-8-1-19-1-3-2-3-2"><p> <xref href="GUID-226FB57A-414A-3DC8-BFD7-6B93B55CD4B1.dita"><apiname>PERF_LOG1</apiname></xref> <codeph>(aSubCategory,aUserData)</codeph> </p> </li>
+<li id="GUID-FCBBFB1A-7DC9-5857-A0E0-050EA5C48FED-GENID-1-2-1-9-1-8-1-19-1-3-2-3-3"><p> <xref href="GUID-78D928F5-0ADA-31BE-A71D-0542A9B6E3D6.dita"><apiname>PERF_LOG2</apiname></xref> <codeph>(aSubCategory,aUserData,aUserData2)</codeph> </p> <p>Note:
+the <xref href="GUID-02CF31A2-562D-3E8B-9A12-4C93D1B8DD19.dita"><apiname>PERF_LOG</apiname></xref> macro is identical to <xref href="GUID-78D928F5-0ADA-31BE-A71D-0542A9B6E3D6.dita"><apiname>PERF_LOG2</apiname></xref>. </p> </li>
+</ul> <p>You must specify an the 8-bit integer subcategory value in the <codeph>aSubCategory</codeph> argument.
+You can also supply one or two (or zero) 32-bit values; you are free to decide
+on the meaning of such values. </p> <p>The macros wrap around the standard <codeph>BTrace***</codeph> macros.
+All trace records generated by these macros are given a category of <xref href="GUID-5BF17780-AD31-30CF-AFD9-915CBDA74441.dita#GUID-5BF17780-AD31-30CF-AFD9-915CBDA74441/GUID-E0E36933-0D01-35A9-9CCE-015F28E7E386"><apiname>BTrace::EKernPerfLog</apiname></xref>. </p> <p>The
+generation and capture of trace information is implemented as a kernel extension.
+This means that it is loaded and activated at an early stage in the startup
+process of the device. </p> </section>
+<section id="GUID-AD31830B-ED00-436F-9B36-EB3B3B0BFE4F-GENID-1-2-1-9-1-8-1-19-1-3-3"><title>Performance macro output format</title> <p>The following table
+shows which fields of a trace record are generated by each of the macros <xref href="GUID-0CBE2ABA-A508-3E26-88FE-E4DAAE945D5E.dita"><apiname>PERF_LOG0</apiname></xref>, <xref href="GUID-226FB57A-414A-3DC8-BFD7-6B93B55CD4B1.dita"><apiname>PERF_LOG1</apiname></xref>,
+and <xref href="GUID-78D928F5-0ADA-31BE-A71D-0542A9B6E3D6.dita"><apiname>PERF_LOG2</apiname></xref>: </p> <table id="GUID-B409B220-479A-5999-A746-33787F764B6C-GENID-1-2-1-9-1-8-1-19-1-3-3-3">
+<tgroup cols="4"><colspec colname="col0"/><colspec colname="col1"/><colspec colname="col2"/><colspec colname="col3"/>
+<tbody>
+<row>
+<entry><p> <b>Field</b>  </p> </entry>
+<entry><p> <b>PERF_LOG0</b>  </p> </entry>
+<entry><p> <b>PERF_LOG1</b>  </p> </entry>
+<entry><p> <b>PERF_LOG2</b>  </p> </entry>
+</row>
+<row>
+<entry><p>Fast Counter Timestamp </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p>Context Id </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p>PC value </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p>the 32-bit integer value passed as aUserData </p> </entry>
+<entry><p>NO </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p>the 32-bit integer value passed as aUserData2 </p> </entry>
+<entry><p>NO </p> </entry>
+<entry><p>NO </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p>Tick Count as returned from a call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-CAE58268-9553-37B3-9669-EACD32A1A662"><apiname>NKern::TickCount()</apiname></xref>  </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-70DA77F8-2B90-41B3-9373-7AE902FDE0EA-GENID-1-2-1-9-1-8-1-19-1-3-4"><title>How to use the macros</title> <p>To use the macros: </p> <ul>
+<li id="GUID-4A92EAE7-B042-524B-B007-7828ECC99EC5-GENID-1-2-1-9-1-8-1-19-1-3-4-3-1"><p>Include the header file <filepath>kernperfloger.h</filepath> in
+your source code. </p> </li>
+<li id="GUID-A7A4BEED-F4D5-5D08-A4CB-0C088336FE37-GENID-1-2-1-9-1-8-1-19-1-3-4-3-2"><p>Link to <codeph>btrace.lib</codeph> in
+your project </p> </li>
+<li id="GUID-BF42F248-7D2B-5BE3-87CD-5CEEDBF0B3A5-GENID-1-2-1-9-1-8-1-19-1-3-4-3-3"><p>Call the <codeph>PERF_LOG***</codeph> macros
+at appropriate points in your code. </p> <p>For examples, see the test code
+for the macros in <filepath>...\e32test\group\d_perflogger_test_ldd.mmp</filepath> and <filepath>...\e32test\group\t_perflogger.mmp</filepath>  </p> </li>
+<li id="GUID-B3C6CA8D-7257-59B8-8F96-D7F848F76223-GENID-1-2-1-9-1-8-1-19-1-3-4-3-4"><p>Rebuild your project </p> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-9D4B8CDF-60D7-5952-AAAF-94A3C1E8908F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-9D4B8CDF-60D7-5952-AAAF-94A3C1E8908F" xml:lang="en"><title>Architecture</title><shortdesc>Explains architecture of the User-Side Hardware Abstraction (HAL)
+component.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<fig id="GUID-38D3E959-F627-592D-A05F-9F907B6DB95C">
+<image href="GUID-FF2ABA1D-1F71-5A9C-AFD5-A0CED39BFD86_d0e39571_href.png" placement="inline"/>
+</fig>
+<ul>
+<li id="GUID-47670BE0-64BD-53E8-A7EF-6735FC5C0DC5"><p>Specific items of hardware
+related information are called <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-174A663C-3943-5D36-B507-D97A687C168C">attributes</xref>. </p> <p>The base port customises the <filepath>hal.dll</filepath> library to
+set which attributes can be used on a device. </p> <p>Some attributes are
+simple values, but some attributes must be read and set with a function. These
+functions are called accessor functions. The base port sets identifiers for
+the accessor functions to use. </p> </li>
+<li id="GUID-380B5157-C605-5231-AF98-A08FC974F812"><p>User-side programs use
+the <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-F1F21DDA-DEA0-502E-83DB-84DDCFA5CBF8">user-side
+interface</xref> <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita"><apiname>HAL</apiname></xref> class in <filepath>hal.dll</filepath> to
+get and set information about attributes. </p> </li>
+<li id="GUID-9795E5E7-88AC-56DA-8269-CD4C9493E2C4"><p>The accessor functions
+are implemented on the kernel side by functions called <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-1B59A40C-D023-5555-8E5E-DF18D653D321">HAL handlers</xref>. </p> <p>The variant DLL and many device drivers in a
+base port can implement HAL handlers. </p> </li>
+<li id="GUID-0C70C3D4-3FD0-5CD8-A7C0-A28C77417460"><p>Kernel-side programs
+can use the <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-042A8840-2260-5951-8951-E6E2A83F378E">Kernel-side
+interface</xref> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-DA115709-A225-3E2A-BCCD-6E2BB15979B9"><apiname>Kern::HalFunction()</apiname></xref> function to call HAL
+handler functions. </p> </li>
+</ul>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-9D8C62FB-1E42-5B69-8ECC-2B68AD7C71A5-master.png has changed
Binary file Adaptation/GUID-9D8C62FB-1E42-5B69-8ECC-2B68AD7C71A5_d0e25863_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A04F46F8-1BA9-5A77-B455-59C67DD4AA36.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A04F46F8-1BA9-5A77-B455-59C67DD4AA36" xml:lang="en"><title>Serial Port Driver</title><shortdesc>The Serial Port Driver is a device driver that handles serial port
+hardware (create the physical channel). This section describes how to create
+a port of it for your phone hardware. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p id="GUID-2AC9DD85-20AB-5E41-B21C-A08300989531"> The Serial Port Driver
+provides a logical device driver, <filepath>ecomm.dll</filepath>. You must
+provide a physical device driver to implement the interface to the serial
+port hardware on your phone. </p>
+</conbody><related-links>
+<link href="GUID-B4259E9C-624F-5B73-8ADF-BAC9EDEF898C.dita#GUID-B4259E9C-624F-5B73-8ADF-BAC9EDEF898C/GUID-CA46EF95-D841-5B71-BE0C-E746B11177ED">
+<linktext>H4 serial   connections</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A25FFD79-0797-43EC-8975-8C23E7E539C4.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A25FFD79-0797-43EC-8975-8C23E7E539C4" xml:lang="en"><title>Register Access Technology Guide</title><shortdesc>Provides information about the Register Access technology.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Register Access platform service is implemented in the ASSP
+layer. The Register Access functionality is provided to the clients
+by implementing the <xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita"><apiname>AsspRegister</apiname></xref> class.</p>
+<section id="GUID-F80CF14A-3CB2-41B1-A3BD-DBD116FDBA8C-GENID-1-2-1-10-1-5-1-8-1-1-7-1-3-2">         
+   <title>Purpose</title>             <p>The Register Access platform
+service provides an interface to the kernel and device drivers to
+read, write or modify the contents of only the ASSP registers.</p>  </section>
+<section id="GUID-59E2379C-CD1F-4ABD-A380-2195651D1443"><title>Key
+concepts</title><dl>
+<dlentry>
+<dt>Register</dt>
+<dd><p>A register is a memory location on the ASSP hardware to store
+data that relates to the operation of that hardware. The Symbian platform
+support registers that can store 8, 16, 32 and 64–bit data.</p></dd>
+</dlentry>
+<dlentry>
+<dt>Bitmask</dt>
+<dd><p>The <codeph>Modify</codeph> function of the AsspRegister class
+allows the clients to set or clear certain bits stored in the register.</p></dd>
+</dlentry>
+<dlentry>
+<dt>Application-Specific Standard Product (ASSP)</dt>
+<dd><p>ASSP is an integrated circuit consisting of CPU, Memory Management
+Unit (MMU), cache and a number of on-chip peripherals, which is intended
+to be used in a class of devices. Typical examples include UARTs,
+timers, LCD controller that are designed and marketed by a silicon
+vendor.</p></dd>
+</dlentry>
+</dl></section>
+<section id="GUID-44AD8B68-B9AF-472A-A4E5-6102B3767E97"><title>Typical
+uses</title><p>The Register Access platform service allows the clients
+to:</p><ul>
+<li><p>read data stored in 8, 16, 32 and 64–bit registers</p></li>
+<li><p>store data in 8. 16, 32 and 64–bit registers</p></li>
+<li><p>change certain bits of the data in 8, 16, 32 and 64–bit registers.</p></li>
+</ul></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,369 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA" xml:lang="en"><title>Keyword reference (D-F)</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This page lists the keywords starting from D to F. </p>
+<section id="GUID-D3FA449B-0A87-4739-991C-6C59C6DEEC71"><title>data-align</title><codeblock xml:space="preserve">data-align = &lt;hex-number&gt;</codeblock><p><i>rombuild
+only</i></p><p>This keyword specifies the alignment for the executable's
+data. It indicates the start address of a data segment that must be
+aligned to a specified value.</p><p><b>Note</b>: The
+inclusion of <codeph>data-align</codeph> keyword in an OBY file does
+not increase the size of ROM image.</p></section>
+<section id="GUID-DF3AEED2-A9D0-5176-B4E5-63F73262BE07"><title>datapagingoverride</title> <codeblock id="GUID-76519D8D-65AA-5553-87D6-70BDBA94F6CB" xml:space="preserve">datapagingoverride [NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED | DEFAULTPAGED]</codeblock> <p> <i>rombuild and rofsbuild </i>  </p> <p>If the <codeph>datapagingoverride</codeph> keyword is spe,cified in an OBY file, it overrides the configuration
+for data paging for the executable files defined in OBY file. This
+keyword takes a single argument, which can be one of the possible
+values listed in <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-20A2663B-FE05-5E0A-ACF9-669EDDC8317C">codepagingoverride</xref>. </p> </section>
+<section id="GUID-7DAC5804-0A03-5098-836A-2DB2CDB6F5D4"><title>datapagingpolicy</title> <codeblock id="GUID-F3A5F40B-2FF3-54FE-91A4-EDA247D184DE" xml:space="preserve">datapagingpolicy [NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED | DEFAULTPAGED]</codeblock> <p> <i>rombuild and rofsbuild </i>  </p> <p>This overrides the default
+settings for data paging and the settings from all the <xref href="GUID-85B33746-074D-5B54-ACF4-1B1620D48FF6.dita#GUID-85B33746-074D-5B54-ACF4-1B1620D48FF6/GUID-08CFF2B1-63CC-5358-AD13-B4152A83B640">previous levels</xref>. </p> <p>This keyword takes a single argument,
+which can be one of the possible values listed in <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-20A2663B-FE05-5E0A-ACF9-669EDDC8317C">codepagingoverride</xref>. </p> </section>
+<section id="GUID-23851F44-7FAC-5B99-8D15-44099A61A4E4"><title>data[[HWVD]]</title> <codeblock id="GUID-BF169545-15DE-5044-8800-880DD16C301C" xml:space="preserve">data[[HWVD]] = &lt;source-file&gt; &lt;destination-file&gt; [File-attribute-list]
+</codeblock> <p> <i>rombuild and rofsbuild</i>  </p> <p>A file that
+is copied from its source location into the ROM without any processing. </p> <p>Note that the HWVD is optional but, if specified, must be enclosed
+within square brackets. </p> </section>
+<section id="GUID-2F0E6FDC-4822-5FFF-9D7A-E2E25E088945"><title>dataaddress</title> <codeblock id="GUID-D060AFCC-0D79-5C8E-9D16-49883DE78C94" xml:space="preserve">dataaddress = &lt;hex-address&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Linear address of data/bss chunks
+for all executables except the Kernel. </p> </section>
+<section id="GUID-EAD738DD-C0D5-5437-926D-8F567B78EDB2"><title>datadriveimagename</title> <codeblock id="GUID-CEA1CE42-50FD-5E49-8EB7-E6EBDAE3D090" xml:space="preserve">datadriveimagename = &lt;image name&gt;</codeblock> <p> <i> ROFSBUILD only</i>  </p> <p>Specifies the name of the data
+drive image. </p> </section>
+<section id="GUID-DD194603-EF11-5119-944B-399844BE8FF6"><title>DATA_IMAGE</title> <codeblock id="GUID-266AF2AA-32D1-5226-83DF-EEC3BE30645E" xml:space="preserve">DATA_IMAGE &lt;id&gt; &lt;name&gt; [size=&lt;partition size&gt;] [FAT16 | FAT32] [compress | no-compress]</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Defines a data drive image. </p> <p>This is a data drive configuration feature. There is no limitation
+for the number of data drive images that can be defined for an internal
+media. </p> <table id="GUID-00ED8A80-B25C-50FB-83CB-CEA1D97D5872">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>id</codeph>  </p> </entry>
+<entry><p>A value to identify the data drive image. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>name</codeph>  </p> </entry>
+<entry><p>A name suitable as a suffix for the data drive image, IBY
+and logs. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>size = &lt;partition size&gt;</codeph>  </p> </entry>
+<entry><p>Defines the size of the data drive image that has to be
+generated. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>compress</codeph>  </p> </entry>
+<entry><p>Compresses files in the image. If not specified, no compression
+is the default behaviour. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>To mark a file for inclusion in a data drive it is prefixed
+with the keyword DATA_IMAGE. For example: </p> <codeblock id="GUID-5BC759DE-15ED-547B-8011-B0ED471D4520" xml:space="preserve">DATA_IMAGE[2] fatname size=16000000 fat16 -compress</codeblock> <p>The above information can also be included using '{' '}' braces,
+for example: </p> <codeblock id="GUID-26C953FA-7885-55D1-A404-FE6DA2BD3A84" xml:space="preserve">DATA_IMAGE[2]
+    {
+    dataimagename=fatname
+    compress
+    dataimagefilesystem=fat16
+    dataimagesize=16000000    
+    }
+      </codeblock> </section>
+<section id="GUID-3C7B6900-5190-540B-8B17-F0BCE7FCB1DB"><title> dataimagefilesystem</title> <codeblock id="GUID-C65978B7-63E7-513D-8733-F63062BED849" xml:space="preserve">dataimagefilesystem = &lt;FAT16 | FAT32&gt;</codeblock> <p> <i>BUILDROM and ROFSBUILD only</i>  </p> <p>Specifies the file
+system type of the datadrive image. If this is not specified then
+by default <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">BUILDROM</xref> sets the image file system as fat16. </p> </section>
+<section id="GUID-F15BB2C7-6773-5636-B329-4789AFEC809C"><title>dataimagename</title> <codeblock id="GUID-921E43DC-BCF6-59C5-9C29-6280E5ABF128" xml:space="preserve">dataimagename = &lt;image name&gt;</codeblock> <p> <i> ROFSBUILD only</i>  </p> <p>Specifies the name of the datadrive
+image. If this is not specified then by default <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">BUILDROM</xref> sets
+the image name as <b>dataimagex</b>, where x is the image index. </p> </section>
+<section id="GUID-C0E3CB31-93F9-548F-BAD1-54D04F719504"><title> dataimagesize</title> <codeblock id="GUID-BD29E016-BC13-5D0B-9CC6-39B7288C2EE9" xml:space="preserve">dataimagesize = &lt;size in bytes&gt;</codeblock> <p> <i>ROFSBUILD only</i>  </p> <p>Specifies the maximum size of
+a data drive image. The default size is the size of the data drive
+folder. </p> </section>
+<section id="GUID-A3DA2415-FAF3-56D9-9598-6A3E615C2248"><title>DEFAULT_LANGUAGE</title> <codeblock id="GUID-37A5F46F-9A43-51D5-A141-E617EC540002" xml:space="preserve">DEFAULT_LANGUAGE NN</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Localisation support. Specifies
+the default language as a Symbian 2-digit code. This keyword should
+only be used once. </p> </section>
+<section id="GUID-06D8C5BB-5FFD-5A49-98FC-C5F133C0C126"><title>DEFINE</title> <codeblock id="GUID-8C60E867-2372-5823-ACB5-E336E99BC009" xml:space="preserve">DEFINE &lt;name&gt; &lt;replacement&gt;</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Performs textual substitution.
+All subsequent instances of &lt;name&gt; are replaced by &lt;replacement&gt;. </p> <p>Notes: </p> <ul>
+<li id="GUID-82C80198-2F51-5D7C-84DB-F398F09FE9E5"><p>There is no
+UNDEFINE facility, and substitutions are applied in an unspecified
+order </p> </li>
+<li id="GUID-31FA7AC7-4615-57B5-8AF7-A289E0734792"><p>The C++ preprocessor
+cannot be used conveniently because it inserts whitespace around substituted
+text. </p> </li>
+</ul> </section>
+<section id="GUID-5A5348CB-1562-5C05-857D-C3F3EEDB51D7"><title>device[[HWVD]]</title> <codeblock id="GUID-12D1F89D-7E21-5FE0-8037-6B9E1516400C" xml:space="preserve">device[[HWVD]] = &lt;source-file&gt; &lt;destination-image-file&gt; [File-attribute-list] [Override-Attribute-list]</codeblock> <p> <i>rombuild only</i>  </p> <p>Defines kernel-mode logical or
+physical device drivers, which can have global data. The address of
+this data is generated by <codeph>rombuild</codeph>. </p> <p>Note
+that the <codeph>HWVD</codeph> is optional but, if specified, must
+be enclosed within square brackets. </p> </section>
+<section id="GUID-35E198AB-4B68-55C1-B6FB-471E743412DD"><title>dll[[HWVD]]</title> <codeblock id="GUID-BA573051-4702-5D15-B9D1-83E69B35F34E" xml:space="preserve">dll[[HWVD]] = &lt;source-file&gt; &lt;destination-image-file&gt; [File-attribute-list] [Override-Attribute-list]</codeblock> <p> <i>rombuild only</i>  </p> <p>Specifies an executable file whose
+entry point must be called. </p> </section>
+<section id="GUID-28C6642D-FBA6-5FD4-A8A5-BE761F71FBB6"><title>debugport</title> <codeblock id="GUID-260500B6-DF9D-58C8-B2C5-9EEBCEFD8281" xml:space="preserve">debugport = &lt;32bit-number&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Specifies the destination port
+for Kernel and Bootstrap traces. </p> <p> <codeph>rombuild</codeph> stores the value in the ROM header. Each ASSP is free to interpret
+the debug port as it pleases, for example, as a serial port number
+or as an I/O base address. The default value is -1. </p> </section>
+<section id="GUID-0F63B6BF-5F9B-54A6-9109-D8661D365E5D"><title>defaultstackreserve</title> <codeblock id="GUID-58808242-D04B-5EB0-A2C8-0BD552976C3D" xml:space="preserve">defaultstackreserve = &lt;default stack reserve&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Specifies the maximum size of
+the stack. </p> </section>
+<section id="GUID-F6F5BB84-ED0A-578F-88E5-26017E303C8E"><title>demandpagingconfig</title> <codeblock id="GUID-E2E8D89C-EE12-57F6-8F96-EBB170F74BC6" xml:space="preserve">demandpagingconfig &lt;MinLivePages&gt; &lt;MaxLivePages&gt; &lt;YoungOldPageRatio&gt; &lt;NANDPageReadDelay&gt; &lt;NANDPageReadCPUOverhead&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Specifies settings for demand
+paging enabled ROM. </p> <p>This keyword takes four arguments, which
+are described below: </p> <ul>
+<li id="GUID-36F11698-0AE0-5EE1-974F-6649441B8068"><p> <codeph>MinLivePages</codeph>: This is the minimim number of RAM pages to reserve for the paging
+system.The number must be at least equal to 2*(YoungOldPageRatio+1).
+If a smaller number is specified, a number equal to this formula is
+used instead. </p> <p>For example, the <codeph>YoungOldPageRatio</codeph> is 3 and <codeph>MinLivePages</codeph> is set to 5. According to
+the formula 2*(YoungOldPageRatio+1), the minimum number of live pages
+must be 8, but the number specified is 5. So the minimum number is
+set to 8. </p> </li>
+<li id="GUID-4363D4F0-29B4-528A-A8C0-6AD33EC38E8D"><p> <codeph>MaxLivePages</codeph>: The maximum number of RAM pages the paging system may use. The
+number must be greater than or equal to <codeph>MinLivePages</codeph>. On a production system the number is always set to maximum (32767).
+However, low values may be used to test the effects of low free RAM. </p> </li>
+<li id="GUID-5B7A3BAC-74C2-53F0-BB42-A780C2039A95"><p> <codeph>YoungOldPageRatio</codeph>: The ratio of young to old pages maintained by the system. For this
+purpose, the paging system maintains a list of live pages, which is
+again split into two sub-lists: a list of young pages, and a list
+of old pages in the system. The paging system uses <codeph>YoungOldPageRatio</codeph> to maintain the relative sizes of these two lists. </p> <p>For example,
+let us assume that the ratio is R, the number of young pages is N<sub>y</sub> and the number of old pages is N<sub>o</sub>. If N<sub>y</sub> &gt; RN<sub>o</sub>, a page is taken from the end of the young pages
+list and placed at the start of the old pages list. This process is
+called aging. </p> </li>
+<li id="GUID-F83C2062-8417-5A80-A842-6402B5AB3AFD"><p> <codeph>NANDPageReadDelay</codeph>: The delay in microseconds, between initiating a page read operation
+and completing it. During this delay, other threads in the system
+may use the CPU. </p> </li>
+<li id="GUID-FC3B5DDD-72EF-52CD-BD65-5CFAE8C23C22"><p> <codeph>NANDPageReadCPUOverhead</codeph>: The CPU instruction execution time in microseconds, to setup and
+process a page read operation. During this delay, the CPU is busy
+and is not accessible by other threads. </p> </li>
+</ul> <p> <b>Note</b>: All the above listed attributes are limited
+to the value range 0-32767. </p> </section>
+<section id="GUID-8F9F15ED-B972-517E-91E3-F58657324A31"><title>dlldatatop</title> <codeblock id="GUID-F20FD3D8-BB27-5EBA-9A19-EE4BFC0F6BB5" xml:space="preserve">dlldatatop = &lt;address of data region&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Specifies the top of the DLL data
+region. </p> </section>
+<section id="GUID-E7D77979-190A-5BB4-90A3-00E3C022A6E5"><title>ECHO</title> <codeblock id="GUID-18383190-BB88-535F-8841-624E15B8445A" xml:space="preserve">ECHO &lt;anything at all&gt;</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Prints the rest of the line following
+the ECHO keyword to standard output. </p> </section>
+<section id="GUID-92EAD7F7-6524-57BF-9417-B455AF469C7A"><title>__ECOM_PLUGIN</title> <codeblock id="GUID-3C774FDB-5DB0-5FE1-94E1-F6E368E04FB8" xml:space="preserve">__ECOM_PLUGIN(&lt;local build directory&gt;, &lt;rom binary directory&gt;, &lt;local epoc32\data\Z directory&gt;, &lt;rom resources directory&gt;, &lt;DLL filename&gt;, &lt;resource filename&gt;)</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Specifies an ECom plug-in, consisting
+of an implementation DLL and an ECom registration resource file, to
+include in ROM. </p> <p>Symbian platform code does not use this keyword
+directly. Instead, it uses the macro <codeph>ECOM_PLUGIN</codeph>,
+defined in <codeph>\epoc32\rom\include\header.iby</codeph>, which
+allows the plug-in to be specified more briefly, in the following
+form: </p> <codeblock id="GUID-323952F5-34D9-585A-8623-082A7567FD3D" xml:space="preserve">ECOM_PLUGIN(&lt;DLL name&gt;,&lt;resource file name&gt;)</codeblock> <p>For example: </p> <codeblock id="GUID-B7B37728-A4C2-5DD0-B6E3-8F45272CC157" xml:space="preserve">ECOM_PLUGIN(foo.dll,12345abc.rsc)</codeblock> <p>Note that the resource file name is specified using the <codeph>&lt;DLL-uid&gt;.rsc</codeph> format. </p> <p>Use of this keyword allows <codeph>BUILDROM</codeph> to perform special handling of ECom plug-ins. In
+particular, it allows <codeph>BUILDROM</codeph> optionally to create
+a static plug-in information (SPI) file, which contains all the resource
+registration files for ROM-based plug-ins. This allows ECom to be
+more efficient, as it can use the SPI file to find all ROM-based plug-ins
+and not have to scan the file system for them. BUILDROM implements
+this using the <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-04F39AC1-3947-5C80-90BB-55CDF4D34571">spidata</xref> keyword. </p> <p>Note that as part of the ROM creation
+process, it is possible to add support for multiple languages. This
+affects how ECom resource files are specified by BUILDROM: </p> <ul>
+<li id="GUID-96C7FC54-5652-5CCC-9CAA-DC8F485B57CA"><p>If an SPI file
+is being created the <codeph>ECOM_PLUGIN</codeph> lines are processed
+at an intermediate BUILDROM stage to produce: </p> <codeblock id="GUID-64381884-1F25-515B-9149-5124BC3CADCD" xml:space="preserve">spidata=MULTI_LINGUIFY( EXT sourcename destname ) &lt;spi-id&gt; &lt;target-spi-dir&gt;</codeblock> <p>During the BUILDROM localisation stage these lines become: </p> <codeblock id="GUID-CA8D9809-F375-5056-A919-D69E59A1C263" xml:space="preserve">spidata = &lt;source-file&gt; &lt;original-destination-file&gt; &lt;spi-id&gt; &lt;target-spi-dir&gt;</codeblock> <p>where <codeph>&lt;spi-id&gt;</codeph> has the extension .SPI for
+the default language, and the extension .S<varname>nn</varname> for
+all other language codes <varname>nn</varname>. This means that if
+multiple languages are being included in the ROM image there is an
+SPI file for each included language. </p> </li>
+<li id="GUID-63C3444C-F760-5F1E-A932-C8F0CEA5EA2D"><p>If an SPI file
+is not being created <codeph>ECOM_PLUGIN</codeph> lines are processed
+an intermediate BUILDROM stage to produce: </p> <codeblock id="GUID-C32115C6-CEB4-5A5F-9240-35368276F645" xml:space="preserve">data=MULTI_LINGUIFY( EXT sourcename destname )</codeblock> <p>During the BUILDROM localisation stage these lines become: </p> <p> <codeph>data=sourcename.Enn destname.EXT</codeph> for the default
+language code </p> <p> <codeph>data=sourcename.Enn destname.Enn</codeph> for all other language codes <varname>nn</varname>. </p> </li>
+</ul> </section>
+<section id="GUID-7FB63AF4-EEAF-538E-8E55-95CC6CA9091B"><title>EPOCROOT</title> <codeblock id="GUID-AEA1E441-8DEC-5F45-9BE3-E8147F1F73B4" xml:space="preserve">EPOCROOT</codeblock> <p> <i>BUILDROM only</i>  </p> <p>A pre-defined substitution. This
+is replaced with the value of the EPOCROOT environment variable. </p> <p>Note that there is no UNDEFINE facility, and substitutions are
+applied in an unspecified order. </p> </section>
+<section id="GUID-14316103-95C6-50A2-A15C-4980979EBCF2"><title>epocwrapper</title> <codeblock id="GUID-0A447659-7A3A-55BF-B86E-86644CCF0648" xml:space="preserve">epocwrapper</codeblock> <p> <i>rombuild only</i>  </p> <p>Indicates that a Symbian platform
+ROM wrapper is required </p> </section>
+<section id="GUID-1756F49A-2609-52C1-AC31-6CC0B2306069"><title>ERROR</title> <codeblock id="GUID-07B567F3-84A2-5ACD-939E-F6E2C1BFEB93" xml:space="preserve">ERROR &lt;anything at all&gt;</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Prints the rest of the line following
+the ERROR keyword to standard output, and reports the source file
+name and the line number. In addition, it causes <codeph>BUILDROM</codeph> to terminate without attempting to create the ROM image(s). </p> </section>
+<section id="GUID-1374D944-1C79-5C23-B972-1B0BABA09450"><title>exattrib</title> <codeblock id="GUID-7B7E6EFC-1E48-5D92-ABBC-8041AB4F5936" xml:space="preserve">exattrib=U</codeblock> <p> <i>ROFSBUILD only</i>  </p> <p>This keyword is used with the <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-23851F44-7FAC-5B99-8D15-44099A61A4E4">data</xref> keyword to specify an additional attribute for the file
+being included in the ROM image. This attribute enables the file server
+to append the ROFS mounting information in the format, <codeph>file.ext[&lt;mount_id&gt;-00]</codeph> when registering the file. </p> <p>The following example shows how
+this keyword is used to set the attribute for a text file, which is
+copied to the ROM image: </p> <codeblock id="GUID-947FF981-CA3C-5D63-93FE-17AF4ECE5C89" xml:space="preserve">data=EPOCROOT##epoc32\rom\rofstest\hello8.txt Exattrib\test1.txt exattrib=U
+</codeblock> <p>Assuming that the <filepath>test1.txt</filepath> file
+is in the ROFS image and is the first one to be mounted by the file
+server, the file is included in the ROM image in the following format: </p> <codeblock id="GUID-2A1E6F77-9E14-5606-86C0-A73E11387B55" xml:space="preserve">z:\Exattrib\test1.txt[01-00]</codeblock> </section>
+<section id="GUID-B46B421D-4237-5053-BF27-66EA64EFAD92"><title>EXCLUDE_FEATURE</title> <codeblock id="GUID-DA793DC7-DB78-5EDF-A03E-B2516845DAA7" xml:space="preserve">EXCLUDE_FEATURE &lt;feature name&gt; [ SF &lt;status flags&gt; ]  [ UD &lt;user data&gt; ] </codeblock> <p>Where <codeph>&lt;feature&gt;</codeph> is either the feature name
+or a feature uid value. </p> <p> <b>Note</b>: The space between the <codeph>keyword FEATURE</codeph> and <codeph>&lt;feature name&gt;</codeph> is
+optional. </p> <p> <codeph>&lt;status flags&gt;</codeph> is a 32 bit
+hex number indicating the status flags of the feature. Each bit in
+the status flag signifies the following: </p> <table id="GUID-69260F1E-5EEA-520B-83DD-38BF980AA7C2">
+<tgroup cols="3"><colspec colname="col0"/><colspec colname="col1"/>
+<colspec colname="col2"/>
+<thead>
+<row>
+<entry>Bit</entry>
+<entry>Flag Name</entry>
+<entry>Value</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p>0 </p> </entry>
+<entry><p>Supported </p> </entry>
+<entry><p>If the bit is set the feature is included, else the feature
+is excluded. </p> </entry>
+</row>
+<row>
+<entry><p>1</p> </entry>
+<entry><p>Upgradeable </p> </entry>
+<entry><p>This bit is reserved for future use. It will be used to
+upgrade a feature which is already associated to the device. </p> </entry>
+</row>
+<row>
+<entry><p>2</p> </entry>
+<entry><p>Modifiable </p> </entry>
+<entry><p>If the bit is set the feature is modified at run-time. The
+default flag values for such a feature are defined in a ROM image
+obey file. </p> </entry>
+</row>
+<row>
+<entry><p>3</p> </entry>
+<entry><p>Blacklisted </p> </entry>
+<entry><p>If the bit is set the feature is blacklisted, and cannot
+be changed at run-time. It signifies that if the feature appears in
+subsequent data files or plug-in info, it would be ignored. </p> <p>It also prevents a feature from being upgraded and it can never be
+changed/ overridden. If a feature is blacklisted, its upgradeable
+flag is not set. </p> </entry>
+</row>
+<row>
+<entry><p>4</p> </entry>
+<entry><p>Uninitialised </p> </entry>
+<entry><p>If the bit is set the flag supported state is not initialised
+at build-time, and it is initialised at run-time by system software. </p> <p>To set the supported flag of a specific feature, perform a runtime
+call to <codeph>RFeatureControl</codeph>. </p> </entry>
+</row>
+<row>
+<entry><p>5</p> </entry>
+<entry><p>Persisted </p> </entry>
+<entry><p>If the bit is set the flag value is preserved across reboot
+or system turn off period. </p> </entry>
+</row>
+<row>
+<entry><p>6-31 </p> </entry>
+<entry><p>Reserved </p> </entry>
+<entry><p>These bits are reserved for future use. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p> <codeph>&lt;user data&gt;</codeph> is a 32 bit hex number
+indicating the user data value associated with the feature. </p> <p> <i>BUILDROM only</i>  </p> <p>The <b>EXCLUDE_FEATURE</b> keyword
+is used to mark a feature as excluded. </p> </section>
+<section id="GUID-1D8AC4CF-8EDA-538B-8A74-5A55CCDEE2AB"><title>extension[[HWVD]]</title> <codeblock id="GUID-26B88CD3-6BEB-5CCD-8BA4-5659295BAA65" xml:space="preserve">extension[[HWVD]] = &lt;source-file&gt; &lt;destination-image-file&gt; [File-attribute-list] [Override-Attribute-list]</codeblock> <p> <i>rombuild only</i>  </p> <p>Defines a kernel-mode DLL that
+can have global data, the address of which is generated by <codeph>rombuild</codeph>. Extension files are connected together in a linked
+list, which allows the Kernel to load the extensions at boot time
+before the ROM file system is available. </p> <p>Note that the <codeph>HWVD</codeph> is optional but, if specified, must be enclosed within
+square brackets. </p> </section>
+<section id="GUID-1E15B489-2FF4-5C14-90B2-0EE66CBB7F7F"><title>extensionrofs</title> <codeblock id="GUID-30CBD9F3-B021-5A26-9C00-5BFC470BFE1C" xml:space="preserve">extensionrofs</codeblock> <p> <i>rofsbuild only</i>  </p> <p>Marks the start of the definition
+of an optional extension ROFS. </p> </section>
+<section id="GUID-7780C1D5-92C0-58D1-9953-7231A760546E"><title>extensionrofsname</title> <codeblock id="GUID-8AE6D48E-5202-5B2F-9BC7-535325A771AE" xml:space="preserve">extensionrofsname = &lt;filename&gt;</codeblock> <p> <i>rofsbuild only</i>  </p> <p>Defines the name of the ROFS
+extension image. </p> <p>Any new files added after this keyword will
+appear in the extension. The files in the core can be renamed, hidden,
+and aliased by using the other keywords. </p> </section>
+<section id="GUID-0BDDFFBC-C045-5A1A-8DEC-7FBF6AEFFC64"><title>extensionrom</title> <codeblock id="GUID-E0D850A0-0B91-5A4C-B904-2AC8196BDFC3" xml:space="preserve">extensionrom = &lt;rom-file-name&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>This marks the start of an extension
+ROM section. A filename of "*" can be specified, which means use the
+file name specified on the <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-29BEF45C-2361-5245-9184-0261B99B6FB1">romname</xref> keyword in a rom-information-statement </p> </section>
+<section id="GUID-A71135A8-C6A6-50DB-8081-8CCD5B6AC0CB"><title>externaltool</title> <codeblock id="GUID-4A76182B-1A07-5C3B-8403-59C9F7910873" xml:space="preserve">externaltool=&lt;toolname&gt;</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Used for invoking external tools
+through the IBY file keyword externaltool, specifying the list of
+toolnames each seperated by a comma. <codeph>externaltool=toolname1,
+toolname2,... toolnameN</codeph>  </p> <p>The same invocation can
+be achieved alternatively by using <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita#GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463/GUID-3E50F8DA-36D3-5E3D-B229-F841EF4AC47D">BUILDROM</xref> command-line option <codeph>-e&lt;toolname&gt;.</codeph>  </p> </section>
+<section id="GUID-1D289928-36B0-55D6-A061-7D01C6E5802A"><title>fattable</title> <codeblock id="GUID-7F17C3F3-4CF9-5268-BCFB-4B2B99F7464B" xml:space="preserve">fattable=&lt;number of FAT tables&gt;</codeblock> <p> <i>rofsbuild only</i>  </p> <p>Configures the number of FAT
+tables for the file system in the data-drive image. </p> </section>
+<section id="GUID-AA809069-1D03-5578-8409-314DD3D27FD5"><title>FEATURE</title> <codeblock id="GUID-216E30B1-1105-5E89-87C8-A2BF1FBE7FC2" xml:space="preserve">FEATURE &lt;feature name&gt; [ SF &lt;status flags&gt; ]  [ UD &lt;user data&gt; ]</codeblock> <p>Where <codeph>&lt;feature&gt;</codeph> is either the feature name
+or the feature uid value. </p> <p> <b>Note</b>: The space between
+the <codeph>keyword FEATURE</codeph> and <codeph>&lt;feature name&gt;</codeph> is optional. </p> <p> <codeph>&lt;status flags&gt;</codeph> is a 32
+bit hex number indicating the status flags of the feature. Each bit
+in the status flag signifies the following: </p> <table id="GUID-CDA5C906-4B45-5BCF-9923-37D7FF042BF0">
+<tgroup cols="3"><colspec colname="col0"/><colspec colname="col1"/>
+<colspec colname="col2"/>
+<thead>
+<row>
+<entry>Bit</entry>
+<entry>Flag Name</entry>
+<entry>Value</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p>0 </p> </entry>
+<entry><p>Supported </p> </entry>
+<entry><p>If the bit is set the feature is included, else the feature
+is excluded. </p> </entry>
+</row>
+<row>
+<entry><p>1</p> </entry>
+<entry><p>Upgradeable </p> </entry>
+<entry><p>This bit is reserved for future use. It will be used to
+upgrade a feature which is already associated to the device. </p> </entry>
+</row>
+<row>
+<entry><p>2</p> </entry>
+<entry><p>Modifiable </p> </entry>
+<entry><p>If the bit is set the feature is modified at run-time. The
+default flag values for such a feature are defined in a ROM image
+obey file. </p> </entry>
+</row>
+<row>
+<entry><p>3</p> </entry>
+<entry><p>Blacklisted </p> </entry>
+<entry><p>If the bit is set the feature is blacklisted, and cannot
+be changed at run-time. It signifies that if the feature appears in
+subsequent data files or plug-in info, it would be ignored. </p> <p>It also prevents a feature from being upgraded and it can never be
+changed/ overridden. If a feature is blacklisted, its upgradeable
+flag is not set. </p> </entry>
+</row>
+<row>
+<entry><p>4</p> </entry>
+<entry><p>Uninitialised </p> </entry>
+<entry><p>If the bit is set the flag supported state is not initialised
+at build-time, and it is initialised at run-time by system software. </p> <p>To set the supported flag of a specific feature, perform a runtime
+call to <codeph>RFeatureControl</codeph>. </p> </entry>
+</row>
+<row>
+<entry><p>5</p> </entry>
+<entry><p>Persisted </p> </entry>
+<entry><p>If the bit is set the flag value is preserved across reboot
+or system turn off period. </p> </entry>
+</row>
+<row>
+<entry><p>6-31 </p> </entry>
+<entry><p>Reserved </p> </entry>
+<entry><p>These bits are reserved for future use. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p> <codeph>&lt;user data&gt;</codeph> is a 32 bit hex number
+indicating the user data value associated with the feature. </p> <p> <i>BUILDROM only</i>  </p> <p>The <b>FEATURE</b> keyword is used
+to mark a feature as included. </p> </section>
+<section id="GUID-ECDEA52A-1357-5173-AA80-4E34A83A4511"><title>file[[HWVD]]</title> <codeblock id="GUID-7196504A-CE79-5EC6-BA7E-9E6F6F1FCDBE" xml:space="preserve">file[[HWVD]] = &lt;source-file&gt; &lt;destination-image-file&gt; [File-attribute-list] [Override-Attribute-list] [paged | unpaged]</codeblock> <p> <i>rombuild and rofsbuild</i>  </p> <p>A standard executable
+file, for example, a <filepath>.exe</filepath> or a <codeph>.dll</codeph>, in PE format or E32 image format. Executable files are stripped
+of their relocation information prior to being stored in the ROM.
+The relocation information is not necessary in the ROM because all
+files are executed in place with an address that is determined at
+ROM build time. Use the modifiers <codeph>paged</codeph> and <codeph>unpaged</codeph> to specify whether to page the executables or not.
+You can also use the <filepath>MMP</filepath> file keywords <codeph>paged</codeph> and <codeph>unpaged</codeph> to specify whether to
+page an executable or not. </p> <p>For example, the following entry
+in the Obey file provides the source and destination locations of
+the file <filepath>MyLibrary.dll</filepath> and marks the DLL as <codeph>unpaged</codeph>. </p> <codeblock id="GUID-E2AE0C0E-E2A8-5ADF-9F12-96F21D5F34D3" xml:space="preserve">file=ABI_DIR\DEBUG_DIR\MyLibrary.dll   \sys\bin\MyLibrary.dll   unpaged</codeblock> <p>Notes: </p> <ul>
+<li id="GUID-8B7F564E-445C-5E30-BF66-6A54A96AF6C1"><p>the <codeph>HWVD</codeph> is optional but, if specified, must be enclosed within
+square brackets. </p> </li>
+<li id="GUID-8BA09533-EE23-597A-A294-4977B50362B1"><p>the information
+required to relocate the file is not preserved; this keyword provides
+a fully resolved uncompressed file. </p> </li>
+</ul> </section>
+<section id="GUID-B4C3E29E-9E4A-565E-B9EC-B078894521B6"><title>filecompressnone</title> <codeblock id="GUID-29E83E81-9DEB-5E2B-979E-749DFE444762" xml:space="preserve">filecompressnone=\Epoc32\release\&lt;platform&gt;&lt;build&gt;&lt;target directory&gt;&lt;source file&gt; &lt;destination file&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Doesn't compress the resulting
+ROM image. </p> <p>For example: </p> <codeblock id="GUID-0AC7EA96-8B92-56B9-8D62-23EDA26F2A6F" xml:space="preserve">filecompressnone=\epoc32\release\ARMV\UREL\TEST\RUNTEST.EXE    sys\bin\RUNTEST.EXE</codeblock> </section>
+<section id="GUID-5B670D2C-9295-556A-BF56-B1018EB79CCE"><title>filecompressinflate</title> <codeblock id="GUID-E0C7D396-3E1B-5C7E-979A-C0C949308542" xml:space="preserve">filecompressinflate=\Epoc32\release\&lt;platform&gt;&lt;build&gt;&lt;target directory&gt;&lt;source file&gt; &lt;destination file&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Compresses the resulting ROM image
+using the Deflate, Huffman+LZ77 algorithm. </p> <p>For example: </p> <codeblock id="GUID-9D881B0E-1B8A-5914-A28F-9DCBE499E11E" xml:space="preserve">filecompressinflate=\epoc32\release\ARMV\UREL\TEST\RUNTEST.EXE    sys\bin\RUNTEST.EXE</codeblock> </section>
+<section id="GUID-6003A5F3-0537-53DF-BEC4-13D310FD944D"><title>filecompressbytepair</title> <codeblock id="GUID-051F3506-C0AD-5C30-ABAA-AC7BD46E0925" xml:space="preserve">filecompressbytepair=\Epoc32\release\&lt;platform&gt;&lt;build&gt;&lt;target directory&gt;&lt;source file&gt; &lt;destination file&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Compresses the resulting ROM image
+using the bytepair algorithm. </p> <p>For example: </p> <codeblock id="GUID-BB37B728-0A9A-5C19-9978-005C3BD3BF7F" xml:space="preserve">filecompressbytepair=\epoc32\release\ARMV\UREL\TEST\RUNTEST.EXE    sys\bin\RUNTEST.EXE</codeblock> </section>
+<section id="GUID-B9B523ED-4D61-5EBF-9EFC-C47F8FA78C80"><title>filecompress[[HWVD]]</title> <codeblock id="GUID-30AAFC4F-7AD6-5E36-9CF3-4280D36FFA9B" xml:space="preserve">filecompress[[HWVD]] = &lt;source-file&gt; &lt;destination-file&gt; [File-attribute-list] [Override-Attribute-list]</codeblock> <p> <i>rombuild only</i>  </p> <p>An XIP (execute-in-place) executable
+to be loaded into the ROM in compressed format. Note that the information
+required to relocate the file is preserved. </p> </section>
+<section id="GUID-9CAD6F80-7817-56E6-BB06-DB70B0A1EBF1"><title>fileuncompress[[HWVD]]</title> <codeblock id="GUID-A7B40C3C-8D7A-5EC7-96E4-4E7B5398DB07" xml:space="preserve">fileuncompress[[HWVD]] = &lt;source-file&gt; &lt;destination-file&gt; [File-attribute-list] [Override-Attribute-list]</codeblock> <p> <i>rombuild only</i>  </p> <p>XIP (execute-in-place) executable
+to be loaded into the ROM uncompressed format. Note that the information
+required to relocate the file is preserved. </p> </section>
+<section id="GUID-37403D0E-65E7-5998-A568-CC5839B7ACDC"><title>fixed</title> <codeblock id="GUID-6232741F-FCA0-5E29-9287-D34B03D66822" xml:space="preserve">fixed</codeblock> <p> <i>rombuild only</i>  </p> <p>This executable is loaded as a
+fixed address process, and has its data fixed in kernel space (high
+memory). The data of normal executables is paged in and out of low
+memory as the executable runs. Fixing a chosen subset of the system
+servers saves context switch time, and speeds execution considerably. </p> </section>
+<section id="GUID-F594BE86-6FFD-4939-B8B9-5DC45C24607C"><title>formatversion</title><p><codeblock xml:space="preserve">formatversion= &lt;format version&gt;</codeblock></p><p>Specifies the SMR image format version. This value is checked by
+the SMR consumers (such as HCR) at runtime to ensure code compatibility
+with image or data format.</p></section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-A328F9E3-7D91-594A-A589-E8CE5FA9227A-master.png has changed
Binary file Adaptation/GUID-A328F9E3-7D91-594A-A589-E8CE5FA9227A_d0e69077_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A3A3405C-C89C-5079-85CE-8CB069C8E0C0.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A3A3405C-C89C-5079-85CE-8CB069C8E0C0" xml:lang="en"><title>IIC Client Interface Quickstart</title><shortdesc>This document gives a brief overview of the IIC client
+interface API. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-969E5E79-1CCE-45DD-B243-734E446B490A"><title>Purpose</title> <p>The IIC client interface API creates a common interface from
+device drivers to serial inter-IC buses (IIC buses). </p> <p><b>Intended
+audience</b> </p> <p>This document is intended to be used by device
+driver writers. </p> </section>
+<section id="GUID-921BEB8B-C943-483D-BB67-15E1042F9F5F"><title>Architectural
+relationship</title> <p>The IIC client interface API is part of a
+group of APIs which provide a common, hardware-independent, interface
+from kernel to different hardware. Other APIs of this type include
+GPIO.</p> <p><b>Description</b> </p> <p>Physically, a bus represented
+by IIC is accessed over a node. The IIC client interface API wraps
+a node in a software construct called a channel. It provides functionality
+for creating and accessing channels directly. There are two possible
+modes of operation:</p><ul>
+<li><p>Controller</p><p>Where the device drivers that use the IIC
+client interface API can access different IIC channels.</p></li>
+<li><p>Controller-less</p><p>Where the channels that the device driver
+can access are set at compile time.</p></li>
+</ul><p>Furthermore, there are three possible channel behaviors: </p><ul>
+<li><p>Master</p><p>The device driver initializes the data transfer.</p></li>
+<li><p>Slave</p><p>The device driver carries out a data transfer that
+is controlled by another node attached to the bus.</p></li>
+<li><p>MasterSlave</p><p>The device driver can carry out both roles.</p></li>
+</ul> </section>
+<section id="GUID-0F84B972-8260-4373-9F1F-F068AA356F4F"><title>IIC
+classes</title> <p>If the access to the IIC bus is to be via a controller,
+then the IIC platform service API class to use is:</p><ul>
+<li id="GUID-3D3B2AFB-4451-5FCD-98B7-7090DD2D9943"><p> <xref href="GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF.dita"><apiname>IicBus</apiname></xref>  </p> </li>
+</ul> <p>If the access to the IIC bus is to be without a controller
+(controller-less operation), then the IIC platform service API classes
+to use are:</p><ul>
+<li id="GUID-209C4026-156C-5887-AA8C-98C378E04558"><p> <xref href="GUID-FA3881ED-B736-34EB-8F1F-026BE1602B1B.dita"><apiname>DIicBusChannelMaster</apiname></xref>  </p> </li>
+<li id="GUID-9D8474E8-9274-5602-AC32-C040BF6EE15D"><p> <xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita"><apiname>DIicBusChannelSlave</apiname></xref>  </p> </li>
+<li><p><xref href="GUID-26DBC836-03F1-31C4-BBFF-1F406E2BAEDB.dita"><apiname>DIicBusChannelMasterSlave</apiname></xref></p></li>
+</ul> </section>
+</conbody><related-links>
+<link href="GUID-9986DCC6-EE73-59FB-BDAC-9B09DC64FBCE.dita"><linktext>Client
+of Master Channel Tutorial</linktext></link>
+<link href="GUID-F461CBB3-F8D1-5961-AD51-5741143A1CB1.dita"><linktext>Client
+of Slave Channel Tutorial</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A4179FF3-4541-44B8-A8F3-52C1318159B3.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,60 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A4179FF3-4541-44B8-A8F3-52C1318159B3" xml:lang="en"><title>Platform
+Security</title><shortdesc>This document discusses how device drivers should implement platform
+security.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Device drivers must follow the Symbian platform security guidelines. As
+a part of platform security, drivers must be given the necessary platform
+security capabilities. A driver can also check the capabilities of a process
+opening a channel on the device, in order to restrict access to the device. </p>
+<section id="GUID-74BFFE9A-2904-4EFC-952A-581844A9095B"><p><b>Driver-side
+definition</b> </p> <p>Because drivers are loaded by the Kernel, both LDDs
+and PDDs must have the same level of trust and capability as the Kernel. This
+means that platform security capabilities must be set to <codeph>ALL</codeph> in
+the LDD and PDD <filepath>.mmp</filepath> files. </p> <codeblock id="GUID-91D17A93-4DFE-58DB-A071-F82399B7D9CE" xml:space="preserve">// LDD: mmp file
+...
+CAPABILITY     ALL</codeblock> <codeblock id="GUID-68471C34-7E9A-5CE7-BED3-1F3C6AEB08BF" xml:space="preserve">// PDD: mmp file
+...
+CAPABILITY     ALL</codeblock> <p>The user program must have the necessary
+capability set in its <filepath>.mmp</filepath> file to open and access the
+driver API. The reference documentation for the API should say what capabilities
+are required. Usually, they are the same as the minimum capability that is
+required to load the drivers. </p> <codeblock id="GUID-18BF036F-1A2E-59AA-BF8E-05D80B7916B5" xml:space="preserve">// Test application: mmp file
+...
+CAPABILITY    CommDD ReadDeviceData PowerMgmt</codeblock></section>
+<section id="GUID-7177D7FD-088C-432F-BABC-4E5DAA0E07D4"><p><b>User-side verification</b> </p> <p>A
+device driver must check the capability of the process that is accessing it.
+This is typically done during channel creation and, if required, for specific
+requests to the LDD. The Kernel provides the <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-E34E27F2-921A-3F78-9DE3-C5B16F37CF8B"><apiname>Kern::CurrentThreadHasCapability()</apiname></xref> API
+to check the capability of the calling process. It can check for more than
+one capability. </p> <p>The following shows how the example driver checks
+during channel creation that the user has the <xref href="GUID-460F2258-02FB-316E-8044-4649E4488486.dita"><apiname>ECapabilityCommD</apiname></xref> capability: </p> <codeblock id="GUID-79B4EB40-14C8-5BDA-9FC9-A82DF87C83A7" xml:space="preserve">TInt DExDriverLogicalChannel::DoCreate(TInt /*aUnit*/, const TDesC8* 
+/*anInfo*/, const TVersion&amp; aVer)
+    {
+    // Capability check - CommDD
+    if (!Kern::CurrentThreadHasCapability (ECapabilityCommDD,
+    __PLATSEC_DIAGNOSTIC_STRING("Checked by Tutorial Driver")))
+        return KErrPermissionDenied;    
+    ...
+    }</codeblock></section>
+<section id="GUID-7B302793-1A00-40D6-8E9A-BA694541D0D4"><p><b>Data caging </b> </p> <p>Symbian
+platform security requires that all DLLs and EXEs are placed in the folder <filepath>/sys/bin</filepath>.
+Drivers and test application binaries must be placed in the <filepath>/sys/bin</filepath> folder
+by their ROM <filepath>.iby</filepath> file. </p> <codeblock id="GUID-42FE3528-37BB-5DD2-B565-4DB527EBC596" xml:space="preserve">// iby file
+device[VARID]=KERNEL_DIR\DEBUG_DIR\exdriver_ldd.ldd     \Sys\Bin\exdriver_ldd.ldd
+device[VARID]=KERNEL_DIR\DEBUG_DIR\exdriver_pdd.pdd     \Sys\Bin\exdriver_pdd.pdd
+file=ABI_DIR\BUILD_DIR\exdriver_test.exe                \Sys\Bin\exdriver_test.exe
+</codeblock></section>
+</conbody><related-links>
+<link href="GUID-EA20E614-C911-4EE9-92B5-C8F9B657D59E.dita"><linktext>Platform
+security architecture</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A4C19890-2380-5498-A5F8-3B6D95CEFEF4.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,428 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A4C19890-2380-5498-A5F8-3B6D95CEFEF4" xml:lang="en"><title>PSL
+Implementation</title><shortdesc>Describes how to create the PSL implementation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>To create a port of the DMA Framework, you must create an implementation
+of the PSL for the DMA controller hardware.</p>
+<section id="GUID-8664FA8F-E53A-5DBA-999F-A0B800C1F54B"><title>Define and
+implement PSL-specific channel classes</title> <p>The choice of class to be
+used for implementing DMA channels is governed by the mode of operation to
+be supported: </p> <ul>
+<li id="GUID-C254C7CA-D010-5885-811D-05BEAF068EDD"><p>single-buffer channels
+should use <xref href="GUID-A8B4AD1B-770C-363E-A0DE-C78A9786CBDC.dita"><apiname>TDmaSbChannel</apiname></xref>  </p> </li>
+<li id="GUID-91DDE5AD-16E5-5FCE-86E9-80069F2CCDDB"><p>double-buffer channels
+should use <xref href="GUID-FD76AF08-6250-3054-8A06-16343E385B23.dita"><apiname>TDmaDbChannel</apiname></xref>  </p> </li>
+<li id="GUID-994E863D-2C32-5AE3-931A-B852855883CA"><p>scatter-gather channels
+should use <xref href="GUID-2D4CFBB1-8D64-3CF5-B6F0-B24D16D5BAD4.dita"><apiname>TDmaSgChannel</apiname></xref>  </p> </li>
+</ul> <p>These three classes are defined in <filepath>dma.h</filepath>. </p> <p>In
+addition, the PSL may need to store channel-specific data. One way of achieving
+this is by deriving a PSL-specific class from one of the generic ones. For
+example, the template scatter-gather implementation defines a <codeph>TTemplateSgChannel</codeph> class
+derived from <codeph>TDmaSgChannel</codeph> for storing data when appending
+new descriptors to a running channel: </p> <codeblock id="GUID-C4807321-01A3-5893-800A-6E22B8B5E131" xml:space="preserve">class TTemplateSgChannel : public TDmaSgChannel
+    {
+public:
+    TDmaDesc* iTmpDes;
+    TPhysAddr iTmpDesPhysAddr;
+    };
+
+      </codeblock> </section>
+<section id="GUID-0991CFB7-B37E-57B9-BC1F-4A69FEDAF5A5"><title>Define and
+implement the controller classes</title> <p>A controller can either be a physical
+controller, or a logical one depending on which <xref href="GUID-97F97D7B-D5A3-5471-A359-77B805ED198C.dita">DMA
+mode you intend to support</xref>. </p> <p>The PSL (platform-specific layer)
+must define one concrete controller class per supported controller. A controller
+class is derived from <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref>. The concrete class must implement
+all the pure virtual functions defined in <codeph>TDmac</codeph>, and, optionally
+the functions used to manipulate hardware descriptors. </p> <p>Taking the
+template port as an example, the class is defined as: </p> <codeblock id="GUID-1C275111-6597-5616-822A-9EABF40BFE77" xml:space="preserve">class TTemplateDmac : public TDmac
+    {
+public:
+    TTemplateDmac();
+    TInt Create();
+private:
+    // from TDmac (PIL pure virtual)
+    virtual void Transfer(const TDmaChannel&amp; aChannel, const SDmaDesHdr&amp; aHdr);
+    virtual void StopTransfer(const TDmaChannel&amp; aChannel);
+    virtual TBool IsIdle(const TDmaChannel&amp; aChannel);
+    virtual TInt MaxTransferSize(TDmaChannel&amp; aChannel, TUint aFlags, TUint32 aPslInfo);
+    virtual TUint MemAlignMask(TDmaChannel&amp; aChannel, TUint aFlags, TUint32 aPslInfo);
+    // from TDmac (PIL virtual)
+    virtual void InitHwDes(const SDmaDesHdr&amp; aHdr, TUint32 aSrc, TUint32 aDest, TInt aCount,
+                            TUint aFlags, TUint32 aPslInfo, TUint32 aCookie);
+    virtual void ChainHwDes(const SDmaDesHdr&amp; aHdr, const SDmaDesHdr&amp; aNextHdr);
+    virtual void AppendHwDes(const TDmaChannel&amp; aChannel, const SDmaDesHdr&amp; aLastHdr,
+                             const SDmaDesHdr&amp; aNewHdr);
+    virtual void UnlinkHwDes(const TDmaChannel&amp; aChannel, SDmaDesHdr&amp; aHdr);
+    // other
+    static void Isr(TAny* aThis);
+    inline TDmaDesc* HdrToHwDes(const SDmaDesHdr&amp; aHdr);
+private:
+    static const SCreateInfo KInfo;
+public:
+    TTemplateSgChannel iChannels[KChannelCount];
+    };
+</codeblock> <p>Notes: </p> <ul>
+<li id="GUID-4E8059FF-0BBC-5F65-9F66-3C96BC86FE55"><p>The array of channels
+must be defined in the PSL controller class because only the PSL knows what
+kind of channels are used. </p> </li>
+<li id="GUID-66E7787B-E933-5E17-9169-E0D245B9D27A"><p>The PSL controller class
+must be allocated in the BSS section of the DMA kernel extension. The second
+phase constructor must be called from the extension entry point. </p> </li>
+<li id="GUID-7306F4CB-5D0F-5E82-AC61-E068A48C9C9B"><p>The C++ constructor
+must pass a <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-BBD2153C-4B41-357C-9299-D710930AFCBE"><apiname>TDmac::SCreateInfo</apiname></xref> structure to the <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> constructor.
+This structure defines what the PIL (platform-independent layer) needs to
+know about the underlying DMA controller. The template <codeph>TTemplateDmac</codeph> constructor
+just passes a <codeph>TDmac::ScreateInfo</codeph> structure, which defines
+the layout of the (base class managed) descriptor pool to the base class constructor
+through a ctor list: </p> <codeblock id="GUID-E00DD5C0-0976-58A0-B3C0-22DFD9216BC0" xml:space="preserve">TTemplateDmac::TTemplateDmac()
+//
+// Constructor.
+//
+    : TDmac(KInfo)
+    {}
+
+          </codeblock> <p>where KInfo is a <codeph>TDmac::ScreateInfo</codeph> type. </p> </li>
+<li id="GUID-4C6FB95D-BE6F-5938-8AC3-824B3BB508EE"><p>The PSL controller class
+needs a second phase constructor. This is the <codeph>Create()</codeph> function,
+which must: </p> <ol id="GUID-33DC912F-C5B4-5F33-A427-62700522D958">
+<li id="GUID-F0E8A497-B09F-5DA0-A94A-3B08FC28707C"><p>call the second phase
+constructor of the base class: <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-9B0C8C35-F149-3358-90B8-B4670CFE888F"><apiname>TDmac::Create()</apiname></xref>. </p> </li>
+<li id="GUID-1FD43FAD-4F43-557E-9EF0-19C725DD5FF5"><p>perform any hardware-specific
+initialisation. </p> </li>
+<li id="GUID-A522B8D4-744B-5C5B-B684-C82F34462171"><p>bind and enable the
+DMA interrupt(s). </p> </li>
+</ol> <p>In the template port, <codeph>Create()</codeph> calls the base class <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-9B0C8C35-F149-3358-90B8-B4670CFE888F"><apiname>TDmac::Create()</apiname></xref> function
+and then initialises the template specific channel object members (the temporary
+descriptor fields used for appending requests to live channels), and performs
+platform specific initialisation for the interrupt dispatch of DMA interrupt
+events: </p> <codeblock id="GUID-FBCC8132-129C-53A4-99B7-290B56C3035D" xml:space="preserve">TInt TTemplateDmac::Create()
+//
+// Second phase construction.
+//
+    {
+    TInt r = TDmac::Create(KInfo);                            // Base class Create()
+    if (r == KErrNone)
+        {
+        __DMA_ASSERTA(ReserveSetOfDes(KChannelCount) == KErrNone);
+        for (TInt i=0; i &lt; KChannelCount; ++i)
+            {
+            TDmaDesc* pD = HdrToHwDes(*iFreeHdr);
+            iChannels[i].iTmpDes = pD;
+            iChannels[i].iTmpDesPhysAddr = DesLinToPhys(pD);
+            iFreeHdr = iFreeHdr-&gt;iNext;
+            }
+        r = Interrupt::Bind(EAsspIntIdDma, Isr, this);
+        if (r == KErrNone)
+            {
+            // TO DO: Map DMA clients (requests) to DMA channels here.
+
+            r = Interrupt::Enable(EAsspIntIdDma);
+            }
+        }
+    return r;
+    }
+          </codeblock> </li>
+</ul> </section>
+<section id="GUID-0DBA2E68-7759-5447-B34B-14F237369CB1"><title>Implement the
+channel allocator</title> <p>Channel allocation is implemented in the PSL
+(platform-specific layer) because this is a hardware-specific operation. There
+are two basic options: </p> <ul>
+<li id="GUID-A9246754-F21B-5BFC-9FDB-2CE5C92D1FA3"><p>Preallocate, at design
+time, one channel per DMA-aware peripheral. This is the simplest approach,
+and it should be acceptable for most Symbian platform devices because the
+set of supported peripherals is closed. In this case, cookies passed by client
+device drivers map uniquely to DMA channels. </p> </li>
+<li id="GUID-C1164FA0-9B70-55C1-9C5A-2D02728FA67A"><p>Full dynamic allocation.
+This is a simple approach too, but DMA channels are, in general, not completely
+identical. For example, some channels may have greater priorities than others. </p> </li>
+</ul> <p>Mixed schemes are also possible, for example, client device driver
+cookies could be used to select a subset of channels, and dynamic allocation
+used inside this subset. </p> <p>Whatever option is chosen, the PSL must provide
+an implementation for the function <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita#GUID-176B8E0D-0422-341B-A134-7C85432E1303/GUID-934F46B3-1DF9-3870-87EE-A8E2DEF82810"><apiname>DmaChannelMgr::Open()</apiname></xref>.
+The template implementation is: </p> <codeblock id="GUID-9C7F5850-F72B-5A16-9DA0-606FBABAB5F0" xml:space="preserve">TDmaChannel* DmaChannelMgr::Open(TUint32 aOpenId)
+//
+//
+//
+    {
+    __KTRACE_OPT(KDMA, Kern::Printf("&gt;DmaChannelMgr::Open aOpenId=%d", aOpenId));
+
+    __DMA_ASSERTA(aOpenId &lt; static_cast&lt;TUint32&gt;(KChannelCount));
+
+    TDmaChannel* pC = Controller.iChannels + aOpenId;
+    if (pC-&gt;IsOpened())
+        pC = NULL;
+    else
+        {
+        pC-&gt;iController = &amp;Controller;
+        pC-&gt;iPslId = aOpenId;
+        }
+
+    return pC;
+    }
+      </codeblock> <p>The template DMA channel manager returns a pointer to
+a DMA channel if the channel has not been previously allocated. Note that
+since channels possess preset priorities, the device drivers must be aware
+of which channel(s) they require DMA service from and configure the DMA controller
+to route sources to allocated channels accordingly. </p> <p>The platform-specific
+cookies passed by client device drivers to the PSL must be defined somewhere
+so that client device drivers can access them. </p> </section>
+<section id="GUID-6B35E9A7-11D6-5B26-B562-934169503412"><title>[Optionally]
+implement channel cleanup</title> <p>In the template PSL (platform-specific
+layer), the function <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita#GUID-176B8E0D-0422-341B-A134-7C85432E1303/GUID-909D795A-7303-3A76-9C8E-3B07A97DD716"><apiname>DmaChannelMgr::Close()</apiname></xref> is a no-operation.
+This function is called by the PIL (platform-independent layer) when client
+device drivers call <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-8204AFBD-2A60-372E-B626-35BD19851FF7"><apiname>TDmaChannel::Close()</apiname></xref>. If the PSL needs
+to perform any hardware-specific operation when the channel is closed, then
+the implementation of <codeph>DmaChannelMgr::Close()</codeph> should be updated
+to reflect that. </p> </section>
+<section id="GUID-C9439F04-0BCC-5BC7-B18B-5C1B88515340"><title>Implement the
+mandatory controller virtual functions</title> <p>The <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> class
+contains several pure virtual functions that must be implemented by the PSL
+(platform-specific layer): </p> <ul>
+<li id="GUID-FF533DDF-E4B1-5AD1-9CBD-19A1D94AB07D"><p> <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-81921A9D-41F5-34BC-B882-60CC4CD807FB"><apiname>TDmac::Transfer()</apiname></xref>  </p> </li>
+<li id="GUID-F6D6524A-09E3-54C0-AEB6-1D6BAB29210C"><p> <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-B738D1B9-80FA-334D-ABEB-DFFF093E0B9D"><apiname>TDmac::StopTransfer()</apiname></xref>  </p> </li>
+<li id="GUID-6209F3C7-9E3C-58BF-ABA4-6DF4BBF44A82"><p> <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-7422834D-CE6B-32DB-A040-7762A8BAB7D7"><apiname>TDmac::IsIdle()</apiname></xref>  </p> </li>
+</ul> <p>These functions start and stop transfers on a DMA channel and are
+the main interface between the PIL (platform-independent layer) and the PSL.
+The implementation of these functions depends on the hardware available for
+performing DMA, and on the characteristics used to specify a DMA transfer: </p> <ul>
+<li id="GUID-81DA9FED-18F0-5205-9597-33542B0CB3CC"><p>the source and destination
+addresses </p> </li>
+<li id="GUID-D6684249-31CC-544B-8CEE-DD1D7FC8A8A1"><p>the burst size </p> </li>
+<li id="GUID-91D910DB-E1D7-5993-9ADB-6823662249D0"><p>the maximum transfer
+size </p> </li>
+<li id="GUID-C1926D7D-8349-5BA1-8E21-AB5D90486443"><p>the transfer width,
+i.e. number of bits per memory access </p> </li>
+<li id="GUID-C091D505-1088-56CA-8630-F1099B0A2234"><p>the memory alignment
+and endianness. </p> </li>
+</ul> <p>The DMA Framework manages the transfer descriptors according to the
+descriptor parameter passed into the <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> constructor
+by the derived class constructor; the descriptor parameter is a <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-BBD2153C-4B41-357C-9299-D710930AFCBE"><apiname>TDmac::SCreateInfo</apiname></xref> structure.
+The per-request transfer parameters are passed into the descriptors for each
+request issued by a driver. </p> <p><b>The
+transfer function: Transfer()</b> </p> <p>This function initiates a previously
+constructed request on a specific channel. This is the template implementation: </p> <codeblock id="GUID-80B95C0E-B30D-5A10-8512-68317D404DB3" xml:space="preserve">void TTemplateDmac::Transfer(const TDmaChannel&amp; aChannel, const SDmaDesHdr&amp; aHdr)
+//
+// Initiates a (previously constructed) request on a specific channel.
+//
+    {
+    const TUint8 i = static_cast&lt;TUint8&gt;(aChannel.PslId());
+    TDmaDesc* pD = HdrToHwDes(aHdr);
+
+    __KTRACE_OPT(KDMA, Kern::Printf("&gt;TTemplateDmac::Transfer channel=%d des=0x%08X", i, pD));
+
+    // TO DO (for instance): Load the first descriptor address into the DMAC and start it
+    // by setting the RUN bit.
+    (void) *pD, (void) i;
+
+    }
+        </codeblock> <p><b>The
+stop transfer function: StopTransfer()</b> </p> <p>This function requires
+that the RUN mode is cleared. This is the template implementation: </p> <codeblock id="GUID-1BF7A5B4-2723-5A18-98E0-1F79A4928121" xml:space="preserve">void TTemplateDmac::StopTransfer(const TDmaChannel&amp; aChannel)
+//
+// Stops a running channel.
+//
+    {
+    const TUint8 i = static_cast&lt;TUint8&gt;(aChannel.PslId());
+
+    __KTRACE_OPT(KDMA, Kern::Printf("&gt;TTemplateDmac::StopTransfer channel=%d", i));
+
+    // TO DO (for instance): Clear the RUN bit of the channel.
+    (void) i;
+
+    }
+        </codeblock> <p><b>The
+function: IsIdle()</b> </p> <p> <codeph>IsIdle()</codeph> returns the state
+of a given channel. This is the template implementation: </p> <codeblock id="GUID-C7CC986E-986B-5C5E-AA3D-86851131BE93" xml:space="preserve">TBool TTemplateDmac::IsIdle(const TDmaChannel&amp; aChannel)
+//
+// Returns the state of a given channel.
+//
+    {
+    const TUint8 i = static_cast&lt;TUint8&gt;(aChannel.PslId());
+
+    __KTRACE_OPT(KDMA, Kern::Printf("&gt;TTemplateDmac::IsIdle channel=%d", i));
+
+    // TO DO (for instance): Return the state of the RUN bit of the channel.
+    // The return value should reflect the actual state.
+    (void) i;
+
+    return ETrue;
+    }
+        </codeblock> </section>
+<section id="GUID-A362A7CF-3674-525C-8114-485315E6594B"><title>Implement the
+non-mandatory controller virtual functions</title> <p>The following auxiliary
+functions are used to implement the scatter-gather transfer mode behaviour
+by creating and manipulating the linked list of transfer fragment headers
+that describe a given scatter-gather transaction. They are called by the <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> base
+class functions when the instance of the <codeph>TDmac</codeph> derived class
+reports itself as being capable of scatter-gather operations. </p> <ul>
+<li id="GUID-D401D7C8-B086-56CD-BAE0-96EEB0AA7E38"><p> <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-90AC3E58-E589-3F91-85F7-16A4ADFFFA69"><apiname>TDmac::InitHwDes()</apiname></xref>  </p> </li>
+<li id="GUID-58633367-FE56-53B7-A967-21828DA85F5C"><p> <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-05021B05-75DE-3F75-92C6-8B9445EB86D3"><apiname>TDmac::ChainHwDes()</apiname></xref>  </p> </li>
+<li id="GUID-94F81366-77D4-5AF6-9933-53E964863301"><p> <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-AFCDDA16-991D-3BDA-B90B-87BCAFF66E5C"><apiname>TDmac::AppendHwDes()</apiname></xref>  </p> </li>
+</ul> <p><b>First
+scatter-gather support function: InitHwDes()</b> </p> <p>This is a function
+for creating a scatter-gather list. From the information in the passed-in
+request, the function sets up the descriptor with that fragment's: </p> <ul>
+<li id="GUID-098E886D-D98D-5AC9-BB25-7FF8E6F0D05B"><p>source and destination
+address </p> </li>
+<li id="GUID-83440454-B955-55C8-BF10-DF86CDA0C466"><p>size </p> </li>
+<li id="GUID-294D3B08-0A64-534D-858F-F43759A2DC59"><p>driver/DMA controller
+specific transfer parameters: memory/peripheral, burst size, transfer width. </p> </li>
+</ul> <p>This is the template implementation: </p> <codeblock id="GUID-EB6F9C76-EC23-5464-A6C5-AB0B36717D2B" xml:space="preserve">void TTemplateDmac::InitHwDes(const SDmaDesHdr&amp; aHdr, TUint32 aSrc, TUint32 aDest, TInt aCount,
+                              TUint aFlags, TUint32 aPslInfo, TUint32 /*aCookie*/)
+//
+// Sets up (from a passed in request) the descriptor with that fragment's source and destination address,
+// the fragment size, and the (driver/DMA controller) specific transfer parameters (mem/peripheral,
+// burst size, transfer width).
+//
+    {
+    TDmaDesc* pD = HdrToHwDes(aHdr);
+
+    __KTRACE_OPT(KDMA, Kern::Printf("TTemplateDmac::InitHwDes 0x%08X", pD));
+
+    // Unaligned descriptor? Error in generic layer!
+    __DMA_ASSERTD(IsHwDesAligned(pD));
+
+    pD-&gt;iSrcAddr = (aFlags &amp; KDmaPhysAddrSrc) ? aSrc : Epoc::LinearToPhysical(aSrc);
+    pD-&gt;iDestAddr = (aFlags &amp; KDmaPhysAddrDest) ? aDest : Epoc::LinearToPhysical(aDest);
+    pD-&gt;iCmd = DcmdReg(aCount, aFlags, aPslInfo);
+    pD-&gt;iDescAddr = TDmaDesc::KStopBitMask;
+    }
+
+          </codeblock> <p><b>Second
+scatter-gather support function: ChainHwDes()</b> </p> <p>If the framework
+needs to fragment the client’s request, for transfer size or memory discontiguousness
+reasons, then the framework calls this function. It chains hardware descriptors
+together by setting the next pointer of the original descriptor to the physical
+address of the descriptor to be chained. It assumes that the DMAC channel
+is quiescent when called. </p> <p>This is the template implementation: </p> <codeblock id="GUID-7979A1FB-5FA1-5078-8762-3874A62E6C63" xml:space="preserve">void TTemplateDmac::ChainHwDes(const SDmaDesHdr&amp; aHdr, const SDmaDesHdr&amp; aNextHdr)
+//
+// Chains hardware descriptors together by setting the next pointer of the original descriptor
+// to the physical address of the descriptor to be chained.
+//
+    {
+    TDmaDesc* pD = HdrToHwDes(aHdr);
+    TDmaDesc* pN = HdrToHwDes(aNextHdr);
+
+    __KTRACE_OPT(KDMA, Kern::Printf("TTemplateDmac::ChainHwDes des=0x%08X next des=0x%08X", pD, pN));
+
+    // Unaligned descriptor? Error in generic layer!
+    __DMA_ASSERTD(IsHwDesAligned(pD) &amp;&amp; IsHwDesAligned(pN));
+
+    // TO DO: Modify pD-&gt;iCmd so that no end-of-transfer interrupt gets raised any longer.
+
+    pD-&gt;iDescAddr = DesLinToPhys(pN);
+    }
+
+</codeblock> <p><b>Third
+scatter-gather support function: AppendHwDes()</b> </p> <p>This function is
+called by the <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref> base class when a driver request is
+called for a channel that is still active, i.e. where the intent is to provide
+data streaming so that the target device is constantly provided with data;
+for example, an audio device playing a track. In this case, the function provided
+by the derived class must: </p> <ul>
+<li id="GUID-F94FBAA8-2A0D-5863-BA09-0EC1D61005A9"><p>stop the DMAC to prevent
+any corruption of the scatter-gather list while appending the new fragment
+descriptor </p> </li>
+<li id="GUID-AEF81B78-73D8-5B70-AFE4-0AEA7862CB74"><p>append the new descriptor </p> </li>
+<li id="GUID-2304F2D4-833E-5F75-B88E-C794DF9D984E"><p>re-enable the channel,
+ideally before the target has detected the gap in service. </p> </li>
+</ul> <p>This is the template implementation: </p> <codeblock id="GUID-18512439-C781-5267-ADBC-B9047942F800" xml:space="preserve">void TTemplateDmac::AppendHwDes(const TDmaChannel&amp; aChannel, const SDmaDesHdr&amp; aLastHdr,
+                                const SDmaDesHdr&amp; aNewHdr)
+//
+// Appends a descriptor to the chain while the channel is running.
+//
+    {
+    const TUint8 i = static_cast&lt;TUint8&gt;(aChannel.PslId());
+
+    TDmaDesc* pL = HdrToHwDes(aLastHdr);
+    TDmaDesc* pN = HdrToHwDes(aNewHdr);
+
+    __KTRACE_OPT(KDMA, Kern::Printf("&gt;TTemplateDmac::AppendHwDes channel=%d last des=0x%08X new des=0x%08X",
+                                    i, pL, pN));
+    // Unaligned descriptor? Error in generic layer!
+    __DMA_ASSERTD(IsHwDesAligned(pL) &amp;&amp; IsHwDesAligned(pN));
+
+    TPhysAddr newPhys = DesLinToPhys(pN);
+
+    const TInt irq = NKern::DisableAllInterrupts();
+    StopTransfer(aChannel);
+
+    pL-&gt;iDescAddr = newPhys;
+    const TTemplateSgChannel&amp; channel = static_cast&lt;const TTemplateSgChannel&amp;&gt;(aChannel);
+    TDmaDesc* pD = channel.iTmpDes;
+
+    // TO DO: Implement the appropriate algorithm for appending a descriptor here.
+    (void) *pD, (void) i;
+
+    NKern::RestoreInterrupts(irq);
+
+    __KTRACE_OPT(KDMA, Kern::Printf("&lt;TTemplateDmac::AppendHwDes"));
+    }
+    </codeblock> </section>
+<section id="GUID-F5968000-0C3E-5E53-A2D5-120B81F3140F"><title>Implement an
+interrupt service routine</title> <p>The interrupt service routine needs to
+do the following: </p> <ul>
+<li id="GUID-CE55E999-0886-5620-87BA-99A36D694FD4"><p>identify the channel
+that raised the interrupt </p> </li>
+<li id="GUID-02467F17-DC1E-552C-B1C2-D3C2CCE12347"><p>decide whether the interrupt
+was raised because of a successful data transfer or because of an error </p> </li>
+<li id="GUID-0D5FDA57-A45E-54E5-A69C-64D22B916AB4"><p>call the base class
+function <codeph>TDmac::HandleIsr()</codeph>, which queues a DFC, or increments
+the number of pending interrupts if a DFC is already queued. </p> </li>
+</ul> <p>This is the template implementation: </p> <codeblock id="GUID-4CFCA5A1-9657-55F1-BE3C-AFF1F3974F80" xml:space="preserve">void TTemplateDmac::Isr(TAny* aThis)
+//
+// This ISR reads the interrupt identification and calls back into the base class
+// interrupt service handler with the channel identifier and an indication whether the
+// transfer completed correctly or with an error.
+//
+    {
+    TTemplateDmac&amp; me = *static_cast&lt;TTemplateDmac*&gt;(aThis);
+
+    // TO DO: Implement the behaviour described above, call HandleIsr().
+
+    HandleIsr(me.iChannels[5], 0);                            // Example
+
+    }
+     </codeblock> </section>
+<section id="GUID-D7F410A1-DC70-515D-A00D-3955B534C62F"><title>Implement the
+test support table and function</title> <p>The DMA Framework comes with a
+test harness that can be used to validate the port if the underlying DMA controller
+supports memory to memory transfers. </p> <p>The test harness needs to know
+about the capabilities of the port being tested. The PSL provides the global
+function <xref href="GUID-3D0A9A03-E210-30EE-A1A1-7DA06E668CAA.dita"><apiname>DmaTestInfo()</apiname></xref> that returns a <xref href="GUID-59EE15C1-19E7-3AA7-8339-A80CCC074D64.dita"><apiname>TDmaTestInfo</apiname></xref> object
+that contains this information. In the template PSL, this structure is initialised
+to binary zeroes. Before using the test harness, it must be initialised with
+valid values. </p> <p>See <xref href="GUID-59EE15C1-19E7-3AA7-8339-A80CCC074D64.dita"><apiname>TDmaTestInfo</apiname></xref>, <xref href="GUID-3D0A9A03-E210-30EE-A1A1-7DA06E668CAA.dita"><apiname>DmaTestInfo()</apiname></xref> and <xref href="GUID-8552E66E-73D6-51DA-8F53-DDF437186CD6.dita">Validation</xref>. </p> </section>
+<section id="GUID-D452D2CD-D251-50F4-818E-E7125501CE8F"><title>Optimise the
+performance of critical functions</title> <p>You can optionally optimise critical
+functions by writing them in assembler. The two candidates for an assembler
+rewrite are: </p> <ul>
+<li id="GUID-157E6F4A-0310-5923-B446-040F75E469D4"><p>The interrupt service
+routine </p> </li>
+<li id="GUID-74C9D4DB-9CA9-5C5E-A475-B6840EBC2245"><p>In scatter-gather mode,
+the <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-AFCDDA16-991D-3BDA-B90B-87BCAFF66E5C"><apiname>TDmac::AppendHwDes()</apiname></xref> function if it needs to suspend
+a transfer when appending a new descriptor chain to an existing one. </p> </li>
+</ul> </section>
+<section id="GUID-A2AF293F-558A-5F69-821F-EC2B202A5A4F"><title>Extend the
+framework with platform-specific functionality</title> <p>There are two ways
+of extending the DMA Framework: </p> <ol id="GUID-D6C660FC-FF23-55B2-B91E-4BC04C592059">
+<li id="GUID-4453F4C2-3444-5A3E-94C7-BE6320B1EF89"><p>to provide platform-specific
+functionality on a per-channel basis. </p> </li>
+<li id="GUID-C0C6A072-134A-5753-A6DC-185F3975C2A6"><p>to provide platform-specific
+functionality on a <i>channel independent</i> basis. </p> </li>
+</ol> <p>In the first case, the PSL provides an implementation of the virtual
+function <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-D6D011E9-9D75-3881-87D8-1986FFBBA106"><apiname>TDmac::Extension()</apiname></xref>. The default implementation
+just returns <xref href="GUID-F89DA3F0-2A48-3F9B-8F08-29350E92D0E4.dita"><apiname>KErrNotSupported</apiname></xref>. </p> <p> <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-2CF7498E-F5D2-3C4A-8E98-47504F9FC404"><apiname>TDmaChannel::Extension()</apiname></xref> calls <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita#GUID-25398075-927B-36E4-B953-16785EC4086C/GUID-D6D011E9-9D75-3881-87D8-1986FFBBA106"><apiname>TDmac::Extension()</apiname></xref>. </p> <p>In the second case, the PSL provides an implementation of the static
+function <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita#GUID-176B8E0D-0422-341B-A134-7C85432E1303/GUID-C733B302-4269-3391-8ADE-617CFF198B56"><apiname>DmaChannelMgr::StaticExtension()</apiname></xref>. The template
+PSL implementation just returns <xref href="GUID-F89DA3F0-2A48-3F9B-8F08-29350E92D0E4.dita"><apiname>KErrNotSupported</apiname></xref>. </p> <p> <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-75562653-1F27-39D3-96D8-55A94BA9B68B"><apiname>TDmaChannel::StaticExtension()</apiname></xref> calls <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita#GUID-176B8E0D-0422-341B-A134-7C85432E1303/GUID-C733B302-4269-3391-8ADE-617CFF198B56"><apiname>DmaChannelMgr::StaticExtension()</apiname></xref>. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A4CCF2B6-26B7-5E8C-B738-9EE9E68A0B35.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A4CCF2B6-26B7-5E8C-B738-9EE9E68A0B35" xml:lang="en"><title>Reference</title><shortdesc>Summary of related documentation for the DMA Framework. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-5B47330F-DE7A-5FCA-9A8F-33D111D67DFE"><title>API Reference</title> <p><b>Kernel
+Architecture 2 </b> </p> <table id="GUID-FF8EA434-8108-5B7B-9BD4-44F5023CAADB">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Item</b>  </p> </entry>
+<entry><p> <b>Header</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita"><apiname>DDmaRequest</apiname></xref>  </p> </entry>
+<entry><p> <filepath>dma.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita"><apiname>DmaChannelMgr</apiname></xref>  </p> </entry>
+<entry><p> <filepath>dma.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-710B3501-FF22-307D-AC88-D142E9A07CB8.dita"><apiname>SDmaDesHdr</apiname></xref>  </p> </entry>
+<entry><p> <filepath>dma.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-D7934AD9-38F6-325A-A734-F867D886D7C2.dita"><apiname>SDmaPseudoDes</apiname></xref>  </p> </entry>
+<entry><p> <filepath>dma.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-25398075-927B-36E4-B953-16785EC4086C.dita"><apiname>TDmac</apiname></xref>  </p> </entry>
+<entry><p> <filepath>dma.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref>  </p> </entry>
+<entry><p> <filepath>dma.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A8B4AD1B-770C-363E-A0DE-C78A9786CBDC.dita"><apiname>TDmaSbChannel</apiname></xref>  </p> </entry>
+<entry><p> <filepath>dma.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-2D4CFBB1-8D64-3CF5-B6F0-B24D16D5BAD4.dita"><apiname>TDmaSgChannel</apiname></xref>  </p> </entry>
+<entry><p> <filepath>dma.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-59EE15C1-19E7-3AA7-8339-A80CCC074D64.dita"><apiname>TDmaTestInfo</apiname></xref>  </p> </entry>
+<entry><p> <filepath>dma.h</filepath>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-BFCBC5D4-5741-5E9A-B145-C7D116D1C7C5"><title>Engineering
+Specifications</title> <p>No specifications are published. </p> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-A51C3E48-3ED0-519B-A128-C5175D7E175B-master.png has changed
Binary file Adaptation/GUID-A51C3E48-3ED0-519B-A128-C5175D7E175B_d0e19782_href.png has changed
Binary file Adaptation/GUID-A568F9D3-58E3-58D6-8A6E-4EC6BEC41A4D-master.png has changed
Binary file Adaptation/GUID-A568F9D3-58E3-58D6-8A6E-4EC6BEC41A4D_d0e29723_href.png has changed
Binary file Adaptation/GUID-A6845EB0-4B4D-49C8-85A5-A933A2C351CF-master.png has changed
Binary file Adaptation/GUID-A6845EB0-4B4D-49C8-85A5-A933A2C351CF_d0e89230_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,183 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930" xml:lang="en"><title>Factory
+Implementation</title><shortdesc>Media driver must implement a PDD factory class derived from <codeph>DPhysicalDevice</codeph>. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The PDD factory creates the main media driver objects. </p>
+<p>The <xref href="GUID-0437DB4C-FC4E-51DC-BB4C-95C0B26834F5.dita">Device Driver
+Guide</xref> describes the general theory for implementing a derived class,
+while this section gives the specifics for the media driver. </p>
+<p>In implementing your <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita"><apiname>DPhysicalDevice</apiname></xref> derived class,
+you must, as a minimum, provide an implementation for the following four functions,
+defined as pure virtual in <codeph>DPhysicalDevice</codeph>: </p>
+<ul>
+<li id="GUID-7D2FC41B-4294-5082-92D7-07DA9A991CF4"><p> <xref href="GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930.dita#GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930/GUID-CBAFA0EC-B111-57B9-8E4F-EE8ADDB56252">Install() - complete the initialisation of the PDD factory object</xref>  </p> </li>
+<li id="GUID-BDCE51AB-897F-5609-971F-1F3E36AC34D0"><p> <xref href="GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930.dita#GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930/GUID-32B157E9-0F71-5C1B-A0FA-08D5B1ACA700">Create() - create the media driver object</xref>  </p> </li>
+<li id="GUID-B3F2FE95-F58A-5C48-99F1-39C2521153C5"><p> <xref href="GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930.dita#GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930/GUID-9EAFB357-5770-529A-BED5-0721C38C7BD1">Validate() - check that the PDD is suitable for use</xref>  </p> </li>
+<li id="GUID-6D959402-0B3F-547D-B1E7-500C96768649"><p> <xref href="GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930.dita#GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930/GUID-2F29C284-DE66-5A92-9D9A-0348E01D1139">GetCaps() - return the capabilities of the Media Driver</xref>  </p> </li>
+</ul>
+<p>The following function is virtual in <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita"><apiname>DPhysicalDevice</apiname></xref> but
+has a default implementation that must be changed: </p>
+<ul>
+<li id="GUID-53148446-2A45-5E6B-A9F8-B653383F2256"><p> <xref href="GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930.dita#GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930/GUID-E3E875BD-F89D-5728-AF4B-658A595E9298">Info() - set the priority of the media driver</xref>  </p> </li>
+</ul>
+<section id="GUID-CBAFA0EC-B111-57B9-8E4F-EE8ADDB56252"><title>Install() -
+complete the initialisation of the PDD factory object</title> <p>See also <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita#GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930/GUID-0065FAAF-D734-3ED2-816A-CCE9BF607BAB"><apiname>DPhysicalDevice::Install()</apiname></xref>. </p> <p>This
+PDD factory function is called after the PDD DLL has been successfully loaded,
+as a result of a call to <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-A0F4BF4A-9C58-3E5E-88E1-6D98597DDA18"><apiname>User::LoadPhysicalDevice()</apiname></xref>, and
+the factory object has been successfully created on the kernel heap. </p> <p>The
+function is a second stage constructor for the factory object, and allows
+any further initialisation of the factory object to be done. As a minimum,
+the function must set a name for the media driver's factory object. The name
+is important as it is the way in which the object will subsequently be found.
+The name should be of the form: </p> <codeblock id="GUID-DE6A4AD9-EE64-536D-8532-6624EDAB69AB" xml:space="preserve">Media.&lt;MDExt&gt;</codeblock> <p>where <codeph>&lt;MDExt&gt;</codeph> is descriptive of the specific media. For example, <codeph>Media.Ata</codeph>,
+and <codeph>Media.Iram</codeph>. </p> <p>When a <xref href="GUID-918D17D8-B751-35EE-A592-4F0EAB005EC7.dita"><apiname>DMedia</apiname></xref> object,
+created by the internal Symbian platform <filepath>ELOCD.LDD</filepath> logical
+device driver, attempts to mount a media device, i.e. to open a media driver,
+it does a search by name. This is a search through all loaded PDDs whose names
+match <codeph>Media.*</codeph>. </p> <p>The following simple function is typical: </p> <codeblock id="GUID-8FA1A096-470B-55EC-A0CE-282AD6ABC9CA" xml:space="preserve">TInt DMyPhysicalDeviceMedia::Install()
+    {
+    _LIT(KDrvNm, "Media.MyName");
+    return SetName(&amp;KDrvNm);
+    }
+        </codeblock> </section>
+<section id="GUID-32B157E9-0F71-5C1B-A0FA-08D5B1ACA700"><title>Create() -
+create the media driver object</title> <p>See also <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita#GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930/GUID-B88265CA-0881-3666-BF76-C32E47F9A3A1"><apiname>DPhysicalDevice::Create()</apiname></xref>. </p> <p>This
+PDD factory function is called by the device driver framework to create, and
+return, the media driver object. This is an instance of a class derived from <xref href="GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC.dita"><apiname>DMediaDriver</apiname></xref>.
+Note that, occasionally, you may find this object referred to as the physical
+channel. </p> <p> <codeph>Create()</codeph> is called when initially mounting
+a media device, or accessing a removable media after an insertion event. Contrast
+this with <xref href="GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930.dita#GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930/GUID-CBAFA0EC-B111-57B9-8E4F-EE8ADDB56252">Install()</xref>,
+which is only called once, when the PDD factory object is loaded. </p> <p>Typically, <codeph>Create()</codeph> does
+the following: </p> <ul>
+<li id="GUID-C5FF60E4-9512-597F-9F89-7C0E6BB75ED8"><p>Compares the build version
+of the media driver with the version requested, and returns <xref href="GUID-F89DA3F0-2A48-3F9B-8F08-29350E92D0E4.dita"><apiname>KErrNotSupported</apiname></xref> if
+the versions are incompatible. </p> </li>
+<li id="GUID-B3F68A1C-320D-5CA5-BAE4-59A716C937B0"><p>Creates an instance
+of the <xref href="GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC.dita"><apiname>DMediaDriver</apiname></xref> derived class, the media driver object. </p> </li>
+<li id="GUID-13D14DBA-8629-54A8-9CFD-E50E7AF32CD7"><p>Initiates second-phase
+construction of the media driver object. Typically, this involves initialisation
+that is capable of failing. This may be done synchronously or asynchronously.
+You would probably do this asynchronously for removable media that is slow
+to power up, or for slow internal media, in which case, you would need to
+make sure that you attached a DFC queue during <xref href="GUID-A70A01D2-467E-5BA8-A01D-6182558F3F52.dita">media
+driver initialisation</xref>. Although the device driver framework does not
+mandate any specific function name in which to implement this, the example
+code fragment suggests a function name of <codeph>DoCreate()</codeph>. </p> </li>
+<li id="GUID-CB1D26B5-A868-5993-9ABF-BD101A94443F"><p>Acknowledges creation
+of the media driver object. The way you do this depends on whether creation
+is done synchronously or asynchronously: </p> <ul>
+<li id="GUID-0C8288F4-874D-5C34-8D38-FCF1665903BD"><p>Synchronous creation
+- call <xref href="GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC.dita#GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC/GUID-DF0539A1-FDB2-3A31-A57B-863F9033B67A"><apiname>DMediaDriver::OpenMediaDriverComplete()</apiname></xref> passing <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref>,
+or an error code if appropriate, and then return <codeph>KErrNone</codeph> from <codeph>Create()</codeph>.
+Do not return any value other than <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref> from Create(),
+otherwise the framework may call it again. </p> <p>Note that <xref href="GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC.dita#GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC/GUID-DF0539A1-FDB2-3A31-A57B-863F9033B67A"><apiname>DMediaDriver::OpenMediaDriverComplete()</apiname></xref> can
+be called from within the media driver class, if that is the way the driver
+is designed, but <codeph>Create()</codeph> must still return <codeph>KErrNone</codeph>. </p> </li>
+<li id="GUID-AF5F1A17-990F-5475-8B0D-25DA45E74B72"><p>Asynchronous creation
+- return either <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref>, if initiation of the operation
+was successful, or an error code, if the operation failed immediately. However,
+it is the responsibility of the media driver object to signal completion. </p> </li>
+</ul> </li>
+</ul> <p>The following is a typical example: </p> <codeblock id="GUID-69BF7285-1086-5BD9-9624-61DAF0A22DE9" xml:space="preserve">TInt DMyPhysicalDeviceMedia::Create(DBase*&amp; aChannel, TInt aMediaId, const TDesC8* aInfo ,const TVersion &amp;aVer)
+    {
+    // Check the build version of the media driver
+    if (!Kern::QueryVersionSupported(iVersion,aVer))
+        {
+        return KErrNotSupported;
+        }
+
+    //Create my DMediaDriver derived object
+    DMyMediaDriver* pD=new DMyMediaDriver (aMediaId);
+    aChannel=pD;
+
+    // Call my media driver’s second-stage constructor
+    Tint r = KErrNoMemory;
+    if(pD)
+        {
+        r = pD-&gt;DoCreate(aMediaId);
+        }
+
+    // Synchronous Creation (don’t do this if Asynchronous)…
+    if(r == KErrNone)
+        {
+        pD-&gt;OpenMediaDriverComplete(KErrNone);
+        }
+
+    return r;
+    }
+        </codeblock> </section>
+<section id="GUID-9EAFB357-5770-529A-BED5-0721C38C7BD1"><title>Validate()
+- check that the PDD is suitable for use</title> <p>See also <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita#GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930/GUID-70B6293C-9000-31D9-AE9E-441C9760B92E"><apiname>DPhysicalDevice::Validate()</apiname></xref>. </p> <p>This
+PDD factory function is called by the kernel's device driver framework to
+check whether this PDD is suitable for use with the media type specified in
+the function. </p> <p>A typical implementation of this function would perform
+the following steps: </p> <ul>
+<li id="GUID-A4708377-3D61-5115-92CA-BB0660D9B3F1"><p>Compare the build version
+of the media driver with the version requested </p> </li>
+<li id="GUID-47FECD2E-FF54-56F2-93A6-5CC08CB24DB7"><p>Confirm that this driver
+is responsible for the media type </p> </li>
+</ul> <p>The following is a very typical implementation: </p> <codeblock id="GUID-E08EC5CD-BCC7-517F-86A9-0B04E62D6E9E" xml:space="preserve">TInt DMyPhysicalDeviceMedia::Validate(TInt aUnit, const TDesC8* aInfo, const TVersion&amp; aVer)
+    {
+    // Check the build version of the media driver
+    if (!Kern::QueryVersionSupported(iVersion,aVer))
+        {
+        return KErrNotSupported;
+        }
+
+    // Check that the given type of media is supported by this driver
+    if (aUnit!=MEDIA_DEVICE_MYMEDIA)
+        {
+        return KErrNotSupported;
+        }
+
+    return KErrNone;
+    }
+
+        </codeblock> <p>Note that the value passed in via the <codeph>aUnit</codeph> argument
+is the unique media ID used when the media driver was registered. In other
+contexts, the argument may be denoted by the symobol <codeph>aMediaId</codeph>. </p> </section>
+<section id="GUID-2F29C284-DE66-5A92-9D9A-0348E01D1139"><title>GetCaps() -
+return the capabilities of the Media Driver</title> <p>See also <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita#GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930/GUID-CA336905-B068-3CFB-80D7-4DF29B92BF4F"><apiname>DPhysicalDevice::GetCaps()</apiname></xref>. </p> <p>For
+media drivers, this PDD factory function is not used. However, an implementation
+is required because the function is defined as pure virtual in the <codeph>DPhysicalDevice</codeph> base
+class. Simply implement an empty function, for example: </p> <codeblock id="GUID-D1DF97CF-7719-5414-9CFB-237E3079B280" xml:space="preserve">void DMyPhysicalDeviceMedia::GetCaps(TDes8&amp; /*aDes*/) const
+//
+// Return the media drivers capabilities.
+//
+    {
+    }
+        </codeblock> </section>
+<section id="GUID-E3E875BD-F89D-5728-AF4B-658A595E9298"><title>Info() - set
+the priority of the media driver</title> <p>See also <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita#GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930/GUID-440B4A06-BA90-385B-A06D-B8553F0EE63F"><apiname>DPhysicalDevice::Info()</apiname></xref>. </p> <p>This
+PDD factory function is intended to return information relating to the media
+driver. The function can, potentially, return many different types of information,
+depending on the value passed as the first parameter. However, the only type
+of information that Symbian platform currently requires is the priority of
+the media driver. The returned priority value is used by Symbian platform
+to decide the order in which media drivers are to be opened. </p> <p>The default
+implementation just returns 0, and therefore needs to be overridden. </p> <p>Under
+most circumstances, you can return the value <xref href="GUID-CE45BE16-7122-3250-B9B5-8CD0F7F7FAEB.dita"><apiname>KMediaDriverPriorityNormal</apiname></xref>.
+You can, however, return <xref href="GUID-52FB0DED-240A-342A-8922-9450BE2F9E02.dita"><apiname>KMediaDriverPriorityHigh</apiname></xref> in circumstances
+where it is important that the driver is initialised before a lower priority
+driver. </p> <p>The following code fragment is a typical implementation: </p> <codeblock id="GUID-7A065EF3-FE4B-541D-B9E4-0F112A9B741B" xml:space="preserve">TInt DMyPhysicalDeviceMedia::Info(TInt aFunction, TAny* /*a1*/)
+    {
+    if (aFunction==EPriority)
+        {
+        return KMediaDriverPriorityNormal;
+        }
+    return KErrNotSupported;
+    }
+        </codeblock> <p>where <codeph>EPriority</codeph> indicates that priority
+information is required (this is an enum value of enum <codeph>TInfoFunction</codeph>,
+defined in <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita"><apiname>DPhysicalDevice</apiname></xref>. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A70A01D2-467E-5BA8-A01D-6182558F3F52.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A70A01D2-467E-5BA8-A01D-6182558F3F52" xml:lang="en"><title>Boot
+Time Initialisation Implementation</title><shortdesc>How to write an initialisation function, implemented by the Media
+driver and called by the kernel at boot time. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>You use the <xref href="GUID-7964FC46-4641-3BDD-92C9-50FA22C3321A.dita"><apiname>DECLARE_STANDARD_EXTENSION()</apiname></xref> macro as a
+wrapper around the code that does this. There are at two important things
+to do at this stage: </p>
+<ul>
+<li id="GUID-21EA5C7E-7147-596E-A340-1D6FED0328CE"><p>attach a DFC queue,
+if the underlying media driver supports asynchronous creation </p> </li>
+<li id="GUID-4E9CD255-B954-5B75-B639-2AC494296AA4"><p>register the media driver
+with the local media system. </p> </li>
+</ul>
+<section id="GUID-43EB0EC7-AAA3-5FFC-8724-E938F6BFB158"><title>Asynchronous
+creation of the media driver</title> <p>If the underlying media driver supports
+asynchronous creation, then a DFC queue <i>must</i> be attached at this stage.
+However, media drivers that interface to the Peripheral Bus Controller should
+create a new <xref href="GUID-B4E66372-2654-3434-AFB7-844B0B8D2FC9.dita"><apiname>DPBusPrimaryMedia</apiname></xref> object, as shown in the
+code above, but should not allocate a DFC for asynchronous creation; this
+is handled by the Peripheral Bus Controller. </p> <p>See also <xref href="GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930.dita#GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930/GUID-32B157E9-0F71-5C1B-A0FA-08D5B1ACA700">Create() - create the media driver object</xref>. </p> </section>
+<section id="GUID-4A8DEEAB-32C4-5431-8226-5623E2BD9098"><title>Register the
+media driver with the local media system</title> <p>The media driver must
+be registered with the Local Media Subsystem; this provides information such
+as the number of supported drives, partitions, names and drive numbers. This
+is done by calling <xref href="GUID-9E60E8D9-619E-3A76-BAC8-93A60D62C7DF.dita#GUID-9E60E8D9-619E-3A76-BAC8-93A60D62C7DF/GUID-647D0858-FE04-3A4F-99CE-81CD0B34CE7B"><apiname>LocDrv::RegisterMediaDevice()</apiname></xref>, and passing
+appropriate values. </p> <p>The media device type can be any of the <xref href="GUID-0FE5A5FE-5D38-3620-8674-2B770CB9D049.dita"><apiname>TMediaDevice</apiname></xref> enumerated
+values provide that a given value is only used once. This value may sometimes
+be referred to as the media ID. </p> <p>The values passed to this function
+are highly dependent on the target hardware platform, and it is common practice
+to define them in a file contained within the Variant directory, instead of
+hard-coding them into generic Symbian platform code. For example, Variant
+A may provide two PC Card slots, while Variant B may provide 4. </p> <p>The
+port for the template reference board has the header file <filepath>...\template_variant\inc\variantmediadef.h</filepath>,
+which defines constants that are used when registering a media driver for
+that specific hardware. </p> <p>Your code may find it convenient to use the
+struct <xref href="GUID-FC0F974E-9ABB-348B-9AE9-778B3A1F413A.dita"><apiname>SMediaDeviceInfo</apiname></xref> to capture this information. </p> </section>
+<example><p>The following code is used: </p> <codeblock id="GUID-2A3ADFBB-C2D4-51DD-AE3E-21C5C34554D9" xml:space="preserve">DECLARE_STANDARD_EXTENSION()
+    {
+    TInt r=KErrNoMemory;
+    DPrimaryMediaBase* pM=new DPrimaryMediaBase;
+    if (pM)
+        {
+        //…Required here for Asynchronous creation (if supported)
+        pM-&gt;iDfcQ = &amp;MyDfcQ;
+ 
+        //…Perform registration here
+        r = LocDrv::RegisterMediaDevice(MEDIA_DEVICE_TYPE,
+                                        MEDIA_DRIVECOUNT,
+                                        &amp;IMediaDriveNumbers[0],
+                                        pM,MEDIA_NUMMEDIA,KMediaDriveName
+                                       );
+        }
+    return(r);
+    }
+      </codeblock> <p>You can also do any further initialisation that is appropriate
+to your driver. </p></example>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A74BC61D-85E6-5DB5-93F4-DFE4F0B93EF2.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A74BC61D-85E6-5DB5-93F4-DFE4F0B93EF2" xml:lang="en"><title>Concepts</title><shortdesc>Describes the source code organisation and format of the bootstrap.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> </p>
+</conbody><related-links>
+<link href="GUID-5EB03086-A87D-5588-8927-7A7F8DB38366.dita"><linktext>Port
+Implementation Tutorial</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A74F0245-1A37-41C8-B0E9-63AF858EE4B6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A74F0245-1A37-41C8-B0E9-63AF858EE4B6" xml:lang="en"><title>Platform Services</title><shortdesc>Summary of platform services available on
+the Symbian platform.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A789E0D6-74B2-517D-B73A-F9B11794F175.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,160 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A789E0D6-74B2-517D-B73A-F9B11794F175" xml:lang="en"><title>Peripheral Driver Power Implementation Tutorial</title><shortdesc>Describes an implementation of the <codeph>DPowerHandler</codeph> class.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Peripheral driver power management is based on the <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita"><apiname>DPowerHandler</apiname></xref> class. This is a class that defines the interface that the driver
+must provide to the generic kernel side power manager. </p>
+<p>The class also provides the necessary support functions. The class
+is defined as: </p>
+<codeblock id="GUID-C34B90B1-5AB2-51E4-A7C9-01601B8698F6" xml:space="preserve">class DPowerHandler : public DBase
+    {
+public:
+    IMPORT_C ~DPowerHandler();
+public:
+    IMPORT_C DPowerHandler(const TDesC&amp; aName);
+    IMPORT_C void Add();
+    IMPORT_C void Remove();
+    IMPORT_C void PowerUpDone();
+    IMPORT_C void PowerDownDone();
+    IMPORT_C void SetCurrentConsumption(TInt aCurrent);
+    IMPORT_C void DeltaCurrentConsumption(TInt aCurrent);
+public: 
+    virtual void PowerDown(TPowerState aTargetState) = 0;
+    virtual void PowerUp() = 0;
+private:
+    ...
+    };
+      </codeblock>
+<p>Typically, at least one power handler object is implemented by
+the peripheral driver. In some cases the peripheral driver interface
+class may derive from <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita"><apiname>DPowerHandler</apiname></xref>, in others
+it creates and owns an instance of a <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita"><apiname>DPowerHandler</apiname></xref> derived class. </p>
+<p>The first eight functions are exported from the kernel, <filepath>EKERN.EXE</filepath>, while the remaining two pure virtual functions
+are implemented by the peripheral driver. </p>
+<ul>
+<li id="GUID-C5E97751-13E6-5439-AA62-2323D4DA7A37"><p> <xref href="GUID-A789E0D6-74B2-517D-B73A-F9B11794F175.dita#GUID-A789E0D6-74B2-517D-B73A-F9B11794F175/GUID-6A4484AA-B10E-54D8-B32B-05583EB66841">PowerDown()</xref>  </p> </li>
+<li id="GUID-44F74198-A6DA-56FA-AE39-AADBC3DFB79F"><p> <xref href="GUID-A789E0D6-74B2-517D-B73A-F9B11794F175.dita#GUID-A789E0D6-74B2-517D-B73A-F9B11794F175/GUID-389D4920-2956-5CBE-979E-30C23A0C3E49">PowerUp()</xref>  </p> </li>
+</ul>
+<p>Notes: </p>
+<ol id="GUID-C1640CE7-AF3E-5EF4-9D4C-B44F19B83AB3">
+<li id="GUID-757692DC-EE42-577F-8D92-AC1C61A7C381"><p>Current consumption
+monitoring does not have a full implementation in the power manager
+at present. It is unclear whether this will be ever required. However, <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita"><apiname>DPowerHandler</apiname></xref> does provide two functions: <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-01C1C7F2-CC98-303F-B044-90C1B96304B6"><apiname>DPowerHandler::SetCurrentConsumption()</apiname></xref> and <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-96524179-926E-371A-9694-235C4D3B6163"><apiname>DPowerHandler::DeltaCurrentConsumption()</apiname></xref> that
+a power handler can use to track the peripheral's power consumption.
+Note that this is not based on actual measurements. </p> <p> <codeph>SetCurrentConsumption()</codeph> sets a target current consumption,
+usually at driver creation time. </p> <p> <codeph>DeltaCurrentConsumption()</codeph> changes this target current consumption value, specifying a positive
+or a negative value as appropriate; this might be called in response
+to an operation that is about to start. </p> <p>Although we have described
+the context in which these functions would be used, we recommend that
+you do not use them. </p> </li>
+<li id="GUID-54F4071B-E8E3-5EC3-A7F3-26F74451C707"><p>Fixed media
+drivers do not have a power handler. This means there is currently
+no mechanism to power down media drivers and the associated fixed
+media when the system transitions to a low power state. </p> </li>
+<li id="GUID-AF58E9DB-F1E9-5802-A9E8-8744CBA6C461"><p>The <codeph>__NEW_POWER_HANDLERS</codeph> macro is used to maintain backwards
+compatibility with the power model used in previous versions of Symbian
+platform. If this macro is <i>not</i> defined, it is possible for
+power handlers to revert back to the behavior they present in Kernel
+Architecture 1 (EKA1). </p> <p>If implementing an old style power
+handler, the following functions will have to have an implementation
+provided by the peripheral driver: </p> <codeblock id="GUID-8D7F6D5A-01C7-5F7B-BE25-11D4D3110A26" xml:space="preserve">virtual TInt DoPowerUp()
+virtual void DoPowerDown(TUint32 /* aPowerDownMask */)
+virtual void DoEmergencyPowerDown()
+          </codeblock> <p>If using at least an old style power handler
+the power manager will not complete any powering down (transition
+to <i>Off</i> or <i>Standby</i>). Thus it is recommended that they
+not be used. </p> </li>
+</ol>
+<section id="GUID-6A4484AA-B10E-54D8-B32B-05583EB66841"><title>DPowerHandler::PowerDown()</title> <codeblock id="GUID-61142DAF-895E-5432-B9DB-01CF88C24F26" xml:space="preserve">virtual void PowerDown(TPowerState) = 0;</codeblock> <p><b>When is it called?</b> </p> <p> <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-578DB5FB-731D-36B2-A459-AAC7F250D726"><apiname>DPowerHandler::PowerDown()</apiname></xref> is called by the <xref href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita#GUID-0C435514-EEC6-5660-BB5F-535790349632/GUID-330F07B2-BBDF-5675-B7D5-FF6B25DD03F4">Power manager</xref> during a transition to the <i>Standby</i> or
+the <i>Off</i> state. The <xref href="GUID-87AB8B20-04EE-31D2-8F3D-EA904D05B8D0.dita"><apiname>TPowerState</apiname></xref> argument
+specifies which of the two power states is the target. </p> <p><b>Implementation issues</b> </p> <ol id="GUID-60A913E7-16A2-5350-ACC0-448B980C045E">
+<li id="GUID-98DC816F-B1DE-5524-BCD6-A1AA9DADC05F"><p>After receiving
+a request to power down, as a result of a system transition to the <i>Standby</i> or <i>Off</i> states, a peripheral driver should perform
+the necessary activity to power down the peripheral and ancillary
+hardware, unless it is required for the detection of wake-up events.
+This activity might include requesting the removal of the power supply
+and any other power resources. </p> </li>
+<li id="GUID-3EA32F60-D2B5-522D-901F-91B9D802B67F"><p>The power down
+operation can be done in the same thread in which <codeph>PowerDown()</codeph> runs, i.e. synchronously, or it can run in another thread, i.e.
+asynchronously. You would probably implement power down in another
+thread if the operation were potentially slow. Once the peripheral
+has powered down, it must inform the power manager by calling <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-EBE8CFF8-50BD-3AC3-A4C8-47094DA5674D"><apiname>DPowerHandler::PowerDownDone()</apiname></xref>, and this function can be
+called from the same thread in which <codeph>PowerDown()</codeph> runs,
+or it can be called from another thread. Two points to note: </p> <ul>
+<li id="GUID-E108AAD0-6E84-5BF5-91DA-0EBACD909DA5"><p> <codeph>PowerDownDone()</codeph> can be called before or after <codeph>PowerDown()</codeph> returns </p> </li>
+<li id="GUID-0341DC51-FAFA-5CA0-8F11-E1BD7765DCD5"><p> <codeph>PowerDownDone()</codeph> cannot be called before <codeph>PowerDown()</codeph> has been entered. </p> </li>
+</ul> </li>
+<li id="GUID-0DF3E109-1EE8-5760-BE17-0998CF32EC97"><p> <codeph>PowerDown()</codeph> is only called on a transition to the <i>Standby</i> or the <i>Off</i> state. If the peripheral hardware is powered down when the peripheral
+driver is closed, or when the hardware resources are relinquished
+by the driver, then this is managed by the driver alone. </p> </li>
+<li id="GUID-C3E38B61-7417-5C1A-AB24-355738BCD3EF"><p>There are synchronisation
+issues related to calls to the <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-E8353DF6-B21B-383F-99AB-94B6B5139E47"><apiname>DPowerHandler::Add()</apiname></xref> and <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-FD0BA400-FDCD-3E8C-9130-992A95A3FF84"><apiname>DPowerHandler::Remove()</apiname></xref> functions. <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-E8353DF6-B21B-383F-99AB-94B6B5139E47"><apiname>DPowerHandler::Add()</apiname></xref> is called by the peripheral driver
+when the driver object is created. This registers the power handler
+with the power manager so that so that the driver can receive notification
+of power state transitions. Conversely, <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-FD0BA400-FDCD-3E8C-9130-992A95A3FF84"><apiname>DPowerHandler::Remove()</apiname></xref> is called when the peripheral driver is in the process of being
+destroyed. This de-registers the power handler so that the driver
+is no longer notified of power state transitions. Calls to <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-E8353DF6-B21B-383F-99AB-94B6B5139E47"><apiname>DPowerHandler::Add()</apiname></xref>, <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-FD0BA400-FDCD-3E8C-9130-992A95A3FF84"><apiname>DPowerHandler::Remove()</apiname></xref>, <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-578DB5FB-731D-36B2-A459-AAC7F250D726"><apiname>DPowerHandler::PowerDown()</apiname></xref> and <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-DDC564B4-BD12-30E9-B04A-DBA6CFAF8743"><apiname>DPowerHandler::PowerUp()</apiname></xref> can run asynchronously in relation to one another. For example,
+it is entirely possible that the kernel may be asking the driver to
+power down while it is being created, or indeed while it is being
+destroyed. </p> <p>To avoid deadlock, <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-E8353DF6-B21B-383F-99AB-94B6B5139E47"><apiname>DPowerHandler::Add()</apiname></xref>, <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-FD0BA400-FDCD-3E8C-9130-992A95A3FF84"><apiname>DPowerHandler::Remove()</apiname></xref>, and the <xref href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita#GUID-0C435514-EEC6-5660-BB5F-535790349632/GUID-330F07B2-BBDF-5675-B7D5-FF6B25DD03F4">Power manager</xref> functions that call your <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-578DB5FB-731D-36B2-A459-AAC7F250D726"><apiname>DPowerHandler::PowerDown()</apiname></xref> and your <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-DDC564B4-BD12-30E9-B04A-DBA6CFAF8743"><apiname>DPowerHandler::PowerUp()</apiname></xref> functions,
+all acquire a lock, a <codeph>DMutex</codeph>. While the lock itself
+is internal to Symbian platform, it does impose a requirement that: </p> <ul>
+<li id="GUID-9C3D1630-F6BE-5B8F-8528-E6BF769BECAB"><p> <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-E8353DF6-B21B-383F-99AB-94B6B5139E47"><apiname>DPowerHandler::Add()</apiname></xref>  </p> </li>
+<li id="GUID-104276CB-95F7-57BD-9988-BEEF1CE3255F"><p> <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-FD0BA400-FDCD-3E8C-9130-992A95A3FF84"><apiname>DPowerHandler::Remove()</apiname></xref>  </p> </li>
+<li id="GUID-1B260C33-7697-5574-A623-15D9693DE21F"><p> <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-578DB5FB-731D-36B2-A459-AAC7F250D726"><apiname>DPowerHandler::PowerDown()</apiname></xref>  </p> </li>
+<li id="GUID-0EBC4021-B090-5799-B0F6-3B2808FBBAB1"><p> <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-DDC564B4-BD12-30E9-B04A-DBA6CFAF8743"><apiname>DPowerHandler::PowerUp()</apiname></xref>  </p> </li>
+</ul> <p>all run in the same thread. A common implementation of <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-578DB5FB-731D-36B2-A459-AAC7F250D726"><apiname>DPowerHandler::PowerDown()</apiname></xref>, therefore, schedules a DFC
+to run on the same thread (a DFC queue) as the one that calls <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-E8353DF6-B21B-383F-99AB-94B6B5139E47"><apiname>DPowerHandler::Add()</apiname></xref> and <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-FD0BA400-FDCD-3E8C-9130-992A95A3FF84"><apiname>DPowerHandler::Remove()</apiname></xref>. </p> </li>
+</ol> </section>
+<section id="GUID-389D4920-2956-5CBE-979E-30C23A0C3E49"><title>DPowerHandler::PowerUp()</title> <codeblock id="GUID-F66A2F92-7C60-5D61-BEAD-392FA5F36830" xml:space="preserve">virtual void PowerUp() = 0;</codeblock> <p><b>When is it called?</b> </p> <p> <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-DDC564B4-BD12-30E9-B04A-DBA6CFAF8743"><apiname>DPowerHandler::PowerUp()</apiname></xref> is called by the <xref href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita#GUID-0C435514-EEC6-5660-BB5F-535790349632/GUID-330F07B2-BBDF-5675-B7D5-FF6B25DD03F4">Power manager</xref> during a transition from the <i>Standby</i> state
+back to the <i>Active</i> state. It is up to the peripheral driver
+to decide whether or not to power up the peripheral. </p> <p><b>Implementation
+issues</b> </p> <ol id="GUID-A0A555C9-516B-5408-AC8D-86F7F37501CA">
+<li id="GUID-FF569561-DFB4-59F0-9665-34567D9E159A"><p>After receiving
+a notification to power up, as a result of a system transition from
+the <i>Standby</i> to the <i>Active</i> state, it is up to the peripheral
+driver to decide whether or not to power up the peripheral and ancillary
+hardware. The decision usually depends on whether or not the peripheral
+driver is currently in use. </p> </li>
+<li id="GUID-C2317AFC-9615-56B3-83CC-B2A8F515FF01"><p>The power up
+operation can be done in the same thread in which <codeph>PowerUp()</codeph> runs, i.e. synchronously, or it can run in another thread, i.e.
+asynchronously. You would probably implement power up in another thread
+if the operation were potentially slow. Whether or not the peripheral
+driver intends to power up immediately, it must acknowledge the power
+up request by calling <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-BF62042B-FB7B-3D5B-8379-490FBA284A7A"><apiname>DPowerHandler::PowerUpDone()</apiname></xref>, and this function can be called from the same thread in which <codeph>PowerUp()</codeph> runs, or it can be called from another thread.
+Two points to note: </p> <ul>
+<li id="GUID-C8BA1C99-2731-56A0-96B1-99BF61DF7A46"><p> <codeph>PowerUpDone()</codeph> can be called before or after <codeph>PowerUp()</codeph> returns </p> </li>
+<li id="GUID-0CBF462D-12B9-5598-B968-00F69099E409"><p> <codeph>PowerUpDone()</codeph> cannot be called before <codeph>PowerUp()</codeph> has been entered. </p> </li>
+</ul> </li>
+<li id="GUID-C64797E0-F77B-55D8-8BBC-C0335174B0DF"><p> <codeph>PowerUp()</codeph> is only called on a transition to the <i>Active</i> state. If the
+peripheral hardware is powered up when the peripheral driver is opened,
+or when the hardware resources are first used by the driver, then
+this is managed by the driver alone. </p> </li>
+<li id="GUID-534A5CAA-4FF8-596A-AC79-DBFB31ACF1B9"><p>There are synchronisation
+issues related to calls to the <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-E8353DF6-B21B-383F-99AB-94B6B5139E47"><apiname>DPowerHandler::Add()</apiname></xref> and <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-FD0BA400-FDCD-3E8C-9130-992A95A3FF84"><apiname>DPowerHandler::Remove()</apiname></xref> functions. <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-E8353DF6-B21B-383F-99AB-94B6B5139E47"><apiname>DPowerHandler::Add()</apiname></xref> is called by the peripheral driver
+when the driver object is created. This registers the power handler
+with the power manager so that so that the driver can receive notification
+of power state transitions. Conversely, <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-FD0BA400-FDCD-3E8C-9130-992A95A3FF84"><apiname>DPowerHandler::Remove()</apiname></xref> is called when the peripheral driver is in the process of being
+destroyed. This de-registers the power handler so that the driver
+is no longer notified of power state transitions. Calls to <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-E8353DF6-B21B-383F-99AB-94B6B5139E47"><apiname>DPowerHandler::Add()</apiname></xref>, <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-FD0BA400-FDCD-3E8C-9130-992A95A3FF84"><apiname>DPowerHandler::Remove()</apiname></xref>, <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-578DB5FB-731D-36B2-A459-AAC7F250D726"><apiname>DPowerHandler::PowerDown()</apiname></xref> and <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-DDC564B4-BD12-30E9-B04A-DBA6CFAF8743"><apiname>DPowerHandler::PowerUp()</apiname></xref> can run asynchronoulsy in relation to one another. For example,
+it is entirely possible that the kernel may be asking the driver to
+power down while it is being created, or indeed while it is being
+destroyed. </p> <p>To avoid deadlock, <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-E8353DF6-B21B-383F-99AB-94B6B5139E47"><apiname>DPowerHandler::Add()</apiname></xref>, <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-FD0BA400-FDCD-3E8C-9130-992A95A3FF84"><apiname>DPowerHandler::Remove()</apiname></xref>, and the <xref href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita#GUID-0C435514-EEC6-5660-BB5F-535790349632/GUID-330F07B2-BBDF-5675-B7D5-FF6B25DD03F4">power manager</xref> functions that call your <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-578DB5FB-731D-36B2-A459-AAC7F250D726"><apiname>DPowerHandler::PowerDown()</apiname></xref> and your <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-DDC564B4-BD12-30E9-B04A-DBA6CFAF8743"><apiname>DPowerHandler::PowerUp()</apiname></xref> functions,
+all acquire a lock, a <codeph>DMutex</codeph>. While the lock itself
+is internal to Symbian platform, it does impose a requirement that: </p> <ul>
+<li id="GUID-6A297274-057E-5549-A2D6-6E4FE0D1FDD0"><p> <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-E8353DF6-B21B-383F-99AB-94B6B5139E47"><apiname>DPowerHandler::Add()</apiname></xref>  </p> </li>
+<li id="GUID-8C902FBC-D818-5A56-ADBB-5B7E0C01C192"><p> <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-FD0BA400-FDCD-3E8C-9130-992A95A3FF84"><apiname>DPowerHandler::Remove()</apiname></xref>  </p> </li>
+<li id="GUID-352D5DD5-FE31-5FF9-A988-E0E4D31BD687"><p> <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-578DB5FB-731D-36B2-A459-AAC7F250D726"><apiname>DPowerHandler::PowerDown()</apiname></xref>  </p> </li>
+<li id="GUID-BB116FED-0F67-57B1-98DA-1F5A3BF2E61D"><p> <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-DDC564B4-BD12-30E9-B04A-DBA6CFAF8743"><apiname>DPowerHandler::PowerUp()</apiname></xref>  </p> </li>
+</ul> <p>all run in the same thread. A common implementation of <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-DDC564B4-BD12-30E9-B04A-DBA6CFAF8743"><apiname>DPowerHandler::PowerUp()</apiname></xref>, therefore, schedules a DFC to
+run on the same thread (a DFC queue) as the one that calls <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-E8353DF6-B21B-383F-99AB-94B6B5139E47"><apiname>DPowerHandler::Add()</apiname></xref> and <xref href="GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7.dita#GUID-761AE02B-41A6-35EA-AA9F-0AEEFF67A6F7/GUID-FD0BA400-FDCD-3E8C-9130-992A95A3FF84"><apiname>DPowerHandler::Remove()</apiname></xref>. </p> </li>
+</ol> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A7ECF51F-F96A-5251-A71F-2F269C8C0664.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,204 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A7ECF51F-F96A-5251-A71F-2F269C8C0664" xml:lang="en"><title>Accessor
+Functions for Derived Attributes</title><shortdesc>Explains how to add accessor functions for derived attributes.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>You can change HAL to add accessor functions for new derived attributes.
+This step is not often done, because all normal accessor functions are already
+defined in <filepath>...\hal\src\userhal.cpp</filepath>. </p>
+<p>Each derived attribute is declared with an associated function name in <xref href="GUID-52583CC7-483E-54B5-8094-F0F61BD46B7F.dita#GUID-52583CC7-483E-54B5-8094-F0F61BD46B7F/GUID-8648B87A-B712-5458-850A-FDF318669FE3">Config
+file</xref>. A function with that name must be provided, and it must have
+the following signature, which is also defined by the <xref href="GUID-0885487F-1482-3BD4-9EA8-9E9643125A0A.dita"><apiname>THalImplementation</apiname></xref> typedef: </p>
+<codeblock id="GUID-53946166-A153-57E1-8FAB-BB3870B0B829" xml:space="preserve">TInt Function(TInt aAttrib, TBool aSet, TAny* aInOut);</codeblock>
+<p>This function is called whenever any client of the HAL references the associated
+attribute. </p>
+<table id="GUID-2672A463-7AB1-504E-9D0C-2AA29757178A">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>aAttrib</codeph>  </p> </entry>
+<entry><p>Contains the attribute number. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>aSet</codeph>  </p> </entry>
+<entry><p>Defines whether the attribute is being set or being read: <xref href="GUID-781E8158-805B-3784-8FED-D7A191822FC3.dita"><apiname>ETrue</apiname></xref> means
+that the attribute value is being set; <xref href="GUID-A759CA2D-8327-348F-9337-4886E619D920.dita"><apiname>EFalse</apiname></xref> means that
+the attribute value is being read. </p> <p>Note that if the attribute, as
+defined in the <filepath>config.hcf</filepath> file, does not have the settable
+property, then <codeph>aSet</codeph> is ignored . </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>aInOut</codeph>  </p> </entry>
+<entry><p>A pointer to a <xref href="GUID-7A2A43EC-6125-3BFE-834B-23C37F7B40D5.dita"><apiname>TInt</apiname></xref> type, that contains: </p> <ul>
+<li id="GUID-B7598EEB-4B73-5E51-8F92-EC527FCED605"><p>the attribute value
+to be set, if <codeph>aSet</codeph> is <xref href="GUID-781E8158-805B-3784-8FED-D7A191822FC3.dita"><apiname>ETrue</apiname></xref>  </p> </li>
+<li id="GUID-BEA21EED-2D95-5169-B09C-DD6CC7CE4507"><p>the attribute value
+to be read, if <codeph>aSet</codeph> is <xref href="GUID-A759CA2D-8327-348F-9337-4886E619D920.dita"><apiname>EFalse</apiname></xref>. </p> </li>
+</ul> </entry>
+</row>
+</tbody>
+</tgroup>
+</table>
+<p>Once the config file has been written, the Perl script <filepath>...\hal\group\halcfg.pl</filepath> can
+be used to generate a skeleton implementation file. For example, calling </p>
+<p><userinput>perl \hal\group\halcfg.pl -s \hal\inc\hal_data.h config.hcf
+imp.cpp</userinput> </p>
+<p>produces the file <filepath>imp.cpp</filepath> containing the following
+skeleton code for <i>each</i> derived attribute: </p>
+<codeblock id="GUID-EAA857F6-61FB-5FAE-815E-9B3601CF182C" xml:space="preserve">// EAttributeName
+TInt Function(TInt /*aAttrib*/, TBool /*aSet*/, TAny* aInOut)
+    {
+    return KErrNone;
+    }
+</codeblock>
+<p>The full implementation for the function can now be written. </p>
+<p>Notes: </p>
+<ul>
+<li id="GUID-25545667-6870-5AAF-9271-D7402E9F777E"><p>The <codeph>aAttrib</codeph> parameter
+is always marked as a comment because it is not usually needed; it is only
+needed if the same function is used to implement more than one attribute. </p> </li>
+<li id="GUID-8DE7C359-AA59-5158-82BD-2184D874168C"><p>The <codeph>aSet</codeph> parameter
+is marked as a comment if the attribute does not have the <i>settable</i> property. </p> </li>
+<li id="GUID-27CE60FA-8104-511C-9FC2-3D4557D92BBC"><p>On some platforms it
+may be necessary to access some HAL attributes via a device driver or server,
+rather than using <codeph>UserSvr::HalFunction()</codeph> . In this case,
+a handle to the device driver or server must be opened on the first access.
+Use the <codeph>HalInternal::Tls()</codeph> function to do this. </p> </li>
+<li id="GUID-72462FB8-F607-56D8-9F0B-FD9980FDCEBD"><p>Access to any HAL attribute
+requiring the use of a server or device driver can fail due to lack of memory. </p> </li>
+</ul>
+<p>Thee code fragments in the <xref href="GUID-A7ECF51F-F96A-5251-A71F-2F269C8C0664.dita#GUID-A7ECF51F-F96A-5251-A71F-2F269C8C0664/GUID-61707920-B82E-5580-8821-4FD1DC3BE77A">example
+accessor functions</xref> show the cases where the HAL has an attribute that
+requires a device driver and another attribute that requires a server. </p>
+<p>See also <xref href="GUID-F8B8C030-B5E1-5EB3-A672-83BF35555801.dita">halcfg.pl
+Syntax</xref>. </p>
+<section id="GUID-61707920-B82E-5580-8821-4FD1DC3BE77A"><title>Example accessor
+functions for derived attributes using a device driver and a server</title> <p>This
+code fragment shows the implementation of accessor functions for two HAL derived
+attributes. One uses a device driver, and the other uses a server to provide
+the necessary functionality. </p> <p>The examples assume that the attributes
+are defined in the <filepath>config.hcf</filepath> file with function names <codeph>Attrib1</codeph> and <codeph>Attrib2</codeph>. </p> <p><b>Using a device driver</b> </p> <codeblock id="GUID-810DF0E3-4AE7-5FFC-8434-A845513BCC65" xml:space="preserve">TInt Attrib1(TInt /*aAttrib*/, TBool aSet, TAny* aInOut)
+    {
+       // Do something with the device driver
+       RHwDevice d;
+       TInt r=GetDeviceDriverHandle(d);
+       if (r==KErrNone)
+        {
+        if (aSet)
+            {
+            r=d.Write((TInt)aInOut);
+            }
+        else
+            {
+            r=d.Read(*(TInt*)aInOut);
+            }
+         }
+    return r;
+    }</codeblock> <codeblock id="GUID-88E9FA83-D669-5073-B92A-48A22BFEC4B2" xml:space="preserve">TInt GetDeviceDriverHandle(RHwDevice&amp; aDevice)
+    {
+    // Return the device driver handle for this thread
+    // If it doesn't exist, attempt to open a handle
+    // Careful with OOM errors
+
+    SHandles* pH=GetHandles();
+    if (!pH)
+        {
+        return KErrNoMemory;    // couldn't allocate TLS memory
+        }
+    if (pH-&gt;iDevHandle)
+        {
+        // device driver handle already open
+        aDevice.SetHandle(pH-&gt;iDevHandle);
+        return KErrNone;
+        }
+
+    // note: Someone should have previously loaded the required
+    // device driver.  Eg.
+    // User::LoadLogicalDevice(_L("HARDWARE.LDD"));
+    // This can be done here, but it is inefficient since it will
+    // happen once per thread.  It's much better to do it once
+    // at Hal start-up.
+
+    TInt r=aDevice.Open();    // open handle to driver
+    if (r==KErrNone)
+        {
+           pH-&gt;iDevHandle=aDevice.Handle();    // store handle
+        }
+    return r;
+    }</codeblock> <codeblock id="GUID-264AF5EC-A4F3-5BA7-AC47-576C338D81F2" xml:space="preserve">struct SHandles
+    {
+    TInt iDevHandle;
+    TInt iSvrHandle;
+    };
+</codeblock> <codeblock id="GUID-7F5DC241-B4B1-501F-A7B6-0B864676A4A2" xml:space="preserve">SHandles* GetHandles()
+    {
+    // Return a pointer to the SHandles structure for this thread
+    // If it doesn't exist, attempt to create it
+
+    // This function zeros a newly allocated memory block
+    return (SHandles*)HalInternal::Tls(sizeof(SHandles));
+    }
+</codeblock> <p><b>Using
+a server</b> </p> <codeblock id="GUID-E0CB12CC-2F83-5AB6-B1F3-B494AD7346CB" xml:space="preserve">TInt Attrib2(TInt /*aAttrib*/, TBool aSet, TAny* aInOut)
+    {
+    // Do something with the server
+    RHwServer s;
+    TInt r=GetServerHandle(s);
+    if (r==KErrNone)
+        {
+        if (aSet)
+            {
+            r=s.Write((TInt)aInOut);
+            }
+            else
+            {
+            r=s.Read(*(TInt*)aInOut);
+            }
+        }
+    return r;
+    }</codeblock> <codeblock id="GUID-C74F36A5-78CA-52A6-A8E9-6BEAAC7B9257" xml:space="preserve">TInt GetServerHandle(RHwServer&amp; aServer)
+    {
+    // Return the server handle for this thread
+    // If it doesn't exist, attempt to open a handle
+    // Careful with OOM errors
+
+    SHandles* pH=GetHandles();
+    if (!pH)
+        {
+        return KErrNoMemory;    // couldn't allocate TLS memory
+        }
+    if (pH-&gt;iSvrHandle)
+        {
+        // server handle already open
+           aServer.SetHandle(pH-&gt;iSvrHandle);
+           return KErrNone;
+        }
+    TInt r=aServer.Connect();    // create session with server
+    if (r==KErrNone)
+        {
+        pH-&gt;iSvrHandle=aServer.Handle();    // store handle
+        }
+    return r;
+    }</codeblock> <codeblock id="GUID-9527E73D-FAFA-519A-80F1-FD10E5AF3D40" xml:space="preserve">struct SHandles
+    {
+    TInt iDevHandle;
+    TInt iSvrHandle;
+    };
+</codeblock> <codeblock id="GUID-6C88ED9C-E8D1-5901-BE00-F52130F3509C" xml:space="preserve">SHandles* GetHandles()
+    {
+    // Return a pointer to the SHandles structure for this thread
+    // If it doesn't exist, attempt to create it
+
+    // This function zeros a newly allocated memory block
+    return (SHandles*)HalInternal::Tls(sizeof(SHandles));
+    }
+</codeblock> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-A819DE06-7B00-4643-9D3E-EFE14132981C-master.png has changed
Binary file Adaptation/GUID-A819DE06-7B00-4643-9D3E-EFE14132981C_d0e99133_href.png has changed
Binary file Adaptation/GUID-A819DE06-7B00-4643-9D3E-EFE14132981C_d0e99345_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A87D9280-B61A-49BA-A9AF-178DB9BAECBC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,101 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A87D9280-B61A-49BA-A9AF-178DB9BAECBC" xml:lang="en"><title>Reading and Writing</title><shortdesc>This document describes how device drivers should open, read from
+and write to shared chunks.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Both user-side code and drivers can read and write to shared chunks. Once
+the chunk is created, opened, and memory committed to it, data can be written
+and read to the shared chunk using the base address. </p>
+<section id="GUID-4CF7C47A-24D2-4D6D-B577-F0351178CA38"><title>Opening</title> <p>If a shared chunk has already been created
+by a driver, then another driver can access that shared chunk through its
+handle by using one of the following functions: </p> <codeblock id="GUID-EB073A6D-5DC3-5572-BD7C-E96F63BB8DCF" xml:space="preserve">DChunk* Kern::OpenSharedChunk(DThread* aThread, TInt aChunkHandle,
+                    TBool aWrite);
+
+DChunk* Kern::OpenSharedChunk(DThread *aThread, 
+                    const TAny *aAddress, TBool aWrite, 
+                    TInt &amp;aOffset);
+</codeblock></section>
+<section id="GUID-95D166D2-C6BE-45F5-84E7-6F5ACB1BFA38"><title>User-side access</title> <p> <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita"><apiname>RChunk</apiname></xref> is
+the user side representation of a shared chunk. The user gets a shared chunk
+handle from a driver, and initialises the <codeph>RChunk</codeph> object with
+it using <codeph>RChunk::SetHandle(TInt aHandle)</codeph>. </p> <p>The user
+can now obtain the base address of the chunk by calling <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita#GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07/GUID-D19E68E8-3C5F-3F97-80F2-B2F80A814A80"><apiname>RChunk::Base()</apiname></xref>.
+Data can be read or written to this memory location, in same way as any other
+memory. </p> <codeblock id="GUID-E0F57FBB-1F43-564F-8350-A49B6AFEE3F1" xml:space="preserve">// User side chunk object.     
+ RChunk chunkTx; 
+     
+// Get the handle to the chunk. A driver creates the chunk and
+// returns the handle to the user to access it. The handle is  
+// assigned to the user side chunk object using RChunk::SetHandle(). 
+// (here done in the GetTxChunkHandle function). The handle has to be a positive 
+// value. It can be obtained using RChunk::Handle(), if required.
+//
+r=ldd.GetTxChunkHandle(chunkTx);     
+test(r==KErrNone);        
+     
+// Create a constant descriptor with test data
+_LIT8(KTestSendData,"&lt;&lt; TEST DATA FOR TUTORIAL DRIVER EXAMPLE &gt;&gt;");
+     
+TUint8* chunkbase;
+// Retrieve the base address of the chunk. Using this address, the user 
+// can access the shared chunk just like any memory pointer. 
+// RChunk::Base() returns the linear address of the shared chunk.
+//
+chunkbase=chunkTx.Base(); 
+    
+// Write the data to the shared chunk, using the chunk base address.
+// Note here we do not need to send data to the driver. We just write to 
+// the buffer and the driver directly accesses the chunk from the kernel side.
+//
+TPtr8 inbuf(chunkbase,KTestSendData().Size());
+inbuf = KTestSendData;
+…
+
+// Call the LDD interface TransmitData(). There is no need to send the 
+// data, instead we send only a TRequestStatus object (as it's an  
+// asynchronous function), and buffer size. If required, an offset in the shared chunk 
+// can be passed to the driver.
+r = ldd.TransmitData(txStatus,inbuf.Size());
+ test(r==KErrNone);</codeblock> </section>
+<section id="GUID-5524489D-37FB-41CF-BC87-540569FF943F"><title>Kernel-side access</title> <p>On the kernel side, a chunk
+is represented by a <xref href="GUID-85454082-6734-3F1D-983F-734D4C2AB12D.dita"><apiname>DChunk</apiname></xref> object. A chunk is created,
+mapped, or opened as shown in earlier sections. The linear and physical addresses
+of the chunk are returned when this is done. At a later stage in the driver,
+use <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-626CCD99-63D8-322A-A807-9DB96523C82D"><apiname>Kern::ChunkAddress()</apiname></xref> and <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-79F110C1-2764-34B5-857B-6C0012D2049D"><apiname>Kern::ChunkPhysicalAddress()</apiname></xref> to
+get the linear and physical addresses respectively. A chunk is read or written
+to using this address pointer and an offset. </p> <codeblock id="GUID-1E341298-F67A-5A21-8C21-405E1BB97946" xml:space="preserve">// Note: Following lines of code are located in different 
+// functions and different files. Here they are shown together for 
+// easy comprehension.
+
+// Linear address of the Rx Shared chunk
+TLinAddr iRxChunkKernAddr;
+...
+
+// iRxChunkKernAddr returns the linear address of the Rx chunk
+TInt r=Kern::ChunkCreate(info,chunk,iRxChunkKernAddr, mapAttr);
+...
+
+// iRxBufPhysAddr returns the physical address of the Rx chunk
+r=Kern::ChunkCommitContiguous(chunk, bufoffset, size, iRxBufPhysAddr);
+...
+
+// Here we are directly using the linear address of the shared 
+// chunk, and so can get rid of any buffer copies. If the DMA 
+// port supports physical address, then the physical address can be
+// used instead of a linear address.
+// 
+TInt retval = iRxDmaRequest-&gt;Fragment(
+            TUint32)iUartComm-&gt;iPortAddr+KHoUART_RHR,
+            TUint32)(iUartComm-&gt;iRxChunkKernAddr), aCount, 
+            KDmaMemDest|KDmaIncDest, 0 /* no HW Flags*/);</codeblock> <p>Synchronization
+between user access and kernel access to a shared chunk is handled by the
+shared chunk API. </p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,83 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1" xml:lang="en"><title>Kernel
+API Validity Checks</title><shortdesc>Describes the pre-condition checks that Kernel APIs can do when
+they are called. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<ul>
+<li id="GUID-5D68233C-71CB-5779-B73D-675543F03817-GENID-1-2-1-8-1-1-7-1-1-4-1-3-1-1"><p><xref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1.dita#GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1/GUID-55866E19-257D-5C0B-BFD2-31F0A5B74070-GENID-1-2-1-8-1-1-7-1-1-4-1-3-2">What does checking the validity of calls mean?</xref>  </p> </li>
+<li id="GUID-3F5064A8-174B-503C-AA02-08797E804126-GENID-1-2-1-8-1-1-7-1-1-4-1-3-1-2"><p><xref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1.dita#GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1/GUID-E2945D82-0EC5-53AD-82DE-AD47C21E870C-GENID-1-2-1-8-1-1-7-1-1-4-1-3-3">What happens if a validity check fails?</xref>  </p> </li>
+<li id="GUID-C9DCF427-9283-5476-9F16-88C94FC18D28-GENID-1-2-1-8-1-1-7-1-1-4-1-3-1-3"><p><xref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1.dita#GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1/GUID-BB0C87D0-CC1E-5EC9-872C-AA50C99F323F-GENID-1-2-1-8-1-1-7-1-1-4-1-3-4">Which conditions are checked?</xref>  </p> </li>
+</ul>
+<section id="GUID-55866E19-257D-5C0B-BFD2-31F0A5B74070-GENID-1-2-1-8-1-1-7-1-1-4-1-3-2"><title>What does checking
+the validity of calls mean?</title> <p>A kernel-side function or service almost
+always requires that various preconditions apply before that function or service
+can be called. There are also times when a call to a kernel-side function
+or service from device drivers may not be appropriate, for example, calls
+to some specific functions from within Interrupt Service Routines (ISRs) or
+from within Deferred Function Calls (DFCs). </p> <p>For example, before you
+call <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-71A20F01-5E5F-3B27-92BA-3B3BF7D578C9"><apiname>Kern::CloseHandle()</apiname></xref>, the following conditions apply: </p> <ul>
+<li id="GUID-8B1908C7-BBC0-58DB-BA95-D6E550B53E2D-GENID-1-2-1-8-1-1-7-1-1-4-1-3-2-4-1"><p>the calling thread must
+be in a critical section </p> </li>
+<li id="GUID-DBBDB602-3451-5745-B80C-4779BCDCEDC7-GENID-1-2-1-8-1-1-7-1-1-4-1-3-2-4-2"><p>interrupts must be enabled </p> </li>
+<li id="GUID-094CE1C9-0F5E-5ECE-96CE-187CAF998633-GENID-1-2-1-8-1-1-7-1-1-4-1-3-2-4-3"><p>the kernel must be unlocked </p> </li>
+<li id="GUID-765B8EFA-F539-5169-B593-F077942E2164-GENID-1-2-1-8-1-1-7-1-1-4-1-3-2-4-4"><p>no fast mutex can be
+held </p> </li>
+</ul> <p>If conditions such as these are not met before you call the kernel-side
+function or service, then you risk damaging the integrity of the kernel and
+the whole system, with a very high risk of causing the kernel to fault followed
+by a re-boot of the device. </p> <p>The pre-conditions that apply vary with
+the function called; they are listed as part of the reference documentation
+for that function. </p> <p>To help device driver test suites check that device
+driver code is valid, stringent checks can be switched on in debug (non-production)
+builds of Symbian platform (and in the resulting test ROM images). These checks
+help to catch non-compliant device driver code during the testing phase of
+a new device. This minimizes the risk of production devices failing because
+of faulty device driver code. </p> </section>
+<section id="GUID-E2945D82-0EC5-53AD-82DE-AD47C21E870C-GENID-1-2-1-8-1-1-7-1-1-4-1-3-3"><title>What happens
+if a validity check fails?</title> <p>Validity checking is done by code that
+is conditionally compiled into a build of Symbian platform. Such code has
+an impact on the performance of the device on which it runs, but is always
+restricted to test devices. On production builds of Symbian platform, validity
+checking is switched off, which means that the code is not compiled in and
+has no effect on performance. </p> <p>Validity checking is switched ON for
+a build of Symbian platform if <i>one or both</i> of the following macros
+is defined in <filepath>...\e32\kernel\kern_int.mmh</filepath> : </p> <ul>
+<li id="GUID-47071D73-190A-5996-9E82-67AE907A4918-GENID-1-2-1-8-1-1-7-1-1-4-1-3-3-4-1"><p><xref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1.dita#GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1/GUID-F97EBEF0-D07C-5F40-ADE6-BD050B54A010-GENID-1-2-1-8-1-1-7-1-1-4-1-3-3-6">__KERNEL_APIS_CONTEXT_CHECKS_WARNING__</xref> </p> </li>
+<li id="GUID-FAFC6553-92CB-52A5-843D-C9A2136F22F6-GENID-1-2-1-8-1-1-7-1-1-4-1-3-3-4-2"><p><xref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1.dita#GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1/GUID-A2D9762E-6A1A-5307-9BEE-4EA9A86350EF-GENID-1-2-1-8-1-1-7-1-1-4-1-3-3-11">__KERNEL_APIS_CONTEXT_CHECKS_FAULT__</xref> </p> </li>
+</ul> <p>Validity checking is switched OFF for a build of Symbian platform
+if <i>both</i> macros are <i>undefined</i> (in practice they will be marked
+as a comment rather than being completely deleted from the <filepath>.mmh</filepath> file). </p> <p id="GUID-F97EBEF0-D07C-5F40-ADE6-BD050B54A010-GENID-1-2-1-8-1-1-7-1-1-4-1-3-3-6"><b> __KERNEL_APIS_CONTEXT_CHECKS_WARNING__</b> </p> <p>If
+this macro is defined, then calling a kernel-side function when the necessary
+pre-conditions have not been satisfied causes a text message to be written
+to a trace port. The message has the format: </p> <codeblock id="GUID-637F4DA3-5B60-542B-8BC7-BEF67A884FFD-GENID-1-2-1-8-1-1-7-1-1-4-1-3-3-8" xml:space="preserve">Description of pre-condition that has not been met
+The name of the function checking the pre-condition</codeblock> <p>For example,
+when you call <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita#GUID-A3CC1D95-4681-3349-A67C-F113A614041D/GUID-CF1F6A0E-342A-3EDD-953C-3176D7D7F0A0"><apiname>DLogicalChannel::Close()</apiname></xref>, you must be in
+a critical section. If you are not, then you will see the following text in
+your trace: </p> <codeblock id="GUID-73E792DA-9C83-5885-A5E3-9293341ACFFC-GENID-1-2-1-8-1-1-7-1-1-4-1-3-3-10" xml:space="preserve">Assertion failed: Calling thread must be in a critical section
+DLogicalChannel::Close</codeblock> <p id="GUID-A2D9762E-6A1A-5307-9BEE-4EA9A86350EF-GENID-1-2-1-8-1-1-7-1-1-4-1-3-3-11"><b>__KERNEL_APIS_CONTEXT_CHECKS_FAULT__</b> </p> <p>If
+this macro is defined, then calling a kernel-side function when the necessary
+pre-conditions have not been satisfied: </p> <ol id="GUID-6735A9D4-C120-54E1-884C-1008221652DC-GENID-1-2-1-8-1-1-7-1-1-4-1-3-3-13">
+<li id="GUID-B4E5922D-FB75-5DD5-BF9B-F0D2833FAB9B-GENID-1-2-1-8-1-1-7-1-1-4-1-3-3-13-1"><p>causes a text message
+to be written to a trace port, as happens if <codeph/><xref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1.dita#GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1/GUID-F97EBEF0-D07C-5F40-ADE6-BD050B54A010-GENID-1-2-1-8-1-1-7-1-1-4-1-3-3-6">__KERNEL_APIS_CONTEXT_CHECKS_WARNING__</xref> is defined. </p> </li>
+<li id="GUID-821EAF7B-E8D5-5D9E-85BA-AEF3A88C5EBD-GENID-1-2-1-8-1-1-7-1-1-4-1-3-3-13-2"><p>causes the kernel to
+fault, specifying the function name as the fault category, and zero as the
+fault number. The crash debugger is also started if this is present on the
+device. </p> </li>
+</ol> <p><b>__KERNEL_APIS_CONTEXT_CHECKS_WARNING__
+and __KERNEL_APIS_CONTEXT_CHECKS_FAULT__</b> </p> <p>If both macros are defined,
+then validity checking behaves as if <xref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1.dita#GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1/GUID-A2D9762E-6A1A-5307-9BEE-4EA9A86350EF-GENID-1-2-1-8-1-1-7-1-1-4-1-3-3-11">__KERNEL_APIS_CONTEXT_CHECKS_FAULT__</xref> is defined. </p> </section>
+<section id="GUID-BB0C87D0-CC1E-5EC9-872C-AA50C99F323F-GENID-1-2-1-8-1-1-7-1-1-4-1-3-4"><title>Which conditions
+are checked?</title> <p>The section <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-5F986149-D75B-5B3F-92F3-7B4FB89F4718">pre-conditions</xref> within the larger section <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita">Pre-Conditions
+and Post-Conditions for Kernel APIs</xref> gives you some context for the
+most common pre-conditions that apply when calling kernel-side functions.
+This list is not exhaustive. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,83 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1" xml:lang="en"><title>Kernel
+API Validity Checks</title><shortdesc>Describes the pre-condition checks that Kernel APIs can do when
+they are called. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<ul>
+<li id="GUID-5D68233C-71CB-5779-B73D-675543F03817-GENID-1-2-1-9-1-8-1-17-1-3-1-1"><p><xref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1.dita#GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1/GUID-55866E19-257D-5C0B-BFD2-31F0A5B74070-GENID-1-2-1-9-1-8-1-17-1-3-2">What does checking the validity of calls mean?</xref>  </p> </li>
+<li id="GUID-3F5064A8-174B-503C-AA02-08797E804126-GENID-1-2-1-9-1-8-1-17-1-3-1-2"><p><xref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1.dita#GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1/GUID-E2945D82-0EC5-53AD-82DE-AD47C21E870C-GENID-1-2-1-9-1-8-1-17-1-3-3">What happens if a validity check fails?</xref>  </p> </li>
+<li id="GUID-C9DCF427-9283-5476-9F16-88C94FC18D28-GENID-1-2-1-9-1-8-1-17-1-3-1-3"><p><xref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1.dita#GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1/GUID-BB0C87D0-CC1E-5EC9-872C-AA50C99F323F-GENID-1-2-1-9-1-8-1-17-1-3-4">Which conditions are checked?</xref>  </p> </li>
+</ul>
+<section id="GUID-55866E19-257D-5C0B-BFD2-31F0A5B74070-GENID-1-2-1-9-1-8-1-17-1-3-2"><title>What does checking
+the validity of calls mean?</title> <p>A kernel-side function or service almost
+always requires that various preconditions apply before that function or service
+can be called. There are also times when a call to a kernel-side function
+or service from device drivers may not be appropriate, for example, calls
+to some specific functions from within Interrupt Service Routines (ISRs) or
+from within Deferred Function Calls (DFCs). </p> <p>For example, before you
+call <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-71A20F01-5E5F-3B27-92BA-3B3BF7D578C9"><apiname>Kern::CloseHandle()</apiname></xref>, the following conditions apply: </p> <ul>
+<li id="GUID-8B1908C7-BBC0-58DB-BA95-D6E550B53E2D-GENID-1-2-1-9-1-8-1-17-1-3-2-4-1"><p>the calling thread must
+be in a critical section </p> </li>
+<li id="GUID-DBBDB602-3451-5745-B80C-4779BCDCEDC7-GENID-1-2-1-9-1-8-1-17-1-3-2-4-2"><p>interrupts must be enabled </p> </li>
+<li id="GUID-094CE1C9-0F5E-5ECE-96CE-187CAF998633-GENID-1-2-1-9-1-8-1-17-1-3-2-4-3"><p>the kernel must be unlocked </p> </li>
+<li id="GUID-765B8EFA-F539-5169-B593-F077942E2164-GENID-1-2-1-9-1-8-1-17-1-3-2-4-4"><p>no fast mutex can be
+held </p> </li>
+</ul> <p>If conditions such as these are not met before you call the kernel-side
+function or service, then you risk damaging the integrity of the kernel and
+the whole system, with a very high risk of causing the kernel to fault followed
+by a re-boot of the device. </p> <p>The pre-conditions that apply vary with
+the function called; they are listed as part of the reference documentation
+for that function. </p> <p>To help device driver test suites check that device
+driver code is valid, stringent checks can be switched on in debug (non-production)
+builds of Symbian platform (and in the resulting test ROM images). These checks
+help to catch non-compliant device driver code during the testing phase of
+a new device. This minimizes the risk of production devices failing because
+of faulty device driver code. </p> </section>
+<section id="GUID-E2945D82-0EC5-53AD-82DE-AD47C21E870C-GENID-1-2-1-9-1-8-1-17-1-3-3"><title>What happens
+if a validity check fails?</title> <p>Validity checking is done by code that
+is conditionally compiled into a build of Symbian platform. Such code has
+an impact on the performance of the device on which it runs, but is always
+restricted to test devices. On production builds of Symbian platform, validity
+checking is switched off, which means that the code is not compiled in and
+has no effect on performance. </p> <p>Validity checking is switched ON for
+a build of Symbian platform if <i>one or both</i> of the following macros
+is defined in <filepath>...\e32\kernel\kern_int.mmh</filepath> : </p> <ul>
+<li id="GUID-47071D73-190A-5996-9E82-67AE907A4918-GENID-1-2-1-9-1-8-1-17-1-3-3-4-1"><p><xref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1.dita#GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1/GUID-F97EBEF0-D07C-5F40-ADE6-BD050B54A010-GENID-1-2-1-9-1-8-1-17-1-3-3-6">__KERNEL_APIS_CONTEXT_CHECKS_WARNING__</xref> </p> </li>
+<li id="GUID-FAFC6553-92CB-52A5-843D-C9A2136F22F6-GENID-1-2-1-9-1-8-1-17-1-3-3-4-2"><p><xref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1.dita#GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1/GUID-A2D9762E-6A1A-5307-9BEE-4EA9A86350EF-GENID-1-2-1-9-1-8-1-17-1-3-3-11">__KERNEL_APIS_CONTEXT_CHECKS_FAULT__</xref> </p> </li>
+</ul> <p>Validity checking is switched OFF for a build of Symbian platform
+if <i>both</i> macros are <i>undefined</i> (in practice they will be marked
+as a comment rather than being completely deleted from the <filepath>.mmh</filepath> file). </p> <p id="GUID-F97EBEF0-D07C-5F40-ADE6-BD050B54A010-GENID-1-2-1-9-1-8-1-17-1-3-3-6"><b> __KERNEL_APIS_CONTEXT_CHECKS_WARNING__</b> </p> <p>If
+this macro is defined, then calling a kernel-side function when the necessary
+pre-conditions have not been satisfied causes a text message to be written
+to a trace port. The message has the format: </p> <codeblock id="GUID-637F4DA3-5B60-542B-8BC7-BEF67A884FFD-GENID-1-2-1-9-1-8-1-17-1-3-3-8" xml:space="preserve">Description of pre-condition that has not been met
+The name of the function checking the pre-condition</codeblock> <p>For example,
+when you call <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita#GUID-A3CC1D95-4681-3349-A67C-F113A614041D/GUID-CF1F6A0E-342A-3EDD-953C-3176D7D7F0A0"><apiname>DLogicalChannel::Close()</apiname></xref>, you must be in
+a critical section. If you are not, then you will see the following text in
+your trace: </p> <codeblock id="GUID-73E792DA-9C83-5885-A5E3-9293341ACFFC-GENID-1-2-1-9-1-8-1-17-1-3-3-10" xml:space="preserve">Assertion failed: Calling thread must be in a critical section
+DLogicalChannel::Close</codeblock> <p id="GUID-A2D9762E-6A1A-5307-9BEE-4EA9A86350EF-GENID-1-2-1-9-1-8-1-17-1-3-3-11"><b>__KERNEL_APIS_CONTEXT_CHECKS_FAULT__</b> </p> <p>If
+this macro is defined, then calling a kernel-side function when the necessary
+pre-conditions have not been satisfied: </p> <ol id="GUID-6735A9D4-C120-54E1-884C-1008221652DC-GENID-1-2-1-9-1-8-1-17-1-3-3-13">
+<li id="GUID-B4E5922D-FB75-5DD5-BF9B-F0D2833FAB9B-GENID-1-2-1-9-1-8-1-17-1-3-3-13-1"><p>causes a text message
+to be written to a trace port, as happens if <codeph/><xref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1.dita#GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1/GUID-F97EBEF0-D07C-5F40-ADE6-BD050B54A010-GENID-1-2-1-9-1-8-1-17-1-3-3-6">__KERNEL_APIS_CONTEXT_CHECKS_WARNING__</xref> is defined. </p> </li>
+<li id="GUID-821EAF7B-E8D5-5D9E-85BA-AEF3A88C5EBD-GENID-1-2-1-9-1-8-1-17-1-3-3-13-2"><p>causes the kernel to
+fault, specifying the function name as the fault category, and zero as the
+fault number. The crash debugger is also started if this is present on the
+device. </p> </li>
+</ol> <p><b>__KERNEL_APIS_CONTEXT_CHECKS_WARNING__
+and __KERNEL_APIS_CONTEXT_CHECKS_FAULT__</b> </p> <p>If both macros are defined,
+then validity checking behaves as if <xref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1.dita#GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-9-1-8-1-17-1/GUID-A2D9762E-6A1A-5307-9BEE-4EA9A86350EF-GENID-1-2-1-9-1-8-1-17-1-3-3-11">__KERNEL_APIS_CONTEXT_CHECKS_FAULT__</xref> is defined. </p> </section>
+<section id="GUID-BB0C87D0-CC1E-5EC9-872C-AA50C99F323F-GENID-1-2-1-9-1-8-1-17-1-3-4"><title>Which conditions
+are checked?</title> <p>The section <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita#GUID-63456B20-3A61-554A-BBA4-C23B176E39A8/GUID-5F986149-D75B-5B3F-92F3-7B4FB89F4718">pre-conditions</xref> within the larger section <xref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita">Pre-Conditions
+and Post-Conditions for Kernel APIs</xref> gives you some context for the
+most common pre-conditions that apply when calling kernel-side functions.
+This list is not exhaustive. </p> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-AA53650C-664C-53F0-8BE9-445677FC1FE2-master.png has changed
Binary file Adaptation/GUID-AA53650C-664C-53F0-8BE9-445677FC1FE2_d0e19130_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-AABC7605-9EE9-41E4-BFDF-77A589A9887B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-AABC7605-9EE9-41E4-BFDF-77A589A9887B" xml:lang="en"><title>Building
+a DMA Adaptation</title><shortdesc>This document describes what is needed to include the DMA adaptation
+in a ROM image.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>When building a ROM image, all the processes and data needed to execute
+a build are included in a single file. This file is executed by the platform
+when the hardware is powered up.</p>
+<section id="GUID-72D93CEF-4E7D-473B-B607-ACBC0071DF6D-GENID-1-2-1-10-1-5-1-5-1-1-8-1-8-1-3-2"><title>Requirements</title><ul>
+<li><p>DMA framework.</p></li>
+<li><p>You must be familiar with building a ROM for the Symbian platform.</p></li>
+</ul></section>
+<section id="GUID-D627B27F-CCFE-42A0-856C-7B09E873BAE1-GENID-1-2-1-10-1-5-1-5-1-1-8-1-8-1-3-3"><title>Use the template
+port to start your port</title><p>There is a template DMA Framework consisting
+of the source file <filepath>dmapsl.cpp</filepath>, and the <filepath>.mmp</filepath> file <filepath>dma.mmp</filepath> located
+in the directory<filepath> ...\template\dma</filepath> that can be used as
+the starting point for your DMA PSL port. You need to: </p><ul>
+<li><p>Decide which directory your DMA PSL and associated<filepath>.mmp</filepath> file
+are to be stored in. You would normally choose the Variant or the ASSP directory.</p></li>
+<li><p>Copy the template framework into your chosen location. Be aware that
+the template <filepath>dma.mmp</filepath> file contains relative paths that
+must be updated.</p></li>
+<li><p>Change the Variant's <filepath>bld.inf</filepath> file to include a
+reference to your <codeph>mmp</codeph> file.</p></li>
+</ul></section>
+<section id="GUID-E4423114-056C-4874-8FF2-53EB1FF5F074-GENID-1-2-1-10-1-5-1-5-1-1-8-1-8-1-3-4"><title>Building the
+ROM with DMA included</title><p>Include the <filepath>DMA PIL</filepath> libraries
+in the final ROM image, in the list of buildrom parameters.</p><p>For more
+information, refer to <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">BUILDROM</xref> .</p></section>
+</conbody><related-links>
+<link href="GUID-0ADC2927-5AC9-5461-9A17-382FBB170067.dita"><linktext>ROM Tools
+Overview</linktext></link>
+<link href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita"><linktext>BUILDROM</linktext>
+</link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-AB5370D9-9F0B-4583-A825-11CBF7C6365C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-AB5370D9-9F0B-4583-A825-11CBF7C6365C" xml:lang="en"><title>DMA Tutorials Overview </title><shortdesc>How to use the DMA for different types of data transfers.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-AB9175EB-1B61-5341-B6B9-5613A7862D74.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,278 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-AB9175EB-1B61-5341-B6B9-5613A7862D74" xml:lang="en"><title>Channel
+Implementation</title><shortdesc>Describes how to implement <codeph>DComm</codeph> to drive a serial
+port hardware.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>A physical channel defines the interface between the logical device and
+the physical device. The Serial Port Driver physical channel interface is
+defined by the <codeph>DComm</codeph> class. </p>
+<p>The <codeph>DComm</codeph> class is defined in: <filepath>...\e32\include\drivers\comm.h</filepath>,
+which is exported to <filepath>epoc32\include\drivers</filepath>: </p>
+<codeblock id="GUID-F9E58262-51AA-5A58-A113-3FA994F00156" xml:space="preserve">class DComm : public DBase
+    {
+public:
+    virtual TInt Start() =0;
+    virtual void Stop(TStopMode aMode) =0;
+    virtual void Break(TBool aState) =0;
+    virtual void EnableTransmit() =0;
+    virtual TUint Signals() const =0;
+    virtual void SetSignals(TUint aSetMask,TUint aClearMask) =0;
+    virtual TInt ValidateConfig(const TCommConfigV01 &amp;aConfig) const =0;
+    virtual void Configure(TCommConfigV01 &amp;aConfig) =0;
+    virtual void Caps(TDes8 &amp;aCaps) const =0;
+    virtual void CheckConfig(TCommConfigV01&amp; aConfig)=0;
+    virtual TInt DisableIrqs()=0;
+    virtual void RestoreIrqs(TInt aIrq)=0;
+    virtual TDfcQue* DfcQ(TInt aUnit)=0;
+    inline TBool PowerGood(); 
+    inline void SetCurrent(TInt aCurrent);
+    inline void ReceiveIsr(TUint* aChar, TInt aCount, TInt aXonXoff);
+    inline TInt TransmitIsr();inline void CheckTxBuffer();
+    inline void StateIsr(TUint aSignals);
+    inline TBool Transmitting();
+public:
+    DChannelComm *iLdd;
+    TBool iTransmitting;
+    };
+</codeblock>
+<p>Note that <codeph>DComm</codeph> defines the minimum set of functions to
+be used by the LDD. A real physical channel object, typically, requires the
+addition of an interrupt handler, some DFC callback routines (if these are
+not handled in the LDD itself) and various other state variables. </p>
+<section id="GUID-B0D61B54-EDF3-4804-9B1E-370C36E01708"><title>DCommVariant constructor</title> <p>Implement the constructor
+for the channel object. Since there is no unit number argument, the constructor
+is limited to initialising only those members that are common across all possible
+channels, with no access to any specific hardware. </p> </section>
+<section id="GUID-550681C3-F1A6-4298-BAA5-C6F2D9D61624"><title>DCommVariant destructor</title> <p>Implement the destructor
+for the channel object. It should release any hardware and Symbian platform
+resources that have been allocated to the driver, typically unbinding the
+UART interrupt ISR, and any private DFCs that are still in use. The destructor
+merely unbinds the interrupt as no channel specific DFCs are active at destructor
+invocation. </p> </section>
+<section id="GUID-8254536B-E938-4B86-A735-798DD03E3456"><title>DoCreate()</title> <p>Implement the <codeph>DoCreate()</codeph> channel
+initialisation function for the UART driver. In general, defining a <codeph>DoCreate()</codeph> function
+is not mandated by the device driver framework but is useful for drivers that
+make use of unit numbers. This is called by the factory object’s <xref href="GUID-6DE69F29-45B0-5E62-AA13-DA4041B1BC46.dita#GUID-6DE69F29-45B0-5E62-AA13-DA4041B1BC46/GUID-48EF94F9-ACBC-58DA-9F0E-4034E56C6C74">Create()</xref> function after the device object’s allocation has succeeded. </p> <p>Typical
+operations performed by this function are to setup any channel specific hardware
+states and bind the driver’s ISR to the (possibly channel specific) interrupt
+channel, as well as enabling the UART hardware itself. However, since the <xref href="GUID-AB9175EB-1B61-5341-B6B9-5613A7862D74.dita#GUID-AB9175EB-1B61-5341-B6B9-5613A7862D74/GUID-0CAA6D27-FE2E-5569-8747-EB3D4976E7FD">Start()</xref> function
+has not yet been called, it should not enable the UART interrupts/poll routines
+which would actively buffer incoming data; any data I/O requests should be
+discarded until the driver’s <xref href="GUID-AB9175EB-1B61-5341-B6B9-5613A7862D74.dita#GUID-AB9175EB-1B61-5341-B6B9-5613A7862D74/GUID-0CAA6D27-FE2E-5569-8747-EB3D4976E7FD">Start()</xref> routine
+has been called. </p> </section>
+<section id="GUID-0CAA6D27-FE2E-5569-8747-EB3D4976E7FD"><title>Start()</title> <p> Implement
+the <codeph>Start()</codeph> function. This should enable the driver’s receive
+path.</p><p> Received characters are placed in the LDD upstream buffer, either
+by the interrupt handler routine, or by a polling routine that tests for the
+existence of received characters (and their associated error state). This
+is done by calling the LDD’s <codeph>ReceiveIsr()</codeph> routine, with a
+pointer to the buffered characters, a count and a flag indicating whether
+the XON or XOFF flow control characters have been received.</p><p>The function
+is called by the LDD when the owning thread opens the device channel. It should
+complete any UART data I/O enabling that has not already been performed in
+the <codeph>DoCreate()</codeph> function, i.e. the enabling of UART receive
+interrupt processing as a minimum. After this function returns, it is expected
+that incoming data will be placed in a (local) buffer and passed upstream
+to the LDD, until <xref href="GUID-AB9175EB-1B61-5341-B6B9-5613A7862D74.dita#GUID-AB9175EB-1B61-5341-B6B9-5613A7862D74/GUID-9428082D-581D-530B-8838-1DBF6D0EB8E7">Stop()</xref> is
+invoked. Note that since there may have been line activity prior to this call,
+it may be necessary to reset the UART state, as we do not want to report errors/states
+that may have occurred before the UART was (logically) enabled.</p></section>
+<section id="GUID-9428082D-581D-530B-8838-1DBF6D0EB8E7"><title>Stop()</title><p>Implement
+the <codeph>Stop()</codeph> function. This should disable the driver’s transmit
+and receive paths. </p><p>Depending on the type of stop requested, i.e. emergency
+power down, or otherwise, <codeph>Stop()</codeph> may not wait for the UART
+to finish transmitting any characters stored in the transmit FIFO queue. All
+receive paths are stopped instantly and any characters that may be in the
+receive FIFO queue are ignored. </p><p>The function is called by the LDD when
+the owning thread closes the device channel. At this point, the UART device
+should revert to the state in which all data I/O requests are ignored or failed.
+To save OS resources the natural method to accomplish this is to disable the
+UART interrupt processing or disable the UART itself. It may also be necessary
+to cancel any DFCs queued, so that event notifications are not sent to the
+LDD after it has requested an end to I/O. </p></section>
+<section id="GUID-5E4B6533-75F5-47FB-A4DF-55FAA1E1B973"><title>DfcQ()</title><p>Implement the <codeph>DfcQ()</codeph> function.
+This should return the DFC queue on which the LDD will install its DFCs. Usually
+the standard low priority kernel DFC queue 0 is returned. </p></section>
+<section id="GUID-ADC89B5B-0E29-4723-92E6-A6F1A5604710"><title>Break()</title><p>Implement the <codeph>Break()</codeph> function.
+This starts or ends a BREAK condition on the wire. </p><p>This operation is
+explicitly requested by the owning thread through the LDD. A break state requires
+the forcing of the line into an abnormal state, which violates standard data
+format timings (a form of out of band signalling), and is detected by the
+remote device and is usually used to force it to cycle through its baud rate
+detection modes. Forcing a break state requires that the PDD explicitly set
+some state in the UART hardware. </p></section>
+<section id="GUID-82A259A7-54F7-536A-B829-31C0AF3C5C81"><title>Signals()</title><p>Implement
+the <codeph>Signals()</codeph> function. This returns the state of the flow
+and MODEM control inputs, ie. DCD, DSR, CTS and RI (if implemented on the
+device itself). This function is called by the LDD to return the state of
+all the handshaking lines so that it can decide whether further data I/O operations
+are allowed. </p></section>
+<section id="GUID-492D86E5-BEEF-4408-B6E0-6DDA1244CA74"><title>SetSignals()</title><p>Implement the <codeph>SetSignals()</codeph> function.
+This controls the state of the flow and MODEM control outputs. It is used
+by the LDD to control MODEM handshaking and line failure detection, and can
+be invoked in response to a specific user request to change the handshake
+signal’s state, or when the LDD itself decides that the output lines states
+should be changed in response to some transfer state (e.g. requesting no further
+transmissions if buffer availability runs low). </p></section>
+<section id="GUID-CB1FA26C-5D29-50ED-AF40-8CC579AF776F"><title>Caps()</title><p>Implement
+the <codeph>Caps()</codeph> function. This returns the driver supported configurations:
+speed, format, and handshaking. </p><p>It is called by the LDD in response
+to a user request for the device's capabilities. The PDD must fill a <xref href="GUID-98A18771-CA6D-3B68-8784-449CDBEC3D88.dita"><apiname>TCommCapsV02</apiname></xref> object,
+with the capabilities for that port. </p><p>The object is defined in <filepath>d32comm.h</filepath>: </p><codeblock id="GUID-A95D8753-E574-5C86-85DC-6AA10F635612" xml:space="preserve">class TCommCapsV01
+    {
+public:
+    TUint iRate;
+    TUint iDataBits;
+    TUint iStopBits;
+    TUint iParity;
+    TUint iHandshake;
+    TUint iSignals;
+    TUint iFifo;
+    TUint iSIR;
+    };
+
+class TCommCapsV02 : public TCommCapsV01
+    {
+public:
+    TUint iNotificationCaps;
+    TUint iRoleCaps;
+    TUint iFlowControlCaps;
+    };</codeblock> <p>The base object, <xref href="GUID-BDBB61A7-18BC-3C85-A258-77D8B16621AD.dita"><apiname>TCommCapsV01</apiname></xref>, defines
+capabilities in terms of: </p> <ul>
+<li id="GUID-7AE03D23-1013-5522-B219-23153E1B7798"><p>data rate </p> </li>
+<li id="GUID-E2FBD4C1-B704-592A-B3A2-1BCFFC7E5451"><p>word format (i.e. parity,
+data bits, stop bits) </p> </li>
+<li id="GUID-525050DD-8ACE-5580-BDF7-3717295D704E"><p>flow control lines </p> </li>
+<li id="GUID-B5DBE4E6-8184-522A-856A-9BD17E76FF33"><p>MODEM control lines </p> </li>
+<li id="GUID-62ACC296-4B9B-59D3-8531-480E04264FE0"><p>IrDA support. </p> </li>
+</ul> <p>Each attribute range is passed as a bitfield of possible settings,
+all assumed to be orthogonal, i.e. each attribute can assume all the values
+independently of the other attributes. </p> <p>The attribute bitfields are
+defined in <filepath>d32comm.h</filepath>. </p> <p>The <codeph>iSIR</codeph> attribute
+in <xref href="GUID-BDBB61A7-18BC-3C85-A258-77D8B16621AD.dita"><apiname>TCommCapsV01</apiname></xref> indicates whether the port can support
+slow infrared protocol. </p> <p>The <codeph>iNotificationCaps</codeph> attribute
+in <xref href="GUID-98A18771-CA6D-3B68-8784-449CDBEC3D88.dita"><apiname>TCommCapsV02</apiname></xref> allows the driver to describe its ability
+to report asynchronous events, if requested to do so by the client thread.
+The only useful applications seem to be to report data arrival and handshake
+line status change, although fields exist for other capabilities. </p> <p>The <codeph>iRoleCaps</codeph> attribute
+in <xref href="GUID-98A18771-CA6D-3B68-8784-449CDBEC3D88.dita"><apiname>TCommCapsV02</apiname></xref> is intended to indicate that the device
+is capable of acting as a DCE as well as a DTE, i.e. that the port can be
+configured to act like a MODEM port. This essentially reverses the normal
+I/O of the status lines, and could add functionality such as ring indication.
+Normal UART devices will never need to change this field from the default,
+i.e. DTE device personality. </p> <p>The <codeph>iFlowControlCaps</codeph> field
+in <xref href="GUID-98A18771-CA6D-3B68-8784-449CDBEC3D88.dita"><apiname>TCommCapsV02</apiname></xref> is unused and should be set to 0. </p> <p>The <codeph>iHandshake</codeph> field
+in <xref href="GUID-BDBB61A7-18BC-3C85-A258-77D8B16621AD.dita"><apiname>TCommCapsV01</apiname></xref> describes the flow control signal support
+on the device. Input signals have attributes “Obey” and “Fail” e.g. ObeyCts,
+FailCts. Output signals have only the “Free” attribute, which indicates they
+can be driven (via a call to <xref href="GUID-AB9175EB-1B61-5341-B6B9-5613A7862D74.dita#GUID-AB9175EB-1B61-5341-B6B9-5613A7862D74/GUID-82A259A7-54F7-536A-B829-31C0AF3C5C81">Signals()</xref>)
+to any state, independent of the internal state of the UART, i.e. they are
+entirely under LDD control. The Fail attribute implies that the LDD will deem
+operations to have failed if an input line thus labelled becomes disasserted.
+This means that the PDD can report these signal states asynchronously. If,
+for example, a change in CTS state can generate an interrupt, then the PDD
+should report it as possessing both Obey and Fail attributes, whereas if the
+DCD line cannot generate an asynchronous event, it should merely present itself
+as “Obey”. If the line is unimplemented then neither attribute should be reported. </p> </section>
+<section id="GUID-DA860E4A-4240-4C16-B1C0-5E9B7C96F9E8"><title>Configure()</title> <p>Implement the <codeph>Configure()</codeph> function.
+This configures the UART device according to the configuration data passed
+into the function. </p> <p>Configuration data is encapsulated by a <xref href="GUID-0CBAE946-AB8E-3114-89FC-9591125C4BDC.dita"><apiname>TCommConfigV02</apiname></xref> object: </p> <codeblock id="GUID-275DAD25-9EF9-5084-A82B-8E2392CB14E8" xml:space="preserve">class TCommConfigV01
+    {
+public:
+    TBps iRate;
+    TDataBits iDataBits;
+    TStopBits iStopBits;
+    TParity iParity;
+    TUint iHandshake;
+    TUint iParityError;
+    TUint iFifo;
+    TInt iSpecialRate;
+    TInt iTerminatorCount;
+    TText8 iTerminator[KConfigMaxTerminators];
+    TText8 iXonChar;
+    TText8 iXoffChar;
+    TText8 iParityErrorChar;
+    TSir iSIREnable;
+    TUint iSIRSettings;
+    };
+
+class TCommConfigV02: public TCommConfigV01
+    {
+public:
+    TInt iTxShutdownTimeout;
+    };
+</codeblock> <p>This function is called by the LDD when the physical channel
+is opened. The default configuration is set by the LDD when the <codeph>Dcomm</codeph> object
+is constructed, but the user can override the configuration with a <codeph>SetConfig</codeph> request
+on the opened channel. The configuration is described by specifying a set
+of individual capability attributes from the supported ranges returned in
+the <xref href="GUID-AB9175EB-1B61-5341-B6B9-5613A7862D74.dita#GUID-AB9175EB-1B61-5341-B6B9-5613A7862D74/GUID-CB1FA26C-5D29-50ED-AF40-8CC579AF776F">Caps()</xref> call. </p> <p>Note
+that the <codeph>iTerminatorCount</codeph>, the <codeph>iTerminatorArray</codeph> and<codeph> iSpecialRate</codeph> are
+currently unused. The <codeph>iParityErrorChar</codeph> replaces the character
+that the UART determined had a parity violation. This can be used to send
+a prearranged escape character to the upstream LDD. </p> </section>
+<section id="GUID-509C63E0-09D9-48F1-8ECB-F18377B73E8A"><title>CheckConfig()</title> <p>Implement the <codeph>CheckConfig()</codeph> function.
+This is used by autosensing UARTs to pass detected configuration upstream
+to the LDD. This is called by the LDD when it creates the initial channel
+to allow the autosensed state to override any default it has set. If the UART
+device cannot perform autosensing, and most cannot, then the <codeph>CheckConfig()</codeph> function
+should leave the parameter buffer unchanged. </p> </section>
+<section id="GUID-6F26F95A-7115-4E07-BA72-7AEF75DC2912"><title>ValidateConfig()</title> <p>Implement the <codeph>ValidateConfig()</codeph> function.
+This returns true if the specified configuration is supported by the driver.
+This should never return false if the correct capabilities have been setup,
+but may be used to check for cases where, for example, a specific set of attributes
+cannot be applied together. As an example, a data format word size may not
+be generated for some specific baud rate. </p> </section>
+<section id="GUID-10FB213C-47B3-4CFF-AB2B-5868AE4531E0"><title>DisableIrqs()</title> <p>Implement the <codeph>DisableIrqs()</codeph> function.
+This is called by the LDD to disable (all) interrupts during critical sections,
+for example, during LDD buffer manipulation. It calls the kernel utility to
+perform the task. </p> </section>
+<section id="GUID-BFE0DF32-3D2A-4D86-8BEE-6EB5AF32C3BB"><title>RestoreIrqs()</title> <p>Implement the <codeph>RestoreIrqs()</codeph> function,
+called by the LDD to enable (all) interrupts after critical sections have
+completed. Calls the kernel utility to perform the task. </p> </section>
+<section id="GUID-96B9D6FE-1E2C-45C0-B7F4-E5CF9B5BD802"><title>EnableTransmit()</title> <p>Implement the <codeph>EnableTransmit()</codeph> function.
+This initialises the UART transmit hardware, and the transmit ISR code path.
+This function can be called from the ISR (on receipt of an unblocking XON
+character), or to start a transmission of a LDD originated data buffer. It
+causes the UART to generate Tx service interrupts as it finishes transmitting
+a FIFOs worth of data, so that the entire buffer (passed by the LDD) can be
+sent under interrupt control. </p> </section>
+<section id="GUID-593C5E94-A188-48C4-BB02-07268735270A"><title>Data handling routines</title> <p>Implement the main data
+handling routines. These are entirely dependent on the UART hardware interface
+and cannot therefore be described generally. They are typically driven by
+the interrupt service routine as asynchronous events from the UART (eg. data
+received, finished transmission of data, change in handshaking/flow control
+inputs) occur. </p> <p>The main ISR is typically driven by an interrupt multiplexed
+from all the sources in the UART. The ISR, therefore, needs to determine which
+of the interrupt sources requires attention. Since the most critical source
+is the data received state, as this requires that the data is processed before
+following data overwrites earlier data, then this is usually the signal to
+be checked first. To avoid wasting time, the error state of the data is also
+checked – data that has bad parity or framing must be noted as such. Typically
+the receive path will save the currently available data into a temporary buffer,
+and queue a DFC to process the data further at a later time, when more client
+thread context is available (though this is a function of the LDD). The receive
+ISRr just passes the location of the ISR buffer into an LDD function which
+queues a DFC to process it. </p> <p>The transmit path, called when the transmit
+FIFO contents drop below a programmable number, merely requests more data
+from the LDD. If there is none available it disables the transmit interrupt
+so as to prevent further requests when there is no data to be sent. Further
+data to transmit will cause the transmit FIFO empty interrupt to be re-enabled.
+Hence the start of any transmission is always performed on an explicit start
+request from the LDD and then continues under PDD interrupt control until
+the source data is exhausted. </p> <p>The status notification path is present
+to inform the upstream LDD of changes in the input status signals (MODEM and
+flow control status). The UART can generate interrupts when any input handshake
+line changes state – the ISR merely reads the current state and queues a handler
+DFC so that the LDD can be informed. The LDD is responsible for determining
+what status change has occurred and dealing with it. </p> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-ABE7BC1A-C51B-5ADD-8568-87A81423B648-master.png has changed
Binary file Adaptation/GUID-ABE7BC1A-C51B-5ADD-8568-87A81423B648_d0e77808_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-AC2E5824-4E69-4964-968F-839EB5D2EF4F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE reference
+  PUBLIC "-//OASIS//DTD DITA Reference//EN" "reference.dtd">
+<reference id="GUID-AC2E5824-4E69-4964-968F-839EB5D2EF4F" xml:lang="en"><title>Board Support Package (BSP)</title><shortdesc>A BSP provides hardware-specific support code for a given
+hardware reference board. A package may be delivered as a single component
+or in multiple components. </shortdesc><prolog><metadata><keywords/></metadata></prolog><refbody>
+<section id="GUID-6B2A1BCB-0A51-45AB-A4A9-6696C3D58644"> 			 		</section>
+</refbody></reference>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-AC560324-798C-5D0A-B23D-2419A7688A5B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,583 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-AC560324-798C-5D0A-B23D-2419A7688A5B" xml:lang="en"><title>Channel
+Implementation</title><shortdesc>Describes how to implement the physical channels with the template
+port. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>A Sound Driver PDD must implement physical channels to use the audio hardware
+of the phone. The main Sound Driver PDD class is derived from <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita"><apiname>DSoundScPdd</apiname></xref>.
+A Sound Driver PDD that provides record and playback functions must implement
+a record driver channel and a playback driver channel. </p>
+<p>The template defines two classes: <codeph>DTemplateSoundScRxPdd</codeph> and <codeph>DTemplateSoundScTxPdd</codeph>,
+corresponding to record and playback respectively. The classes provide default
+implementations for the virtual functions defined by <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita"><apiname>DSoundScPdd</apiname></xref>,
+together with a constructor and destructor, and typically need little or no
+modification. </p>
+<section id="GUID-61725EEB-5114-5A85-9C28-57A47F14000C"><title>PDD class constructor</title> <p>Implement
+the PDD class constructor for both the playback and record driver channels.
+This is normally limited to </p> <ul>
+<li id="GUID-E02B0EE1-5171-5E9F-9BFE-FFAB6E15B290"><p>initialising any data
+members that need values other than zero </p> </li>
+<li id="GUID-4B39AEC4-0A02-5099-9805-F35B2AF4AD90"><p>initialising any DFC
+call-backs added. </p> </li>
+</ul> <p>Access to hardware has the potential to fail and so should be deferred
+to the second stage constructor <xref href="GUID-AC560324-798C-5D0A-B23D-2419A7688A5B.dita#GUID-AC560324-798C-5D0A-B23D-2419A7688A5B/GUID-F66BF339-FCE6-5859-87D1-7A0B0ED69D84">DoCreate()</xref>. </p> </section>
+<section id="GUID-CD12E6E9-C363-5CF9-91E1-694C34DE2BD9"><title>PDD class destructor</title> <p>Implement
+the PDD class destructor for both the playback and record driver channels.
+The destructor must release any hardware and Symbian platform resources that
+have been allocated to the driver. For example, this might include: </p> <ul>
+<li id="GUID-6D33C44B-B88F-504B-B750-FF010A72A290"><p>unbinding ISRs </p> </li>
+<li id="GUID-9DF0D93B-6782-5E94-80EB-A806BC1AB6B9"><p>cancelling private DFCs </p> </li>
+<li id="GUID-157C24A6-52F6-5BF1-BF94-035394F274F5"><p>closing DMA channels </p> </li>
+<li id="GUID-47452140-FA8E-55A8-BE2D-32AC87FF215E"><p>deleting any mono-to-stereo
+conversion buffers </p> </li>
+</ul> <p>The template versions of this function delete each DMA request object
+created in the PDD second stage constructor <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-C0CA28E4-2356-333D-B708-CBE469F1614F"><apiname>DSoundScPdd::DoCreate()</apiname></xref> and
+close the DMA channel. </p> </section>
+<section id="GUID-F66BF339-FCE6-5859-87D1-7A0B0ED69D84"><title>DoCreate()</title> <p>Implement
+a PDD class second stage constructor for both the playback and record driver
+channels. In the template version, the function <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-C0CA28E4-2356-333D-B708-CBE469F1614F"><apiname>DSoundScPdd::DoCreate()</apiname></xref> is
+called from the PDD factory when a channel is opened on the device. Generally,
+any hardware or Symbian platform resources required by the driver
+channel should be acquired here. However, powering up the sound device should
+be deferred to the <xref href="GUID-AC560324-798C-5D0A-B23D-2419A7688A5B.dita#GUID-AC560324-798C-5D0A-B23D-2419A7688A5B/GUID-B72057E6-B93C-505F-9789-83251D09B78E">PowerUp()</xref> function.
+Operations performed by this function include: </p> <ul>
+<li id="GUID-C3E2E6ED-14AE-52D1-9F11-618DCE7D2C1E"><p>binding an ISR to an
+audio related interrupt </p> </li>
+<li id="GUID-129BD014-9302-50AE-A33B-728D40DBF428"><p>open a DMA channel </p> </li>
+<li id="GUID-51B51BEC-B8B8-50CF-8618-BB0B5B00F999"><p>allocate a mono-to-stereo
+conversion buffer </p> </li>
+</ul> <p>The template versions of this function include code to set up a DMA
+channel. This involves opening a DMA channel in the appropriate direction
+for the driver channel and then allocating a set of DMA request objects. However,
+to use this implementation you must supply the missing platform specific information: </p> <ul>
+<li id="GUID-64F62CF9-9D26-5E39-A632-39DF91AB1E98"><p>Provide values for the
+maximum number of DMA requests outstanding on the DMA channel. These values
+determine the number of separate DMA request objects allocated for the DMA
+channel, and so the number of transfer fragments that the PDD can accept from
+the LDD at any time. See <xref href="GUID-15FDDEED-89F1-5BE5-97AD-8DFD3640369A.dita">playback</xref> and <xref href="GUID-4AEF7595-17C0-513E-9568-B212E6194388.dita">record</xref>. </p> </li>
+<li id="GUID-60C86EBD-B26F-501D-B7D5-CE113D4368C0"><p>Set the appropriate
+DMA values for your device within the file <filepath>soundsc_plat.h</filepath>.
+These values, renamed in section <xref href="GUID-C6ABE2CA-901E-55F1-9837-7018A1612BCF.dita">copying
+the template port implementation</xref> to reflect your device name, are <codeph>KTemplateMaxTxDmaRequests</codeph> or <codeph>KTemplateMaxRxDmaRequests</codeph> for playback and record respectively. </p> </li>
+<li id="GUID-BBF4F320-22A7-54AE-ACD1-6C10138F5031"><p>Setup the DMA channel
+information for the device. This includes the following members of <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita#GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37/GUID-6B973278-8BE7-3CE5-97D8-60E8D3F4D473"><apiname>TDmaChannel::SCreateInfo</apiname></xref>. </p> <ul>
+<li id="GUID-084CF2BA-308D-5F32-9BC2-C5B39DEC497B"><p> <codeph>iCookie</codeph>:
+The platform specific ID used by the DMA controller to select the DMA channel
+to open. </p> </li>
+<li id="GUID-7EE1F596-9FB5-5C29-8130-097CE6129F91"><p> <codeph>iDesCount</codeph>:
+The number of DMA descriptors the DMA controller should create. This is typically
+set with the same value as <codeph>KTemplateMaxTxDmaRequests</codeph> or <codeph>KTemplateMaxRxDmaRequests</codeph>. </p> </li>
+<li id="GUID-0B12DDF1-AC34-5592-AC55-E0363C60449A"><p> <codeph>iDfcQ</codeph>:
+The DFC queue to use to service DMA interrupts. This should point to the same
+DFC queue that is returned to the LDD for client request handling. See the <xref href="GUID-AC560324-798C-5D0A-B23D-2419A7688A5B.dita#GUID-AC560324-798C-5D0A-B23D-2419A7688A5B/GUID-32C77B77-76CE-54AE-B791-28A7DD309A7D">DfcQ()</xref> section. </p> </li>
+<li id="GUID-AE4E59DD-4FBB-54A8-BE79-F4138AB34D5C"><p> <codeph>iDfcPriority</codeph>:
+The DFC priority. This should be set to a higher value than that used by the
+LDD for handling client requests. For example, higher than one. </p> </li>
+</ul> </li>
+</ul> </section>
+<section id="GUID-32C77B77-76CE-54AE-B791-28A7DD309A7D"><title>DfcQ()</title> <p>Make
+sure that the template version of the <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-C41B9733-BE86-3CF1-83A7-150EC9D35249"><apiname>DSoundScPdd::DfcQ()</apiname></xref> function
+is appropriate for your configuration. This function has the following signature: </p> <codeblock id="GUID-28E301B7-C032-5F6E-BCA7-A6D20FC541EA" xml:space="preserve">TDfcQue* DfcQ()</codeblock> <p>The
+supplied implementation is as follows </p> <codeblock id="GUID-D95DC9F9-C68A-50E2-ADA6-8D1268A18147" xml:space="preserve">TDfcQue* DTemplateSoundScTxPdd::DfcQ()
+    {
+    return(iPhysicalDevice-&gt;iDfcQPtr);
+    }</codeblock> <p>Many requests are executed in the context of a kernel-side
+thread. Rather than assign a kernel thread for the driver in the LDD, the
+Sound Driver allows the PDD to specify the DFC thread returned via the <xref href="GUID-71190437-912E-3E23-8E68-4FA8FF913D7A.dita"><apiname>DfcQ()</apiname></xref> function,
+which it calls when the driver channel is opened. </p> <p>The default implementation
+for the record and playback driver channels, returns a pointer to the DFC
+queue created by the PDD factory class. </p> <p>See also <xref href="GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F.dita">Implementing
+the PDD factory</xref>  </p> </section>
+<section id="GUID-B549F062-061D-5876-AB43-AC10C62477EE"><title>GetChunkCreateInfo()</title> <p>Implement
+the <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-9F845935-A6AA-320B-AF09-F121F95C44B2"><apiname>DSoundScPdd::GetChunkCreateInfo()</apiname></xref> function for both
+the playback and record driver channels. This function has the following signature: </p> <codeblock id="GUID-934D39E5-5DDE-5165-BCED-255CA6D0B0F2" xml:space="preserve">void DSoundScPdd::GetChunkCreateInfo(TChunkCreateInfo&amp; aChunkCreateInfo)</codeblock> <p>The
+supplied implementation is as follows: </p> <codeblock id="GUID-47334636-5E5D-59CF-A894-62747DD648BD" xml:space="preserve">void DTemplateSoundScTxPdd::GetChunkCreateInfo(TChunkCreateInfo&amp; aChunkCreateInfo)
+    {
+    __KTRACE_SND(Kern::Printf("&gt;DTemplateSoundScTxPdd::GetChunkCreateInfo"));
+
+    // TO DO: (mandatory)
+    // Setup the shared chunk create information in aChunkCreateInfo for this play device.
+    aChunkCreateInfo.iType=TChunkCreateInfo::ESharedKernelMultiple;
+    // aChunkCreateInfo.iMapAttr=???
+    aChunkCreateInfo.iOwnsMemory=ETrue;                 // Using RAM pages.
+    aChunkCreateInfo.iDestroyedDfc=NULL;                // No chunk destroy DFC.
+    }</codeblock> <p>The PDD must initialise the <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita"><apiname>TChunkCreateInfo</apiname></xref> object
+with the information that defines the characteristics of the shared chunk
+required for the audio device. This function is called by the LDD just before
+it creates a shared chunk for the channel, in response to an <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-1978D84C-6E2A-39C0-AF5F-17C85E5B25B4"><apiname>RSoundSc::SetBufferChunkCreate()</apiname></xref> request
+from the client. </p> <p>Values for the following data members must be supplied
+by the PDD: </p> <ul>
+<li id="GUID-10F7ED98-299F-5D90-A7EC-85BD97BBECEF"><p> <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita#GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4/GUID-4384AF76-CECE-3B86-BE92-375C1DEA36DA"><apiname>TChunkCreateInfo::iType</apiname></xref>  </p> </li>
+<li id="GUID-10159693-8680-5CD7-88C8-A967DDC53024"><p> <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita#GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4/GUID-4D355352-04CA-34D2-B1F4-684E07E7DDE9"><apiname>TChunkCreateInfo::iMapAttr</apiname></xref>  </p> </li>
+<li id="GUID-06459B1A-5D5A-5013-912D-0C52E7FD398A"><p> <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita#GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4/GUID-106850A0-5498-387F-AF70-F9D04EB6318D"><apiname>TChunkCreateInfo::iOwnsMemory</apiname></xref>  </p> </li>
+<li id="GUID-D8DE49EB-04D5-50BA-8CEA-7EFFA7584A74"><p> <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita#GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4/GUID-58271733-146A-3ECB-91AC-C38BD2ADC9A0"><apiname>TChunkCreateInfo::iDestroyedDfc</apiname></xref>  </p> </li>
+</ul> <p>The data member <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita#GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4/GUID-3BE6D452-84D0-3E80-8238-7A9114A89ED5"><apiname>TChunkCreateInfo::iMaxSize</apiname></xref> is
+calculated by the LDD so there is no need to define it. </p> <p>See <xref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita">How to share chunks</xref>. </p> </section>
+<section id="GUID-9D4D9F06-8C88-51C1-9E29-D0B95B523A8D"><title>Caps()</title> <p>Implement
+the <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-B80B86C6-696A-37AA-9ACD-2BC76B88762C"><apiname>DSoundScPdd::Caps()</apiname></xref> function for both the playback
+and record driver channels. The function has the following signature: </p> <codeblock id="GUID-8306A135-350C-5F8D-B51D-F8A2EED41244" xml:space="preserve">void DSoundScPdd::Caps(TDes8&amp; aCapsBuf) const</codeblock> <p>The
+supplied implementation is as follows: </p> <codeblock id="GUID-27BE7DD7-D42B-54BA-AC77-1201C1F09F68" xml:space="preserve">void DTemplateSoundScTxPdd::Caps(TDes8&amp; aCapsBuf) const
+    {
+    __KTRACE_SND(Kern::Printf("&gt;DTemplateSoundScTxPdd::Caps"));
+    
+    // Copy iCaps back.
+    TPtrC8 ptr((const TUint8*)&amp;iCaps,sizeof(iCaps));
+    aCapsBuf.FillZ(aCapsBuf.MaxLength());
+    aCapsBuf=ptr.Left(Min(ptr.Length(),aCapsBuf.MaxLength()));      
+    }</codeblock> <p> <xref href="GUID-39915413-31A6-360F-9758-5DBDF9D70103.dita"><apiname>TSoundFormatsSupportedV02</apiname></xref> is the
+main audio capabilities class. The PDD must fill this object with the capabilities
+for the particular audio device. the LDD uses this to get the play or record
+capabilities of a particular sound device once a driver channel to the device
+has been opened. </p> <p>Values for the following variables must be supplied
+by the PDD: </p> <ul>
+<li id="GUID-2F03F186-D9AF-5431-B3F8-D3B794352208"><p> <xref href="GUID-39915413-31A6-360F-9758-5DBDF9D70103.dita#GUID-39915413-31A6-360F-9758-5DBDF9D70103/GUID-1FE2868A-1823-308A-B1C9-2DAD557F6F3A"><apiname>TSoundFormatsSupportedV02::iDirection</apiname></xref>  </p> <ul>
+<li id="GUID-053B114E-2A52-53FD-912F-F8FF890601C4"><p> <xref href="GUID-AF772B74-0D5F-3270-BA61-2503BA5DFE6B.dita"><apiname>ESoundDirRecord</apiname></xref>  </p> </li>
+<li id="GUID-CEADC6F1-6016-5AB1-9349-EEFB63EF26AA"><p> <xref href="GUID-708043EB-5ED5-3923-B41A-321AD7DF3D8C.dita"><apiname>ESoundDirPlayback</apiname></xref>  </p> </li>
+</ul> </li>
+<li id="GUID-95FC1D2B-BBFB-52DC-ADE3-BA980E7E46F3"><p> <xref href="GUID-39915413-31A6-360F-9758-5DBDF9D70103.dita#GUID-39915413-31A6-360F-9758-5DBDF9D70103/GUID-75B0E2F7-44BE-3A97-B482-E1CB29D9F2E5"><apiname>TSoundFormatsSupportedV02::iChannels</apiname></xref>  </p> <ul>
+<li id="GUID-998425C3-E73B-5DB4-94F8-10BDCFBBE779"><p> <xref href="GUID-65BCF594-59A1-335F-AADB-1920E7AD3F71.dita"><apiname>KSoundMonoChannel</apiname></xref>  </p> </li>
+<li id="GUID-7D5EE578-16AC-56A0-B064-6000F5A9C2DF"><p> <xref href="GUID-4E63CE9C-C604-3B2C-993D-9A0502A39064.dita"><apiname>KSoundStereoChannel</apiname></xref>  </p> </li>
+<li id="GUID-0C17CB17-7452-5A1A-B76D-75A57960BDE8"><p> <xref href="GUID-30E8F803-39E1-3F53-AB5A-3B593BC1D69F.dita"><apiname>KSoundThreeChannel</apiname></xref>  </p> </li>
+<li id="GUID-E1DE0CD0-DD63-5140-A5C5-7141A5E9632D"><p> <xref href="GUID-BD021640-3457-3721-9DF1-A15EE8A874AC.dita"><apiname>KSoundFourChannel</apiname></xref>  </p> </li>
+<li id="GUID-E59E9D5E-F360-52FD-A0D0-C7CDAE5593DC"><p> <xref href="GUID-3E3B5485-F69B-3ECC-A0A4-12183444E61F.dita"><apiname>KSoundFiveChannel</apiname></xref>  </p> </li>
+<li id="GUID-56DD5098-0C0C-5175-B375-766FE628C359"><p> <xref href="GUID-83C9F5FE-DE44-3940-B738-BD4486293C39.dita"><apiname>KSoundSixChannel</apiname></xref>  </p> </li>
+</ul> </li>
+<li id="GUID-A6847CF6-48DC-510E-BCFF-33E7E5FB0161"><p> <xref href="GUID-39915413-31A6-360F-9758-5DBDF9D70103.dita#GUID-39915413-31A6-360F-9758-5DBDF9D70103/GUID-1F79E9BB-BF7C-31AD-AA0C-A85748F4231A"><apiname>TSoundFormatsSupportedV02::iRates</apiname></xref>  </p> <ul>
+<li id="GUID-99377F03-BA89-5DB0-AC4D-5F8892EB1F65"><p> <xref href="GUID-F98BADA5-852B-3859-B74A-B9747F79A754.dita"><apiname>KSoundRate7350Hz</apiname></xref>  </p> </li>
+<li id="GUID-99FFC99B-740B-5809-9C75-C8CC1157F4E3"><p> <xref href="GUID-47512813-5787-3328-9980-399AA782E6A2.dita"><apiname>KSoundRate8000Hz</apiname></xref>  </p> </li>
+<li id="GUID-D2C75BB5-5D8B-556B-A5BF-6A8C24D07D74"><p> <xref href="GUID-A622C93B-DF18-359D-B74A-0F90695900B7.dita"><apiname>KSoundRate8820Hz</apiname></xref>  </p> </li>
+<li id="GUID-83D98EBD-AD0E-588E-8CFD-59B44C22FE6A"><p> <xref href="GUID-165180AC-1227-30BF-97DA-860C3AC3AA4E.dita"><apiname>KSoundRate9600Hz</apiname></xref>  </p> </li>
+<li id="GUID-8D99D6B7-7FA7-5B8A-BEB9-2D982273C201"><p> <xref href="GUID-8DF1D395-4AC1-38AA-9F6A-C8867B1F4A60.dita"><apiname>KSoundRate11025Hz</apiname></xref>  </p> </li>
+<li id="GUID-98353A3A-EFAC-5B6C-A779-8F12BB9150BA"><p> <xref href="GUID-512150A4-0796-3016-9CBC-83117E2930ED.dita"><apiname>KSoundRate12000Hz</apiname></xref>  </p> </li>
+<li id="GUID-C27DD198-13FA-522A-9079-0BAA37094E16"><p> <xref href="GUID-892B4698-4914-348B-AB88-A1AC33D1E5EE.dita"><apiname>KSoundRate14700Hz</apiname></xref>  </p> </li>
+<li id="GUID-71087DE2-06A9-536A-94DF-74FFFCB2F0DF"><p> <xref href="GUID-1A199051-5D76-396B-AA44-89506A128BFF.dita"><apiname>KSoundRate16000Hz</apiname></xref>  </p> </li>
+<li id="GUID-666FA027-30AF-593B-894B-443B5C57E2DF"><p> <xref href="GUID-4021CE80-6667-36BB-9839-583E84AB9E83.dita"><apiname>KSoundRate22050Hz</apiname></xref>  </p> </li>
+<li id="GUID-9D0D7E14-1FBE-5C80-A108-D3903D57ED49"><p> <xref href="GUID-73C38AA3-92AD-3EF0-BF60-3A207CD29C0E.dita"><apiname>KSoundRate24000Hz</apiname></xref>  </p> </li>
+<li id="GUID-721DCA57-6E9B-5B02-9EA4-7640C652C5CE"><p> <xref href="GUID-9092C33B-C406-3044-AC8F-885F3EAE8B86.dita"><apiname>KSoundRate29400Hz</apiname></xref>  </p> </li>
+<li id="GUID-5362CD78-1981-559B-9E1B-C999CDC8E3D9"><p> <xref href="GUID-0237DB93-3C16-3DCF-836E-CDECE95EAB1E.dita"><apiname>KSoundRate32000Hz</apiname></xref>  </p> </li>
+<li id="GUID-61D0A788-2160-538F-82DB-414E6A34EC97"><p> <xref href="GUID-D3045D52-3092-3CCA-9AA5-05DE1ACAB92C.dita"><apiname>KSoundRate44100Hz</apiname></xref>  </p> </li>
+<li id="GUID-28474DAC-AD25-506B-9112-F56825F845D2"><p> <xref href="GUID-DBD2AD6A-79F9-3D94-B6CB-1ED1E45F401A.dita"><apiname>KSoundRate48000Hz</apiname></xref>  </p> </li>
+</ul> </li>
+<li id="GUID-CB112345-C035-5F7E-9AE5-B5222FF4F0A9"><p> <xref href="GUID-39915413-31A6-360F-9758-5DBDF9D70103.dita#GUID-39915413-31A6-360F-9758-5DBDF9D70103/GUID-21F664A7-046E-3B1F-8C0B-A8B0EC0EC16C"><apiname>TSoundFormatsSupportedV02::iEncodings</apiname></xref>  </p> <ul>
+<li id="GUID-F5833DD3-D273-5B62-9F4B-FEEC51D8CDF2"><p> <xref href="GUID-5BE58F42-47B2-3EB8-9F3B-DEF019C79499.dita"><apiname>KSoundEncodings8BitPCM</apiname></xref>  </p> </li>
+<li id="GUID-B58CB616-CDCD-5CD0-AEC4-622F5AAB2474"><p> <xref href="GUID-790BA733-2B34-33B2-BF7B-7113DB1856A6.dita"><apiname>KSoundEncodings16BitPCM</apiname></xref>  </p> </li>
+<li id="GUID-A4019328-CC8B-5224-8808-F3822230C389"><p> <xref href="GUID-EAB5A509-B0D6-3E2F-8106-D87A7C9D504F.dita"><apiname>KSoundEncodings24BitPCM</apiname></xref>  </p> </li>
+</ul> </li>
+<li id="GUID-52DDB751-925B-5CC5-81F9-6F65A9D2039E"><p> <xref href="GUID-39915413-31A6-360F-9758-5DBDF9D70103.dita#GUID-39915413-31A6-360F-9758-5DBDF9D70103/GUID-7950BC29-5C2E-34E0-B037-DDDDE0261DB7"><apiname>TSoundFormatsSupportedV02::iDataFormats</apiname></xref>  </p> <ul>
+<li id="GUID-AD7EA560-7914-5D9D-B548-14DB3FA4AC7A"><p> <xref href="GUID-E02D661C-430F-306F-BD12-42238A91D83A.dita"><apiname>KSoundDataFormatInterleaved</apiname></xref>  </p> </li>
+<li id="GUID-36EAAA69-B18A-555A-9646-FB8F6EC66505"><p> <xref href="GUID-ACC09AC6-A29B-3926-8AE4-4DA60416A3C1.dita"><apiname>KSoundDataFormatNonInterleaved</apiname></xref>  </p> </li>
+</ul> </li>
+<li id="GUID-905CC707-760B-52F3-A942-0ADA02B69FA8"><p> <xref href="GUID-39915413-31A6-360F-9758-5DBDF9D70103.dita#GUID-39915413-31A6-360F-9758-5DBDF9D70103/GUID-6F2D37B3-C465-3C77-A861-7FF9061F8EB9"><apiname>TSoundFormatsSupportedV02::iRequestMinSize</apiname></xref>  </p> </li>
+<li id="GUID-8FCD4F3E-F70F-5E1B-8952-B667DC9D4AD2"><p> <xref href="GUID-39915413-31A6-360F-9758-5DBDF9D70103.dita#GUID-39915413-31A6-360F-9758-5DBDF9D70103/GUID-472BCD65-11CE-3AEE-8DAE-9E56523AC096"><apiname>TSoundFormatsSupportedV02::iRequestAlignment</apiname></xref>  </p> </li>
+<li id="GUID-749CE201-0554-5202-ABFC-FF9C0C4B1C1A"><p> <xref href="GUID-39915413-31A6-360F-9758-5DBDF9D70103.dita#GUID-39915413-31A6-360F-9758-5DBDF9D70103/GUID-AB35243B-ECD9-3268-A6FF-5079D1A45EA0"><apiname>TSoundFormatsSupportedV02::iHwConfigNotificationSupport</apiname></xref> </p> </li>
+</ul> <p>Many of the attribute ranges are passed as bit settings, and can
+assume all the values independently of one another. </p> <p>The following
+is a portion of the <xref href="GUID-161BA615-FD2C-3A7E-992E-FBBED621CBBB.dita"><apiname>Caps()</apiname></xref> function for the template port
+for the playback path of the AC97 Controller Unit (UCB140) codec device. </p> <p>The
+PDD maintains a <xref href="GUID-39915413-31A6-360F-9758-5DBDF9D70103.dita"><apiname>TSoundFormatsSupportedV02</apiname></xref> object as one
+of its data members named <codeph>iCaps</codeph>. The contents of <codeph>iCaps</codeph> is
+copied into the descriptor and passed as an argument to the <xref href="GUID-161BA615-FD2C-3A7E-992E-FBBED621CBBB.dita"><apiname>Caps()</apiname></xref> function: </p> <codeblock id="GUID-21B70DCD-7133-53A1-AE5C-848E0F68DF43" xml:space="preserve">void DTemplateSoundScTxPdd::Caps(TDes8&amp; aCapsBuf) const
+    {
+     __KTRACE_SND(Kern::Printf("&gt;DTemplateSoundScTxPdd::Caps"));
+    
+     // Copy iCaps back.
+     TPtrC8 ptr((const TUint8*)&amp;iCaps,sizeof(iCaps));
+     aCapsBuf.FillZ(aCapsBuf.MaxLength());
+     aCapsBuf=ptr.Left(Min(ptr.Length(),aCapsBuf.MaxLength()));        
+    }
+</codeblock> <p>The data member <codeph>iCaps</codeph> is initialised by the
+function <xref href="GUID-681FB26E-0027-38E6-88A1-9E9046011312.dita"><apiname>SetCaps()</apiname></xref> called from the second stage constructor
+of the PDD object: </p> <codeblock id="GUID-B17BA93D-14D6-56A9-8F1F-9FFEF88559D3" xml:space="preserve">void DTemplateSoundScTxPdd::SetCaps()
+    {
+     __KTRACE_SND(Kern::Printf("&gt;DTemplateSoundScTxPdd::SetCaps"));
+    
+     // The data transfer direction for this unit is play.
+     iCaps.iDirection=ESoundDirPlayback;
+    
+     // TO DO: (mandatory)
+     // Setup the rest of the capabilities structure DTemplateSoundScTxPdd::iCaps with the capabilities of this
+     // audio playback device.
+    }</codeblock> </section>
+<section id="GUID-A2A7A6FF-8F46-589D-B5D6-E33ED3FF0692"><title>MaxTransferLen()</title> <p>Implement
+the <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-534D46F4-2CB1-3130-9E72-A1C3BF085865"><apiname>DSoundScPdd::MaxTransferLen()</apiname></xref> function for both playback
+and record driver channels. The function has the following signature: </p> <codeblock id="GUID-039E8EF1-AA13-5C38-92DD-46AFC8E1E8F3" xml:space="preserve">TInt DSoundScPdd::MaxTransferLen() const</codeblock> <p>The
+supplied implementation is as follows: </p> <codeblock id="GUID-E27E52F5-175A-5264-8B08-AE0BDAD5B495" xml:space="preserve">TInt DTemplateSoundScTxPdd::MaxTransferLen() const
+    {
+    return(KTemplateMaxTxDmaTransferLen);
+    }</codeblock> <p>This function is called each time the LDD alters the
+audio configuration of the channel. For example, after calling <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-39AA2B2D-E98B-33A0-9C46-08B783413860"><apiname>DSoundScPdd::SetConfig()</apiname></xref>.
+The LDD uses the value returned to fragment record and playback data transfers
+so that they are manageable by the PDD. See <xref href="GUID-15FDDEED-89F1-5BE5-97AD-8DFD3640369A.dita">playback</xref> and <xref href="GUID-4AEF7595-17C0-513E-9568-B212E6194388.dita">record</xref>. </p> <p>The
+value returned by <xref href="GUID-615DF55C-EC50-3BF0-9C46-AB24E9505C5E.dita"><apiname>MaxTransferLen()</apiname></xref> is not as important
+for PDDs that use the Symbian DMA framework because the DMA framework handles
+fragmentation. </p> <p>If the PDD has to employ mono-to-stereo data conversion
+using a conversion buffer when configured in mono mode, then it needs to return
+the value that corresponds with the size of the conversion buffer each time
+it is configured in mono mode. See <xref href="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita#GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6/GUID-5C66667B-55C0-521D-86E3-67593DB381C9">mono
+to stereo conversion</xref>. </p> </section>
+<section id="GUID-B72057E6-B93C-505F-9789-83251D09B78E"><title>PowerUp()</title> <p>Implement
+the <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-6301A4AA-CC41-3DBC-A349-9BD5C9B01276"><apiname>DSoundScPdd::PowerUp</apiname></xref> function for both the playback
+and record driver channels. The function has the following signature: </p> <codeblock id="GUID-F9706BE3-125F-56B3-947E-3534FB3A5D23" xml:space="preserve">TInt DSoundScPdd::PowerUp()</codeblock> <p>The
+supplied implementation is as follows: </p> <codeblock id="GUID-DB986B0B-CC10-5842-BB54-76683A35EB38" xml:space="preserve">TInt DTemplateSoundScTxPdd::PowerUp()
+    {
+    // TO DO: (mandatory)
+    // Power up the audio device.
+    
+    return(KErrNone);
+    }</codeblock> <p>This function initialises the codec device and any associated
+controller hardware that allows the CPU to communicate with it. However, at
+this stage only basic initialisation of these hardware components is required,
+as the specific audio configuration has not yet been specified, and data transfer
+has not yet started. </p> <p>If the PDD supports both record and playback
+driver channels then most, if not all, of this hardware initialisation is
+common to both channels. It may be necessary to ensure that such initialisation
+on one channel cannot interfere with the other. For example, when calling <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-1B2E2F89-75A8-3740-893A-4DCDB0A350D3"><apiname>DSoundScPdd::PowerUp()</apiname></xref> on
+the record driver channel while the playback driver channel is active, make
+sure that it does not interfere with audio playback. This typically requires
+hardware status information to be held in the PDD factory object that is common
+to both channels. </p> </section>
+<section id="GUID-3764C238-A458-5D13-8AB2-EE53CA91F6E5"><title>SetConfig()</title> <p>Implement
+the <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-39AA2B2D-E98B-33A0-9C46-08B783413860"><apiname>DSoundScPdd::SetConfig()</apiname></xref> function for both playback
+and record driver channels. The function has the following signature: </p> <codeblock id="GUID-DB782F12-E5CE-5D13-8C12-8E57AB47BDB4" xml:space="preserve">TInt DSoundScPdd::SetConfig(const TDesC8&amp; aConfigBuf)</codeblock> <codeblock id="GUID-868A3301-3CAD-5077-88AC-2A2A6C125AFD" xml:space="preserve">TInt DTemplateSoundScTxPdd::SetConfig(const TDesC8&amp; aConfigBuf)
+    {
+    __KTRACE_SND(Kern::Printf("&gt;DTemplateSoundScTxPdd::SetConfig"));
+    
+    // Read the new configuration from the LDD.
+    TCurrentSoundFormatV02 config;
+    TPtr8 ptr((TUint8*)&amp;config,sizeof(config));
+    Kern::InfoCopy(ptr,aConfigBuf);
+    
+    // TO DO: (mandatory)
+    // Apply the specified audio configuration to the audio device.
+    TInt r=KErrNone;
+    
+    __KTRACE_SND(Kern::Printf("&lt;DTemplateSoundScTxPdd::SetConfig - %d",r));
+    return(r);
+    }</codeblock> <p>A configuration buffer in a packaged <xref href="GUID-EF1D41AB-929D-3E51-98AA-F175DDB58F68.dita"><apiname>TCurrentSoundFormatV02</apiname></xref> object
+containing the new configuration settings. </p> <ul>
+<li id="GUID-2D88064E-2258-55FA-BE68-831889E9E2C8"><p> <xref href="GUID-EF1D41AB-929D-3E51-98AA-F175DDB58F68.dita#GUID-EF1D41AB-929D-3E51-98AA-F175DDB58F68/GUID-AE4EDE94-5902-3D73-BAE4-4A49B3E3CC6C"><apiname>TCurrentSoundFormatV02::iChannels</apiname></xref>  </p> </li>
+<li id="GUID-CBACC0C9-1C73-59E0-BAA4-63110DECDED9"><p> <xref href="GUID-EF1D41AB-929D-3E51-98AA-F175DDB58F68.dita#GUID-EF1D41AB-929D-3E51-98AA-F175DDB58F68/GUID-FA39A28F-4B0C-3B89-AB4B-763E0369AD31"><apiname>TCurrentSoundFormatV02::iRate</apiname></xref>  </p> <ul>
+<li id="GUID-00FD1F5A-7941-5ED8-9878-69EDAE03F630"><p> <xref href="GUID-306655BD-FD24-37CE-8F67-F6BC5FBAA455.dita"><apiname>ESoundRate7350Hz</apiname></xref>  </p> </li>
+<li id="GUID-3BEB74D8-B829-5B49-A740-F4BC0597E389"><p> <xref href="GUID-F6D595E9-BE6E-3D5F-AEEF-57FEBA5D165F.dita"><apiname>ESoundRate8000Hz</apiname></xref>  </p> </li>
+<li id="GUID-E077B1A6-A625-55C8-8587-96EF7242C5F0"><p> <xref href="GUID-256AD4BA-8D30-38B8-8AC3-A63AFDCDF82E.dita"><apiname>ESoundRate8820Hz</apiname></xref>  </p> </li>
+<li id="GUID-5664E1E2-DBC3-5F2C-A5BD-3EE5512C254E"><p> <xref href="GUID-3A48C172-FEEF-3A5A-A986-E5C1FD8E5048.dita"><apiname>ESoundRate9600Hz</apiname></xref>  </p> </li>
+<li id="GUID-7E607F76-3975-591F-AEE3-D4CBC2B0F003"><p> <xref href="GUID-0B13D3F1-57D0-3741-BCC8-3E3BE50B59DE.dita"><apiname>ESoundRate11025Hz</apiname></xref>  </p> </li>
+<li id="GUID-8054CF86-27CF-531A-9233-C6602BB958EF"><p> <xref href="GUID-88C3603E-D69F-3DE9-9AA0-F6F724432C76.dita"><apiname>ESoundRate12000Hz</apiname></xref>  </p> </li>
+<li id="GUID-1AD1415C-0D0D-508F-B63E-69B553AA4109"><p> <xref href="GUID-D49E0BA6-AB68-334A-BECF-7221996C71CF.dita"><apiname>ESoundRate14700Hz</apiname></xref>  </p> </li>
+<li id="GUID-1D23B890-0AFC-5E2B-8D00-E56CF1E75D07"><p> <xref href="GUID-6FDDFE56-B32E-3DA1-8E90-DCAE1476A75F.dita"><apiname>ESoundRate16000Hz</apiname></xref>  </p> </li>
+<li id="GUID-A2637B2C-AD6B-5A87-86AC-FDB56DBF46C0"><p> <xref href="GUID-86882923-4DB3-3461-AF9E-D36BF75125AB.dita"><apiname>ESoundRate22050Hz</apiname></xref>  </p> </li>
+<li id="GUID-8682C600-A7C8-5B8B-9824-DD670812C598"><p> <xref href="GUID-2E1FC700-5B43-39DE-8B67-7DADD38B55A5.dita"><apiname>ESoundRate24000Hz</apiname></xref>  </p> </li>
+<li id="GUID-51A42D66-5B71-5325-90B7-B5A1503F21C5"><p> <xref href="GUID-244A1091-0F4A-376B-AE3E-93F09029ECF0.dita"><apiname>ESoundRate29400Hz</apiname></xref>  </p> </li>
+<li id="GUID-04621385-220C-587B-9C59-68115E251D8C"><p> <xref href="GUID-1C1526A2-4BA2-3296-BBE0-152070B43EE9.dita"><apiname>ESoundRate32000Hz</apiname></xref>  </p> </li>
+<li id="GUID-5DECBAD3-09E7-5967-82B3-7C923F870DA6"><p> <xref href="GUID-028FCDA8-E1FC-3E5D-827B-E4513991C1F2.dita"><apiname>ESoundRate44100Hz</apiname></xref>  </p> </li>
+<li id="GUID-27AA4D39-3CA5-52A0-9F97-C8543AAECB97"><p> <xref href="GUID-14D9C50A-2F72-3D1D-A15B-BDE4FAA33ED8.dita"><apiname>ESoundRate48000Hz</apiname></xref>  </p> </li>
+</ul> </li>
+<li id="GUID-95DDDF4C-B70E-56B1-92E6-616ADCB45025"><p> <xref href="GUID-EF1D41AB-929D-3E51-98AA-F175DDB58F68.dita#GUID-EF1D41AB-929D-3E51-98AA-F175DDB58F68/GUID-1A4256A2-A2FE-3FD0-8849-A9F37E1D7A77"><apiname>TCurrentSoundFormatV02::iEncoding</apiname></xref>  </p> <ul>
+<li id="GUID-48484A2E-6970-59AE-9CD5-C93BE349C28D"><p> <xref href="GUID-866386CC-C9CA-3029-95C2-800F6B6C3C2D.dita"><apiname>ESoundEncoding8BitPCM</apiname></xref>  </p> </li>
+<li id="GUID-357130A0-C112-5803-A4D3-9B1237B5931C"><p> <xref href="GUID-E69FCDC5-9A22-3C5A-89C9-A7B869744948.dita"><apiname>ESoundEncoding16BitPCM</apiname></xref>  </p> </li>
+<li id="GUID-E2920329-BDFC-5B28-BF53-F4CF45DBE9AC"><p> <xref href="GUID-289CBD4B-ACEF-3A43-8935-201635AC658F.dita"><apiname>ESoundEncoding24BitPCM</apiname></xref>  </p> </li>
+</ul> </li>
+<li id="GUID-406F8EE9-885D-5569-98E0-A473BB7462FB"><p> <xref href="GUID-EF1D41AB-929D-3E51-98AA-F175DDB58F68.dita#GUID-EF1D41AB-929D-3E51-98AA-F175DDB58F68/GUID-3A9546CB-33D6-3171-A8F7-0E642EB8E798"><apiname>TCurrentSoundFormatV02::iDataformat</apiname></xref>  </p> <ul>
+<li id="GUID-D21416A0-3E78-5D5C-BFE3-0C8A75F80429"><p> <xref href="GUID-5ADC3C98-2D05-35E1-96D2-42B3A65BF25F.dita"><apiname>ESoundDateFormatInterleaved</apiname></xref>  </p> </li>
+<li id="GUID-1A7EC2CC-D94F-514E-BB8A-9A3B3551B13F"><p> <xref href="GUID-352ED2EF-C98C-305E-80F1-FE30DF1BE4CA.dita"><apiname>ESoundDateFormatNonInterleaved</apiname></xref>  </p> </li>
+</ul> </li>
+</ul> <p>The PDD must read and locally save the contents of the <xref href="GUID-EF1D41AB-929D-3E51-98AA-F175DDB58F68.dita"><apiname>TCurrentSoundFormatV02</apiname></xref> configuration
+object that has been passed as a descriptor from the LDD. The template version
+contains the following code to achieve this: </p> <codeblock id="GUID-7FF5383E-FAE0-51A7-8E9E-0F489D841C72" xml:space="preserve">// Read the new configuration from the LDD.
+TCurrentSoundFormatV02 config;
+TPtr8 ptr((TUint8*)&amp;config, sizeof(config));
+Kern::InfoCopy(ptr, aConfigBuf);</codeblock> <p>It is not necessary to check
+for configurations requested by the LDD that are not supported by the audio
+hardware device if the <xref href="GUID-161BA615-FD2C-3A7E-992E-FBBED621CBBB.dita"><apiname>Caps()</apiname></xref> function has been implemented
+correctly by the PDD. This is because the LDD rejects such audio configuration
+requests from the client. However, if the PDD supports both playback and record
+driver channels then it needs to check that the specified configuration does
+not conflict with one already in use by the other channel. </p> <p>The PDD
+sets up the audio hardware device according to the audio configuration specified
+if it is required. Some, if not all of this hardware configuration may be
+put off until data transfer is started, this is when <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-54D3CC19-0C00-3FFA-BD1A-62618D36EB20"><apiname>DSoundScPdd::StartTransfer()</apiname></xref> is
+called, so for now the PDD needs to save the configuration. </p> <p>If the
+PDD has to employ mono-to-stereo conversion of data using a conversion buffer
+while the audio configuration is set to mono, then the memory for the conversion
+buffer should be allocated at this time. </p> </section>
+<section id="GUID-51420A2F-180B-5916-AF5A-685ABD156A2D"><title>SetVolume()</title> <p>Implement
+the <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-3C56E870-1F05-31BC-B799-AF49F77E2930"><apiname>DSoundScPdd::SetVolume</apiname></xref> function for both the playback
+and record driver channels. This has the following signature: </p> <codeblock id="GUID-6FEA0876-7753-54C7-A414-9A54913F1778" xml:space="preserve">TInt DSoundScPdd::SetVolume(TInt aVolume)</codeblock> <p>The
+supplied implementation is as follows: </p> <codeblock id="GUID-14196DC5-8630-5E06-869A-D9A5EE423BF6" xml:space="preserve">TInt DTemplateSoundScTxPdd::SetVolume(TInt aVolume)
+    {
+    __KTRACE_SND(Kern::Printf("&gt;DTemplateSoundScTxPdd::SetVolume"));
+    
+    // TO DO: (mandatory)
+    // Set the specified play volume on the audio device.
+    TInt r=KErrNone;
+    
+    return(r);
+    }</codeblock> <p>The PDD must first convert the volume/record level information
+specified into a form which can be used to program the hardware. This may
+require converting the value from a gain factor to an attenuation factor and/or
+applying a scaling factor. The LDD detects situations where the client specifies
+a record level /volume that is already in effect, and in this case does not
+unnecessarily call the PDD. </p> <p>The PDD may opt to setup the audio hardware
+device within this function or it may defer this until data transfer is started
+with the function <xref href="GUID-CCACE58D-8884-37A4-B7DB-F1DFDEE4A8F1.dita#GUID-CCACE58D-8884-37A4-B7DB-F1DFDEE4A8F1/GUID-788592C9-FCCA-3E34-BEA7-5DC5E6A497C8"><apiname>DSOundScPdd::StartTransfer()</apiname></xref>. For PDDs
+which support both record and playback driver channels, it is normal for audio
+devices to allow the record and playback gains to be programmed independently,
+this means that checking for conflicts between the channels is rarely required
+for this function. </p> </section>
+<section id="GUID-287BB55C-E0FD-5214-9FAA-857AB46C64ED"><title>StartTransfer()</title> <p>Implement
+the <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-66F3D9DA-F61F-3C1D-8C95-02C7C561AE64"><apiname>DSoundScPdd::StartTransfer</apiname></xref> function for both the playback
+and record driver channels. This has the following signature: </p> <codeblock id="GUID-02F7B0B7-35A7-525C-A88D-6555113D6D62" xml:space="preserve">TInt DSoundScPdd::StartTransfer()</codeblock> <p>The
+supplied implementation is as follows: </p> <codeblock id="GUID-DE7BF31A-B5D4-5348-9280-0C326D37DAF8" xml:space="preserve">TInt DTemplateSoundScTxPdd::StartTransfer()
+    {
+    __KTRACE_SND(Kern::Printf("&gt;DTemplateSoundScTxPdd::StartTransfer"));
+    
+    // TO DO: (mandatory)
+    // Prepare the audio device for playback.
+    TInt r=KErrNone;
+    
+    __KTRACE_SND(Kern::Printf("&lt;DTemplateSoundScTxPdd::StartTransfer - %d",r));
+    return(r);
+    }</codeblock> <p>This function performs any configurations of the audio
+hardware device that were deferred from the <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-39AA2B2D-E98B-33A0-9C46-08B783413860"><apiname>DSoundScPdd::SetConfig()</apiname></xref> function.
+These configurations may include start-up of the DMA engine, enabling any
+interrupts related to audio transfer and interrupts that detect error conditions,
+for example. At this stage, no data has yet been supplied to the device for
+transfer as the function <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-8C79D09B-317A-3D8E-B9C2-474812F17529"><apiname>DSoundScPdd::TransferData()</apiname></xref> has
+not yet been called. </p> <p>If the PDD supports both record and playback
+driver channels then it may be necessary to ensure that such hardware configuration
+on one channel cannot interfere with the other. </p> </section>
+<section id="GUID-5E29637F-140F-5F1B-B969-DF9682CEF5E2"><title>TransferData()</title> <p>Implement
+the <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-EF749829-6C35-3954-A48D-483FD0182CC9"><apiname>DSoundScPdd::TransferData</apiname></xref> function for both playback
+and record driver channels. This has the following signature: </p> <codeblock id="GUID-F13C3C46-D208-5E24-B986-3A32FAFBE453" xml:space="preserve">TInt DSoundScPdd::TransferData(TUint aTransferID,TLinAddr aLinAddr,
+                               TPhysAddr aPhysAddr,TInt aNumBytes)</codeblock> <p>Once
+transfer has been started by calling <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-54D3CC19-0C00-3FFA-BD1A-62618D36EB20"><apiname>DSoundScPdd::StartTransfer()</apiname></xref>,
+the function <xref href="GUID-209D8909-56BD-3601-98C4-FB6E004D78EE.dita"><apiname>TransferData</apiname></xref> is called repeatedly by the LDD
+for the transfer of each fragment. See the <xref href="GUID-15FDDEED-89F1-5BE5-97AD-8DFD3640369A.dita">playback</xref> and <xref href="GUID-4AEF7595-17C0-513E-9568-B212E6194388.dita">record</xref> sections for
+details. </p> <p>The template version for the record driver channel contains
+the following code: </p> <codeblock id="GUID-C86982D4-A2FE-5904-A46C-D52D349D018E" xml:space="preserve">TInt DTemplateSoundScRxPdd::TransferData(TUint aTransferID, TLinAddr aLinAddr,
+                                         TPhysAddr /*aPhysAddr*/, TInt aNumBytes)
+    {  
+    TInt r=KErrNone;
+   
+    // Check that we can accept the request
+    if (iPendingRecord&gt;=KTemplateMaxRxDmaRequests)
+        r=KErrNotReady;
+    else
+        {
+        // Start a DMA transfer.
+        iDmaRequest[iFlag]-&gt;iTransferID=aTransferID;
+        iDmaRequest[iFlag]-&gt;iTransferSize=aNumBytes;
+        // TO DO: (mandatory)
+        // Supply the DMA source information.
+        TUint32 src=0; // ???
+        r=iDmaRequest[iFlag]-&gt;Fragment(src,aLinAddr,aNumBytes,KDmaMemDest|KDmaIncDest,0);
+        if (r==KErrNone)
+            {
+            iDmaRequest[iFlag]-&gt;Queue();
+            iPendingRecord++;
+            if ((++iFlag)&gt;=KTemplateMaxRxDmaRequests)
+                iFlag=0;
+         
+            // TO DO: (mandatory)
+            // Start the audio device transferring data.
+            }
+        }
+                                    
+    return(r);
+    }</codeblock> <p><note> The template version used by the playback function
+is very similar. </note></p> <p>The first step is for the PDD to check that
+it has the capacity to accept a further transfer. For example, check that
+the PDD has a DMA request object that is free and that the DMA controller
+has the capacity for another transfer to be queued. If the PDD does not have
+the capacity to accept another transfer then it should immediately return <xref href="GUID-51298FCE-7857-39F8-BFAB-49AF5556D0CC.dita"><apiname>KErrNotReady</apiname></xref> to
+signal this. </p> <p>Otherwise, the PDD can start a DMA transfer. To do this
+it must acquire a DMA request object. The class <xref href="GUID-6B0DB695-9033-3F85-AC3A-1867E99BE2BD.dita"><apiname>DTemplateSoundScRxDmaRequest</apiname></xref> is
+the abstraction for a DMA record request and is defined as follows: </p> <codeblock id="GUID-04B1D7FD-4E17-5CD0-974F-A3A1BCB04C58" xml:space="preserve">/** Wrapper function for a shared chunk sound driver record DMA request. */
+class DTemplateSoundScRxDmaRequest : public DDmaRequest
+    {
+public:  
+    DTemplateSoundScRxDmaRequest(TDmaChannel&amp; aChannel, DTemplateSoundScRxPdd* aPdd,
+                                 TInt aMaxTransferSize=0);
+    static void DmaService(TResult aResult, TAny* aArg);
+public:
+    /** Pointer back to the PDD. */
+    DTemplateSoundScRxPdd* iPdd;
+    /** The transfer ID for this DMA request - supplied by the LDD. */
+    TUint iTransferID;
+    /** The transfer sizes in progress. */
+    TUint iTransferSize;
+    };
+    This is derived from DDmaRequest the base class
+    for a DMA request.</codeblock> <p>The data member <codeph>iPdd</codeph> is
+a pointer to the owning PDD object. This is used within the member function <xref href="GUID-8B538AA6-9489-309F-8756-2474310CD5DA.dita"><apiname>DmaService()</apiname></xref> which
+is the DMA callback function, and is called when the DMA request has been
+completed by the DMA framework. The data member <codeph>iTransferID</codeph> is
+a value supplied by the LDD which it uses to identify the transfer fragment.
+The PDD must save this value and pass it back to the LDD when the transfer
+is completed. Similarly, the member <codeph>iTransferSize</codeph> is used
+to hold the length of the transfer fragment in bytes. If the transfer is successful
+then this value is also passed back to the LDD to allow it to maintain its
+count of bytes recorded. </p> <p>The record PDD class owns an array of DMA
+request objects: </p> <codeblock id="GUID-8314BE9B-2D19-585F-B44E-17C8529CEFEF" xml:space="preserve">/** The DMA request structures used for transfers. */             
+DTemplateSoundScRxDmaRequest* iDmaRequest[KTemplateMaxRxDmaRequests];</codeblock> <p>It
+also owns the data member <codeph>iFlag</codeph>, which always holds the number
+for the next DMA request that should be used for transfer. Before starting
+the DMA transfer, setup the appropriate DMA request object with the transfer
+ID and the transfer length. </p> <codeblock id="GUID-2F4CB025-C2E2-52DD-A679-CF1DCC3677FA" xml:space="preserve">/** A flag selecting the next DMA request for transfer. */
+TInt iFlag;</codeblock> <p>Next the function <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-B14B0478-80D6-3F5E-88B6-1676411D9CF2"><apiname>DDmaRequest::Fragment()</apiname></xref> is
+called to specify the details of the transfer to the DMA framework and to
+allow it to analyse this. Here the appropriate platform specific 32-bit DMA
+source identifier, <codeph>src</codeph>, needs to be supplied. The template
+driver shown previously specifies the destination memory address as a linear
+address but the physical address may be used instead. Both forms of this address
+are passed as arguments to the <xref href="GUID-34E7FF1F-091A-3C45-B83A-AEB64E2AD286.dita"><apiname>TransferData()</apiname></xref> function. </p> <p>If
+fragmentation is successful then the request object is queued on the DMA channel <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-0A83F782-DB62-39ED-8D32-DBD5949C8D3F"><apiname>DDmaRequest::Queue()</apiname></xref> and
+the value of <codeph>iFlag</codeph> is updated ready for the next transfer.
+The PDD class also keeps a count of the number of transfer fragments outstanding
+by incrementing the variable <codeph>iPendingRecord</codeph>: </p> <codeblock id="GUID-5C738134-0683-5FAB-8733-29D9A336402F" xml:space="preserve">/** The number of outstanding DMA record requests on the DMA channel. */   
+TInt iPendingRecord;</codeblock> <p>The final part of this function requires
+platform specific code to start the audio hardware device transferring data.
+This needs to be executed for each fragment transferred or just for the first
+fragment queued following the <xref href="GUID-FE6DE994-719C-3900-B4A0-009914697380.dita"><apiname>StartTransfer()</apiname></xref> function. </p> <p>Once
+the transfer is complete, either successfully or with an error, the DMA framework
+executes the static DMA callback function, <xref href="GUID-6B0DB695-9033-3F85-AC3A-1867E99BE2BD.dita#GUID-6B0DB695-9033-3F85-AC3A-1867E99BE2BD/GUID-E12BA027-3D58-30A8-A9F7-B7B7DC55D0D5"><apiname>DTemplateSoundScRxDmaRequest::DmaService()</apiname></xref>,
+as follows: </p> <codeblock id="GUID-2ED07474-F489-5545-9FB6-BC229C00D4F3" xml:space="preserve">/**
+DMA rx service routine. Called in the sound thread's DFC context by the s/w DMA controller.
+@param aResult Status of DMA transfer.
+@param aArg Argument passed to DMA controller.
+*/ 
+void DTemplateSoundScRxDmaRequest::DmaService(TResult aResult, TAny* aArg)
+    {
+    DTemplateSoundScRxDmaRequest&amp; req=*(DTemplateSoundScRxDmaRequest*)aArg;
+   
+    TInt res=KErrNone;
+    TInt bytesTransferred=req.iTransferSize;
+    if (aResult!=DDmaRequest::EOk)
+        {
+        res=KErrCorrupt;
+        bytesTransferred=0;
+        }
+      
+    // Inform the LDD of the result of the transfer.
+    req.iPdd-&gt;RecordCallback(req.iTransferID,res,bytesTransferred);   
+    return;
+    }</codeblock> <p>This function receives two arguments: </p> <ul>
+<li id="GUID-7D4D15BD-3BA0-5899-B67E-C7F24F548D22"><p>the result of the transfer
+from the DMA framework </p> </li>
+<li id="GUID-FE18B3C9-A3B3-5599-8CC6-66977D0FA56A"><p>an argument supplied
+to the DMA framework when the request object was created </p> </li>
+</ul> <p>In this specific case, the argument type is a pointer to the DMA
+request object, and allows the retrieval of the transfer ID and the transfer
+size. In the template driver version an unsuccessful transfer returns an error
+value of <xref href="GUID-253F06EA-F14E-3A8E-BA4C-8E787B5F0670.dita"><apiname>KErrCorrupt</apiname></xref> with a transfer byte count of zero. </p> <p>From
+the callback function we call the record PDD function to decrement the count
+of transfer fragments outstanding and to inform the LDD of the completion
+of transfer. </p> <codeblock id="GUID-69C81D24-D725-51B2-8099-1D089A70AE00" xml:space="preserve">void DTemplateSoundScRxPdd::RecordCallback(TUint aTransferID, TInt aTransferResult,TInt aBytesTransferred)
+    {
+    iPendingRecord--;
+    Ldd()-&gt;RecordCallback(aTransferID,aTransferResult,aBytesTransferred);
+    } 
+</codeblock> </section>
+<section id="GUID-E9B63AC5-4AED-53E3-B7CA-21AACE04FC37"><title>StopTransfer()</title> <p>Implement
+the <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-7C629A7C-0C64-32AB-8159-A4075DEEF544"><apiname>DSoundScPdd::StopTransfer</apiname></xref> function for both the play
+and record driver channels. This has the following signature: </p> <codeblock id="GUID-E56EFFEC-59CA-595F-BFA8-72299999DD05" xml:space="preserve">void DSoundScPdd::StopTransfer()</codeblock> <p>The
+PDD must reverse any operation performed on the audio hardware device done
+as part of <xref href="GUID-FE6DE994-719C-3900-B4A0-009914697380.dita"><apiname>StartTransfer()</apiname></xref> or <xref href="GUID-34E7FF1F-091A-3C45-B83A-AEB64E2AD286.dita"><apiname>TransferData()</apiname></xref>.
+This includes stopping the audio hardware device from transferring data and
+stopping the DMA channel. </p> <p>The template version for the record driver
+channel contains the following code: </p> <codeblock id="GUID-D8A0C5F9-3E9D-54F5-8906-465801CC3A3E" xml:space="preserve">void DTemplateSoundScRxPdd::StopTransfer()
+    {
+    // Stop the DMA channel.
+    iDmaChannel-&gt;CancelAll();
+    iFlag=0;
+    iPendingRecord=0;
+    
+    // TO DO: (mandatory)
+    // Stop the audio device transferring data.
+    }</codeblock> <p> <note> The version used by the playback function is
+very similar. </note></p> </section>
+<section id="GUID-2F694050-660B-5941-B9AA-FB21C1D33400"><title>PauseTransfer()</title> <p>Implement
+the <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-0608766F-2645-3E28-B804-BD4B953DB5FF"><apiname>DSoundScPdd::PauseTransfer()</apiname></xref> function for both the
+playback and record driver channels. This has the following signature: </p> <codeblock id="GUID-51C0B918-4883-574A-B1AF-476C61A85120" xml:space="preserve">TInt DSoundScPdd::PauseTransfer()</codeblock> <p>When
+pausing playback, there is normally some way to temporarily stop the codec
+and pause the DMA channel so that it can be resumed later starting from the
+next play sample. </p> <p>Pausing record requires a different implementation.
+All active transfers must be aborted. When this has been achieved, the PDD
+must report back to the LDD how much data has been received for the fragment
+that was actively being transferred when the abort took place by calling <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita#GUID-5807543D-A30F-3EB9-8F28-91A623B0D484/GUID-9112E399-DC3C-334F-BE16-B5F42216F903"><apiname>DSoundScLdd::RecordCallBack()</apiname></xref>.
+If it is not possible to determine the byte count for the last fragment from
+the DMA controller, then you must find some other way to discover its value.
+One solution is to re-start a timer at the start of each record fragment,
+and use this to calculate how much data will have been written into the record
+buffer at the point the transfer is aborted. </p><p><note> In this case the
+returned transfer ID is not important.</note> </p> <p>The supplied template
+implementation is as follows: </p> <codeblock id="GUID-5B5B290E-C751-5599-AA67-0AC59E697898" xml:space="preserve">TInt DTemplateSoundScRxPdd::PauseTransfer()
+    {    
+    // Stop the DMA channel.
+    iDmaChannel-&gt;CancelAll();
+   
+    if (iPendingRecord)
+        {
+        // TO DO: (mandatory)
+        // Determine how much data was successfully transferred to the
+        // record buffer before transfer was aborted.
+        TInt byteCount=0; // ???
+        Ldd()-&gt;RecordCallback(0,KErrNone,byteCount);
+        iPendingRecord=0;
+        }
+    iFlag=0;
+    
+    // TO DO: (mandatory)
+    // Halt recording on the audio device.
+    TInt r=KErrNone;
+    
+    return(r); 
+    }
+</codeblock> <p> <note> There is no need for the PDD to perform any state
+checking as this is already performed by the LDD. For example, checking that
+the device is not already paused or transferring data. </note></p> </section>
+<section id="GUID-00368C95-2AE6-5EBA-8C09-787D0E7C10BC"><title>ResumeTransfer()</title> <p>Implement
+the <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-788AEAF9-E33A-3BD2-8B60-9A066DBA2496"><apiname>DSoundScPdd::ResumeTransfer</apiname></xref> function for both the playback
+and record driver channels. This has the following signature: </p> <codeblock id="GUID-81A86CB7-E089-5B3D-A28F-A371AFDF5471" xml:space="preserve">TInt DSoundScPdd::ResumeTransfer()</codeblock> <p>The
+template version for the record driver channel contains the following code: </p> <codeblock id="GUID-D72D3F34-197F-500F-8483-E307418127F6" xml:space="preserve">TInt DTemplateSoundScTxPdd::ResumeTransfer()
+    {
+    __KTRACE_SND(Kern::Printf("&gt;DTemplateSoundScTxPdd::ResumeTransfer"));
+    
+    // TO DO: (mandatory)
+    // Resume playback on the audio device.
+    TInt r=KErrNone;
+            
+    return(r);
+    }</codeblock> <p>To resume playback, it is normally necessary to re-start
+the codec and resume the DMA channel in order to restart playback from the
+next play sample. </p> <p>To resume record, all active transfers should have
+been aborted when the device was paused with the function <xref href="GUID-1126E802-39C1-3BAD-85BA-A6DDED981B8A.dita"><apiname>PauseTransfer()</apiname></xref>.
+However, the LDD issues a new <xref href="GUID-34E7FF1F-091A-3C45-B83A-AEB64E2AD286.dita"><apiname>TransferData()</apiname></xref> request subsequent
+to this function to resume record data transfer so the only action required
+here is to recreate the same audio hardware setup that was achieved in response
+to the <xref href="GUID-FE6DE994-719C-3900-B4A0-009914697380.dita"><apiname>StartTransfer()</apiname></xref> function. </p> <p>There is no need
+for the PDD to perform any state checking as this is already performed by
+the LDD. For example, checking that the device is not already paused. </p> </section>
+<section id="GUID-3155494B-AFFD-5E07-8E2F-D6EC81E4E69B"><title>PowerDown()</title> <p>Implement
+the <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-53CDB4F4-470C-3A40-B948-C14B0FCA0E24"><apiname>DSoundScPdd::PowerDown()</apiname></xref> function for both the playback
+and record driver channels. This has the following signature: </p> <codeblock id="GUID-69B46DDC-DA62-55E2-9E7C-A4E0B1550E03" xml:space="preserve">void DSoundScPdd::PowerDown()</codeblock> <p>The
+PDD must reverse any operation performed on the audio hardware as part of <xref href="GUID-B70A3916-5644-330F-872B-FADB8E3D80B5.dita"><apiname>PowerUp()</apiname></xref>. </p> </section>
+<section id="GUID-4B71AE98-3692-54B3-9CD8-525991DBAEAA"><title>CustomConfig()</title> <p>Implement
+the <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-B0F89BCD-69AF-3D40-A601-EB22C6FA0435"><apiname>DSoundScPdd::CustomConfig()</apiname></xref> function for both the playback
+and record driver channels. This has the following signature: </p> <codeblock id="GUID-C24D93F2-9A7E-5E43-8750-6BE8978B9C01" xml:space="preserve">TInt DSoundScPdd::CustomConfig(TInt aFunction,TAny* aParam)</codeblock> <p> <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita#GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3/GUID-78AA2782-80D0-3815-8F71-AA218756BAE6"><apiname>RSoundSc::CustomConfig()</apiname></xref> is called by the LDD in response to a custom configuration request by the
+client. Custom configurations allow clients to issue requests to setup platform
+specific audio configuration settings. Any such requests from the client with
+a function identifier equal to or above 0x10000000 are passed straight through
+to the PDD for function identification and implementation. These are handled
+in the context of the sound driver DFC thread. </p> <p>If custom configuration
+is not supported, then the PDD should simply return <codeph>KErrNotSupported</codeph>. </p> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-AC7830F9-C3FB-5117-B851-1D106AE400D4-master.png has changed
Binary file Adaptation/GUID-AC7830F9-C3FB-5117-B851-1D106AE400D4_d0e10568_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-ACA48BEE-FE73-5C47-B022-E50728CEDBEE.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,55 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-ACA48BEE-FE73-5C47-B022-E50728CEDBEE" xml:lang="en"><title>Architecture</title><shortdesc>Describes the architecture of the Sound Driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There are three main parts: </p>
+<ul>
+<li id="GUID-6EEE9FF2-FA3A-5B50-9CD9-D098C66D5331"><p>the user side interface
+to the <xref href="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita#GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6/GUID-4D6A01FE-47E7-5A6F-9DFE-F612B880165B">Driver
+channel</xref>. This is an instance of a class derived from <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita"><apiname>RSoundSc</apiname></xref>. </p> <p>The
+class <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita"><apiname>RSoundSc</apiname></xref> provides the user side interface to the
+driver. This class is defined in <filepath>\e32\include\d32soundsc.h</filepath>.
+An instance of <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita"><apiname>RSoundSc</apiname></xref> is required for each <xref href="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita#GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6/GUID-4D6A01FE-47E7-5A6F-9DFE-F612B880165B">driver channel</xref> opened by the client. When opening a <xref href="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita#GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6/GUID-4D6A01FE-47E7-5A6F-9DFE-F612B880165B">driver channel</xref>, the client specifies a channel number for the <xref href="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita#GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6/GUID-74B14664-8D9D-57D2-B090-709136FEB5E3">audio
+channel</xref>. Channel numbers 0 to 3 are allocated for output/playback channels
+and channels 4 to 7 are allocated for input/record channels. </p> </li>
+<li id="GUID-FA62DA0C-F56E-51B4-84B2-EF8316CACC1B"><p>the <xref href="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita#GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6/GUID-4D6A01FE-47E7-5A6F-9DFE-F612B880165B">driver channel</xref>, also known as the logical channel or LDD. </p> <p>The
+class <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita"><apiname>DSoundScLdd</apiname></xref> is the <xref href="GUID-0956CE5E-C02B-5EEE-890A-5E8E84A8D9A1.dita">logical
+channel</xref> object for either audio playback or record. This class is defined
+in <filepath>\e32\include\drivers\soundsc.h</filepath>. An instance of <xref href="GUID-5807543D-A30F-3EB9-8F28-91A623B0D484.dita"><apiname>DSoundScLdd</apiname></xref> is
+created for each <xref href="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita#GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6/GUID-4D6A01FE-47E7-5A6F-9DFE-F612B880165B">driver
+channel</xref> opened. The driver implements play and record operation over
+a single audio hardware device as two separate <xref href="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita#GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6/GUID-7C8FF32F-2E84-57B1-8962-9EDB4D51FEE6">units</xref>. Therefore, a client that needs to issue both record and playback requests
+has to open two separate <xref href="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita#GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6/GUID-4D6A01FE-47E7-5A6F-9DFE-F612B880165B">driver
+channels</xref>. </p> <p> <codeph>DSOundScLdd</codeph> is derived from <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita"><apiname>DLogicalChannel</apiname></xref>. <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita"><apiname>DLogicalChannel</apiname></xref> is
+the base class for a logical channel and provides the framework in which user
+side client requests are normally executed in the context of a kernel side
+thread. However, for this particular driver, not every request is executed
+in the context of a kernel thread. Requests that do not require access to
+hardware are handled in the context of the calling thread. </p> </li>
+<li id="GUID-861F1E3E-9087-530A-938D-DDD934D4EB67"><p>the <xref href="GUID-461A9DAD-1C1D-537D-A7A7-9E1AF33ABBA2.dita">physical
+channel</xref>, also known as the PDD, manages access to the audio hardware
+device for all instances of the <xref href="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita#GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6/GUID-4D6A01FE-47E7-5A6F-9DFE-F612B880165B">driver
+channel</xref>. </p> <p>The class <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita"><apiname>DSoundScPdd</apiname></xref> is the base
+class for the Sound Driver PDD object. This class is used for either playback
+or record, it implements the platform specific layer of the driver and an
+instance of this class is created for each <xref href="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita#GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6/GUID-4D6A01FE-47E7-5A6F-9DFE-F612B880165B">driver
+channel</xref> opened. This is created by the Sound Driver physical device
+class <xref href="GUID-AA9C0AAC-C718-3DE7-BF4B-D10C277AED6D.dita"><apiname>DSoundScPddFactory</apiname></xref> when a channel is opened. The
+class <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita"><apiname>DSoundScPdd</apiname></xref> is defined in <filepath>\e32\include\drivers\soundsc.h</filepath>. </p> <p>The
+following diagram illustrates the Sound Driver architecture. The interactions
+between the user side and kernel side classes are shown. </p> </li>
+</ul>
+<fig id="GUID-257F5F90-AC86-5029-81EB-5CBB16B8A1F9">
+<title>           The main classes involved in Sound Driver implementation.
+         </title>
+<image href="GUID-8C9F26BC-2579-545C-9A86-9C45E06679F0_d0e32265_href.png" placement="inline"/>
+</fig>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-ACB79CEF-CA4D-5C96-AFCD-6AD7C7C26C53.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-ACB79CEF-CA4D-5C96-AFCD-6AD7C7C26C53" xml:lang="en"><title>Thrashing
+Guide</title><shortdesc>Describes thrashing in terms of demand paging and how to prevent
+it. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-378E14C9-A83A-56BD-BE7D-7DF565E58A46"><title>Introduction</title> <p>Thrashing
+is an undesirable state where most of the processes in the system are in the
+process of paging-in memory and none of the threads are doing useful work.
+This results in unacceptable system performance. </p> </section>
+<section id="GUID-E39982CD-62E4-4EA0-92A6-4BE9E7F9B00E"><title>Background information</title><p>These topics are useful background
+information on thrashing:</p><ul>
+<li><p>Paging </p></li>
+<li><p>Virtual memory </p></li>
+</ul></section>
+<section id="GUID-A2C57999-E701-40FF-872D-396AFD6FA082"><title>Thrashing features</title><p>The signs of thrashing in demand
+paging are: </p><ul>
+<li><p>The system performance rapidly becomes unacceptable, since no threads
+are doing useful work. The device will become unresponsive or appear to 'hang'. </p></li>
+<li><p>When observing paging activity logs it's seen that the same set of
+pages are paged in and out many times over the course of a use case. </p></li>
+<li><p>When observing paging activity logs there are long periods where many
+threads are waiting for pages to be paged in. </p></li>
+<li><p>There are large periods of null thread activity. </p></li>
+</ul></section>
+<section id="GUID-D8D94E88-7B6C-4408-B78D-162201224DB6"><title>Thrashing prevention</title><p>The following is a means of
+preventing thrashing from occurring:  </p><ul>
+<li><p>Increase the size of the paging cache. This reduces page faults and
+hence the need to page-in memory.  </p></li>
+<li><p>Mark the code or data involved as unpaged, for example if a 20MB buffer
+is actively used through a use-case and discarded afterwards there is little
+use in making it paged as it will need to always be in the page cache.  </p></li>
+<li><p>Reduce the working set size so that it fits into the paging cache,
+for example instead of having four activities running concurrently, serialize
+them.  </p></li>
+</ul></section>
+</conbody><related-links>
+<link href="GUID-44540C74-CD73-5D8E-A9E0-F90F46B4E7B1.dita"><linktext>Preventing
+And Recovering From Thrashing Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-ACC010D4-B419-4CDD-8091-C85579575D46-master.png has changed
Binary file Adaptation/GUID-ACC010D4-B419-4CDD-8091-C85579575D46_d0e94724_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-AD195629-81CE-5E57-A59E-C67AACF7A2C2.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,206 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-AD195629-81CE-5E57-A59E-C67AACF7A2C2" xml:lang="en"><title>USB
+Client Driver Technology</title><shortdesc>This topic describes the technology that the USB Client Driver
+provides.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-2FF7A568-3908-4AF5-ABA7-2A2F92E2D063"><title>USB</title> <p>The Universal Serial Bus (USB) is a high speed
+data transport mechanism that uses a 4 wire cable attached to a USB Host to
+transfer signals and bus power to low cost peripherals (clients). Theoretically,
+up to 127 devices (such as keyboards, video cameras etc.) can share the bus,
+although less than four devices is more typical. </p> <p>There are two versions
+of the USB standard in use: V1.1 and V2.0. The following table shows the speeds
+supported by the different versions: </p> <p><b>USB Speeds </b> </p> <table id="GUID-EEBE7ED4-EB35-5E1D-B3FA-7518F6C4D2DE">
+<tgroup cols="3"><colspec colname="col0"/><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p> <b> Name</b>  </p> </entry>
+<entry><p> <b>Rate</b>  </p> </entry>
+<entry><p> <b>USB Version</b>  </p> </entry>
+</row>
+<row>
+<entry><p>High Speed </p> </entry>
+<entry><p>480Mbit/s </p> </entry>
+<entry><p>2.0 only </p> </entry>
+</row>
+<row>
+<entry><p>Low Speed </p> </entry>
+<entry><p>12Mbits/s </p> </entry>
+<entry><p>1.1 and 2.0 </p> </entry>
+</row>
+<row>
+<entry><p>Full Speed </p> </entry>
+<entry><p>1.5Mbits/s </p> </entry>
+<entry><p>1.1 and 2.0 </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>As the table shows USB V2.0 adds support for the higher speed
+of 480Mbit/s. </p> <p>The USB system consists of single USB host controller
+(the USB Host) connected to a number of USB peripheral devices. The host is
+the bus master, initiating all transactions over the bus. </p> <p>A client
+device is a USB peripheral device. It is connected to a USB Controller and
+responds to transactions addressed to it from the Controller. The Universal
+Serial Bus Specification 1.1 describes how a USB Host sends commands to a
+peripheral and how data can be transferred from and to a Client. The main
+points are: </p> <ul>
+<li id="GUID-F247C990-BE75-52EE-8F5F-BA1726541336"><p>USB is a Host polled
+bus. This means that a peripheral cannot send a data packet unless the Host
+has requested it. The request must either be accepted, and the data packet
+sent within a given time period, or refused. </p> </li>
+<li id="GUID-F517A353-4B3F-5EE2-8432-B10718774A85"><p>Every peripheral attached
+to the USB is allocated a unique device address. The Host uses the device
+address to direct its communication to a particular device. In fact, the Host
+sees the peripheral as a collection of endpoints. Each endpoint is an address
+within the peripheral to which the Host sends packets or from which the Host
+receives packets. </p> </li>
+<li id="GUID-35285198-7F18-5ABA-B0B8-1E4437CA65A6"><p>Endpoints are grouped
+together by the peripheral into Interfaces. The Host regards each peripheral
+as a set of functions and communicates with each function via its Interface.
+Simple devices, such as mice, contain only one function, other devices may
+contain more than one function, e.g. a monitor may contain speakers and a
+microphone. </p> </li>
+<li id="GUID-1BDEBAC5-23C0-5CDD-A6BD-1CCB6D1B0EC3"><p>Each function requires
+its own driver at the Host end which communicates with the function within
+the peripheral using a USB class driver or vendor defined protocol. The function
+informs the Host what protocol it understands via its Interface. </p> </li>
+</ul> <p>The USB Client Driver supports: </p> <ul>
+<li id="GUID-B5051F6F-9E1E-5A79-B45A-D81B7A94EA23"><p>multiple USB interfaces,
+i.e. it supports licensee products that implement multiple USB interfaces
+simultaneously </p> </li>
+<li id="GUID-31AC620E-4DD3-51B9-9492-E0C3EB0C8751"><p>alternate USB interfaces </p> </li>
+<li id="GUID-D9563D5D-679E-540C-AA96-B55CB65578FC"><p>a single USB Configuration
+only; the API does not provide a mechanism for specifying more than one USB
+configuration. </p> </li>
+<li id="GUID-CD97C393-9630-5A56-934A-D2453CEAA56C"><p>extended standard endpoint
+descriptors. </p> </li>
+<li id="GUID-28F9D219-0FD8-57FD-867D-2AA2E5461914"><p>reading and modifying
+standard descriptors. </p> </li>
+<li id="GUID-8AF1738D-3321-5503-8440-2F8782658BD9"><p>setting class specific
+interface and endpoint descriptors. </p> </li>
+<li id="GUID-6665A0F8-E1DD-5CB9-98AD-79D5BE63B074"><p>remote wakeup signalling. </p> </li>
+<li id="GUID-15199F33-31AB-54E0-B427-1B68B946213E"><p>reading device directed
+Ep0 (Endpoint Zero) traffic. </p> </li>
+</ul> </section>
+<section id="GUID-1ECB4FAF-745C-52CE-92A4-9077ABB585C3"><title>Endpoint types</title> <p>There
+are four endpoint types corresponding to the four transfer types: </p> <ul>
+<li id="GUID-63D3194C-E3B0-5C76-9A11-398963275D38"><p>Control endpoints </p> </li>
+<li id="GUID-BC5DBF35-B82D-554F-AF6A-325316248464"><p>Bulk endpoints </p> </li>
+<li id="GUID-C33C7BF8-9E81-5541-ABE4-DF31CF101977"><p>Interrupt endpoints </p> </li>
+<li id="GUID-549981D7-9AC8-5D2A-BDC8-9643F8C27B9F"><p>Isochronous endpoints. </p> </li>
+</ul> <p><b>Control
+endpoints</b> </p> <p>These are serially bi-directional. This means that they
+can send and receive data, but not simultaneously. </p> <p>Every peripheral
+has at least one control endpoint. Although other control endpoints are possible,
+Symbian platform only allows Endpoint zero (Ep0) as the control endpoint.
+Ep0 is a shared resource, which must always be available. </p> <p>Ep0 is vital
+for the operation of the device. Its primary function is the control endpoint
+for the Host. When the device is first connected to the Host, a process known
+as enumeration must occur, and this takes place through Ep0. During enumeration,
+the client tells the Host what kind of device it is and what classes it supports.
+Enumeration is complete, for the purpose of writing client drivers, when the
+Host moves the client into its configured state. The Host moves the client
+into its configured state when a Host driver is available to communicate with
+the client. </p> <p>Ep0 needs handling with some sensitivity. Every request
+arriving on Ep0 must be handled either by the Controller or by a client class
+driver. Each request must be moved through the data phase, even if there is
+no associated request data, so that the status phase may begin. It is imperative
+that this happens otherwise endpoint zero will be unable to accept any further
+requests. This could result in the Host stopping communication with the device. </p> <p><b>Bulk endpoints</b> </p> <p>These are unidirectional. They can have the
+IN or the OUT direction. </p> <p>The IN direction means sending packets to
+the Host. The OUT direction means receiving packets from the Host. </p> <p>Bulk
+endpoints can supply a maximum of 64 bytes of data per packet, but such transfers
+have no guaranteed bus bandwidth. </p> <p><b>Interrupt
+endpoints</b> </p> <p>Interrupt endpoints are similar to Bulk endpoints but,
+in addition, the endpoint descriptor specifies how often the Host should poll
+the endpoint for data. The polling frequency may be anything from 1ms to 255ms. </p> <p><b>Isochronous endpoints</b> </p> <p>Isochronous endpoints can deliver up
+to 1023 bytes of data per packet, but there is no retry capability if an error
+is detected. Like Interrupt endpoints, they have an associated polling frequency,
+which is fixed at 1ms. </p> </section>
+<section id="GUID-A2A987CD-2DEA-5B40-8C42-157DD36BA2CA"><title>Endpoint numbering</title> <p>Two
+numbering schemes are used within the USB implementation. There is also the
+external USB address numbering scheme. </p> <p id="GUID-2CFB38E0-0A98-516C-B4EE-DECCD65F824A"><b>Virtual endpoint numbers</b> </p> <p>Applications
+or class drivers use virtual endpoints when communicating with the USB client
+driver. These numbers are used when exchanging data over the USB. </p> <p>Virtual
+endpoints range in value from 1 to <xref href="GUID-CB8EA082-EA6E-3A7E-81C7-E06A6F8DD9B8.dita"><apiname>KMaxEndpointsPerClient</apiname></xref>,
+and applications refer to these endpoints by number when using the user side
+handle to the USB client driver. </p> <p>For applications that implement a
+specific USB device class, and which need access to endpoint-0, virtual endpoint-0
+is available. This endpoint is special because it does not belong to any specific
+interface. It is always available and, at the interface to the USB client
+driver, is the only bi-directional endpoint. </p> <p><b>Implementation note </b> </p> <p>Within the platform independent layer,
+virtual endpoint numbers are represented by instances of the internal class <codeph>TUsbcLogicalEndpoint</codeph>.
+Note that there is no representation for virtual endpoint-0. </p> <p><b>Physical endpoints</b> </p> <p>Physical (or 'real') endpoints are used
+at the interface between the platform independent layer and the platform specific
+layer within the USB client controller. They represent endpoints physically
+present on a given device. </p> <p><b>Implementation note </b> </p> <p>Within the platform independent layer,
+physical endpoint numbers are represented by instances of the internal class <codeph>TUsbcPhysicalEndpoint</codeph>,
+in the array represented by the internal data member <codeph>DUsbClientController::iRealEndPoints</codeph>. </p> <p>To
+simplify array indexing, the numbering scheme uses "transformed" USB endpoint
+addresses. We represent each channel as a separate endpoint, RX (OUT) channel
+as <codeph>iRealEndpoints[n]</codeph> and TX (IN) channel as <codeph>iRealEndpoints[n
++ 1]</codeph>. </p> <p id="GUID-8592C90D-ECA7-59CB-A419-0C4ABDEB9229"><b>Canonical endpoint numbers</b> </p> <p>The
+two layers of the USB client controller, i.e. the Platform Independent layer
+and the Platform Specific layer, use a numbering system known as canonical
+endpoint numbers when communicating between each other. The physical endpoint
+numbers are never used explicitly. </p> <p>This system is based upon the physical
+endpoint number, but takes the direction of the endpoint into account. If <codeph>r</codeph> is
+the physical endpoint number, then the corresponding canonical endpoint number
+is a value defined as: </p> <ul>
+<li id="GUID-DFD56EC6-7B4D-58C2-96E3-E232D9D26494"><codeblock id="GUID-2A405E0A-857A-5978-9BE7-2C4193CA16D8" xml:space="preserve">2r + 1</codeblock> <p>if
+the endpoint direction is IN </p> </li>
+<li id="GUID-FD8BABD6-39E5-54E5-A4D6-EA5F809B0D28"><codeblock id="GUID-A868BFCC-6FB7-501D-8CAE-D2ECB56B78DA" xml:space="preserve">2r</codeblock> <p>if
+the endpoint direction is OUT </p> </li>
+</ul> <p>This means that canonical endpoint numbers fall into a range from
+0 to 31. </p> <p>For example, Endpoint 0 (Ep0) is represented by 2 canonical
+endpoint numbers: </p> <ul>
+<li id="GUID-9A9D6B64-C15D-554A-B34B-90521659600A"><p>0, representing Ep0(OUT) </p> </li>
+<li id="GUID-B85424E3-D704-5EDA-87E8-2216BA1878DF"><p>1, representing Ep0(IN). </p> </li>
+</ul> <p id="GUID-4037A87D-802A-5FD5-A0B5-2A002A0FD092"><b>Converting between Endpoint
+number representations</b> </p> <p>It is possible to convert between the Endpoint
+Address representation and the Canonical Endpoint. The following text explains
+how these values are stored in memory and shows the conversion process: </p> <p><b>Endpoint Address </b> </p> <fig id="GUID-0135DF6D-895B-53E0-A2EA-8E7F0EF6BBDE">
+<desc><p>where the numbers 0-7 represent bits 0-7 of the byte containing the
+endpoint address. </p> <p>D = Direction: 0 = Receive/IN, 1 = Transmit/OUT </p> <p>P3
+P2 P1 P0 represents the physical endpoint number (0-15) </p> </desc>
+<image href="GUID-59FF3BFE-21E2-554D-99EC-1A1D34AAEB7C_d0e35295_href.png" placement="inline"/>
+</fig> <p><b>Canonical Endpoint Number </b> </p> <p>The canonical endpoint number is
+just the endpoint address rotated left by 1 bit as shown below: </p> <fig id="GUID-237E227A-03E7-5BDE-B8E0-AA96FB74CA36">
+<image href="GUID-CDDD8189-D532-5179-92F6-74264C2E3D81_d0e35308_href.png" placement="inline"/>
+</fig> <p><b>Summary
+of Endpoint Number Representations</b> </p> <p>The APIs use the following
+conventions for representing endpoint numbers types: </p> <table id="GUID-E5C3C773-3D6F-521C-B012-11A13E8008C7">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Name</b>  </p> </entry>
+<entry><p> <b> Endpoint number</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>aRealEndpoint</codeph>  </p> </entry>
+<entry><p>Canonical Endpoint Number </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>aEndpointNum</codeph>  </p> </entry>
+<entry><p>Virtual Endpoint Number </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>aAddress</codeph>  </p> </entry>
+<entry><p>Endpoint Address </p> </entry>
+</row>
+<row>
+<entry><p> <b>n/a</b>  </p> </entry>
+<entry><p>Physical Endpoint Number </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,243 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51" xml:lang="en"><title>Environment
+Slots</title><shortdesc>Up to 16 separate pieces of information can be passed to a process
+on creation using Environment Slots. These include handles and binary data.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Handles and binary data can be passed to a process at process creation
+time using environment slots. This topic describes this concept, and explains
+how to use the process APIs for environment slots. </p>
+<ul>
+<li id="GUID-1D2A9BFD-FAE6-55F0-9A54-58BA4165B1F0"><p> <xref href="GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51.dita#GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51/GUID-FCF8DC31-9D90-53C8-BE30-76D6CD0243BC">Overview</xref>  </p> </li>
+<li id="GUID-E2F77CE5-E856-582C-BF4F-0EF13E6A40D1"><p> <xref href="GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51.dita#GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51/GUID-D84521B5-4C3B-538C-946A-88EAA3713A8D">The APIs</xref>  </p> </li>
+<li id="GUID-8C3631E9-D240-5C72-A6E0-EF255A3C8D17"><p> <xref href="GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51.dita#GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51/GUID-7F6B118C-0911-5979-8420-475985DB884B">Passing a file handle and a subsession</xref>  </p> </li>
+<li id="GUID-3DDB166F-E949-5B0A-B4B9-FC6EE580ECCE"><p> <xref href="GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51.dita#GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51/GUID-19964DED-E6AD-59B4-BEDB-2A40864FBD29">Passing a general handle, derived from RHandleBase</xref>  </p> </li>
+<li id="GUID-D6A9288F-5B22-56B8-8F8E-738F7B38BD1E"><p> <xref href="GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51.dita#GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51/GUID-AAB81C64-A515-50E5-BF80-1D625AF1251C">Passing descriptor data</xref>  </p> </li>
+<li id="GUID-502C284C-3B56-5B6E-AEB5-F1E9DB513CA6"><p> <xref href="GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51.dita#GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51/GUID-D2F661C6-21EB-50A6-A475-2A4A775A9F4D">Passing an integer</xref>  </p> </li>
+<li id="GUID-E5B29175-9647-5F88-961C-47CD20DF2238"><p> <xref href="GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51.dita#GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51/GUID-02AD23DF-7D54-5178-AA5B-050333CD2609">Error handling issues</xref>  </p> </li>
+</ul>
+<section id="GUID-FCF8DC31-9D90-53C8-BE30-76D6CD0243BC"><title>Overview</title> <p>Handles
+and binary data, in the form of descriptors or integer values, can be passed
+to a process at process creation time, using what are called environment slots. </p> <p>Up
+to 16 separate pieces of information can be passed to a process on creation.
+For this purpose, a process has 16 environment slots that can contain the
+information passed to it by the launching process. </p> <p>Slot 0 is reserved
+and is never available for general purpose information passing. </p> <p>The
+parent (launching) process can only pass information to the child (created)
+process after the child process has been created. However, it should be done
+before the child process is resumed; it is an error to try and set environment
+data in a child process that has been resumed. </p> <p>A child process can
+only extract the information from its environment slots once. Extracting information
+from a slot causes that information to be deleted from the slot. </p> <p>It
+is a matter of convention between the parent and child process as to the meaning
+to be applied to a slot, and the type of data that it is to contain. </p> </section>
+<section id="GUID-D84521B5-4C3B-538C-946A-88EAA3713A8D"><title>The APIs</title> <p>To
+pass, a handle, a client server subsession, or binary data to a child process,
+the parent process calls <codeph>RProcess::SetParameter()</codeph>, where
+the <xref href="GUID-9DD1EA2B-DC59-315C-8E9C-CE6D9461B695.dita"><apiname>RProcess</apiname></xref> object represents the newly created child
+process. There are five overloaded variants of <codeph>SetParameter()</codeph> used
+for passing: </p> <table id="GUID-5BEA9FCB-68E8-56DD-BA60-71372984AA38">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>handle: </p> </entry>
+<entry><codeblock id="GUID-EA9128DD-3694-5A2B-AB86-78BA81B43F5A" xml:space="preserve">TInt RProcess::SetParameter(TInt aSlot, RHandleBase aHandle);</codeblock> </entry>
+</row>
+<row>
+<entry><p>client server subsession: </p> </entry>
+<entry><codeblock id="GUID-D7FFAA04-44E4-5C4C-8B3B-4628AB965B58" xml:space="preserve">TInt RProcess::SetParameter(TInt aSlot, const RSubSessionBase&amp; aSession);</codeblock> </entry>
+</row>
+<row>
+<entry><p>8-bit descriptor: </p> </entry>
+<entry><codeblock id="GUID-32499AC5-3C9F-5927-A797-24A0367E22A7" xml:space="preserve">TInt RProcess::SetParameter(TInt aSlot, const TDesC8&amp; aDes);</codeblock> </entry>
+</row>
+<row>
+<entry><p>16-bit descriptor: </p> </entry>
+<entry><codeblock id="GUID-1997FC14-79C7-5DEC-9647-9FA14CB8EE84" xml:space="preserve">TInt RProcess::SetParameter(TInt aSlot, const TDesC16&amp; aDes);</codeblock> </entry>
+</row>
+<row>
+<entry><p>integer: </p> </entry>
+<entry><codeblock id="GUID-0F865FC0-C2D7-55A5-B90A-17F88958F6D9" xml:space="preserve">TInt RProcess::SetParameter(TInt aSlot, TInt aData);</codeblock> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>To extract, a handle, or a client server subsession, a child process
+can use the <codeph>Open()</codeph> function called on the relevant <xref href="GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB.dita"><apiname>RHandleBase</apiname></xref> derived
+type: </p> <codeblock id="GUID-244AB92B-34FD-5B45-B0AA-1679D3DD9761" xml:space="preserve">TInt RSemaphore ::Open(TInt aArgumentIndex, TOwnerType aType=EOwnerProcess);
+TInt RBusLogicalChannel::Open(TInt aArgumentIndex, TOwnerType aType=EOwnerProcess);
+TInt RMsgQueueBase::Open(TInt aArgumentIndex, TOwnerType aType=EOwnerProcess);
+TInt RMutex::Open(TInt aArgumentIndex, TOwnerType aType=EOwnerProcess);
+TInt RChunk::Open(TInt aArgumentIndex, TOwnerType aType=EOwnerProcess);
+TInt RSessionBase::Open(TInt aArgumentIndex, TOwnerType aType=EOwnerProcess);
+    </codeblock> <p>To extract descriptor data, or integer data, a child process
+can use the <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita"><apiname>User</apiname></xref> class functions: </p> <codeblock id="GUID-CC129A19-0FF6-58C6-B11C-564D816BF845" xml:space="preserve">static TInt User::ParameterLength(TInt aSlot);
+static TInt User::GetTIntParameter(TInt aSlot, TInt&amp; aData);
+static TInt User::GetDesParameter(TInt aSlot, TDes8&amp; aDes);
+static TInt User::GetDesParameter(TInt aSlot, TDes16&amp; aDes);
+    </codeblock> <fig id="GUID-D9CD78E1-6813-5F68-9883-F1F6DC04C92A">
+<title>Environment slots</title>
+<image href="GUID-ABE7BC1A-C51B-5ADD-8568-87A81423B648_d0e77808_href.png" placement="inline"/>
+</fig> </section>
+<section id="GUID-7F6B118C-0911-5979-8420-475985DB884B"><title> Passing a
+file handle and a subsession</title> <p>File server session handles and file
+handles can both be passed to a child process. </p> <p>The child process adopts
+the file handle, and must not be closed by the parent. To use a file handle,
+the session handle must also be passed. </p> <p>For <i>security reasons</i>,
+when sharing a file handle, the parent process should create a separate file
+server session for the specific purpose of sharing the file handle. If the
+parent process has other files open with this file server session, the child
+process can gain access to those files by iterating through all the possible
+values for the file handle and attempting to <codeph>Adopt()</codeph> each
+one. For the same reason, the child process should only use this session for
+sharing the file; it should not access other files through this session. </p> <p>The
+following two code fragments show code in the parent process and corresponding
+code in the child process. </p> <codeblock id="GUID-202421E4-5ADA-50A8-AE75-32F1071C64B0" xml:space="preserve">//Code in the parent (launching) process
+
+    RProcess p;
+    p.Create(KProcName, KNullDesC);    //create “child” process
+    
+    RFile file;
+    RFs session;
+    session.Connect();                //connect to file server
+    session.ShareProtected();
+    file.Create(iSession, KFileName, EFileStreamText|EFileWrite|EFileShareAny);
+    file.Write(0, KTestData);
+    
+    p.SetParameter(5, session);        //session handle passed in slot 5
+    p.SetParameter(6, file);        //file handle passed in slot 6
+    Session.Close();
+    p.Resume();
+  </codeblock> <p> <codeph>KProcName</codeph> is the full path name of the
+executable associated with the child process, and <codeph>KFilename</codeph> is
+the file name. </p> <codeblock id="GUID-AE2354AA-D95A-5291-BFC4-1EDF470D65AE" xml:space="preserve">//Code in the child (launched) process
+
+    RFs session;
+    session.Open(5);            //obtain session handle from slot 5
+    
+    RFile file;
+    TInt handle;
+    ret = User::GetTIntParameter(8, handle);//get file handle from slot 8
+    file.Adopt(session, handle);            //adopt the handle
+    TBuf8&lt;100&gt; rbuf;                         //use the file
+    ret = file.Read(0, rbuf);
+    file.Close();
+    session.Close();
+  </codeblock> </section>
+<section id="GUID-19964DED-E6AD-59B4-BEDB-2A40864FBD29"><title> Passing a
+general handle, derived from RHandleBase</title> <p>General handles derived
+from <xref href="GUID-727D2B62-09A9-3CBC-AB6F-591E52EC68EB.dita"><apiname>RHandleBase</apiname></xref> can be passed to a child process. </p> <p>The
+handle is duplicated when it is stored in the child process’s environment.
+The parent can close the handle immediately after calling <codeph>SetParameter()</codeph>,
+or continue to use the handle and close it later. </p> <p>The following two
+code fragments show code in the parent process and corresponding code in the
+child process. </p> <codeblock id="GUID-591C111A-05B8-5247-84C1-411650AA1FB0" xml:space="preserve">//Code in the parent (launching) process,
+//passing handles to a mutex and a semaphore.
+
+    RMutex mutex;
+    RSemaphore sem; 
+    
+    RProcess p;
+    p.Create(KProcName, KNullDesC);
+    mutex.CreateGlobal(KMutexName);    //create the mutex
+    sem.CreateGlobal(KSemName,0);    //create the semaphore
+    p.SetParameter(3, mutex);    //put mutex handle into child process env' slot 3
+    p.SetParameter(4, sem);        //put semaphore handle into child process env' slot 4
+    mutex.Close();
+    Sem.Close();
+    p.Resume();            //resume the child process
+    </codeblock> <codeblock id="GUID-78E31AB6-4900-5AE8-9755-8ACDD8265235" xml:space="preserve">//Code in the child (launched) process retrieving the handles.
+    
+    RMutex mutex;
+    mutex.Open(3, EOwnerThread);    //get mutex handle
+    RSemaphore sem;
+    sem.Open(4, EOwnerThread);        //get semaphore handle
+    
+    //use the semaphore and mutex
+    mutex.Close();
+    sem.Close();
+    </codeblock> </section>
+<section id="GUID-AAB81C64-A515-50E5-BF80-1D625AF1251C"><title> Passing descriptor
+data</title> <p>Both 8-bit and 16-bit descriptor data can be passed from a
+parent to a child process. </p> <p>Internally, an <xref href="GUID-5BEA9976-B969-3949-B855-E657FFF38EE2.dita"><apiname>HBuf</apiname></xref> descriptor
+is created containing the passed descriptor data, and a pointer to this descriptor
+is passed in the relevant slot. </p> <p>The child process retrieves the descriptor
+data by calling <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-54C7406E-C498-3BE7-BB2C-1C5BA902A4D7"><apiname>User::GetDesParameter()</apiname></xref>. It can get the
+length of the data by calling <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-ABD3F4AE-C226-3AF1-AD25-7A45B186385C"><apiname>User::ParameterLength()</apiname></xref>. </p> <p>The
+following two code fragments show code in the parent process and corresponding
+code in the child process. </p> <codeblock id="GUID-57FFCAC9-CA4E-50B7-843A-0523243F5B1E" xml:space="preserve">//Code in the parent (launching) process, passing 8 and sixteen bit data
+
+    RProcess p;
+    p.Create(KProcName, KNullDesC);
+    p.SetParameter(2, KSixteenBitDes);
+    p.SetParameter(3, KEightBitDes);
+    p.Resume();
+    </codeblock> <p>where <codeph>KSixteenBitDes</codeph> is a 16-descriptor,
+and <codeph>KEightBitDes</codeph> is an 8-bit descriptor. </p> <codeblock id="GUID-8B442CA2-0A6A-546C-805B-99C306891B40" xml:space="preserve">//Code in the child (launched) process retrieving 8 and sixteen bit data
+    
+    TInt len;
+    TInt ret;
+
+    TBuf16&lt;40&gt; buf;
+    len = User::ParameterLength(2);        //parameter length is the size in bytes
+    ret = User::GetDesParameter(2, buf);
+    
+    //buf.Length() should have the value of len/2;
+
+
+    TBuf8&lt;40&gt; buf8;
+    len = User::ParameterLength(3);
+    ret = User::GetDesParameter(3, buf8);
+    //buf.Length() should be the same as len
+    </codeblock> <p>Note that the descriptors, <codeph>buf</codeph>, and <codeph>buf8</codeph> used
+in the child process must have sufficiently large maximum lengths to accomodate
+the data. </p> </section>
+<section id="GUID-D2F661C6-21EB-50A6-A475-2A4A775A9F4D"><title>Passing an
+integer</title> <p>An integer can be passed from a parent to a child process. </p> <p>The
+following two code fragments show code in the parent process and corresponding
+code in the child process. </p> <codeblock id="GUID-AA845210-E551-50B3-9E1F-CD6F8C37D13B" xml:space="preserve">//Code in the parent (launching) process
+
+    RProcess p;
+    TInt ret;
+ 
+    ret = p.Create(KProcName, KNullDesC);
+    p.SetParameter(12, 1234);  // Using slot 12
+    p.Resume();
+    </codeblock> <codeblock id="GUID-D5E4CFA8-15DA-543F-9616-7F075FBBCDC1" xml:space="preserve">//Code in the child (launched) process, retrieving the integer.
+
+    TInt val;
+    TInt ret;
+
+    ret = User::GetTIntParameter(12, val);
+
+    </codeblock> </section>
+<section id="GUID-02AD23DF-7D54-5178-AA5B-050333CD2609"><title>Error handling
+issues</title> <p>The parent process is panicked when calling <codeph>SetParameter()</codeph> with
+a handle if: </p> <ul>
+<li id="GUID-1BDFA3C0-0E69-5B0C-A27F-D2DEFC0B2C0F"><p>the parent process is
+not the creator of the child process </p> </li>
+<li id="GUID-1DF3C097-73AC-54B8-9654-435C6F163E95"><p>the slot number is out
+of range, i.e. is not in the range 0 to 15 </p> </li>
+<li id="GUID-B02324A1-D241-5103-A2EC-297474EF65E1"><p>the slot is in use </p> </li>
+<li id="GUID-6014D837-107F-536C-8947-74C5967D2264"><p>the handle is local. </p> </li>
+</ul> <p>The parent process is panicked when calling <codeph>SetParameter()</codeph> with
+a descriptor or integer if: </p> <ul>
+<li id="GUID-2FAF76CC-2569-5E2E-ADBA-AFA124F11C84"><p>the parent process is
+not the creator of the child process </p> </li>
+<li id="GUID-C23722B2-4EEB-5050-B82E-F58F450F088F"><p>the slot number is out
+of range, i.e. is not in the range 0 to 15 </p> </li>
+<li id="GUID-9ADA7D18-B084-509C-8F4A-66E885F61D0A"><p>the slot is in use </p> </li>
+<li id="GUID-32B64BAC-F13E-5029-93ED-642994E35886"><p>the length of the data
+is negative. </p> </li>
+</ul> <p>The child process is panicked if the slot number is out of range. </p> <p>The
+API functions that extract data from the process environment return <xref href="GUID-0BEA3647-7888-3612-A2D3-7E27AC405E29.dita"><apiname>KErrArgument</apiname></xref> if
+a slot contains the incorrect data type, or the length is incorrect. They
+return <xref href="GUID-5E653C17-372C-32E1-A1B2-9E69A9991C40.dita"><apiname>KErrNotFound</apiname></xref> if a slot is empty. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-ADB848FD-317A-521C-9684-BBCF20358207.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,86 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-ADB848FD-317A-521C-9684-BBCF20358207" xml:lang="en"><title>Architecture</title><shortdesc>Describes the USB client architecture.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Symbian platform provides access to USB client hardware through its USB
+client driver. </p>
+<p>The following diagram shows the USB client architecture. Devices can provide
+more than one USB function. To better show the typical use, the diagram shows
+the components in use with a phone that is configured as a combined
+WHCM and OBEX peripheral. </p>
+<fig id="GUID-8627CEA3-B570-5DA0-AE30-32C9AE08F041">
+<image href="GUID-365283F1-54B4-519A-81EC-9B5018896DDE_d0e35432_href.png" placement="inline"/>
+</fig>
+<p>There are three main elements: </p>
+<ul>
+<li id="GUID-95956004-F78F-53E5-A2F3-693B48D344E8"><p>The user side interface
+to the USB client driver. </p> </li>
+<li id="GUID-6461280C-469F-5726-AE69-9A88ADCC95AB"><p>The USB client driver
+LDD that provides the driver's logical channel. This is hardware independent. </p> </li>
+<li id="GUID-FD47D854-620E-5E2A-9A59-79B4901477D2"><p>The PDD, or client controller,
+that manages access to the USB client hardware. </p> </li>
+</ul>
+<section id="GUID-57BF46A0-0FE2-4074-87DF-A0C55AA29F1F"><title>User API</title> <p>The user side interface to the USB client
+driver is provided by <xref href="GUID-B1E32178-3B7C-3B00-A0AF-62ECE40E8598.dita"><apiname>RDevUsbcClient</apiname></xref>. The user side interface
+is implemented as a set of inline functions and means that there is no separate
+user side library component. This is typically the case for device drivers. </p> </section>
+<section id="GUID-2C341305-95E0-53C4-B4D5-1BB03CCB8C52"><title>USB client
+driver (LDD)</title> <p>The USB client driver provides an interface to the
+USB client device. The USB client driver is also referred to as a <i>channel</i> to
+the USB client device; it may also be referred to as the USB logical device
+driver. </p> <p>Each user component that requires a connection to the USB
+client device opens a channel using the user side <xref href="GUID-B1E32178-3B7C-3B00-A0AF-62ECE40E8598.dita"><apiname>RDevUsbcClient</apiname></xref> class. </p> <p>A
+channel supports only one USB interface. A channel (i.e. the USB LDD) can
+be loaded as many times as needed; the decision is based on the number of
+interfaces required. This can be done either in the same process or in a different
+process depending on the relationship between the interfaces. </p> <p>If there
+is more than one channel open on the USB client device, then they can all
+share Control Endpoint 0 (Ep0). Each channel can make a request on this endpoint.
+The other endpoints cannot be shared between channels; instead each endpoint
+is used exclusively by one, and only one, channel. </p> <p>Each channel can
+claim up to a maximum of <i>five</i> endpoints in addition to Ep0. Each endpoint
+claimed on a channel is locally numbered from one and five. This number need
+not correspond to the actual endpoint number of the hardware interface; this
+number is called the logical endpoint number, and all transfer requests use
+the logical number for the endpoint. A driver can, however, discover the physical
+endpoint address of a logical endpoint by requesting the endpoint descriptor. </p> <p>A
+channel can have asynchronous requests outstanding on one or more of its endpoints
+simultaneously; this includes Ep0. As Ep0 can be shared between channels,
+then the underlying USB Controller must manage multiple requests on this endpoint </p> </section>
+<section id="GUID-660CC1A9-26B5-5869-ADC9-53196AF5F387"><title>USB client
+controller (PDD)</title> <p>The USB client controller manages access to the
+USB client hardware on behalf of all USB client drivers. It has a two layer
+implementation: </p> <ul>
+<li id="GUID-A90C62D9-60B0-5542-9D93-683A7C02EDB2"><p>a licensee product independent
+layer that provides an API for the USB client driver. This is often referred
+to as the Platform Independent Layer, and forms the 'upper' part of the USB
+physical device driver (PDD). </p> </li>
+<li id="GUID-4637A61F-A1D7-522A-B824-4603AF129442"><p>a layer that interfaces
+with the hardware. This is often referred to as the Platform Specific Layer,
+and forms the 'lower' part of the USB physical device driver (PDD). <i>It
+is this part that needs porting effort</i>. </p> </li>
+</ul> <p>The Platform Independent Layer contains, as far as possible, the
+functionality that is defined in the USB specification. This includes the
+‘Chapter 9’ device state handling and request processing. The Platform Specific
+Layer contains only that functionality which cannot be abstracted and made
+generic, because different USB Device Controller designs are programmed differently
+and operate differently. </p> <p>The complete USB client controller (PDD)
+is an instance of a <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita"><apiname>DUsbClientController</apiname></xref> derived class
+and is implemented as a kernel extension named <filepath>usbcc.dll</filepath>. </p> <p>The
+functionality of the Platform Independent Layer is provided by the base class <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita"><apiname>DUsbClientController</apiname></xref>.
+This class also defines a large number of pure virtual functions that are
+intended to provide the functionality that is not part of the USB specification,
+but is specific to the USB Device Controller. Such functions typically implement
+direct USB Device Controller hardware manipulation, register access, endpoint
+FIFO loading/unloading etc. The platform specific layer provides the implementation
+for these pure virtual functions by defining and implementing a device specific
+class derived from <codeph>DUsbClientController</codeph>. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-ADC42B89-B061-50C3-B532-6065A0C418C3.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-ADC42B89-B061-50C3-B532-6065A0C418C3" xml:lang="en"><title>USB Shared Chunks</title><shortdesc>The USB client Logical Device Driver (LDD) API has been extended to share chunks between the kernel side USB LDD and the user side USB applications such as Mass Storage. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody><p>Shared chunks improve performance by eliminating the need to copy data between different processes. USB client application efficiency will be improved by sharing chunks from the kernel side drivers to the application. </p> </conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-AE486C82-8854-463F-8CB9-B7353D6B2804.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-AE486C82-8854-463F-8CB9-B7353D6B2804" xml:lang="en"><title>Baseport Template Build Guide</title><shortdesc>Describes how to build a Baseport Template.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Baseport Template contains dummy functions. The Baseport Template
+is designed to boot without supporting any peripherals. The developers
+should port the individual drivers depending on the hardware used.
+This guide describes a generic build procedure for ARMv5 based devices.</p>
+<section id="GUID-E2165A61-5BC5-4334-918C-17DE643D7DC5"><title>Template
+port</title>             <p>The baseport code is available at <filepath>os/kernelhwrrv/bsptemplate/asspandvariant/template_variant/</filepath>. The comments in the Baseport Template provide enough information
+to start porting.</p>       </section>
+<section id="GUID-4F0686BA-C7D4-45D1-B40F-648696B056A0"><title>Procedure</title><p>The following steps describe how to build the Baseport Template
+for an ARMv5 processor.</p><ol>
+<li id="GUID-DC469030-5658-4C24-B7A8-00249417F86E"><p>Create a file,
+for example, <filepath>commands.txt</filepath> that contains the list
+of files to be built. Each line of <filepath>commands.txt</filepath> would be in the following example format:</p><codeblock xml:space="preserve">-b \os\buildtools\toolsandutils\e32tools\group\bld.inf</codeblock></li>
+<li id="GUID-091F9D98-20B3-49BB-8080-42E35C032154"><p>Call <filepath>commands.txt</filepath> file using the following command:</p><codeblock xml:space="preserve">sbs –command=commands.txt –c armv5_urel</codeblock><note> The above
+would produce a armv5 urel version.</note></li>
+</ol></section>
+</conbody><related-links>
+<link href="http://developer.symbian.org/wiki/index.php/Raptor_Build_System.dita"><linktext>Symbian Build System v2</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-AE53C15E-0C0F-5726-BBA4-E7DCDA7F48B4-master.png has changed
Binary file Adaptation/GUID-AE53C15E-0C0F-5726-BBA4-E7DCDA7F48B4_d0e9145_href.png has changed
Binary file Adaptation/GUID-AEDBF425-6077-4C84-A698-508291671F2B-master.png has changed
Binary file Adaptation/GUID-AEDBF425-6077-4C84-A698-508291671F2B_d0e27993_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-AF245763-EB25-49BC-90DC-0BD5F2D22AA5.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,74 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-AF245763-EB25-49BC-90DC-0BD5F2D22AA5" xml:lang="en"><title>Specific
+Build Information</title><shortdesc>This document discusses the details of the build procedure which
+are specific to device drivers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-093E4B03-8B84-4088-BEC9-9F6E09594E6D">       <title>Building
+device drivers</title>       <p>Building a device driver is similar to building
+any other component in Symbian platform. This section discusses the details
+that are specific to drivers, and assumes that you are familiar with the Symbian
+platform build tools. </p> <p>Device drivers can be built either by using
+console commands (<filepath>bldmake</filepath> and <filepath>abld</filepath>)
+or by using an IDE. Any project can be built for multiple platforms. Generally,
+it is either ARM for the hardware target or WINSCW for the emulator target.
+For hardware target builds, the build can be for ARMV5, ARMV6, and Thumb,
+while for emulator builds, the platform is WINSCW. The compilers used for
+ARM are the ARM RVCT compiler or, in earlier versions of the platform,
+a version of the GNU GCC compiler. For the emulator, the compiler is the Carbide.c++
+or Metrowerks CodeWarrior compiler. </p> <p>The <filepath>.mmp</filepath> file
+(project file) specifies the source files to build and the platform for which
+the target binary will be built. </p>     </section>
+<section id="GUID-E42B5D1E-5244-4A30-AA83-FB7331EE1934"><title>Variant specific target </title> <p>When a target is specified
+using the keyword <codeph>VariantTarget()</codeph>, the build tools generate
+a unique name for the binary by adding the variant name. This allows separate
+binaries to be created for each variant, and prevents the current binary being
+overwritten. </p> <p>For example, if the target to be built is <filepath>d_expio_ldd.ldd</filepath>,
+then <filepath>VariantTarget(d_expio_ldd,ldd)</filepath> would be specified
+in the <filepath>.mmp</filepath> file. If the project is then built for the <codeph>h4hrp</codeph> variant,
+the final target binary built is called <filepath>_h4hrp_d_expio_ldd.ldd</filepath>. </p></section>
+<section id="GUID-F78A81DF-5482-4D63-934D-33AB078B831C"><title>ROM image build</title> <p>To include a driver in a ROM image,
+the driver's files must be included in the corresponding obey files (<filepath>.oby</filepath>).
+In the base subsystem, the binaries are specified in <filepath>.iby</filepath> files,
+and the <filepath>.iby</filepath> files are then included in <filepath>.oby</filepath> files. </p> <p>For
+example, to include a driver in the H4 text shell ROM image, it should be
+included in <filepath>kernel.iby</filepath>. This file is located in <filepath>base\omap_hrp\h4\rom\</filepath>,
+and exported to <filepath>epoc32\rom\h4hrp</filepath>. Similarly for the TechView
+ROM build, the relevant file is <filepath>base_h4hrp.iby</filepath> file,
+which is located in <filepath>base\omap_hrp_h4\rom\</filepath>, and exported
+to <filepath>epoc32\rom\include</filepath>. An example from an <filepath>.iby</filepath> file
+is shown below: </p> <codeblock id="GUID-2A6C74C8-050F-555C-8E50-C92169A513B2" xml:space="preserve">// .iby file
+
+/**
+##KMAIN## gets the path for e32
+##BUILD## gets the build – udeb/urel according to build
+##VARIANT gets the target from corresponding variant  
+*/
+
+device[VARID]=\EPOC32\RELEASE\##KMAIN##\##BUILD##\d_expio_ldd.ldd sys\bin\d_expio_ldd.ldd 
+
+device[VARID]=\EPOC32\RELEASE\##KMAIN##\##BUILD##\_##VARIANT##_d_expio_pdd.pdd sys\bin\d_expio_pdd.pdd</codeblock> <p>On
+building the test .inf files, test <filepath>.iby</filepath> files will be
+generated. This includes the newly added binaries in the <filepath>.iby</filepath> file. </p> <p>After
+building the drivers, a ROM can be built. Device driver and base developers
+generally build text shell ROM images for development and testing. These can
+be built using the <filepath>rom</filepath> tool (from <filepath>base\e32\rombuild</filepath>).
+By default, the ROM image is generated in that directory. An alternate path
+can also be specified. </p> <p>For example, for the H4HRP variant, a text
+shell ROM image is built using: </p> <p><userinput>rom –v=h4hrp –I=armv5 udeb</userinput> </p> <p>This
+builds a ROM called <filepath>H4HRPARMV5D.IMG</filepath>, which can then be
+downloaded to target hardware and tested. </p> <p>To include base test programs
+in a ROM image, the option <codeph>–type</codeph> can be used. For example: </p> <p><userinput>rom
+–v=h4hrp –I=armv5 udeb –type=e32tests</userinput> </p> <p>This includes the
+tests from <filepath>base\e32test</filepath>. The tool uses as input a generated
+or precompiled <filepath>oby</filepath> file, which includes all the generated
+test <filepath>.iby</filepath> files. </p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-AF2E227B-C5BD-5F05-98D4-7D15530161C8.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-AF2E227B-C5BD-5F05-98D4-7D15530161C8" xml:lang="en"><title>Interrupt::Clear()</title><shortdesc>Describes the implementation of the clear function.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The function <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-DB641A23-82B2-373E-A514-E11118CB6E69"><apiname>Interrupt::Clear()</apiname></xref> is used by device drivers
+to acknowledge that they have serviced the interrupt and cleared the pending
+flag in the interrupt controller hardware. </p>
+<p>This is useful in situations where an interrupt must be cleared explicitly
+rather than as a side effect of an I/O register access, especially where the
+clearing is done from generic code such as in the PC card and MMC controllers. </p>
+<p>The implementation of this function is completely dependent on the interrupt
+hardware. </p>
+<p>In the template port, <codeph>Interrupt::Clear()</codeph> is implemented
+in <filepath>...\template_assp\interrupts.cpp</filepath>. </p>
+<codeblock id="GUID-7612CEB2-7ADA-552D-9BB9-B0B1B2D8E4BC" xml:space="preserve">EXPORT_C TInt Interrupt::Clear(TInt anId)
+    {
+     __KTRACE_OPT(KEXTENSION,Kern::Printf("Interrupt::Clear id=%d",anId));
+     TInt r=KErrNone;
+     // if ID indicates a chained interrupt, call variant...
+     if (anId&lt;0 &amp;&amp; ((((TUint)anId)&gt;&gt;16)&amp;0x7fff)&lt;(TUint)KNumTemplateInts)
+         r=TemplateAssp::Variant-&gt;InterruptClear(anId);
+     else if ((TUint)anId&gt;=(TUint)KNumTemplateInts)
+         r=KErrArgument;
+     else
+         {
+         //
+         // TO DO: (mandatory)
+         //
+         // Clear the corresponding Hardware Interrupt source
+         //
+        }
+    return r;
+    }</codeblock>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,216 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07" xml:lang="en"><title>Channel
+Implementation</title><shortdesc>Describes how to use the template port to implement the physical
+channel for the Digitizer Driver. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-EA342370-0293-5762-86FD-E86DC6BC3006"><title>Define the
+size of the digitizer</title> <p>The following four constants defined at the
+top of the template implementation in <filepath>xyin.cpp</filepath> define
+the origin and size of the digitizer device in pixels. Modify the values to
+define your own origin and size. </p> <codeblock id="GUID-8A7E9CCC-D6A2-5E5D-B0DB-8AE3334F6EC9" xml:space="preserve">const TUint KConfigXyOffsetX    = 0;
+const TUint KConfigXyOffsetY    = 0;
+const TUint KConfigXyWidth = 640;  // pixels per line
+const TUint KConfigXyHeight = 480; // lines per panel
+</codeblock> <p>This is information that is returned when calls are made: </p> <ul>
+<li id="GUID-003FE140-2DDF-58B4-AA1F-57F8A0FCF4E7"><p> <i>user side</i> to <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-573C49D6-7763-37AE-B2B2-4C8FB1327E21"><apiname>HAL::Get()</apiname></xref> passing
+the attribute(s) <xref href="GUID-696EDBEB-76B2-3F02-AD33-BA4977551F32.dita"><apiname>EPenX</apiname></xref> and <xref href="GUID-3E3B49CC-53F6-3341-A969-1DDC0A837B0B.dita"><apiname>EPenY</apiname></xref>  </p> </li>
+<li id="GUID-0C5E452E-5564-5A27-B379-5BF3D9518E78"><p> <i>kernel side</i> to <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-DA115709-A225-3E2A-BCCD-6E2BB15979B9"><apiname>Kern::HalFunction()</apiname></xref>,
+passing group <xref href="GUID-357CC84A-F701-3F56-AF4D-0C95002F1A8E.dita"><apiname>EHalGroupdigitizer</apiname></xref> and function-id <xref href="GUID-841ECDFD-7CAB-30BB-A301-CF70C029043B.dita"><apiname>EdigitizerHalXYInfo</apiname></xref>  </p> </li>
+</ul> <p>See <xref href="GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8.dita#GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8/GUID-4DA41221-40B9-5BC7-B2C6-7C6EB4522508">User-Side
+Hardware Abstraction</xref>. </p> <p>The following four constants define the
+digitizer origin and size in digitizer ADC coordinates. Modify the values
+for your own digitizer: </p> <codeblock id="GUID-ED04E417-16B5-5AA2-96FB-B450BAC272A9" xml:space="preserve">const Tint KConfigXySpreadX = 4096; // maximum valid X spread
+const Tint KConfigXySpreadY = 4096; // maximum valid Y spread
+const Tint KConfigXyMinX = 0;       // minimum valid X value
+const Tint KConfigXyMinY = 0;       // minimum valid Y value
+</codeblock> </section>
+<section id="GUID-A4B43E01-9638-5967-8EFA-0AABA33189EA"><title>Implement power
+on behaviour</title> <p>In the template port, this is implemented by <b>DTemplatedigitizer::digitizerPowerUp()</b>.
+Note that this function is not derived from any base class function. </p> <ul>
+<li id="GUID-2B31DD8F-DACF-50FD-8FC6-DC6C55954CC5"><p>Add code to this function
+to do these things: </p> <ol id="GUID-324D32A9-50F0-53F9-A717-AE026626A76E">
+<li id="GUID-7A461F0B-EBEE-5F73-BFA1-031EEAB9BCF9"><p>Clear all digitizer
+interrupts. </p> </li>
+<li id="GUID-62182E91-A6B0-5C3C-8CC5-4C993235EF02"><p>Request power resources
+from the power controller. This will power the device up from sleep mode.
+Note that power up, and power down, can be implemented later. </p> </li>
+<li id="GUID-D9CFB381-4D23-5E47-808B-C5CE52F99223"><p>Configure the hardware
+so that it generates an interrupt when the digitizer is touched. </p> </li>
+</ol> </li>
+<li id="GUID-AFFF418C-9FD7-5EE6-9487-968FDCF7B795"><p>Make sure that the digitizer
+interrupt is defined. In the template port, the interrupt id is defined as
+the constant: </p> <codeblock id="GUID-7D7940D8-4708-501C-AA44-1C9A6961260A" xml:space="preserve">const TInt KIntIddigitizer=EAsspIntIdC</codeblock> <p>in
+the file <filepath>...\template\template_assp\template_assp.h</filepath>. </p> </li>
+<li id="GUID-EE388EFA-84D7-5E1E-A75F-66310EAEF8E5"><p>Make sure that the interrupt
+controller is configured for the digitizer interrupt. See <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita">Interrupt
+Dispatcher</xref>. </p> </li>
+</ul> </section>
+<section id="GUID-1A1194A0-DF74-59E7-B3AD-FD87D501F00F"><title>Implement Ddigitizer::WaitForPenDown()</title> <p>This
+code is executed at startup or whenever the pen is lifted up. It implements
+a request for an interrupt to be generated when the pen next touches the digitizer.
+It is called by the platform independent layer: </p> <ul>
+<li id="GUID-1D1D1ED7-12EC-51B9-A5B7-228E0390DF4C"><p>at startup </p> </li>
+<li id="GUID-C8999684-87B6-5DDA-AB4F-D990B7512365"><p>when the pen is removed
+from the digitizer after a pen-up event has been issued. </p> </li>
+</ul> <p>There are two main cases to deal with: the digitizer is powering
+down; the digitizer is not powering down </p> <p id="GUID-9DC378A0-05F9-52B0-A441-1E451E85D213"><b>The
+digitizer is powering down</b> </p> <p>The implementation for this case can
+be left until later. It is discussed in <xref href="GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07.dita#GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07/GUID-FE7F24DF-6A65-5A7E-A9C8-DBCF7848DEA6">Implement
+power up and power down handling</xref>. </p> <p id="GUID-4B4CF159-E5B2-5EAA-8489-8E1921BA0AF1"><b>The
+digitizer is <i>not</i> powering down</b> </p> <p>To deal with this case,
+your implementation needs to: </p> <ul>
+<li id="GUID-633792DB-C955-57E0-8DB1-2FDB2EC20269"><p>clear the digitizer
+interrupt </p> </li>
+<li id="GUID-2F88C290-C412-50EF-8E2C-BE0CC5A489DA"><p>set up the hardware
+so that it can detect when the digitizer is touched. </p> </li>
+</ul> <p>The pen interrupt is now enabled; if the digitizer is now touched,
+the pen interrupt ISR (interrupt service routine) <codeph>DTemplatedigitizer::PenInterrupt()</codeph> is
+called. </p> <p>In the template port, the ISR includes the statement: </p> <codeblock id="GUID-351F56AC-8B3D-55F6-B3EC-77F623C18BE1" xml:space="preserve">__KTRACE_OPT(KHARDWARE,Kern::Printf("I"));</codeblock> <p>and
+means that if the <codeph>KHARDWARE</codeph> tracing flag has been set, and
+tracing is on, then a single “I” is printed whenever the digitizer is touched. </p><b>Tracing
+note</b> <p>If the <codeph>KEXTENSION</codeph>, <codeph>KPOWER</codeph> and <codeph>KHARDWARE</codeph> tracing
+flags have been set, and tracing is on, then by the time <codeph>WaitForPenDown()</codeph> is
+called, you should be able to see the following sequence of calls in the trace:<ul>
+<li><p><codeph>DoCreate()</codeph></p></li>
+<li><p><codeph>digitizerPowerUp()</codeph></p></li>
+<li><p><codeph>WaitForPenDown()</codeph></p></li>
+</ul></p> </section>
+<section id="GUID-D74C94E4-83AD-5BC0-B435-754E7D3FECA4"><title>Implement the
+pen interrupt ISR</title> <p>In the template port, the interrupt service routine
+(ISR) that handles a pen interrupt is implemented by <b>DTemplatedigitizer::PenInterrupt()</b>.
+Note that this function is not derived from any base class function. </p> <p>There
+are two main things to consider here: </p> <ol id="GUID-4CD5BC52-AC79-55E8-B38F-EA9DCB048A04">
+<li id="GUID-4D9F1CC5-E256-53F7-8E7D-B31ED3296C7D"><p>You need to add code
+to the start of the function to decide whether the pen is now up (i.e. removed
+from the screen panel), or whether the pen is now down (i.e. touching the
+digitizer panel). To make the decision, you may need to read the appropriate
+hardware register. The detail depends on the hardware. </p> </li>
+<li id="GUID-4FF2D674-4BB1-50EB-B55C-DF18652A1E5F"><p>If the pen is down,
+you need to check the value of the configurable constant <xref href="GUID-3574BE12-9DA9-573D-8545-3B073005A139.dita#GUID-3574BE12-9DA9-573D-8545-3B073005A139/GUID-587D0895-7B8D-5FA1-A2DE-2F346780BB78">KPenDownDelayTime</xref>. What you do next depends on the value of this constant: </p> <ul>
+<li id="GUID-C238E00E-7A7C-5A44-A63D-5D214C30727D"><p>If the value is greater
+than zero, then you do not need to change the code at this time. The existing
+code just starts a timer to delay the beginning of the collection of samples.
+Note, however, that you will need to modify the debounce timer callback function <codeph>timerIntExpired()</codeph> to
+clear the digitizer interrupt - see <xref href="GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07.dita#GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07/GUID-7ADA202E-23F8-52E1-BE57-B44FF75C5612">Add
+code to the debounce timer callback function</xref>. </p> </li>
+<li id="GUID-985A0D59-B45D-59D3-894F-9B9509B03E70"><p>If the value is zero,
+then you must clear the digitizer interrupt here in this function, <codeph>PenInterrupt()</codeph>. </p> </li>
+</ul> </li>
+<li id="GUID-B2766A95-D916-428F-84AE-2D4ADDFF999A"><p>To contribute the timing
+of pen interrupts as a source of random data for the Random Number Generator
+(see <xref href="GUID-8290AAF0-577C-51D2-8AC1-0D37A10F45CB.dita">CSPRNG Implementation
+in Kernel</xref>), ensure that a call to <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-C46E48EE-6F4A-3A61-A3C9-84B145119541"><apiname>Interrupt::AddTimingEntropy()</apiname></xref> is
+made in the ISR.</p></li>
+</ol> </section>
+<section id="GUID-4B0737BA-74E2-5FF2-BCE3-4BC822C14470"><title>Initialise
+sampling</title> <p>In the template port, the initialisation of sampling is
+implemented in the first half of the function <b>DTemplatedigitizer::TakeSample()</b> function.
+Note that this function is not derived from any base class function. </p> <p>There
+are two main things to consider here: </p> <ol id="GUID-1101F7D6-EDEF-5B9F-832C-75D298ACF1E4">
+<li id="GUID-A56C4872-FDD0-571C-A721-C267BB1DFD5C"><p>You need to decide whether
+the pen is up or down. Set the variable <codeph>penDown</codeph> to <xref href="GUID-781E8158-805B-3784-8FED-D7A191822FC3.dita"><apiname>ETrue</apiname></xref> if
+the pen is down or <xref href="GUID-A759CA2D-8327-348F-9337-4886E619D920.dita"><apiname>EFalse</apiname></xref> if the pen is up. </p> <p>To
+do this you may need to read the appropriate hardware register - the detail
+depends on the hardware. </p> </li>
+<li id="GUID-4B498AD5-766B-57DF-8021-2A7BB7FB5C19"><p>Change the section of
+code that is executed when the pen is found to be up after a power on, i.e.
+the block of code: </p> <codeblock id="GUID-4CE73640-1D2F-50F2-AD85-92B2F0FA35DC" xml:space="preserve">if (iState==E_HW_PowerUp)
+    {
+    if (!penDown)
+        {
+        ...
+        }</codeblock> <p>The block of code needs to do the following: </p> <ul>
+<li id="GUID-22297738-82AA-5F87-AE35-09903161E793"><p>reset the sample buffer </p> </li>
+<li id="GUID-D22ED4D2-B602-5270-9131-053E6B17191B"><p>clear the digitizer
+interrupt </p> </li>
+<li id="GUID-32A574A0-42D0-5953-AB00-BDFAABD4C82E"><p>set up the hardware
+so that it can detect when the digitizer is touched </p> </li>
+<li id="GUID-B422C5F4-D7F8-5BD1-B9B5-130B9EFBD44A"><p>enable the digitizer
+interrupt. </p> </li>
+</ul> </li>
+</ol> </section>
+<section id="GUID-4E84D583-7745-531B-AB62-65D012B4BCB2"><title>Take sample
+readings</title> <p>In the template port, the initialisation of sampling is
+implemented in the second half of the function <b>DTemplatedigitizer::TakeSample()</b> function.
+Note that this function is not derived from any base class function. </p> <p>This
+code is executed while the pen is down, and needs to do the following: </p> <ul>
+<li id="GUID-F9FB32EF-7967-5753-8D4F-BBEAF3BC2AC9"><p>read the hardware for
+the digitizer samples and put the results into the sample buffer. The sample
+buffer resides in the platform independent layer. </p> </li>
+<li id="GUID-E4F4B6D9-9455-5B43-A025-735A6A1235B0"><p>set up the hardware
+so that it can detect when the digitizer is touched </p> </li>
+<li id="GUID-642B38D4-658A-59A0-AA7C-D497CB6A0FF4"><p>schedule the reading
+of the next sample using a one shot timer; the time interval is defined by
+the value of the configurable constant <xref href="GUID-3574BE12-9DA9-573D-8545-3B073005A139.dita#GUID-3574BE12-9DA9-573D-8545-3B073005A139/GUID-C8EC7A1D-7597-57BB-ADE4-0EDFFEB323D0">KInterSampleTime</xref> </p> </li>
+<li id="GUID-C3B71C41-8C33-5A39-B1D8-B08CD6D7AE6E"><p>when a complete group
+of samples has been taken, tell the platform independent layer by calling <codeph>RawSampleValid()</codeph>;
+the function is a member of the base class <xref href="GUID-52E09E60-E29C-359C-926B-9836D960EF20.dita"><apiname>Ddigitizer</apiname></xref>. </p> </li>
+</ul> <p><b>Tracing note </b> </p> <p>If the <codeph>KHARDWARE</codeph> tracing
+flag has been set, and tracing is on, then it should be possible to move the
+pen over the screen and see the raw sample values on the debug output. Check
+they are correct. </p> </section>
+<section id="GUID-7ADA202E-23F8-52E1-BE57-B44FF75C5612"><title>Add code to
+the debounce timer callback function</title> <p>In the template port, the
+debounce timer callback function is implemented by the local function <b>timerIntExpired()</b>. </p> <p>If
+not already done in <xref href="GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07.dita#GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07/GUID-D74C94E4-83AD-5BC0-B435-754E7D3FECA4">Implement
+the pen interrupt ISR</xref>, add code to this callback function to clear
+the digitizer interrupt. </p> </section>
+<section id="GUID-8F229C58-66B5-5D0A-9058-8C57586F5B45"><title>Deal with a
+pen up interrupt</title> <p>If the digitizer generates an interrupt when the
+pen is lifted, then you need to add code to the pen interrupt ISR to handle
+this. This is the same function, <b>DTemplatedigitizer::PenInterrupt()</b>,
+referred to in <xref href="GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07.dita#GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07/GUID-D74C94E4-83AD-5BC0-B435-754E7D3FECA4">Implement
+the pen interrupt ISR</xref>. </p> <p>The code should: </p> <ul>
+<li id="GUID-46619FF8-B3A0-556C-8B7F-D93CA3BAD2DA"><p>clear the digitizer
+interrupt. </p> </li>
+<li id="GUID-6E7353D8-118D-5FD9-9557-68DBCCBF32D9"><p>set up the hardware
+so that it can detect when the digitizer panel is touched. </p> </li>
+</ul> <p>If there is no pen up interrupt by design, then you need to add code
+into the <b>DTemplatedigitizer::TakeSample()</b> function at the point where
+the pen is up and the digitizer is in the <i>pen up debounce</i> state (i.e. <codeph>E_HW_PenUpDebounce</codeph>): </p> <codeblock id="GUID-6AF28551-7F20-5C70-8D0E-E40F2DD50417" xml:space="preserve">if (!penDown)
+    {
+    if (iState==E_HW_PenUpDebounce)
+        {
+        . . .</codeblock> <p>At this point, you should have almost all digitizer
+capability – pen up handling, pen down handling, and the taking of digitizer
+readings. </p> </section>
+<section id="GUID-6DC8A3DB-452F-5738-9D60-7E34BF8A3596"><title>Implement Ddigitizer::digitizerOff()</title> <p>This
+function is called when the digitizer is being powered down. </p> <p>If the
+device is powered on, then the function needs to do disable the digitizer
+interrupt. </p> <p>If the digitizer is in the <i>collect sample</i> state
+(i.e. <codeph>E_HW_CollectSample</codeph>), then it also needs to do the following: </p> <ul>
+<li id="GUID-7C5A6267-9CE2-587F-9092-F16DB89E8283"><p>set up the hardware
+so that the device wakes up from standby if the digitizer panel is touched. </p> </li>
+<li id="GUID-F606C7D1-A0FD-5845-B9A0-EAF13D3F5B01"><p>relinquish the request
+for power resources; this will place the peripheral hardware into a low power
+"sleep" mode, which is capable of detecting an interrupt. </p> </li>
+</ul> </section>
+<section id="GUID-FE7F24DF-6A65-5A7E-A9C8-DBCF7848DEA6"><title>Implement power
+up and power down handling</title> <p>At this point, the device should be
+working successfully. </p> <p>You now need to put the device into a low power
+"sleep" mode when it is switched off, and to bring it out of "sleep" mode
+when the digitizer is touched. </p> <ul>
+<li id="GUID-EE805C9C-62F1-5F03-A9F9-643BC025E047"><p>Add code to the template
+port function <b>DTemplatedigitizer::digitizerPowerUp()</b> to request power
+resources from the power controller. This will power the device up from sleep
+mode. </p> </li>
+<li id="GUID-141FEF1E-B284-5970-89CF-81F9C6CD3890"><p>Add code to the powering
+down part of your implementation of <xref href="GUID-52E09E60-E29C-359C-926B-9836D960EF20.dita#GUID-52E09E60-E29C-359C-926B-9836D960EF20/GUID-43E7AF76-DF07-3688-984A-80365150C080"><apiname>Ddigitizer::WaitForPenDown()</apiname></xref> that
+does the following: </p> <ul>
+<li id="GUID-310D240A-CCCC-5978-8798-75EE01B13E7D"><p>sets up the hardware
+to wake the device from standby if the digitizer is touched. </p> </li>
+<li id="GUID-D7C488F1-8727-5948-A7D1-3D1C4A306AF9"><p>relinquishes the request
+for power resources - this will place the peripheral hardware into a low power
+"sleep" mode, which is capable of detecting an interrupt. </p> </li>
+</ul> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-AFA1604D-FF0C-56BE-A71E-AF3C662F8943.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,102 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-AFA1604D-FF0C-56BE-A71E-AF3C662F8943" xml:lang="en"><title>Platform-Specific
+Makefile</title><shortdesc>Describes how to write the platform-specific makefile to build
+the bootstrap.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The platform-specific makefile sets some variables for file and path names
+and then includes the generic makefile. </p>
+<p>The makefile consists of a collection of variables divided into a mandatory
+set, which <i>must</i> have values assigned, and an optional set. </p>
+<p>The values are used by the Symbian platform generic makefile. </p>
+<section id="GUID-B949A719-49FB-5D45-BC34-B1A6F90D2D25"><title>Mandatory variables</title><table id="GUID-3A058FA9-6656-5C67-8498-1C6F4AA59687">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>NAME</codeph>  </p> </entry>
+<entry><p>This the name of the bootstrap binary file. The filename is <filepath>NAME.bin</filepath> and
+it appears in <filepath>EPOCROOT/epoc32/release/PLATFORM</filepath> where
+PLATFORM is e.g. ARM4, ARMV5 etc. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>MEMMODEL</codeph>  </p> </entry>
+<entry><p>This specifies which memory model is to be used on the target platform.
+Valid values are: </p><ul>
+<li id="GUID-8555F19E-C904-51DB-AAA2-03FBAD463572"><p> <codeph>direct</codeph>  </p> </li>
+<li id="GUID-E2BFCDB6-E2D7-597F-A1A6-82DE5E3A24D6"><p> <codeph>moving</codeph>  </p> </li>
+<li id="GUID-DFE497B1-7C4E-5C53-BBC5-42F76AA88317"><p> <codeph>multiple</codeph>  </p> </li>
+</ul><p>Platforms that use an ARM architecture 4, 4T or 5 will use <codeph>moving</codeph> for
+the main bootstrap.</p><p>Platforms that use ARM architecture 6 will use <codeph>multiple</codeph>. </p><p>Usually, <codeph>direct</codeph> will
+only be used when building a bootloader. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>SOURCES</codeph>  </p> </entry>
+<entry><p>Specifies a list of platform-dependent assembler source files, each
+separated by at least one space, needed to build the bootstrap. Only file
+names are required, not paths. </p> <p>In the example of the template, there
+is a single source file, <filepath>template.s</filepath>. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>INCLUDES</codeph>  </p> </entry>
+<entry><p>Specifies a list of platform-dependent assembler include files,
+each separated by at least one space, needed to build the bootstrap. Only
+file names are required, not paths. </p> <p>In the example of the template,
+there is a single include file, <filepath>config.inc</filepath>. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>E32PATH</codeph>  </p> </entry>
+<entry><p>Specifies the relative path from the directory containing the platform-specific
+makefile to the directory containing the <filepath>e32</filepath> source tree.
+This is used to find the generic source and the generic include files required
+to build the bootstrap. </p> <p>In the example of the template, the path is <filepath>../..</filepath>. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-77F41D8D-CB34-57DA-ADB0-48A2EC25F698"><title>Optional variables</title> <table id="GUID-E24A5C3A-8685-5E33-BD43-AF8CAB90EB95">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>EXTRA_INC_PATH</codeph>  </p> </entry>
+<entry><p>Specifies a list of directories, each separated by at least one
+space, which should be searched for assembler include files (<filepath>.inc</filepath>),
+and possibly C/C++ header files (<filepath>.h</filepath>) to be translated
+into assembler syntax. </p> <p>Each entry in this list is relative to the
+directory in which the platform-specific makefile resides. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EXTRA_SRC_PATH</codeph>  </p> </entry>
+<entry><p>Specifies a list of directories, each separated by at least one
+space, which should be searched for assembler source files (<filepath>.s</filepath>). </p> <p>Each
+entry in this list is relative to the directory in which the platform-specific
+makefile resides. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>GENINCLUDES</codeph>  </p> </entry>
+<entry><p>Specifies a list of additional C/C++ header files (<filepath>.h</filepath>),
+each separated by at least one space, which should be translated into assembler
+syntax include files (<filepath>.inc</filepath>) for inclusion in assembler
+source. </p> <p>For example, if a file <filepath>x.h</filepath> is specified
+in this list, it will be translated to <filepath>x.inc</filepath> in the build
+directory, and it should be included as <filepath>x.inc</filepath> in any
+source file which requires it. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>ASM_MACROS</codeph>  </p> </entry>
+<entry><p>Specifies a list of additional symbols, each separated by at least
+one space, which should be defined when assembling each source file. Values
+may not be assigned to the symbols; all that can be tested is whether a symbol
+is defined. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-B0FA9741-CB42-560F-A13E-78FAA57F7871-master.png has changed
Binary file Adaptation/GUID-B0FA9741-CB42-560F-A13E-78FAA57F7871_d0e93088_href.png has changed
Binary file Adaptation/GUID-B0FA9741-CB42-560F-A13E-78FAA57F7871_d0e93496_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,357 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671" xml:lang="en"><title> Implement
+the controllable power resources</title><shortdesc>This document describes how to write and use power resources. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-7E91DB93-F9D6-4B93-8BAF-E25642F63C57"><title>Purpose</title> <p>Implement your power resource according
+to the type of resource you wish to support. </p> <p><b>Introduction</b> </p> <p>Power
+resources controlled by the PRM can be turned on, off and varied with software. </p> <p>See
+the <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-4CC0C003-1952-5CAD-A7C5-163C5DDA52C8">Power
+resources</xref> section for detailed information about resources. There are
+five main types of resource that can be implemented: </p> <ul>
+<li id="GUID-C67FB012-A1D6-5047-AD5A-18CF62971B2B"><p>static resources - derived
+from the <xref href="GUID-DB7DDF4C-57EF-34FF-B3CD-13C5CD51A125.dita"><apiname>DStaticPowerResource</apiname></xref> base class, </p> </li>
+<li id="GUID-6170B4D1-2AAD-52C7-88E0-D6BBE8CAFF63"><p>static resource that
+support dependancy - derived from the <xref href="GUID-88C28976-67DF-3109-8D35-FA30A733C581.dita"><apiname>DStaticpowerResourceD</apiname></xref> base
+class, </p> </li>
+<li id="GUID-FAE7BFE3-7C2D-5DB7-A8FF-B7E4F37F5BAF"><p>dynamic resources -
+derived from the <xref href="GUID-CA01041D-8FD6-3B5B-BB5D-A5159DF7C9AB.dita"><apiname>DDynamicPowerResource</apiname></xref> base class. Create
+dynamic resources in the kernel data section or in the heap, </p> </li>
+<li id="GUID-9586824D-FB68-5DC1-B743-9ED551FA286D"><p>dynamic resource that
+support dependancy - derived from the <xref href="GUID-6B224A9F-D2B9-3289-922D-766EF093FCD6.dita"><apiname>DDynamicPowerResourceD</apiname></xref>. </p> </li>
+<li id="GUID-AF8A571A-2AB6-5063-BFA5-3FF8509C95C7"><p>custom sense resources
+- when shared the power level of this resource may be increased or decreased
+freely by some privileged clients but not by others, which are bound by the
+requirement of the privileged clients. </p> </li>
+</ul> <p> <b>Note</b>: dynamic resources and resource dependancies are only
+supported in the extended version of the PRM. See <xref href="GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9.dita#GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9/GUID-0F328055-DBCE-5B2B-A1EB-77F73BA1FC82">setup and configuration requirements</xref>. </p> </section>
+<section id="GUID-D50E75DC-115E-42FD-9111-7A70E3087F33"><title> Implementing power resources </title> <p>The following tasks
+are covered in this tutorial: </p> <ul>
+<li id="GUID-2C4FDE84-401B-5520-B050-9FD475A63863">Create your resource by <p> <xref href="GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671.dita#GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671/GUID-3021B2EA-9829-515C-9074-2D2D0D7A5510">Override
+the pure virtual functions</xref>, </p> </li>
+<li id="GUID-6492CDEF-524E-5A3A-82AB-1D0E0B8E9D28"><p> <xref href="GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671.dita#GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671/GUID-A5D57D89-4499-5C85-80D5-5A7DC5644983">Create resource dependencies</xref>, </p> </li>
+<li id="GUID-56A63835-D0B5-5C32-95D0-623A0D21AEF4"><p> <xref href="GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671.dita#GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671/GUID-9526B472-00ED-583A-8BFC-C02363D4DFA2">Create custom resources</xref>. </p> </li>
+</ul> <p id="GUID-3021B2EA-9829-515C-9074-2D2D0D7A5510"><b>Override the pure
+virtual functions</b> </p> <p>The pure virtual functions of <xref href="GUID-DB7DDF4C-57EF-34FF-B3CD-13C5CD51A125.dita"><apiname>DStaticPowerResource</apiname></xref> or <xref href="GUID-CA01041D-8FD6-3B5B-BB5D-A5159DF7C9AB.dita"><apiname>DDynamicPowerResource</apiname></xref> must
+be implemented. </p> <p><b>Constructor</b> </p> <p>Information about the resource
+based on the resources category must be set in the <codeph>iFlags</codeph> bit
+mask. Static variables that define a resources classification can be found
+within <filepath>32\include\drivers\resource.h</filepath>. </p> <p>Each resource
+is classified based on: </p> <ul>
+<li id="GUID-08E6311D-6403-56CB-B91B-57C93F8CA208"><p>usage, </p> </li>
+<li id="GUID-55F93FDB-137F-51D3-A1E3-F048B279425E"><p>operating levels, </p> </li>
+<li id="GUID-4DD3D8E1-273A-5BFE-8A65-11B9DDE84E4D"><p>latency, </p> </li>
+<li id="GUID-9B00B021-E620-50EA-B2D2-2F18111F5C1E"><p>resource sense. </p> </li>
+</ul> <p>Below is the example implementation of derived class constructor </p> <codeblock id="GUID-1DE1E1CA-7212-5E30-85BF-C67578F9CEC8" xml:space="preserve">// multilevel, shared, long latency, read and write, positive resource. 
+DMLSHLGLSPResource::DMLSHLGLSPResource() : DStaticPowerResource(KDBSHLGLSPResource, E_ON), 
+                     iMinLevel(E_OFF), iMaxLevel(E_ON), iCurrentLevel(E_ON), iPolled(ETrue)
+    {
+    iFlags = EMultilevel | KShared | KLongLatencySet | KLongLatencyGet;
+    . . .   
+    }</codeblock> <p><b> GetInfo()</b> </p> <p>The PIL uses <xref href="GUID-66D96ADA-1C26-3293-9F92-FD65E08D6158.dita"><apiname>GetInfo()</apiname></xref> to
+get resource information. The default implementation of this function provides
+generic information about the resource by updating the passed descriptor that
+contains an information structure <xref href="GUID-FA4D9A07-041C-303C-BF96-2E444DD47024.dita"><apiname>TPowerResourceInfoV01</apiname></xref>.
+Derived implementations must fill in all the PSL specific fields and call
+the base class implementation. Below is an example implementation. </p> <codeblock id="GUID-EB61E8FF-146C-5825-8F16-869FE4DD5B44" xml:space="preserve">TInt DH4SndFclkResource::GetInfo(TDes8* info) const
+    {
+    __KTRACE_OPT(KRESMANAGER, Kern::Printf("&gt;DH4SndFclkResource::GetInfo\n"));
+
+    /** Call base class implementation to fill generic details */
+    DStaticPowerResource::GetInfo((TDes8*) info);
+    TPowerResourceInfoV01 *buf1 = (TPowerResourceInfoV01*) info;
+    buf1-&gt;iMinLevel = iMinLevel;
+    buf1-&gt;iMaxLevel = iMaxLevel;
+    __KTRACE_OPT(KRESMANAGER, Kern::Printf("&lt;DH4SndFclkResource::GetInfo\n"));
+    return KErrNone;
+    }</codeblock> <p>The member variables of the <codeph>TPowerResourceInfoV01</codeph> structure
+are reserved for PSL information. These can be used to return resource specific
+information to clients. </p> <p><b>DoRequest()</b> </p> <p> <xref href="GUID-9D910016-5611-30DD-A139-EE46705A4912.dita"><apiname>DoRequest()</apiname></xref> is
+used by the PIL to control resources. For example, to change and read the
+state of resources. <codeph>DoRequest()</codeph> takes a <xref href="GUID-D204F4A7-8CC8-3EB2-8371-1D1BFD903390.dita"><apiname>TPowerRequest</apiname></xref> object
+that contains all the request information. <b>Note</b>: This function needs
+to be implemented for all resources. </p> <p>Below is an example <xref href="GUID-9D910016-5611-30DD-A139-EE46705A4912.dita"><apiname>DoRequest()</apiname></xref> function
+implementation for a binary, instantaneous resource. </p> <codeblock id="GUID-D5AE04C1-7A9D-5270-840F-6CD662FB46A2" xml:space="preserve">TInt DH4MmcCtrllerPwrResource::DoRequest(TPowerRequest&amp; aRequest)
+    {
+    TInt retVal = KErrNone;
+    TUint16 config;
+    /** Enable/disable the MMC controller by programming the MMC controller 'CON' register- 'POW' bit */
+    if (aRequest.ReqType()==TPowerRequest::EGet) 
+        {
+        PRM_PSL_RESOURCE_GET_STATE_START_TRACE
+        config = OMAPMMC_GET_REG(KHoMMC_Con_Reg);
+        if(config &amp; KHtMMC_PowerUp)
+            {
+            aRequest.Level() = 1;
+            iCurLevel = 1;
+            }
+        else
+            {
+            aRequest.Level() = 0;
+            iCurLevel = 0;
+            }
+        PRM_PSL_RESOURCE_GET_STATE_END_TRACE
+        }
+    else if(aRequest.ReqType()==TPowerRequest::ESetDefaultLevel)
+        {
+        PRM_PSL_RESOURCE_CHANGE_STATE_START_TRACE
+        OMAPMMC_MOD_REG(KHoMMC_Con_Reg, KHtMMC_PowerUp, KClear32);
+        iCurLevel = iDefaultLevel;
+        aRequest.Level() = iDefaultLevel;
+        PRM_PSL_RESOURCE_CHANGE_STATE_END_TRACE
+        }
+    else 
+        {
+        PRM_PSL_RESOURCE_CHANGE_STATE_START_TRACE
+        if(aRequest.Level() == 1)
+            {
+            OMAPMMC_MOD_REG(KHoMMC_Con_Reg, KClear32, KHtMMC_PowerUp);
+            }
+        else
+            {
+            OMAPMMC_MOD_REG(KHoMMC_Con_Reg, KHtMMC_PowerUp, KClear32);
+            }
+        iCurLevel = aRequest.Level();
+        PRM_PSL_RESOURCE_CHANGE_STATE_END_TRACE
+        }
+    return retVal;
+    }</codeblock><p>The DoRequest function implementation should take care
+of blocking the Resource Controller thread as operations on a long latency
+resource take a significant amount of time to complete (in hardware). Usually
+the request completion is notified either through an ISR (interrupt driven)
+or through register setting (polling wait) by hardware. </p><p>Below is an
+example <codeph>DoRequest()</codeph> implementation for a long latency resource. </p> <codeblock xml:space="preserve"> TInt DH4MmcPowerResource::DoRequest(TPowerRequest&amp; aRequest)
+    {
+    TUint8 iMenelausConf;
+    TInt retVal = KErrNone;
+
+    /** Access to Menelaus registers is over I2C bus. This is a long latency synchronous operation.
+    Create a Menelaus Request structure and send it to Menelaus chip, Wait until a response is received */
+
+    if (aRequest.ReqType()==TPowerRequest::EGet)
+        {
+        // Frame the request
+        ... 
+        }
+				// Default level is off.
+    else if (aRequest.ReqType() == TPowerRequest::ESetDefaultLevel)
+        {
+        // Frame request to move the resource to default state
+        ... 
+        }
+				// EChange
+    else 
+       {
+       // Frame request to set the requested resource state
+       ...     
+       }
+    
+    // Request the operation on the hardware
+    retVal = Menelaus::AccessRegister(iMenelausReq);
+    
+    // Wait for the request to complete  
+    __KTRACE_OPT(KPBUS1, Kern::Printf("Waiting for menelaus req to signal sem\n"));
+    NKern::FSSetOwner(&amp;iSemaphore,NULL);
+    iSemaphore.iCount = 0;	
+
+    // This will be signalled in Menelaus access functions callback below
+    NKern::FSWait(&amp;(iSemaphore)); 
+	
+    // Menelaus chip has responded
+    if(iMenelausAccessErr == KErrNone)
+        {
+        switch(iMenelausState)
+            {
+            case EMenelausRead:
+                // Return 0/1 depending on the value set
+                iMenelausConf = (*(iRdBuffer.Ptr())) &amp; KHoMenelausVmmcModeMask;		                    
+                if(iMenelausConf == 3)
+                    {
+                    iCurLevel=aRequest.Level()=1; 
+                    }
+                else 
+                    {
+                    iCurLevel=aRequest.Level()=0;
+                    }
+                PRM_PSL_RESOURCE_GET_STATE_END_TRACE
+                break;
+
+            case EMenelausSingleWrite:
+                iCurLevel = aRequest.Level();
+                PRM_PSL_RESOURCE_CHANGE_STATE_END_TRACE
+                break;
+            }
+        }
+        return iMenelausAccessErr;
+    }
+
+/** Below is the Menelaus access functions callback where the semaphore is signalled. */
+void DH4MmcPowerResource::MenelausAccessDone(TAny* aPtr, TInt aResult)
+    {
+    DH4MmcPowerResource* ptr = reinterpret_cast&lt;DH4MmcPowerResource*&gt;(aPtr);
+    ptr-&gt;iMenelausAccessErr = aResult;
+    if(aResult != KErrNone)
+        {
+        __KTRACE_OPT(KRESMANAGER, 
+        Kern::Printf("Menelaus::MenelausAccessRegister ERR(%d)\n", aResult));
+        }
+				// Signal the waiting thread
+    NKern::FSSignal(&amp;(ptr-&gt;iSemaphore)); 
+    return;
+    }</codeblock><p id="GUID-A5D57D89-4499-5C85-80D5-5A7DC5644983"><b>Create
+resource dependencies</b> </p> <p>A resource has a dependency if the state
+of the resource depends on the state of one or more resources. For example,
+a clock whose frequency is derived from another clock or voltage is a dependent
+resource. The PSL usually handles resource dependencies transparently. However,
+if the resources have public users (clients of the PRM), then these resources
+should be registered with the PRM as <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-473BBE32-6831-52BE-8752-CB6DBBBABD2C">Resource
+dependencies</xref> that are linked. </p> <p>Each dependency must be assigned
+a priority value. The priority is used by the PIL when propagating the change
+and propagating the request for notifications. Each link stemming from a resource
+must have a unique priority value. </p> <p> <b>Note</b>: Resource dependencies
+are only supported in the extended version of the PRM. Only long latency resources
+are allowed to have dependents and no closed loop dependencies are allowed. </p> <p><b> Register
+resource dependencies for dynamic and static resources</b> </p> <p>Static
+resources that support dependencies are created and registered with the PRM
+during resource controller creation time and are derived from <codeph>DStaticPowerResourceD</codeph>: </p> <codeblock id="GUID-1C7E2D5F-8C76-5D4D-84FA-259DE943742E" xml:space="preserve">DXXXStaticPowerResourceD : public DStaticPowerResourceD
+    {
+public:
+    DXXXStaticPowerResourceD();
+    TInt DoRequest(TPowerRequest &amp;req);
+    TInt GetInfo(TDes8* aInfo) const;
+    TChangePropagationStatus TranslateDependentState(TInt aDepId, TInt aDepState, TInt&amp; aResState);
+private:
+    TInt iMinLevel;
+    TInt iMaxLevel;
+    TInt iCurrentLevel;
+    ...
+    };</codeblock> <p>Dependencies between static resources should be established
+by the PSL before registering these resources with the PIL. Use the <xref href="GUID-1CD49D40-1FF9-301C-8160-02A007485ADE.dita#GUID-1CD49D40-1FF9-301C-8160-02A007485ADE/GUID-806D0179-FC98-3106-BCBA-0D3634B43815"><apiname>DStaticPowerResourceD::AddNode()</apiname></xref> function
+provided in the base class to establish a dependency link between static resources.
+See <xref href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita#GUID-66FD040B-133E-57CF-80DD-9369F62709C6/GUID-A912A328-D646-5516-9731-FFA7F3B2EDDA">Creating
+dependencies between static resources</xref>. </p> <p>Dynamic resources that
+support dependency are derived from <xref href="GUID-6B224A9F-D2B9-3289-922D-766EF093FCD6.dita"><apiname>DDynamicPowerResourceD</apiname></xref>.
+These can be registered and deregistered from the PRM at any time after the
+PRM is fully initialised. Dependencies between resources are established by
+the client using <xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita#GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00/GUID-9C1BF3D5-6F5D-3BEF-9DF0-A5FED85CC718"><apiname>PowerResourceManager::RegisterResourceDependency()</apiname></xref>. </p> <codeblock id="GUID-30B2271B-FA2A-53FE-A1F1-0A3E36B95883" xml:space="preserve">DXXXDynamicPowerResourceD : public DDynamicPowerResourceD
+    {
+public:
+    DXXXDynamicPowerResourceD();
+    TInt DoRequest(TPowerRequest &amp;req);
+    TInt GetInfo(TDes8* aInfo) const;
+    TChangePropagationStatus TranslateDependentState(TInt aDepId, TInt aDepState, TInt&amp; aResState);
+private:
+    TInt iMinLevel;
+    TInt iMaxLevel;
+    TInt iCurrentLevel;
+    ...
+    };</codeblock> <p>Dependencies can be established between a dynamic resource
+and a static (dependency enabled) resource using the same API. A client can
+deregister dependencies between a pair of dynamic resource (or between a dynamic
+and static resource) using <xref href="GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00.dita#GUID-40AB9EDA-16CB-371E-8759-1D7C99FF9C00/GUID-127E979F-F540-36E2-A759-8ED408E89F38"><apiname>PowerResourceManager::DeRegisterResourceDependency()</apiname></xref>.
+When a dynamic resource that supports dependency deregisters from the PRM,
+dependencies are removed automatically by the PIL. </p> <p><b>Change the state
+of dependent resources</b> </p> <p>When a state change is requested by a client
+on any resource in a dependency tree before proceeding with the change the
+PIL must check if the change is allowed by its dependents and the ones it
+depends on. The PIL does this by calling the <xref href="GUID-E71F94F6-A4BB-3C85-8E2E-8E3ABAA85897.dita"><apiname>TranslateDependentState()</apiname></xref> function
+on each resource. This is a pure virtual function in the base class and must
+be implemented in the derived class. </p> <p>This function is called by the
+PIL prior to a resource change on any of its dependents. The function returns
+one of these values: </p> <ul>
+<li id="GUID-CEABEBE0-34BB-5CD0-861E-CDB87A066C8B"><p> <codeph>EChange</codeph> -
+If the resource accepts the state change of the dependent resource and, as
+a result of the dependent resources state change this resource needs to change
+its own state. The new state of this resource is updated in <codeph>aResState</codeph>, </p> </li>
+<li id="GUID-A22403B9-38C9-571E-9E14-C7BD1CB032F2"><p> <codeph>ENoChange</codeph> -
+if the resource accepts the dependent resources state change and this resource
+does not need to change its state, </p> </li>
+<li id="GUID-EE30E093-85A0-5205-B1C7-6C36A5410BB1"><p> <codeph>ENotAllowed</codeph> -
+if the resource does not accept the dependent resources state change. </p> </li>
+</ul> <codeblock id="GUID-453D7F61-4187-50DC-B641-34A06AEB722B" xml:space="preserve">TChangePropagationStatus DXXDependResource::TranslateDependentState(TInt /*aDepId*/, TInt aDepState,
+   TInt&amp; aResState)
+    {
+    /* Switch ON if the dependent resource is ON */
+    if((aDepState == 1) &amp;&amp; (iCurrentLevel == 0)
+        {
+        aResState = iMaxLevel;
+           return EChange;
+           }
+
+    /* Don’t allow dependent to OFF, if this is still ON */
+    else if (aDepState == 0) &amp;&amp; (iCurrentLevel == 1)
+        {
+        return ENotAllowed;
+        }
+
+    return ENoChange;
+    }</codeblock> <p id="GUID-9526B472-00ED-583A-8BFC-C02363D4DFA2"><b>Create
+custom resources</b> </p> <p>Clients on a shared resource may have different
+requirements on the state of a shared resource. The resource sense is used
+by the PIL to determine whose requirement prevails: </p> <ul>
+<li id="GUID-495628CC-D257-598F-B420-2784749B1083"><p>positive sense resources
+- when shared can have their value increased without prejudice to their clients, </p> </li>
+<li id="GUID-D4D7CB6D-F99B-568E-9F38-429196599F4F"><p>negative sense resources
+- when shared can have their value decreased without prejudice to their clients, </p> </li>
+<li id="GUID-0BB26EA3-F22B-5C7D-8999-14DB75D066CA"><p>custom sense resources
+- when shared may be increased or decreased freely by some privileged clients
+but not by others, which are bound by the requirement of the privileged clients. </p> </li>
+</ul> <p>A custom function must be supplied for every <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-4CC0C003-1952-5CAD-A7C5-163C5DDA52C8">Power resources</xref> resource. This function is called by the PIL every
+time a change request is issued to determine if the change requested by the
+client is allowed as a decision to allow the resource change is determined
+solely by the PSL. The resource object contains a pointer that must be set
+at construction for custom sense resources by calling this function: </p> <codeblock id="GUID-31716524-4902-5E87-A51F-2EF63DA6D500" xml:space="preserve">inline void SetCustomFunction(TCustomFunction aCustomFunction)</codeblock> <p>This
+function sets the custom function for the resource. If a custom function is
+not supplied for a custom sense resource the PIL panics during a resource
+state change. An example of a custom sense resource is a shared domain clock
+when a domain client uses it as a bit clock. </p> <p> <xref href="GUID-5FDBF9F8-9BC4-3E3B-9A28-5046C65788E2.dita"><apiname>TCustomFunction</apiname></xref> is
+a function pointer: </p> <codeblock id="GUID-A0ECC7F5-A410-50DA-9723-09C1C080927C" xml:space="preserve">typedef TBool (*TCustomFunction) (TInt&amp; /*aClientId*/,
+                                  TUint /*aResourceId*/,
+                                  TInt&amp; /*aLevel*/,
+                                  TAny* /*aLevelList*/);</codeblock> <p>The
+values held in TCustomFunction are: </p> <ul>
+<li id="GUID-5E1EF546-098D-5940-8BD0-4AF2B70861E4"><p>the Id of the client
+requesting the change, </p> </li>
+<li id="GUID-A8E1B48A-C36C-5D88-9388-BE40902832AE"><p>the Id of the resource
+on which the change is requested (this allows a single function to handle
+multiple resources), </p> </li>
+<li id="GUID-CDC2D3F7-2E82-5E56-864B-E0901B57FE83"><p>the level the client
+is requesting, </p> </li>
+<li id="GUID-57C1C8CC-411D-54B7-9548-2D0C5DFB6B3F"><p>a pointer to the list
+of the resource’s <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-F47D2098-16A7-5590-A68A-7AE4B2DAB462">client
+levels</xref>. </p> </li>
+</ul> <p>Custom functions can be set at any time before a resource state change
+is requested on a resource. Ideally a custom function is set at resource creation
+time in the resource's constructor. </p> <codeblock id="GUID-6B688BFC-8D7A-5D7C-B17D-B4D3579230F4" xml:space="preserve">DBSHLGLSCResource::DBSHLGLSCResource() : DStaticPowerResource(KDBSHLGLSCResource, E_ON), iMinLevel(E_OFF), iMaxLevel(E_ON), iCurrentLevel(E_ON), iPolled(EFalse)
+    {
+    iFlags = KMultiLevel | KShared | KLongLatencySet | KSenseCustom;
+    SetCustomFunction(CustomFunction);
+ ...
+    }</codeblock> <p>The decision to allow the requested resource state change
+is specified in the custom function return value. This is <codeph>ETrue</codeph> if
+the change is allowed and <codeph>EFalse</codeph> if the change is not allowed. </p> <p>The
+function can change the state of the resource to a level other than the one
+requested and can choose a client other than the passed client to hold the <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-121C14E3-D446-565E-AAAE-C43C131ACD3C">Caching
+the prevailing level</xref> of the resource. </p> <p><b>Supporting dependencies </b> </p> <p>If
+the custom sense resource supports dependencies then use the function pointer <xref href="GUID-60A17842-3E3B-3748-8F91-F5ED912E642A.dita"><apiname>TDependencyCustomFunction</apiname></xref>.
+This takes an additional parameter that specifies the resource <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-F47D2098-16A7-5590-A68A-7AE4B2DAB462">Client level objects</xref>. </p> </section>
+</conbody><related-links>
+<link href="GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9.dita"><linktext>Porting the
+Power Resource Manager</linktext></link>
+<link href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita"><linktext>Implement
+the PSL for the target</linktext></link>
+<link href="GUID-E7F91A65-235D-589C-9A8C-0B207D19A24B.dita"><linktext>Port the
+client drivers to use the PRM</linktext></link>
+<link href="GUID-C8DF0CB0-92F4-5F9E-A8F1-7DE50954C4F1.dita"><linktext>Debugging
+the PRM</linktext></link>
+<link href="GUID-66E5F769-1156-54CA-94BC-8912159A1240.dita"><linktext>Testing the
+PRM PSL</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B2F86F54-EF50-56DB-ADF7-15325AC9324D.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,298 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-B2F86F54-EF50-56DB-ADF7-15325AC9324D" xml:lang="en"><title>IIC Concepts</title><shortdesc>This document provides an overview of IIC concepts. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>IIC is a an abstraction of serial inter-IC buses such as I2C and
+SPI. It allows serial bus device drivers to be written that do not
+need to know the specifics of the underlying hardware technology.</p>
+<section id="GUID-F9D5DC69-0BFA-42AE-9044-678AAED780A2"><title>Serial
+inter-IC buses</title> <p>Serial inter-chip buses are a class of bus
+used to transmit data between components of a hardware system. Examples
+are: </p> <ul>
+<li id="GUID-AF4E3C14-BA37-5028-A66E-0C2481A68E7E"><p>I2C,</p> </li>
+<li id="GUID-D5633729-DFD4-5E03-BC1B-F2EE13223E02"><p>SPI</p> </li>
+<li id="GUID-E33F3C5F-D824-5B09-BB55-BCE3A3D068BC"><p>SMBus </p> </li>
+<li id="GUID-3ED0A9E8-FEB7-5707-9782-1307E930A124"><p>Microwire</p> </li>
+<li id="GUID-56521027-9D91-5640-9BEF-8513B1B8290B"><p>SCCB</p> </li>
+<li id="GUID-7ABB6B44-F37E-5DCC-84D4-FD0ED6A1993D"><p>CCI. </p> </li>
+</ul> <p>These buses are commonly used to transmit commands, control-signals
+and non time-critical data though other, time-critical, uses are possible.
+The IIC API is used by developers creating client applications, typically
+device drivers. </p> </section>
+<section id="GUID-E67D9AC2-DD3D-48FD-9E48-B79BC73FFE6A-GENID-1-2-1-10-1-5-1-6-1-1-6-1-3-1-3-3"><title>Concepts</title>             <p><b>IIC</b></p><p>IIC provides an abstraction of serial
+inter-IC buses. These buses allow for the exchange of commands and
+simple non time-critical data between devices (nodes) in a bus configuration.
+IIC is not designed for high-bandwidth data transfer. IIC is not a
+bus, but a set of functions and concepts so that device drivers can
+be written that are independent of the chip-specific implementation
+of each bus type. The Platform Independent Layer (PIL) specifies and
+implements the functions that are available to device drivers and
+the SHAI implementation layer implements any parts of the IIC functions
+that are hardware dependent.</p><p><b>Bus</b></p><p>A bus, in this
+case a serial bus, is effectively one or more wires along which data
+or clock signals can be sent. More than one device/node can be attached
+to a bus. This means that the data on the bus must identify which
+node should receive that data. One node will be designated as the
+master node which is responsible for initiating and terminating the
+data transfer on the bus. See below for more on nodes, master and
+slave nodes, configuring the bus etc.</p><p><b>Clients</b></p><p>Clients
+are applications/device drivers that use IIC to send commands and
+basic data over a serial bus. Clients are typically device drivers
+for devices such as digitizers, a built-in camera or the real time
+clock.</p><p><b>Nodes</b></p><p>Each device on the serial bus is a
+node. A particular node can send or receive commands and data, or
+can both send and receive commands and data. On each bus, one of the
+nodes is going to be the phone/handset device which is the one our
+device driver will be using to send commands onto the bus and to receive
+commands from the bus.</p><p><b>Master</b> - a serial bus node that
+is always responsible for initiating and terminating the exchange
+of commands/data and for synchronizing the data transfer (clocking).
+A master node acts on behalf of clients of this bus. For example,
+if a client wants to send commands down a serial bus to a device,
+the device driver will request that the master initiate the command
+transfer. One node on each bus must perform the role of Master.</p><p><b>Slave</b> - each slave node sends or receives commands under
+the control of the master node. A number of slave nodes can be present
+on a single bus. Only one slave node can be addressed by a master
+at one time. A slave must be addressed by a master before it is allowed
+to transmit on the bus. A slave is usually associated with one or
+more functions. Slave nodes sometimes drive the bus but only in response
+to instructions from the master. </p><p>The role of master may be
+exchanged between nodes. For example, in I2C, one or more nodes can
+perform the role of a master, but only one can be the active master
+at any one time. In IIC. this is supported by a ‘<b>MasterSlave</b>’ type, which can alternate the two roles.</p> <fig id="GUID-E7B96ED2-9814-5B75-8051-48337121F985-GENID-1-2-1-10-1-5-1-6-1-1-6-1-3-1-3-3-13">
+<title>             An example of a serial bus (I2C)  SCL=Serial CLock,
+SDA=Serial DAta      </title>
+<image href="GUID-B0FA9741-CB42-560F-A13E-78FAA57F7871_d0e93088_href.png" placement="inline"/>
+</fig><b>Transactions and transfers</b><p>A <b>Transfer</b> is defined
+as single exchange involving data flowing in one direction From the
+master to a slave, or slave to master.</p><p>A <b>Transaction</b> comprises
+a list of transfers, in both directions.</p><p>A basic transaction
+is half duplex (transfers in both directions, but only one at a time). </p><p>Full duplex (simultaneous transfers in both directions) are enabled
+for buses that support them, such as SPI.</p><p>A transaction is a
+synchronous operation and takes control of the bus until the list
+of transfers in that transaction is complete. However the client can
+start the transaction with a synchronous call (waits for it to complete)
+or with an asynchronous call (client thread continues while the transaction
+is processed. At the end of the transaction a callback function is
+called to inform the client that the transaction is complete.)</p>        </section>
+<section id="GUID-98FE3AD9-47EB-4525-9B21-8B477C3F5E60"><title>Transaction
+detail</title><p>A master node initiates a transaction by addressing
+a slave node, this establishes the two ends of the transaction. The
+transaction continues with data being exchanged in either direction.
+The transaction is explicitly terminated by the Master.</p><p>Transactions
+may be executed either synchronously, or asynchronously. </p><p>Asynchronous
+execution requires the client to provide a callback. The client must
+wait for the callback to be executed before accessing the transaction’s
+objects (buffers, transfers and the transaction itself). </p><p>For
+synchronous execution, the client thread is blocked until the transaction
+processing is complete. This means that the client may access the
+transaction’s objects as soon as the client thread resumes.</p><p><b>Transaction Preamble </b></p><p>The transaction preamble is an
+optional client-supplied function that is called just before a transaction
+takes place.</p><p>For example, the transaction preamble may perform
+a hardware operation required on the slave device in order for it
+to handle the transaction. This could be selecting a function on a
+multi-function device, or selecting a set of internal registers.</p><p>The client-supplied transaction preamble function shall not: </p><ul>
+<li><p>Spin.</p></li>
+<li><p>Block or wait on a fast mutex.</p></li>
+<li><p>Use any kernel or base port service that does any of the above.
+For example, alloc/free memory, signal a DMutex, complete a request,
+access user side memory.</p></li>
+</ul></section>
+<section id="GUID-D93E1A25-278B-4F8B-BA6B-8C5BE8FBC8B9"><title>Extended/multiple
+transactions</title><p>An extended/multiple transaction (“multitransaction”)
+is formed from a chain of transactions, and appears to the client
+to be a single high-level transaction. An extended transaction should
+be used when the amount of data that is to be transferred (how many
+transfers) is not known in advance.</p><p>The next transfer in the
+chain is selected by the Extended Transaction callback. The transaction
+may be dynamically composed so that additional transfers are added
+to the transaction while transfers closer to the start of the transaction
+are being processed.</p><p>For example, an extended transaction could
+consist of a write transaction followed by a number of read transactions.
+The reason for making this a single extended transaction is that it
+prevents other clients performing a read transaction after the initial
+write transaction and so stealing the data that the client is expecting.
+Another example is where the multiple transaction consists of a read
+operation followed by several write operations. If another client
+can write data after the read, then the slave buffer may not have
+room for the subsequent write operations.</p></section>
+<section id="GUID-EC6854E7-CD55-4C0D-8F58-A4A4509ED0F2"><title>Channels</title><p>An applications’ ASIC may support a number of bus modules of different
+interface standards. Each bus module for a given interface standard
+may support more than one physical connection. For example, a particular
+ASIC might have two I2C physical connections and one SPI physical
+connection. So to set the master node on one of the I2C connections,
+it must be possible to identify which physical bus to use, which is
+done by allocating a 'channel number' to a particular node on each
+connection. That node is the one that IIC controller or device driver
+talks to.</p><p>The SHAI implementation layer for each bus standard
+(I2C, SPI etc.) assigns unique channel number identifiers.</p><fig id="GUID-B6CF82C8-543A-4D44-B37B-1263271F3E3A">
+<title>Channels</title>
+<image href="GUID-7B0BA327-54A0-4908-B8E3-0C82112EB957_d0e93167_href.png" placement="inline"/>
+</fig><title>IIC Controller</title><p>The IIC controller keeps track
+of the channels. When a client wants to send a command to a particular
+piece of hardware/function (a node), it asks the controller and passes
+the channel ID. The controller checks that the operation is allowed
+and forwards the request to the channel. Or rejects the command if
+it is not allowed. For example, if a slave operation is requested
+on a master channel.</p><p>For application processors that possess
+IIC channels which may be used in a shared manner, the controller
+provides functionality to negotiate access between simultaneous requests
+from a number of clients device drivers. </p><fig id="GUID-A2283D71-6EF6-4D8B-92FC-E01F686BEAE0">
+<title>Using a controller</title>
+<image href="GUID-F67AFC0F-5245-48DE-8901-79461FB6EADE_d0e93180_href.png" placement="inline"/>
+</fig></section>
+<section id="GUID-0F4E2E98-95CE-4571-BE9E-2A5115FA9D01"><title>Controller-less
+(Standalone channel) operation</title><p>If a channel is intended
+to be dedicated to a single client, the controller is not necessary.
+In this case, the client device driver can access the channel interface
+directly. The channel is created and maintained by the client, independently
+of the IIC controller.</p><fig id="GUID-4825FFFC-C5C1-4CEF-919F-0AA1C0B87C00">
+<title>Controller-less operation</title>
+<image href="GUID-690F943E-7459-4FBA-B33C-258969D7759A_d0e93193_href.png" placement="inline"/>
+</fig></section>
+<section id="GUID-788A1BB3-4BE9-480B-8437-F63C6F7DB4C9"><title>Transfers
+and transactions - detail</title> <p><b>Transfers</b> </p> <p>A transfer
+is implemented as a buffer containing the data to be transmitted and
+information used to carry out the transmission, including </p> <ul>
+<li id="GUID-470A0457-9F31-58CA-9D69-CE53C1B12448"><p>the direction
+of transmission (read or write from the point of view of the master
+node), </p> </li>
+<li id="GUID-4BFDA50E-4984-52CA-B2BA-E83E2F88B8C7"><p>the granularity
+of the buffer (the width of the words in bits), and </p> </li>
+<li id="GUID-E280D0B2-8FB8-50BF-B49C-3C6EBE6AEF2D"><p>a pointer to
+the next buffer, used when transfers are combined into transactions
+as a linked list. </p> </li>
+</ul> <p>The buffer is implemented with an 8 bit boundary but the
+data being exchanged may be differently structured. The potential
+conflict is tackled by the configuration mechanism. </p> <p><b>Transactions</b> </p> <p>A transaction is a sequence of transfers implemented as
+a linked list. This is why transfers have pointers to transfers. Transactions
+are of two types. </p> <ul>
+<li id="GUID-3BB4BEB4-16D8-53C7-A407-E10ED7F9B71A"><p>Unidirectional
+transactions are a sequence of transfers, either all of them read
+or all of them write. </p> </li>
+<li id="GUID-6AEF8C6D-F6EA-51BB-B283-1FC5B81758A5"><p>Combined transactions
+are a sequence of transfers, some of them read and the others write. </p> </li>
+</ul> <p>Some buses support duplex transmission, which is simultaneous
+transfers of data in each direction. The transfers within a transaction
+take place sequentially, never simultaneously, so that a combined
+transaction is only ever in half duplex mode. However, it is possible
+to use the full duplex capabilities of a bus by performing two transactions
+at the same time. The simplest case of this is two unidirectional
+transactions in opposite directions. It is also possible to interleave
+two combined transactions, matching the read and write transfers of
+each transaction to create a full duplex combined transaction. The
+IIC platform service API supports this functionality but implementation
+is a matter for client writers. </p> </section>
+<section id="GUID-673F7E28-03DF-4C1D-B587-AD72635EB235"><title>Triggers
+and callbacks</title> <p>A callback is a function to be executed after
+a transaction in response to a condition called a trigger. A callback
+is supplied with the result of the information transmitted. Callbacks
+are of two kinds, master and slave. </p> <p>When the client is master,
+a master callback runs on completion of an asynchronous transaction
+request (synchronous master transaction requests do not have callbacks).
+Its purpose is to notify the client of completion since the client
+will have been performing other tasks during the transaction. </p> <p>A second kind of master callback is a function called just before
+a master transaction. The Symbian platform name for a callback of
+this kind is 'preamble'. </p> <p>Multitransactions may also be associated
+with master callbacks and preambles. </p> <p>Slave callbacks are issued
+during a transaction. Since slave channels are mainly reactive, they
+need to be told what to do on receipt of each individual transfer,
+and this is the purpose of a slave callback. A slave callback object
+contains more information than a master callback because a slave channel
+requires more information in order to proceed with a transfer. The
+information packaged with a slave callback includes: </p> <ul>
+<li id="GUID-FF1A42B7-F94D-5482-81B1-C256E2627FDC"><p>the Id of the
+channel and a pointer to the channel object (which contains the actual
+function to be called), </p> </li>
+<li id="GUID-3B57A5D5-4CF7-5572-B74D-E9730B7BDF9E"><p>a pointer to
+the parameters to be passed to the callback function, </p> </li>
+<li id="GUID-F671AA96-84DC-559D-9DC6-3A87EFE34B04"><p>the trigger, </p> </li>
+<li id="GUID-208B21BA-A1C0-5634-B58C-F4905A950CA0"><p>the number of
+words to be transmitted, and </p> </li>
+<li id="GUID-CF11B5F7-5A8F-5C33-A39C-5BA6FEFD9DF1"><p>the number of
+words to be received. </p> </li>
+</ul> </section>
+<section id="GUID-21F8D5E4-5648-4B23-A4A5-EA1B2933912D"><title>Use
+of the bus API</title> <p>Client applications use the platform service
+API to communicate with an IIC bus. The bus API consists of a class
+representing a bus and contains two sets of functions, the master
+side API used when the client is talking to a master channel, and
+the slave side API used when the client is talking to a slave channel.
+A MasterSlave channel provides both sets of functions but returns
+an error if a master function is used while the channel is in slave
+mode, and similarly returns an error if a slave function is used when
+the channel is in master mode.</p> <p>A client application of a master
+channel may use the functions of a number of devices on the same bus.
+A client may also talk to multiple buses over multiple channels. A
+master channel can also be shared between multiple clients. </p> <p>The master side API provides functionality to: </p> <ul>
+<li id="GUID-6B62796A-4B54-50E6-A104-CB51369C1126"><p>queue transactions
+synchronously, </p> </li>
+<li id="GUID-5D0D76BB-49EE-5176-B998-A2DCD8253043"><p>queue transactions
+asynchronously, and </p> </li>
+<li id="GUID-AE1F7A2B-04AD-521E-98E2-0E7CFD21024D"><p>cancel asynchronous
+transactions. </p> </li>
+</ul> <p>Slave nodes operate at the level of the transfer, not the
+transaction, and must be told what channel and buffer to use. They
+act in response to slave callbacks. </p> <p>The slave side API provides
+functionality to: </p> <ul>
+<li id="GUID-AEE022D0-05C9-57D4-887B-B0B0EDD13694"><p>capture a channel, </p> </li>
+<li id="GUID-BD58A640-F61C-5CBA-8743-876A1FF0B4DA"><p>release a channel, </p> </li>
+<li id="GUID-E1F4CE98-E6CF-5AFF-A287-DEAF87BFFBDD"><p>register a receive
+buffer, </p> </li>
+<li id="GUID-5B1A90FE-FAB0-5BFA-BAB8-C124D4478BA7"><p>register a transmit
+buffer, and </p> </li>
+<li id="GUID-A44525D9-0FB3-5EFF-B233-D6EC3C78CD69"><p>specify a trigger
+which starts the next transfer. </p> </li>
+</ul> <p>A channel may also be a MasterSlave channel. A MasterSlave
+channel enters either master mode or slave mode when certain entry
+conditions are fulfilled and continues in that mode until certain
+exit conditions are fulfilled. A MasterSlave channel can never operate
+in both modes simultaneously. </p> <p>A MasterSlave channel enters
+master mode as soon as a transaction is queued. It continues in master
+mode until all transactions are completed and then exits master mode.
+While in master mode it accepts no slave API calls. </p> <p>A MasterSlave
+channel enters slave mode when a client captures the channel. It continues
+in slave mode until the channel is released and then exits slave mode.
+While in slave mode it accepts no master API calls. </p> <p>The master
+and slave side APIs both also supply a static extension used by developers
+to provide additional functionality. </p> </section>
+<section id="GUID-9DF689AD-5FA8-4EA0-8F1C-007EA2F5FEF2"><title>Configuration
+of bus, transaction and device</title> <p>The proprietary variants
+of IIC technology and the different devices which they support require
+configuration at the level of the bus and the node. Bus configuration
+is static and node configuration dynamic. </p> <p>The static configuration
+of the bus is specified at design time and executed at build time.
+It involves designating nodes as master or slave and assigning addresses
+to nodes. The IIC performance service API encapsulates the bus configuration
+as a single structured integer called the <codeph>bus ID</codeph> whose
+value is set using bit masks representing individual configuration
+parameters. </p> <p>The dynamic configuration of the nodes is performed
+by the clients. Each client configures its channel at the start of
+a transaction, setting parameters relating to the physical node and
+to the transaction: speed, endianness, word length and so on. </p> </section>
+<section id="GUID-B7C1E9D9-6C27-42E3-A769-EBE38A00C110"><title>Timers</title><p>There are two timers that must be implemented in the SHAI implementation
+layer:<ul>
+<li><p>Client Timeout</p></li>
+<li><p>Master Timeout</p></li>
+</ul></p><p><b>Client timeout</b> - specifies how long to wait for
+the client to respond to bus events, such as data received, before
+telling the SHAI implementation layer to cancel the transaction.</p><p><b>Master timeout</b> - specifies how long to wait for the master
+to perform the next transfer in the transaction. If this timer runs
+out, then terminate the transaction by calling the PIL <codeph>NotifyClient()</codeph> which will inform both the client and the SHAI implementation layer
+that the transaction is aborted.</p></section>
+</conbody><related-links>
+<link href="GUID-9986DCC6-EE73-59FB-BDAC-9B09DC64FBCE.dita"><linktext>Client
+of Master Channel Tutorial</linktext></link>
+<link href="GUID-F461CBB3-F8D1-5961-AD51-5741143A1CB1.dita"><linktext>Client
+of Slave Channel Tutorial</linktext></link>
+<link href="GUID-99FC067C-0AED-5373-AF63-8DB7FF5C1F7E.dita"><linktext>SPI
+Technology Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-B30D6027-EB0F-578F-9B2F-AFC2DFD27E39-master.png has changed
Binary file Adaptation/GUID-B30D6027-EB0F-578F-9B2F-AFC2DFD27E39_d0e19057_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B345CDED-92DC-50ED-BC87-AC3C903E5E10.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-B345CDED-92DC-50ED-BC87-AC3C903E5E10" xml:lang="en"><title>Serial
+Port Driver Overview</title><shortdesc>Serial ports are used for debugging. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-586E398E-CB58-4A83-B0E0-97258A1E1A05"><title>Purpose</title> <p>The serial port driver allows Symbian platform
+to communicate with the outside world via a serial port. </p> <p>Serial ports
+are used for debugging by various tools: for example the EKA2 Run-Mode Debugger
+as well as being used on actual phones in implementing the IR port. </p> </section>
+<section id="GUID-7D779840-992B-4B63-99AE-B3C7ECC3DC9F"><title>Key concepts and terms</title> <dl>
+<dlentry>
+<dt>Serial communications</dt>
+<dd><p>Means of sending data whereby transmission proceeds one bit after another
+over a single medium for example a wire. </p> </dd>
+</dlentry>
+</dl> </section>
+<section id="GUID-F3AE7EBD-8746-4EDA-B4B6-8A6892116427"><title>Architecture</title> <p>Serial communications on Symbian platform
+is via a client/server framework. The client communicates with the serial
+communications server which, in turn, communicates to the appropriate plug
+in. These plug ins are known as CSY modules. </p> </section>
+<section id="GUID-3A128EB6-3EF9-4821-8788-4615CC2A4B26"><title>APIs</title> <table id="GUID-A50BA6DF-B9DD-548B-9D7C-170E6F2C991D">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<thead>
+<row>
+<entry>API</entry>
+<entry>Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-5CEF7907-E485-3626-8587-53CAC2A06544.dita"><apiname>CPort</apiname></xref>  </p> </entry>
+<entry><p>Defines the port that is to be used. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-D8C11F99-7452-35BB-B53E-440968D4C1A3.dita"><apiname>CSerial</apiname></xref>  </p> </entry>
+<entry><p>Serial protocol factory interface. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A6E4627A-A3AE-3B64-9E5C-710EE15C5595.dita"><apiname>TSerialInfo</apiname></xref>  </p> </entry>
+<entry><p>Serial protocol information. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B35A70D2-1BC8-51DE-95BF-F315DB394582.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,99 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-B35A70D2-1BC8-51DE-95BF-F315DB394582" xml:lang="en"><title>Demand
+Paging Overview</title><shortdesc>Demand paging is a technique where content appears to be present
+in RAM, but may in fact be stored on some external media and is transparently
+loaded when needed.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-733D5AEF-6488-5F11-ABA7-AB4E5B45F9D0"><title>Purpose</title> <p>Demand
+paging trades off increased available RAM against increased data latency,
+increased media wear and increased power usage. Overall performance may be
+increased as there can be more RAM available to each application as it runs. </p> <p>Demand
+paging is used to reduce the amount of RAM that needs to be shipped with a
+device and so reduces the device cost. </p> </section>
+<section id="GUID-BC958271-5F6B-59D4-A60D-21AB336377D9"><title>Description</title> <p>Demand
+paging relies on the fact that most memory access is likely to occur in a
+small region of memory and not spread over the entire memory map. This means
+that if only that small area of memory is available to a process (or thread)
+at any one time, then the amount of RAM required can be reduced. The small
+area of memory is known as a page. The working RAM is broken down into pages,
+some of which are used directly by the processor and the rest are spare. Since
+Symbian platform is a multi-tasking operating system, there is more than one
+page in the working RAM at any one time. There is one page per thread. </p> <p>There
+are three types of demand paging: ROM paging, code paging and writable data
+paging. All of these types of demand paging have some features in common: </p> <ul>
+<li id="GUID-82F77F93-433B-59E8-B44E-0EC9F183B5C0"><p>A free RAM pool </p> </li>
+<li id="GUID-7318C5DE-4342-51AB-8A2F-86F3B2DB6083"><p>Working RAM </p> </li>
+<li id="GUID-296241B1-9896-5673-A9F3-E87F5404E66E"><p>Paging Fault Handler </p> </li>
+<li id="GUID-D3C9BC6B-9F1F-56E9-9C31-ABFC172CD7D8"><p>A source of code and/or
+data that the processor needs to access. </p> </li>
+</ul> <p>With demand paging, the processor requires content to be present
+in the working RAM. If the content is not present, then a 'paging fault' occurs
+and the required information is loaded into a page of the working RAM. This
+is known as "paged-in". When the contents of this page are no longer required,
+then the page returns to the pool of free RAM. This is known as "paging-out". </p> <p>The
+difference between the types of demand paging is the source that is to be
+used: </p> <ul>
+<li id="GUID-A6CAEFFD-729A-52C6-8576-15D069A287FB"><p>For ROM paging, it is
+code and/or data stored under the <xref href="GUID-1B9EFA73-D949-5E8C-BD7C-17D37079FBC4.dita">ROM
+file system</xref>  </p> </li>
+<li id="GUID-BC64B7AB-2A33-573A-8F0B-C2EB10A49B51"><p>For code paging, it
+is code and/or data stored using <xref href="GUID-02126A62-B2FA-5DAB-AC4D-536A3BCD7BA1.dita">ROFS
+file system</xref>  </p> </li>
+<li id="GUID-B511A99E-187F-5962-A0E8-2783B53834C7"><p>For writable data paging,
+it is the writable data stored in RAM, for example user stacks and heaps.
+In this case, the data is moved to a backing store. </p> </li>
+</ul> <fig id="GUID-FDD6829A-DAF9-5752-9C3F-2338625054FA">
+<image href="GUID-3FE9C184-1880-51E1-B045-3C2EA4BE204A_d0e78117_href.png" placement="inline"/>
+</fig> <p>The diagram above shows the basic operations involved in demand
+paging: </p> <ol id="GUID-598BA3E8-7BB9-585D-913B-5453D8500CBF">
+<li id="GUID-E65CC155-049D-5351-9A01-5FCDA3263FAB"><p>The processor wants
+to access content which is not available in the working RAM, causing a 'paging
+fault'. </p> </li>
+<li id="GUID-DF626329-9D08-5242-881A-15D8837BAA02"><p>The paging fault handler
+starts the process for copying a page of the source into a page of RAM. </p> </li>
+<li id="GUID-BB88798C-1D62-540B-A0C6-9C026E1D1DAB"><p>A page is selected. </p> </li>
+<li id="GUID-CD8265F9-D42A-57B7-8A33-712FA4B9923F"><p>The contents of the
+source is loaded into the page and this becomes part of the working memory. </p> </li>
+<li id="GUID-721F338C-108F-58C9-B430-56730F26B66B"><p>When the contents of
+the page are no longer required, the page is returned to the free RAM pool. </p> </li>
+</ol> </section>
+<section id="GUID-C2E6EE31-1AD6-4580-9296-E8E29E8C76F1"><title>Demand Paging features</title> <p>Demand Paging provides the
+following features: </p> <ul>
+<li id="GUID-75F892EA-D389-50D2-98AF-F66D16CF89E4"><p>Reduced amount of RAM
+required </p> </li>
+<li id="GUID-4356F1F0-1DB1-5DBE-AB30-B4AB4883144C"><p>Improved performance
+in applications that involve loading a large amount of code into RAM, since
+the number of memory access operations required has been reduced </p> </li>
+<li id="GUID-21B9223E-2218-5AAA-8611-4DFAB63224BC"><p>Improved stability in
+Out Of Memory (OOM) conditions. </p> </li>
+</ul> </section>
+<section id="GUID-21427657-A93E-465D-AD6E-F26ED83D2734"><title>Demand Paging limitations</title> <p>The following are known
+limitations of Demand Paging: </p> <ul>
+<li id="GUID-B41C667E-37DF-59B4-A115-E9232F0E293B"><p>The access time cannot
+be guaranteed. </p> <p>There is an orders of magnitude difference in the access
+time between an access where no page fault occurs and one where a page fault
+occurs. If a page fault does not occur, then the time taken for a memory access
+is in the tens to hundreds of nanosecond range. If a page fault does occur,
+then the time taken for a memory access could be in the millisecond range </p> </li>
+<li id="GUID-63D8300F-D884-530A-9394-A51183A399A5"><p>Device drivers have
+to be written to allow for data latency when a page fault occurs. </p> </li>
+</ul> </section>
+</conbody><related-links>
+<link href="GUID-6F82A35E-9F11-591D-AA5C-8F60734A2827.dita"><linktext>Demand Paging
+Guides</linktext></link>
+<link href="GUID-795B8649-B6C3-5540-B52A-9B460F35A5B5.dita"><linktext>ROM paging</linktext>
+</link>
+<link href="GUID-CE9EA167-0594-5E61-9640-6B2B63A92EA7.dita"><linktext>Code Paging</linktext>
+</link>
+<link href="GUID-2B7D04D9-98DE-5284-836D-01DB4FA8949D.dita"><linktext>Writable
+Data Paging</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,597 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE" xml:lang="en"><title>Boot
+Table Functions</title><shortdesc>Describes how to implement the functions that the bootstrap implementation
+must provide.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The <xref href="GUID-9595FD6F-1EDE-51A8-B00D-029CFDFE0F38.dita">boot table</xref> function
+entries are summarised in the following table. Each is identified by its <codeph>TBootTableEntry</codeph> enumerator
+that defines its position in the table. Click the enumerator symbol for more
+detail on what the function must do. </p>
+<table id="GUID-D7774430-469D-5E6F-8419-F23DD3E517A0">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Enumerator symbol</b>  </p> </entry>
+<entry><p> <b>Summary description</b>  </p> </entry>
+</row>
+<row>
+<entry><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-D52E6FFC-7B8B-500C-96B3-9603EA0A3E76">BTF_WriteC</xref> </p> </entry>
+<entry><p>Outputs a character to the debug port. </p> </entry>
+</row>
+<row>
+<entry><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-1C4372C8-DFC8-5989-AC10-5A12F661AE70">BTF_RamBanks</xref> </p> </entry>
+<entry><p>Gets a list of possible RAM banks. </p> </entry>
+</row>
+<row>
+<entry><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-84D468E7-7F0E-53ED-A52F-491869900286">BTF_SetupRamBank</xref> </p> </entry>
+<entry><p>Does any required setup for each RAM bank. </p> </entry>
+</row>
+<row>
+<entry><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-52792290-48DA-5F1A-A7AD-0105A8AA37CF">BTF_RomBanks</xref> </p> </entry>
+<entry><p>Gets a list of possible ROM banks. </p> </entry>
+</row>
+<row>
+<entry><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-CE98DDA6-D809-5DEB-85A0-0332D2472CAA">BTF_SetupRomBank</xref> </p> </entry>
+<entry><p>Does any required setup for each ROM bank. </p> </entry>
+</row>
+<row>
+<entry><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-62CD8D6F-6E12-5DFC-85BC-EA24000BA588">BTF_HwBanks</xref> </p> </entry>
+<entry><p>Gets a list of required I/O mappings. </p> </entry>
+</row>
+<row>
+<entry><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-B3C6ACE9-A803-59D4-8EBD-314363905427">BTF_Reserve</xref> </p> </entry>
+<entry><p>Reserves physical RAM if required. </p> </entry>
+</row>
+<row>
+<entry><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-4DEA1D4C-EC7B-5F9A-A293-A7F80899044B">BTF_Params</xref> </p> </entry>
+<entry><p>Gets a list of configuration parameters. </p> </entry>
+</row>
+<row>
+<entry><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-EEF889E7-915F-57E9-8E2D-DC17B24C7728">BTF_Final</xref> </p> </entry>
+<entry><p>Does any final setup required before booting the kernel. </p> </entry>
+</row>
+<row>
+<entry><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-4C8986CB-0D5A-5D61-8A4B-DAC1B9D2C8B5">BTF_Alloc</xref> </p> </entry>
+<entry><p>Allocates RAM during boot. </p> </entry>
+</row>
+<row>
+<entry><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-9723F1BA-6B97-5E6A-A913-8B17C100787D">BTF_GetPdePerm</xref> </p> </entry>
+<entry><p>Gets MMU PDE permissions for a mapping. </p> </entry>
+</row>
+<row>
+<entry><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-ACAEB6E1-F8D2-51E9-AB57-4E4658E4F004">BTF_GetPtePerm</xref> </p> </entry>
+<entry><p>Gets MMU PTE permissions for a mapping. </p> </entry>
+</row>
+<row>
+<entry><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-DF0A1707-49C5-5050-B096-77704EA449DA">BTF_PTUpdate</xref> </p> </entry>
+<entry><p>Called when a page table entry is updated. </p> </entry>
+</row>
+<row>
+<entry><p><xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-37E8A845-6326-52F1-9607-5488B1E009A8">BTF_EnableMMU</xref> </p> </entry>
+<entry><p>Enables the MMU. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table>
+<section id="GUID-D52E6FFC-7B8B-500C-96B3-9603EA0A3E76"><title>BTF_WriteC</title> <p><b>What the function should do</b> </p> <p>On non-debug bootstrap builds,
+where <codeph>CFG_DebugBootRom</codeph> is set to FALSE, the function should
+return immediately without doing anything. </p> <p>On debug bootstrap builds,
+where <codeph>CFG_DebugBootRom</codeph> is set to TRUE, the function should
+output a single character to the debug port. </p> <p>It may be necessary to
+examine the <xref href="GUID-DE701BC5-4AA8-345F-BDD5-5737DB8C0098.dita#GUID-DE701BC5-4AA8-345F-BDD5-5737DB8C0098/GUID-FCFF2134-D89D-3861-9870-BF1B57D1241B"><apiname>TRomHeader::iDebugPort</apiname></xref> field to determine the
+correct destination for the character. The function should not modify any
+registers, but may change flags. </p> <p>This function can be called with
+the MMU either disabled or enabled. Different I/O port addresses will normally
+be required in these two cases. To simplify handling of this the following
+macro is provided: </p><codeblock id="GUID-44BA5E00-45E0-5864-834A-DCC95A926F8A" xml:space="preserve">GET_ADDRESS    Rd,    PHYSICAL,    LINEAR</codeblock> <p>Where <codeph>Rd</codeph> specifies any <codeph>ARM</codeph> general purpose register. <codeph>PHYSICAL</codeph> is
+the physical address of the peripheral, <codeph>LINEAR</codeph> is its linear
+address. </p> <p>On the direct memory model, the <codeph>PHYSICAL</codeph> address
+is always loaded into <codeph>Rd</codeph>. On the moving or multiple memory
+models the macro performs a runtime check of the <codeph>CP15</codeph> control
+register to determine whether the MMU is enabled. If the MMU is enabled, then
+the <codeph>LINEAR</codeph> address is loaded into <codeph>Rd</codeph>, otherwise
+the <codeph>PHYSICAL</codeph> address is loaded. </p> <p>Note that <codeph>CFG_DebugBootRom</codeph> is
+set in the <xref href="GUID-2E4F8732-F253-5E0D-9A37-9476541E6004.dita">platform
+specific configuration header file</xref>. </p> <p><b>Entry conditions</b> </p><ul>
+<li id="GUID-7375F514-78DB-5620-A076-3F0D0A4E595C"><p> <codeph>R0</codeph> bottom
+8 bits contain the character to be output </p> </li>
+<li id="GUID-F6F936BB-2240-5C4E-AF93-9A5C63ACC28F"><p> <codeph>R10</codeph> points
+to the super page, represented by the <codeph>SSuperPageBase</codeph> struct
+defined in <filepath>os/kernelhwsrv/kernel/eka/include/kernel/kernboot.h</filepath>  </p> </li>
+<li id="GUID-333CCEE2-F3EB-5800-8F12-AE33A9FAC225"><p> <codeph>R12</codeph> points
+to the ROM header, a <xref href="GUID-DE701BC5-4AA8-345F-BDD5-5737DB8C0098.dita"><apiname>TRomHeader</apiname></xref> object </p> </li>
+<li id="GUID-D3BF3853-8542-5F0A-B3AC-4CCE02015C8A"><p> <codeph>R13</codeph> points
+to a valid stack. </p> </li>
+</ul> </section>
+<section id="GUID-1C4372C8-DFC8-5989-AC10-5A12F661AE70"><title>BTF_RamBanks</title> <p><b>What the function should do</b> </p> <p>This function should return a
+pointer to a list of RAM banks that are present. </p> <p>The list should be
+a sequence of two-word entries. Each entry has the following format: </p> <fig id="GUID-3B76398A-AE4C-563B-BB52-3701983D01B4">
+<image href="GUID-921AF7A3-C711-5979-877B-4B6D977888E8_d0e5006_href.png" placement="inline"/>
+</fig> <p>The list is terminated by an entry that has a zero MAXSIZE. </p> <p>Of
+the 32 flag bits, only one is currently defined; all undefined flags should
+be zero. Flag 0, which is bit 0 of the first word is the <codeph>RAM_VERBATIM</codeph> flag
+and is interpreted as follows: </p> <ul>
+<li id="GUID-415A4838-2858-5EE5-B9F4-D55CDD9AE02C"><p>If clear, the specified
+physical address range may or may not contain RAM, and may be only partially
+occupied. In this case generic bootstrap code will probe the range to establish
+if any RAM is present, and if so, which parts of the range are occupied. This
+process is accompanied by calls to <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-84D468E7-7F0E-53ED-A52F-491869900286">BTF_SetupRamBank</xref>. In order for the probing algorithm to work MAXSIZE must be a power of 2
+(greater than or equal to 64K), and BASE must be a multiple of MAXSIZE. </p> </li>
+<li id="GUID-6CB0DED5-838E-5F58-8796-A191ED7199D4"><p>If set, the specified
+physical range is known to be fully occupied by RAM, and furthermore, that
+all memory controller setup for that range has already been completed. In
+this case <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-84D468E7-7F0E-53ED-A52F-491869900286">BTF_SetupRamBank</xref> will
+not be called for this range. </p> </li>
+</ul> <p>Note that all banks declared in this list and subsequently found
+to be occupied will be treated as standard RAM available for any purpose.
+For this reason, internal RAM or TCRAM banks are not generally included in
+the list. </p> <p><b>Entry
+conditions</b> </p> <ul>
+<li id="GUID-61BC32CF-36E0-598F-A97B-D3C1C032951C"><p> <codeph>R10</codeph> points
+to the superpage, represented by the <codeph>SSuperPageBase</codeph> struct
+defined in <filepath>os/kernelhwsrv/kernel/eka/include/kernel/kernboot.h</filepath>  </p> </li>
+<li id="GUID-156C3C48-F4C5-5E4E-9472-C273DF805061"><p> <codeph>R12</codeph> points
+to the ROM header, a <xref href="GUID-DE701BC5-4AA8-345F-BDD5-5737DB8C0098.dita"><apiname>TRomHeader</apiname></xref> object </p> </li>
+<li id="GUID-16D3C3A1-CDE2-5249-95D6-B8B37C1C2C44"><p> <codeph>R13</codeph> points
+to a valid stack </p> </li>
+<li id="GUID-03864AFE-0A45-551B-ADA7-6FB530F7CB4D"><p>the MMU is disabled. </p> </li>
+</ul> <p><b>Exit
+conditions</b> </p> <ul>
+<li id="GUID-C38E1D41-7589-5368-8872-48FE33CA989A"><p> <codeph>R0</codeph> should
+contain the base address of the list of banks </p> </li>
+<li id="GUID-487A2C0B-DC61-5F7F-97FE-5065667134E0"><p> <codeph>R0</codeph> -<codeph>R3</codeph> and
+flags may be modified, but no other registers should be modified. </p> </li>
+</ul> </section>
+<section id="GUID-84D468E7-7F0E-53ED-A52F-491869900286"><title>BTF_SetupRamBank</title> <p><b>What the function should do</b> </p> <p>The function should do any required
+setup for each RAM bank. </p> <p>This function is called <i>twice</i> for
+each RAM bank that does <i>not</i> have the <codeph>RAM_VERBATIM</codeph> flag
+set (see the reference to the flag bits in the description of <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-1C4372C8-DFC8-5989-AC10-5A12F661AE70">BTF_RamBanks</xref>). </p> <p>The first call is prior to RAM bus width detection,
+and the second call is after width detection. </p> <p>This function is only
+required if the system has a complex and very variable RAM setup, for example
+several banks of potentially different widths. Typical systems have one or
+two banks of RAM of known width and all memory controller initialisation can
+be done in the<xref href="GUID-F67FA7B5-F6D1-5C5C-8E10-A8E317A778E4.dita#GUID-F67FA7B5-F6D1-5C5C-8E10-A8E317A778E4/GUID-C111DA06-F7EE-5E70-8D86-26BA2213B506">InitialiseHardware()</xref> function;
+in this case this function can simply return without performing any operation. </p> <p><b>Entry conditions</b> </p> <ul>
+<li id="GUID-4080EA07-03AE-5D7C-9931-71DC7A7844D6"><p> <codeph>R1</codeph> holds
+the physical base address of a bank </p> </li>
+<li id="GUID-02D174D3-A176-55A1-81C6-BEDBA72023FC"><p> <codeph> R3 = 0xFFFFFFFF</codeph> for
+the first call</p> <p> <codeph> R3 = 0x0000000Y</codeph> for the second call,
+where the bottom 4 bits represent the validity of each of the 4 byte lanes
+(bit 0=1 if D0-7 are valid, bit 1=1 if D8-15 are valid, etc.) </p> </li>
+<li id="GUID-0DD72D2D-D26D-59B1-B60B-5DA41D8B4FF0"><p> <codeph>R10</codeph> points
+to the super page, represented by the <codeph>SSuperPageBase</codeph> struct
+defined in <filepath>os/kernelhwsrv/kernel/eka/include/kernel/kernboot.h</filepath>  </p> </li>
+<li id="GUID-7EF8D070-7843-5164-BEC5-E6EC7A2B4159"><p> <codeph>R12</codeph> points
+to the ROM header, a <xref href="GUID-DE701BC5-4AA8-345F-BDD5-5737DB8C0098.dita"><apiname>TRomHeader</apiname></xref> object </p> </li>
+<li id="GUID-86030AEF-E1C5-5CCA-8E95-C9A360286609"><p> <codeph>R13</codeph> points
+to a valid stack </p> </li>
+<li id="GUID-88F1940A-A7A2-5340-8278-BB2CC269B3DE"><p>the MMU is disabled. </p> </li>
+</ul> <p><b>Exit
+conditions</b> </p> <p>Other than flags, no registers should be modified. </p> </section>
+<section id="GUID-52792290-48DA-5F1A-A7AD-0105A8AA37CF"><title>BTF_RomBanks</title> <p><b>What the function should do</b> </p> <p>This function should return a
+pointer to a list of XIP ROM banks that are present. It is not called if the
+bootstrap is found to be running in RAM; in this case it is assumed that all
+XIP code is in RAM. </p> <p>The list should be a sequence of four-word entries.
+Each entry has the following format: </p> <fig id="GUID-35A65482-24F6-5F9A-83B8-ED490F651A9A">
+<image href="GUID-4E6520E8-4BF1-55D1-B643-81B8D2816D1D_d0e5246_href.png" placement="inline"/>
+</fig> <p>The list is terminated by a zero value four-word entry. </p> <p>Only
+the first, second and fourth words of each entry are actually used by the
+rest of the bootstrap. The third is there mainly to support autodetection
+schemes. </p> <p>The <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-7361BC74-7164-52EE-9A5B-D254560D1939">ROM_BANK</xref> macro
+can be used to declare ROM bank entries. </p> <p><b>Entry conditions</b> </p> <ul>
+<li id="GUID-ABFD5EA9-459A-5961-9181-FC5A15463AE7"><p> <codeph>R10</codeph> points
+to the super page, represented by the <codeph>SSuperPageBase</codeph> struct
+defined in <filepath>os/kernelhwsrv/kernel/eka/include/kernel/kernboot.h</filepath>  </p> </li>
+<li id="GUID-888C592D-F49A-508B-80EF-E729D33C1FAE"><p> <codeph>R12</codeph> points
+to the ROM header, a <xref href="GUID-DE701BC5-4AA8-345F-BDD5-5737DB8C0098.dita"><apiname>TRomHeader</apiname></xref> object </p> </li>
+<li id="GUID-CC543EA9-34B7-5806-B987-6565CD07B052"><p> <codeph>R13</codeph> points
+to a valid stack </p> </li>
+<li id="GUID-618F3F1A-E91B-55AA-80D5-D2E894720AB9"><p>the MMU is disabled. </p> </li>
+</ul> <p><b>Exit
+conditions</b> </p> <ul>
+<li id="GUID-DAC651F9-6EF3-584D-92D2-388E7EC8A13B"><p> <codeph>R0</codeph> should
+contain the base address of the list of ROM banks. </p> </li>
+<li id="GUID-F8A205C2-4605-512A-A721-B6D2506D7263"><p> <codeph>R0</codeph> -<codeph>R3</codeph> and
+flags may be modified, but no other registers should be modified. </p> </li>
+</ul> </section>
+<section id="GUID-CE98DDA6-D809-5DEB-85A0-0332D2472CAA"><title>BTF_SetupRomBank</title> <p><b>What the function should do</b> </p> <p>The function should do any required
+setup for each ROM bank. </p> <p>It is called once immediately after the call
+to <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-52792290-48DA-5F1A-A7AD-0105A8AA37CF">BTF_RomBanks</xref> and
+then it is subsequently called again for <i>each</i> ROM bank in the list
+returned by <codeph>BTF_RomBanks</codeph>. It is not called if the bootstrap
+is running in RAM. </p> <p>This function is intended to support autodetection
+of the system ROM configuration. For example, the first call with <codeph>R11</codeph> set
+to zero could be used to set the bus controller to 32 bit width to enable
+width detection to be performed on ROM banks other than the boot block. Subsequent
+per-bank calls could determine the width (possibly using an algorithm that
+repeatedly reads from the same address and checks which bits are consistent)
+and the size of the ROM bank. These would be written to the entry pointed
+by <codeph>R11</codeph> and the bus controller set up correctly for that ROM
+bank. If the bank is absent, then the size in the structure pointed to by <codeph>R11</codeph> is
+set to zero to remove it from the list. </p> <p><b>Entry conditions</b> </p> <ul>
+<li id="GUID-A13AC2C7-01EC-5A15-92F3-1ABF1FB03DD2"><p> <codeph>R10</codeph> points
+to the super page, represented by the <codeph>SSuperPageBase</codeph> struct
+defined in <filepath>os/kernelhwsrv/kernel/eka/include/kernel/kernboot.h</filepath>  </p> </li>
+<li id="GUID-CB332F6C-1B59-5B77-8396-060C9EE413E3"><p>On the first call: </p> <ul>
+<li id="GUID-96520453-4106-55AF-A0F2-D3533594EEE9"><p> <codeph>R11</codeph> contains
+0 </p> </li>
+<li id="GUID-025A5A35-6A7E-5F84-8B05-39E6427D0F63"><p> <codeph>R0</codeph> contains
+the base address of the list of ROM banks returned by <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-52792290-48DA-5F1A-A7AD-0105A8AA37CF">BTF_RomBanks</xref> </p> </li>
+</ul> <p>On subsequent calls: </p> <ul>
+<li id="GUID-CFAED6F6-4344-505B-920E-14B99784621A"><p> <codeph>R11</codeph> points
+to a RAM copy of the entry corresponding to the ROM bank currently being processed </p> </li>
+</ul> </li>
+<li id="GUID-4456CB76-38BA-568B-9295-C965B7B70069"><p> <codeph>R12</codeph> points
+to the ROM header, a <xref href="GUID-DE701BC5-4AA8-345F-BDD5-5737DB8C0098.dita"><apiname>TRomHeader</apiname></xref> object </p> </li>
+<li id="GUID-0087F2C0-343C-5F81-AC75-DEEE357A8B54"><p> <codeph>R13</codeph> points
+to a valid stack </p> </li>
+<li id="GUID-37648CD7-CB3D-547F-BC81-B354F64CF827"><p>the MMU is disabled. </p> </li>
+</ul> <p><b>Exit
+conditions</b> </p> <p>For calls where <codeph>R11</codeph> is non-zero, the
+entry pointed to by <codeph>R11</codeph> may be modified by this function
+call. </p> <p>If the entry size for a bank is set to zero, then that bank
+is assumed not to exist, and is removed from the list of ROM banks. </p> <p>Registers <codeph>R0</codeph> -<codeph>R4</codeph> and
+flags may be modified by this function; all other registers should be preserved. </p> </section>
+<section id="GUID-62CD8D6F-6E12-5DFC-85BC-EA24000BA588"><title>BTF_HwBanks</title> <p><b>What the function should do</b> </p> <p>This function should return a
+pointer to a list of required I/O mappings. </p> <p>The list should be a sequence
+of one-word and two-word entries, terminated by a zero-filled word. The entries
+in the list are defined using the <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-7728C7F2-BB04-518B-8B0A-752CB799A561">macros
+for declaring I/O mappings</xref>: <codeph>HW_MAPPING</codeph>, <codeph>HW_MAPPING_EXT</codeph>, <codeph>HW_MAPPING_EXT2</codeph>,
+and <codeph>HW_MAPPING_EXT3</codeph>. </p> <p>In the template port, this is
+implemented in <filepath>os/kernelhwsrv/bsptemplate/asspandvariant/template_variant/bootstrap/template.s</filepath>.
+Find the symbol <codeph>GetHwBanks</codeph>: </p> <codeblock id="GUID-93B8920C-C244-5CEE-95B4-1F49BB1D8B19" xml:space="preserve">GetHwBanks    ROUT
+        ADR        r0, %FT1
+        MOV        pc, lr
+        ...
+        DCD            0                                            ; terminator
+</codeblock> <p>The pointer in the boot table to this list of I/O mappings
+is defined by the symbol <codeph>GetHwBanks</codeph>. </p> <codeblock id="GUID-AAC33135-33B2-5B31-8D3B-906636669310" xml:space="preserve">BootTable
+    ...
+    DCD    GetHwBanks                ; get list of HW banks
+    ...</codeblock> <p>To support Level 2 cache (either L210 or L220), you
+need to add the base address of the Level 2 cache controller to the list of
+hardware banks. For example: </p> <codeblock id="GUID-F28CD3A1-CBB8-5052-ADC1-96A23FE9DA5D" xml:space="preserve">GetHwBanks  ROUT
+        ADR     r0, %FT1
+        MOV     pc, lr
+        ...
+        HW_MAPPING  L210CtrlBasePhys, 1, HW_MULT_1M
+        ...
+        DCD     0                                 ; terminator
+</codeblock> <p>See also the<xref href="GUID-F67FA7B5-F6D1-5C5C-8E10-A8E317A778E4.dita#GUID-F67FA7B5-F6D1-5C5C-8E10-A8E317A778E4/GUID-C111DA06-F7EE-5E70-8D86-26BA2213B506">InitialiseHardware()</xref> function. </p> <p><b>Entry
+conditions</b> </p> <ul>
+<li id="GUID-74CDF102-52AD-5BE2-83BB-4486D5DCF904"><p> <codeph>R10</codeph> points
+to the super page, represented by the <codeph>SSuperPageBase</codeph> struct
+defined in <filepath>os/kernelhwsrv/kernel/eka/include/kernel/kernboot.h</filepath>  </p> </li>
+<li id="GUID-E6B28758-C709-51E9-9604-12EF39EF95EA"><p> <codeph>R12</codeph> points
+to the ROM header, a <xref href="GUID-DE701BC5-4AA8-345F-BDD5-5737DB8C0098.dita"><apiname>TRomHeader</apiname></xref> object </p> </li>
+<li id="GUID-BCA82596-751E-5045-BADA-E71659254555"><p> <codeph>R13</codeph> points
+to a valid stack </p> </li>
+<li id="GUID-5F7B169A-F4C4-587F-AD33-46CF05619113"><p>the MMU is disabled. </p> </li>
+</ul> <p><b>Exit
+conditions</b> </p> <ul>
+<li id="GUID-59BB29EB-3437-5E3A-ADC8-6AA57BD10DFA"><p> <codeph>R0</codeph> should
+contain the base address of the list of banks </p> </li>
+<li id="GUID-0CEEEA0C-58CB-5A4E-9D94-EFE0496F264F"><p> <codeph>R0</codeph> -<codeph>R3</codeph> and
+flags may be modified, but no other registers should be modified. </p> </li>
+</ul> </section>
+<section id="GUID-B3C6ACE9-A803-59D4-8EBD-314363905427"><title>BTF_Reserve</title> <p><b>What the function should do</b> </p> <p>The function reserves physical
+RAM if required. </p> <p>It is called before the bootstrap's memory allocator
+(<xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-4C8986CB-0D5A-5D61-8A4B-DAC1B9D2C8B5">BTF_Alloc</xref>)
+is initialised to allow physical RAM to be reserved for any platform specific
+purpose. </p> <p>There are two methods available for reserving physical RAM: </p> <ol id="GUID-A68E974D-B79F-5EFF-AC43-FC068B2A0B8C">
+<li id="GUID-37C98A1E-AD3A-5D36-BA64-B24E3EC5045A"><p>Use the generic bootstrap
+function <codeph>ExciseRamArea()</codeph>, implemented in <filepath>os/kernelhwsrv/kernel/eka/kernel/arm/bootutils.s</filepath>.
+This removes a specified region from the list of RAM blocks present in the
+system. Subsequently, the excised area will no longer be treated as RAM. If
+this method is used, then the excised areas must be a multiple of 64K in size
+and aligned to a 64K boundary. </p> <p>The following entry conditions apply
+when calling <codeph>ExciseRamArea()</codeph>: </p> <ul>
+<li id="GUID-8B81140B-36A5-5DE2-A04A-59D6889935B3"><p> <codeph>R0</codeph> =
+physical base address of the area to be excised </p> </li>
+<li id="GUID-56DCD069-6683-5585-9DB5-04F540409F18"><p> <codeph>R1</codeph> =
+size of area to be excised </p> </li>
+<li id="GUID-17C76EFB-E6C3-5645-9E92-4CBC9237EA60"><p> <codeph>R9</codeph> = <codeph>SSuperPageBase::iRamBootData</codeph>  </p> </li>
+<li id="GUID-24675744-4FD7-59BE-993A-0A939682C910"><p> <codeph> R10</codeph> points
+to the super page </p> </li>
+<li id="GUID-39FF3824-78CF-5B83-904A-270E1CC5686B"><p> <codeph> R11</codeph> =
+0 </p> </li>
+<li id="GUID-2DF3FCAF-BEFC-5A87-AD8C-D38DD2A8DFA3"><p> <codeph> R13</codeph> points
+to a valid stack. </p> </li>
+</ul> </li>
+<li id="GUID-C99A07B3-BF0A-58CF-9CA1-37891380D7C5"><p>Write a list of reserved
+RAM blocks to the address passed in R11. The list should consist of two-word
+entries, the first word being the physical base address of the block and the
+second word the size. The list is terminated by an entry with zero size. The
+listed blocks will still be recognised as RAM by the kernel but will be marked
+as allocated during kernel boot. The blocks in the list should be multiples
+of 4K in size and aligned to a 4K boundary. </p> </li>
+</ol> <p>If both methods are used simultaneously, then the <codeph>ExciseRamArea()</codeph> function
+will require recalculation of the value in R11 for the second method. The
+correct value can be found by loading <codeph>R11</codeph> first with <codeph>SSuperPageBase::iRamBootData</codeph>,
+stepping forward 8 bytes at a time until an entry with a zero-filled second
+word is found, and then stepping on by a further 8 bytes. </p> <p><b>Entry conditions</b> </p> <ul>
+<li id="GUID-701D97D3-629C-5270-9E98-5677B52F12E9"><p> <codeph>R10</codeph> points
+to the super page, represented by the <codeph>SSuperPageBase</codeph> struct
+defined in <filepath>os/kernelhwsrv/kernel/eka/include/kernel/kernboot.h</filepath>  </p> </li>
+<li id="GUID-43402496-5018-5473-859A-3B2C5289FE3B"><p> <codeph>r11</codeph> points
+to the place where the pre-allocated block list should be written </p> </li>
+<li id="GUID-E25602F8-36F8-5C49-B3A8-D2B37DD7DEB7"><p> <codeph>R12</codeph> points
+to the ROM header, a <xref href="GUID-DE701BC5-4AA8-345F-BDD5-5737DB8C0098.dita"><apiname>TRomHeader</apiname></xref> object </p> </li>
+<li id="GUID-E53BCEBB-AB2A-52C5-B3C8-FDFC777EB35C"><p> <codeph>R13</codeph> points
+to a valid stack </p> </li>
+<li id="GUID-61ED18DA-CB5B-50F1-81F1-59C8EEC68E15"><p>the MMU is disabled. </p> </li>
+</ul> <p><b>Exit
+conditions</b> </p> <p>The function can modify <codeph>R0</codeph>, <codeph>R1</codeph>, <codeph>R2</codeph>,<codeph>R3</codeph>, <codeph>R11</codeph> and the flags, but should preserve all other registers. </p> </section>
+<section id="GUID-4DEA1D4C-EC7B-5F9A-A293-A7F80899044B"><title>BTF_Params</title> <p><b>What the function should do</b> </p> <p>The function should return the
+value of a run-time configurable boot parameter. The parameter is identified
+by one of the values of the <codeph>TBootParam</codeph> enumeration, which
+is passed in <codeph>R0</codeph>. </p> <p>Typically, the function is implemented
+as follows: </p> <codeblock id="GUID-60C84CAA-3B19-5FC1-8192-05519C3E76DD" xml:space="preserve">GetParameters ROUT
+    ADR    r1, ParameterTable
+    B    FindParameter
+ParameterTable    ; Include any parameters specified in TBootParam
+                ; enum here if you want to override them.
+    DCD    BPR_x, value    ; parameter number, parameter value
+    DCD    -1                ; terminator
+</codeblock> <p>This implementation calls the generic function <codeph>FindParameter()</codeph>,
+which performs the necessary lookup of the parameter number in the table.
+The parameter table should consist of a list of two-word entries, the first
+word being the parameter number and the second the parameter value. The list
+should be terminated by a negative parameter number. The generic function
+searches this table for the parameter value, and if found, returns it in <codeph>R0</codeph> as
+stated in <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-1981A220-876C-5BBD-A84C-E895F133B6B9">Exit
+conditions</xref>. </p> <p>Note that the address of this parameter table is
+also passed to the <codeph>InitCpu()</codeph> function by the <xref href="GUID-F67FA7B5-F6D1-5C5C-8E10-A8E317A778E4.dita#GUID-F67FA7B5-F6D1-5C5C-8E10-A8E317A778E4/GUID-C111DA06-F7EE-5E70-8D86-26BA2213B506">InitialiseHardware()</xref> public function. </p> <p>Each entry in the boot
+parameter table is identified by a <codeph>TBootParam</codeph> enumeration
+value that defines its position within that table. The entries have the following
+meaning: </p> <table id="GUID-B0C82F23-2342-53FE-8CFE-E82DA628D6B5">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Enumerator symbol</b>  </p> </entry>
+<entry><p> <b>Summary description</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> BPR_InitialMMUCRClear</codeph>  </p> </entry>
+<entry><p>Mask of bits to clear in MMUCR in the <codeph>InitCpu()</codeph> generic
+function. Defaults to 0xFFFFFFFF, i.e. clear all bits. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> BPR_InitialMMUCRSet</codeph>  </p> </entry>
+<entry><p>Mask of bits to set in MMUCR in the <codeph>InitCpu()</codeph> generic
+function after clearing those specified by <codeph>BPR_InitialMMUCRClear</codeph>.
+Defaults to a CPU-dependent value. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BPR_FinalMMUCRClear</codeph>  </p> </entry>
+<entry><p>Mask of bits to clear in MMUCR when the MMU is enabled. Defaults
+to 0, which means do not clear any bits. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BPR_FinalMMUCRSet</codeph>  </p> </entry>
+<entry><p>Mask of bits to set in MMUCR when the MMU is enabled after clearing
+those specified in <codeph>BPR_FinalMMUCRSet</codeph>. Defaults to a CPU-dependent
+value. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BPR_AuxCRClear</codeph>  </p> </entry>
+<entry><p>Mask of bits to clear in AUXCR in the <codeph>InitCpu()</codeph> Symbian
+platform generic function. Defaults to a CPU dependent value. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BPR_AuxCRSet</codeph>  </p> </entry>
+<entry><p>Mask of bits to set in AUXCR in the <codeph>InitCpu()</codeph> Symbian
+platform generic function after clearing those specified by <codeph>BPR_InitialAUXCRClear</codeph>.
+Defaults to a CPU-dependent value. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BPR_CAR</codeph>  </p> </entry>
+<entry><p>Initial value to set for coprocessor access register if present.
+Defaults to 0. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BPR_UncachedLin</codeph>  </p> </entry>
+<entry><p>Mandatory parameter on the direct memory model, not used on other
+memory models. The value is copied into <codeph>SSuperPageBase::iUncachedAddress</codeph> for
+use by any code which needs to do an uncached memory access, usually for memory
+controller synchronisation purposes. On systems with an MMU, this address
+will be mapped as an alias of the super page and must refer to the base address
+of a 1Mb region of unused virtual address space, aligned on a 1Mb boundary.
+On a system with no MMU, this address should be the physical address of some
+uncached memory. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> BPR_PageTableSpace</codeph>  </p> </entry>
+<entry><p>Used only on the direct memory model on systems with an MMU. Specifies
+the amount of RAM to reserve for page tables. Defaults to 32K. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BPR_KernDataOffset</codeph>  </p> </entry>
+<entry><p>Used only on the direct memory model. Specifies the offset from
+the base of the super page to the base of the kernel .data section. Defaults
+to 8K. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> BPR_BootLdrImgAddr </codeph>  </p> </entry>
+<entry><p>Mandatory parameter for bootloader configurations; not required
+for other configurations. Specifies the physical base address of the RAM-loaded
+image. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BPR_BootLdrExtraRAM</codeph>  </p> </entry>
+<entry><p>Only used on bootloader configurations. Specifies the amount of
+'user' memory to reserve (this is in fact used to satisfy <codeph>Epoc::AllocPhysicalRam</codeph> requests,
+usually for video RAM) in the case where the RAM-loaded image is at the bottom
+of RAM and so the bootloader RAM is at the top. Defaults to 1MB. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p><b>Entry
+conditions</b> </p> <ul>
+<li id="GUID-38ED47F2-BD04-5039-8A71-81D787C6B679"><p>R0 contains the number
+identifying the required parameter; see the <codeph>TBootParam</codeph> enumerator
+defined in <filepath>os/kernelhwsrv/kernel/eka/include/kernel/arm/bootdefs.h</filepath>. </p> </li>
+<li id="GUID-151A442C-5903-50F5-B425-0FB80CE950B8"><p> <codeph>R10</codeph> points
+to the super page, represented by the <codeph>SSuperPageBase</codeph> struct
+defined in <filepath>os/kernelhwsrv/kernel/eka/include/kernel/kernboot.h</filepath>  </p> </li>
+<li id="GUID-916DB071-2433-512B-A4C4-70C736DABE15"><p> <codeph>r11</codeph> points
+to the place where the pre-allocated block list should be written </p> </li>
+<li id="GUID-32D51889-00F9-5968-A3BC-A1752825B8AC"><p> <codeph>R12</codeph> points
+to the ROM header, a <xref href="GUID-DE701BC5-4AA8-345F-BDD5-5737DB8C0098.dita"><apiname>TRomHeader</apiname></xref> object </p> </li>
+<li id="GUID-7F5685B5-95EA-5C03-9E92-B50B60DAA2FC"><p> <codeph>R13</codeph> points
+to a valid stack </p> </li>
+<li id="GUID-E5D06E47-BF01-51D1-BC15-AF5D588AB5A5"><p>the MMU is disabled. </p> </li>
+</ul> <p id="GUID-1981A220-876C-5BBD-A84C-E895F133B6B9"><b>Exit conditions</b> </p> <p>If
+the parameter value is specified, it should be returned in <codeph>R0</codeph> and
+the <codeph>N</codeph> flag should be cleared. </p> <p>If the parameter value
+is not specified, the <codeph>N</codeph> flag should be set. </p> <p>Registers <codeph>R0</codeph> , <codeph>R1</codeph>, <codeph>R2</codeph> and
+the flags may be modified. All other registers should be preserved. </p> </section>
+<section id="GUID-EEF889E7-915F-57E9-8E2D-DC17B24C7728"><title>BTF_Final</title> <p><b>What the function should do</b> </p> <p>The function should do any final
+setup required before booting the kernel. It is called at the end of the bootstrap,
+just before booting the kernel. </p> <p>The function should: </p> <ul>
+<li id="GUID-388B647D-5AD6-58FD-B78A-67DBC6B945A5"><p>Map any cache flushing
+areas required by the CPU. </p> <p>Processors that flush the data cache by
+reading dummy addresses or by allocating dummy addresses into the cache (e.g.
+StrongARM and XScale processors) will need a main cache flush area. If the
+processor has an alternate data cache (e.g. StrongARM and XScale mini data
+cache) a second flush area may be required for it. On the moving and multiple
+memory models the linear addresses used for these flushing areas are fixed
+(<codeph>KDCacheFlushArea</codeph> and <codeph>KDCacheFlushArea</codeph> +1MB
+respectively). On the direct memory model any unused linear address may be
+selected. The linear addresses used should be written into <codeph>SSuperPageBase::iDCacheFlushArea</codeph> and <codeph>SSuperPageBase::iAltDCacheFlushArea</codeph>. In addition, the fields <codeph>SSuperPageBase::iDCacheFlushWrap</codeph> and <codeph>SSuperPageBase::iAltDCacheFlushWrap</codeph> should
+be written with a power of 2 at least twice the cache size and no bigger than
+half the reserved address area. A value of 0x00080000 (512KB) is usually used. </p> </li>
+<li id="GUID-B0061BBC-DEBE-5A12-B11B-39F73FFC7072"><p>Populate any super page
+or CPU page fields with platform-specific information used by the variant,
+for example addresses of CPU idle routines in the bootstrap. Routines can
+be placed in the bootstrap if known alignment is required for the routine. </p> </li>
+</ul> <p><b>Entry
+conditions</b> </p> <ul>
+<li id="GUID-61AA6724-B809-5742-A6FD-F39D5269B2EE"><p> <codeph>R10</codeph> points
+to the super page, represented by the <codeph>SSuperPageBase</codeph> struct
+defined in <filepath>os/kernelhwsrv/kernel/eka/include/kernel/kernboot.h</filepath>  </p> </li>
+<li id="GUID-B58A49E2-B4AA-53D4-816A-B48491A707D8"><p> <codeph>r11</codeph> points
+to the kernel image header, a <xref href="GUID-88C84EC0-B63E-3848-82BF-E3A81E2F7E9A.dita"><apiname>TRomImageHeader</apiname></xref> object </p> </li>
+<li id="GUID-34A71E2F-9232-5DAF-AF04-D51822B65E8D"><p> <codeph>R12</codeph> points
+to the ROM header, a <xref href="GUID-DE701BC5-4AA8-345F-BDD5-5737DB8C0098.dita"><apiname>TRomHeader</apiname></xref> object </p> </li>
+<li id="GUID-38C918F2-9769-55EC-A9F1-5D64CCB6EA2B"><p> <codeph>R13</codeph> points
+to a valid stack </p> </li>
+<li id="GUID-538DE8FF-2BE4-5D50-933C-F6D7E94A3CC1"><p>the MMU is disabled. </p> </li>
+</ul> <p><b>Exit
+conditions</b> </p> <p>Registers <codeph>R0</codeph> to <codeph>R9</codeph> and
+flags may be modified; other registers should be preserved. </p> </section>
+<section id="GUID-4C8986CB-0D5A-5D61-8A4B-DAC1B9D2C8B5"><title>BTF_Alloc</title> <p><b>What the function should do</b> </p> <p>Allocates RAM during boot. </p> <p>This
+function is called at various points to initialise the memory allocator, or
+to allocate physical RAM. A generic implementation is provided for this function
+and this will normally be sufficient, so a typical implementation for this
+function reduces to: </p> <codeblock id="GUID-90A5743F-4FB5-59A4-9FC8-DAB2CCDF8EB0" xml:space="preserve">DCD HandleAllocRequest</codeblock> <p>in
+the boot table. For systems with no MMU, the function name should be changed
+to <codeph>AllocatorStub</codeph>. </p> <p>It is advisable not to override
+this function. </p> <p><b>Entry
+conditions</b> </p> <ul>
+<li id="GUID-72DBAE17-60F1-5EF1-B9B1-2E69E109FE3B"><p>R2 contains the type
+of allocation required; this is defined by one of the values of the <codeph>TBootMemAlloc</codeph> enumeration </p> </li>
+<li id="GUID-70690B58-7B7B-51CE-A678-F25222CC6664"><p>R4 contains the size
+to allocate (as a log to base 2) for allocations of type <codeph>BMA_Kernel</codeph> </p> </li>
+<li id="GUID-C993DE47-01D2-5D7F-98FE-5CAEDAF16079"><p> <codeph>R10</codeph> points
+to the super page, represented by the <codeph>SSuperPageBase</codeph> struct
+defined in <filepath>os\kernelhwsrv\kernel\eka\include\kernel\kernboot.h</filepath>  </p> </li>
+<li id="GUID-030F04FA-1919-5643-A634-60E9A9228FA9"><p> <codeph>R12</codeph> points
+to the ROM header, a <xref href="GUID-DE701BC5-4AA8-345F-BDD5-5737DB8C0098.dita"><apiname>TRomHeader</apiname></xref> object </p> </li>
+<li id="GUID-DB3E70CC-7B35-5952-BE93-5A47674F3A5A"><p> <codeph>R13</codeph> points
+to a valid stack </p> </li>
+<li id="GUID-7D7962A8-57A0-5F16-9651-0A0E71F1605C"><p>the MMU may be enabled
+or disabled. </p> </li>
+</ul> <p>The type of allocation required is defined by the value of the enumerator <codeph>TBootMemAlloc</codeph>,
+defined in <filepath>os/kernelhwsrv/kernel/eka/include/kernel/arm/bootdefs.h</filepath>.
+The allocation types are as follows: </p> <table id="GUID-756C039B-D079-5EFC-B3A6-37675FD4CCBC">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Enumerator symbol</b>  </p> </entry>
+<entry><p> <b>Summary description</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BMA_Init</codeph>  </p> </entry>
+<entry><p>Called to initialise the memory allocator. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BMA_SuperCPU </codeph>  </p> </entry>
+<entry><p>Should return the physical address of the super page in R0. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BMA_PageDirectory</codeph>  </p> </entry>
+<entry><p>Should return the physical address of the page directory in R0. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BMA_PageTable</codeph>  </p> </entry>
+<entry><p>Allocate a new page table (1KB size and 1KB alignment) and return
+its physical address in R0. It is not necessary to clear the page table here. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BMA_Kernel</codeph>  </p> </entry>
+<entry><p>Allocate a page of size 2R4. This must be a valid processor page
+size; on ARM this means R4=12, 16 or 20. The returned physical address will
+be a multiple of 2R4. If no page of the requested size can be allocated a
+page of the largest possible smaller size will be allocated and R4 will be
+modified accordingly.<note>If no page of any size can be allocated this call
+will fault the system.</note> </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BMA_Reloc</codeph>  </p> </entry>
+<entry><p>Called when the allocator data structures need to be relocated in
+memory. On entry R0 contains the offset to apply to all pointers (that is,
+the new address of data minus the old address). It is assumed that all the
+allocator data is contained in the super page or CPU page and that there are
+no pointers to areas which could be relocated independently. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p><b>Exit
+conditions</b> </p> <p> <codeph>R0</codeph> and flags may be modified. For <codeph>BMA_Kernel</codeph> allocations, <codeph>R4</codeph> may
+also be modified. All other registers should be preserved. </p> </section>
+<section id="GUID-9723F1BA-6B97-5E6A-A913-8B17C100787D"><title>BTF_GetPdePerm</title> <p><b>What the function should do</b> </p> <p>This function is called at various
+points to translate a standardised permission descriptor along with the size
+of mapping required to the PDE permission/attribute bits needed for such a
+mapping. A standardised permission descriptor can be either an index into
+the boot table (for any of the standard permission types) or the value generated
+by a <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-B5EC22B5-B995-5D54-8F33-1B6FCE11BB3F">BTP_ENTRY</xref> macro. </p> <p>A
+generic implementation is provided for this function and it should not be
+necessary to override it. A typical implementation for this function then
+just reduces to: </p> <codeblock id="GUID-57B1277B-B322-506B-A5EC-A4D10C5FA420" xml:space="preserve">DCD GetPdeValue</codeblock> <p>in
+the boot table. </p> <p>Note that for systems with no MMU, this function is
+not required. </p> </section>
+<section id="GUID-ACAEB6E1-F8D2-51E9-AB57-4E4658E4F004"><title>BTF_GetPtePerm</title> <p><b>What the function should do</b> </p> <p>This function is called at various
+points to translate a standardised permission descriptor along with the size
+of mapping required to the PTE permission/attribute bits needed for such a
+mapping. A standardised permission descriptor can be either an index into
+the boot table (for any of the standard permission types) or the value generated
+by <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-B5EC22B5-B995-5D54-8F33-1B6FCE11BB3F">BTP_ENTRY</xref> macro. </p> <p>A
+generic implementation is provided for this function and it should not be
+necessary to override it. In the boot table, a typical implementation for
+this function then reduces to: </p> <codeblock id="GUID-E0836362-3BAE-54CB-9A1E-C81C1E823550" xml:space="preserve">DCD GetPteValue</codeblock> <p>Note
+that for systems with no MMU, this function is not required. </p> </section>
+<section id="GUID-DF0A1707-49C5-5050-B096-77704EA449DA"><title>BTF_PTUpdate</title> <p><b>What the function should do</b> </p> <p>This function is called whenever
+a PDE or PTE is updated. It performs whatever actions are required to make
+sure that the update takes effect. This usually means draining the write buffer
+and flushing the TLB (both TLBs on a Harvard architecture system). </p> <p>A
+generic implementation is provided for this function and it should not be
+necessary to override it. In the boot table, a typical implementation for
+this function then reduces to: </p> <codeblock id="GUID-FE889B79-013E-5A93-8ED0-51BEB97623A4" xml:space="preserve">DCD PageTableUpdate</codeblock> <p>Note
+that for systems with no MMU, this function is not required. </p> </section>
+<section id="GUID-37E8A845-6326-52F1-9607-5488B1E009A8"><title>BTF_EnableMMU</title> <p><b>What the function should do</b> </p> <p>This function is called to enable
+the MMU and thereby switch from operating with physical addresses to operating
+with virtual addresses. </p> <p>A generic implementation is provided for this
+function and it should not be necessary to override it. In the boot table,
+a typical implementation for this function then reduces to: </p> <codeblock id="GUID-4FB9161D-18BA-5ADC-AB32-4D8E86DAF55F" xml:space="preserve">DCD EnableMmu</codeblock> <p>Note
+that for systems with no MMU, this function is not required. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B4C05C46-F2C9-57FA-AD85-EFE6479C2FF1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-B4C05C46-F2C9-57FA-AD85-EFE6479C2FF1" xml:lang="en"><title>Design</title><shortdesc>When you start a port, you must make a decision if the driver must
+provide record, playback, or both playback and record.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>If the PDD is to support audio transfer in a single direction, either record
+or playback, then a conventional PDD implementation is required. The PDD opens
+only a single driver channel and the PDD factory creates either a record or
+playback PDD object. </p>
+<p>If the PDD is to support audio transfer in both directions then it must
+be implemented to open two units, one playback unit and one record unit. For
+each unit the PDD factory must create the appropriate PDD object. </p>
+<p>One complication in this configuration is the need to co-ordinate access
+to the single audio hardware device from the two separate PDD objects. This
+configuration needs coordination when accessing the hardware device from two
+separate PDD objects, detecting and preventing situations where the handling
+of a PDD function for the channel in one direction conflicts with the channel
+setup in the other direction, specifically: </p>
+<ul>
+<li id="GUID-076CE21B-E350-5D87-A486-8AFC120E8DE9"><p>preventing the setup
+of conflicting audio configurations between the record and playback channels. </p> </li>
+<li id="GUID-27C1DD90-DE14-51CD-A723-86C7696D4C4F"><p>preventing the channel
+in one direction from powering down the audio hardware device while it is
+being used for data transfer by the other channel. </p> </li>
+</ul>
+<p>The solution is to move the code that controls those aspects of audio hardware
+setup which are shared between the two driver channels into the PDD factory
+object, as this object is shared. </p>
+<p>The porting process focuses on implementing a PDD that supports both record
+and playback as this is the most common situation. The template port Sound
+Driver is setup for this configuration. A PDD that supports audio transfer
+in a single direction only omits the implementation for the direction not
+supported. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B5657E8C-770C-4322-88B2-057AAEF62E95.ditamap	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,1090 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--Arbortext, Inc., 1988-2008, v.4002-->
+<!DOCTYPE map PUBLIC "-//OASIS//DTD DITA Map//EN"
+ "map.dtd">
+<map id="GUID-B5657E8C-770C-4322-88B2-057AAEF62E95" xml:lang="en"><?Pub
+Caret1?>
+<title>Adaptation</title>
+<topicref href="GUID-59322A4F-B9CB-5997-B843-C4A80F8D42F1.dita"
+id="GUID-F376AD77-061F-409C-9F87-14BF7FB81D64">
+<topicref href="GUID-FCCF9634-0610-5199-A37A-CF2EC9B73261.dita"
+id="GUID-D9D46D92-915E-48E9-9D03-A5D2F5928F9A"></topicref>
+<topicref href="GUID-D5EE0A17-2246-4CB3-9CE5-538F1E01F8D4.dita"
+id="GUID-4A2B8EC1-4227-44D2-96D1-642D8C0E5D9B"></topicref>
+<topicref href="GUID-C9923DF3-8425-4EB4-8066-FB5A92A85F5B.dita"
+id="GUID-9A857DF4-8730-4112-9192-756B4E08AD05"></topicref>
+<topicref href="GUID-FB063C1A-EF9F-4292-827F-A3DBC7C7F13A.dita"
+id="GUID-27BF45C5-9073-4E3A-8124-8ED030A19920">
+<topicref href="GUID-38FD682F-656B-48F7-A553-50BC4F1FB4BB.dita"
+id="GUID-2CFAE410-B92A-48F9-8A85-30E0E1FCBE17"></topicref>
+<topicref href="GUID-AC2E5824-4E69-4964-968F-839EB5D2EF4F.dita"
+id="GUID-B1C54550-EFD6-494F-B633-F30A70DC052A"></topicref>
+<topicref href="GUID-2C6B7D51-C201-453D-ABBA-C9EC6B3DBDB2.dita"
+id="GUID-0B87594A-4B33-46BE-A467-2E9BAC207640"></topicref>
+<topicref href="GUID-5BD2D468-838A-49BC-BA92-F41102D37CBC.dita"
+id="GUID-231674EA-F103-4DF1-96D5-9090A5F46387"></topicref>
+<topicref href="GUID-372D2B88-2035-44A5-82CF-57FF131DDEBE.dita"
+id="GUID-2167E12A-E0F2-4E32-BAD1-484DB21CD8E3"></topicref>
+<topicref href="GUID-CEA3343B-138E-4D6B-8E5F-A255C5C73376.dita"
+id="GUID-B195AFF3-25DE-46A4-B70A-C8A13149779E"></topicref>
+<topicref href="GUID-B8B36A53-CB13-41C1-9CCC-CA5AABE13BF6.dita"
+id="GUID-F1D38F5D-E7D5-4D3B-8170-FD93B57977AA"></topicref>
+<topicref href="GUID-7BCC0EFA-0DD5-4879-BECF-C32D04BC8A39.dita"
+id="GUID-29EF8ED6-CABB-4C3D-9FCC-8F44E700D8FB"></topicref>
+</topicref>
+<topicref href="GUID-0C84FD76-87B2-4AD1-B23A-2C5C8668BC4C.dita"
+id="GUID-9053FE48-B44A-44F2-AC3D-3DFED925816C">
+<topicref href="GUID-5CCF303A-B7D5-570D-9BE8-29DFBE184995.dita"
+id="GUID-4EA3767E-BC4E-4CFC-A371-BC1CC73AD6E9-GENID-1-2-1-8-1-1-4">
+</topicref>
+<topicref href="GUID-84D56A30-1E97-40AE-BFB0-E33495E95AAC.dita"
+id="GUID-784EF6D0-8328-43B4-A917-BF95396A5407">
+<topicref href="GUID-E0DCBDCF-C056-53E5-A375-778327F848E4.dita"
+id="GUID-57B45B32-2A1B-43CD-9357-BD375A3443C9"></topicref>
+<topicref href="GUID-984C2A0D-36BE-5A99-9D65-3F8791C669FF.dita"
+id="GUID-1D6C9BCB-1BE6-44D4-A89E-DB2B494397E4" type="topic"></topicref>
+<topicref href="GUID-80698E62-E310-59CA-A524-5CF44C437BE4.dita"
+id="GUID-48A94568-405A-4C88-A6F5-F77CDF2DBFE3">
+<topicref href="GUID-E5459A54-14BC-55C1-B911-63415E4C61A6.dita"
+id="GUID-45BF78A4-00FE-4C60-9CAB-508630246F27">
+<topicref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita"
+id="GUID-702240E8-EA8E-4073-BA6A-E18DCC676671"></topicref>
+<topicref href="GUID-01F1F488-8E95-56B0-818E-6096CAE4C50C.dita"
+id="GUID-41F6B36B-361D-4D2C-A6E2-1F14476D4718"></topicref>
+<topicref href="GUID-93DA75DE-096F-5E40-A47E-5A1A94C3145A.dita"
+id="GUID-3683C4E7-5DEF-4FEC-A0B5-F255B4BDFBC2"></topicref>
+</topicref>
+<topicref href="GUID-BFE1422D-3B4A-5B25-A757-B5B68D6390F8.dita"
+id="GUID-01E059A9-5CE4-407F-9B74-898AA679FAE9"></topicref>
+<topicref href="GUID-7BB36477-0FE2-51D5-B4C0-86F7265C1B94.dita"
+id="GUID-BEEE41EC-8813-44B5-9765-DE741D406FC2"></topicref>
+</topicref>
+<topicref href="GUID-53944506-5CA2-52BA-8D5A-9EE72092612B.dita"
+id="GUID-87C2AE8C-E846-47B3-8230-95EAE581086F">
+<topicref href="GUID-A74BC61D-85E6-5DB5-93F4-DFE4F0B93EF2.dita"
+id="GUID-FD2E5BCE-AC02-4EA3-B27A-5CFDAEDE1D63">
+<topicref href="GUID-3E85C075-436F-5D2E-B1F7-0C9EC6D382E3.dita"
+id="GUID-D60AD6E8-1C2A-4F28-B8AE-C80A478899B5"></topicref>
+<topicref href="GUID-D729BD58-D4FE-5D46-ACD4-F78B37BA833A.dita"
+id="GUID-74215033-14B3-46EB-BE1F-806346218A72"></topicref>
+<topicref href="GUID-0DC908A1-6CF6-50B5-978F-AF6C8CE04F44.dita"
+id="GUID-6C5F3DD9-3C12-4CA6-9AC9-DC97A35D700B"></topicref>
+<topicref href="GUID-306A0B41-94CD-534A-B3BA-FAECB858E9A9.dita"
+id="GUID-BCFD1EDD-F7F4-4390-853D-355ED8B9F5B8"></topicref>
+</topicref>
+<topicref href="GUID-5EB03086-A87D-5588-8927-7A7F8DB38366.dita"
+id="GUID-B84A213F-40D4-43F7-BEF0-66E6DBFDDF40">
+<topicref href="GUID-2E4F8732-F253-5E0D-9A37-9476541E6004.dita"
+id="GUID-1DF5619B-628E-4AAD-81C3-BBD6D6346380"></topicref>
+<topicref href="GUID-08867AEC-5866-5583-9AAB-068CB51F5C18.dita"
+id="GUID-241259FC-49E5-486F-B0AE-1AEFC71FF223">
+<topicref href="GUID-F67FA7B5-F6D1-5C5C-8E10-A8E317A778E4.dita"
+id="GUID-9529FEBF-F55D-4104-8866-CEA008766EC6"></topicref>
+<topicref href="GUID-9595FD6F-1EDE-51A8-B00D-029CFDFE0F38.dita"
+id="GUID-30A79A3F-329B-4D04-AD86-67322C669A71"></topicref>
+<topicref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita"
+id="GUID-44B7061A-9882-4CF1-823E-6205FE02C503"></topicref>
+<topicref href="GUID-C92CC81A-35A1-5860-AA08-C8C08B39804C.dita"
+id="GUID-BDA30353-6004-400A-BE86-0E1B9C99F57D"></topicref>
+</topicref>
+<topicref href="GUID-AFA1604D-FF0C-56BE-A71E-AF3C662F8943.dita"
+id="GUID-FFF6C8D8-6B42-421C-9886-24D66E654BE1"></topicref>
+</topicref>
+<topicref href="GUID-20F8DA2A-9157-54C5-97D0-4CCA50AB0631.dita"
+id="GUID-CA4DD52F-D1F0-47E2-92E0-64F379F5BAD9">
+<topicref href="GUID-2C1B74C4-C80D-5EF9-B822-2DA2FCF9B006.dita"
+id="GUID-5281FA44-AB07-4EF7-AB7C-D73E4134848F"></topicref>
+<topicref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita"
+id="GUID-736F2948-C225-492A-80C8-B439ED8B3FBE"></topicref>
+<topicref href="GUID-36CD752C-45FE-5BFE-A695-11DF085F301F.dita"
+id="GUID-EFD0200A-8D6F-44F4-9976-B24FE345335A"></topicref>
+<topicref href="GUID-4A910E9F-E881-51D7-A84A-CBC6AC343FD1.dita"
+id="GUID-F9B735C8-7551-417C-8A05-38E117CBD344"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-4993AF8E-28C3-54BA-8D27-D86E05D39CFD.dita"
+id="GUID-A9661C34-BC5B-4A93-A6FE-82EEE1299022" type="topic"></topicref>
+<topicref href="GUID-3A625B23-354E-5CB4-98CF-FF53AD724FA0.dita"
+id="GUID-1A37203A-FF99-4331-9345-5FE02E80C8BB"></topicref>
+<topicref href="GUID-E081474F-6B17-5D2E-833B-E8177778577A.dita"
+id="GUID-64F41689-CCB1-469E-8DA8-87697653672A" type="topic">
+<topicref href="GUID-6C27AAD6-EB88-53AF-8E04-921A957042CF.dita"
+id="GUID-5FC4F744-93E6-49E6-9B3E-8AA49C750F30" type="topic">
+<topicref href="GUID-F6E83530-3F8E-5930-8C6C-4D58B675E67A.dita"
+id="GUID-F9884B3F-4A78-4FB4-9058-969D9BBE67A0" type="topic"></topicref>
+<topicref href="GUID-552530EB-1287-542D-AED3-125387B485C1.dita"
+id="GUID-C0CC4A17-2DAE-43EE-A176-F564ABCE6F30" type="topic"></topicref>
+<topicref href="GUID-DBEAD516-5DD4-5E33-B6DA-657C1AE60C4B.dita"
+id="GUID-7B0BD144-CF82-42CC-91BD-20C5124063DA" type="topic"></topicref>
+</topicref>
+<topicref href="GUID-0563266C-8B5A-5664-9AC6-A5504AB5056F.dita"
+id="GUID-79845C04-6955-4CDD-8AEE-AD076384D17C" type="topic">
+<topicref href="GUID-2C915A03-AD8C-5924-87BB-953AE323E0FA.dita"
+id="GUID-7F9E07AE-3927-4FF3-8E7D-8E60390A0623" type="topic"></topicref>
+<topicref href="GUID-7BCDDA55-1460-5411-AFCF-C4640BEB9DE4.dita"
+id="GUID-88C35365-217F-4744-AE54-B547597F81FC" type="topic"></topicref>
+<topicref href="GUID-3574BE12-9DA9-573D-8545-3B073005A139.dita"
+id="GUID-E9CD4D1F-5576-48B6-80D1-3543E89FC368" type="topic"></topicref>
+<topicref href="GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07.dita"
+id="GUID-B8D4E4B2-A3F0-4D47-BD21-F71889A261D4" type="topic"></topicref>
+<topicref href="GUID-009D71C6-481F-5EF1-B230-EB64F67047C8.dita"
+id="GUID-11087DBC-7B77-463C-9BD4-3683028AA317" type="topic"></topicref>
+</topicref>
+<topicref href="GUID-D683DBD8-15AA-5F2F-826C-B56CCE1DC06E.dita"
+id="GUID-5A90C85D-9BD0-42E2-BECF-42E1CAE5CBB6" type="topic"></topicref>
+</topicref>
+<topicref href="GUID-DF2F0439-AE1A-599C-91B9-6EF2177C3C7E.dita"
+id="GUID-6F797334-D86F-480C-AF98-34499CD68ED1" type="topic">
+<topicref href="GUID-81C69779-27AE-55E0-ACCF-E4F3E6657427.dita"
+id="GUID-D23BA7F6-E43A-4F5B-8690-BD7A7859D3A1" type="topic">
+<topicref href="GUID-4C5DB74E-41A5-53CB-A053-CBBEADD31AFF.dita"
+id="GUID-34F48400-511E-4E14-8144-FA8203735894" type="topic"></topicref>
+<topicref href="GUID-0D2F811C-81C3-526F-8EA4-98E50261BF4B.dita"
+id="GUID-194655E6-3991-4AE2-9B30-597EEC660BE0" type="topic"></topicref>
+</topicref>
+<topicref href="GUID-3F47E907-975A-5739-9B03-042CB90D675D.dita"
+id="GUID-1573D26E-1E02-49A6-B19F-3BA423A50D35" type="topic">
+<topicref href="GUID-97F97D7B-D5A3-5471-A359-77B805ED198C.dita"
+id="GUID-A36821E5-8EBA-4A07-BFE4-9884ABD55E10" type="topic"></topicref>
+<topicref href="GUID-CDB2DD00-482D-5AEA-AF89-064C8F904DD9.dita"
+id="GUID-C54D6BBE-F1B0-4898-9DD3-A7CBC0EB0724" type="topic"></topicref>
+<topicref href="GUID-812DEBEB-84D0-5BD4-A5BB-5AF6B8384CCF.dita"
+id="GUID-6D18CAA3-2CDF-4E4E-A674-B2104DDD9B45" type="topic"></topicref>
+<topicref href="GUID-A4C19890-2380-5498-A5F8-3B6D95CEFEF4.dita"
+id="GUID-2D66EF22-0C54-4B7A-916B-0120DF259BAE" type="topic"></topicref>
+<topicref href="GUID-8552E66E-73D6-51DA-8F53-DDF437186CD6.dita"
+id="GUID-FF3E3C18-6A48-4058-8AFD-9E1D10A1EDBF" type="topic"></topicref>
+</topicref>
+<topicref href="GUID-A4CCF2B6-26B7-5E8C-B738-9EE9E68A0B35.dita"
+id="GUID-6739E4E0-D375-433D-8D96-6EA4F1843329" type="topic"></topicref>
+</topicref>
+<topicref href="GUID-7C064328-8368-4259-9CE1-B8DFE2DF4AAC.dita"
+id="GUID-17C9D42A-D46C-4D83-B0B0-303F677D254B">
+<topicref href="GUID-5B24741C-7CE0-58E8-98C9-1D1CACCD476F.dita"
+id="GUID-FD3F2281-3592-4004-9726-390DCF16DD1D"></topicref>
+<topicref href="GUID-89BCF9A5-ABBD-5523-BA76-FDB00B806A30.dita"
+id="GUID-AE76EA73-4694-4BC4-AB8F-44FF79C68F21"></topicref>
+</topicref>
+<topicref href="GUID-BB507973-77A4-4DC1-91C0-65E3CA2CF790.dita"
+id="GUID-EA04BA3E-4017-46D6-877A-E657A1112668">
+<topicref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita"
+id="GUID-319D261F-76F7-41CF-87F7-A8DFF5AE8B76"></topicref>
+<topicref href="GUID-3C34724F-B476-5329-B0B1-6D5A34294979.dita"
+id="GUID-D7CCA2A0-3DC3-4660-99EA-BADCC662ADB5" type="topic">
+<topicref href="GUID-B9B35999-0937-51C5-BB77-91A6C039CE2F.dita"
+id="GUID-4B516900-97FB-4730-B3B0-02A4C9C736EF" type="topic"></topicref>
+<topicref href="GUID-8B7E2A72-B793-5E70-87F0-92AA0A482F23.dita"
+id="GUID-88830A52-125A-4588-A69F-B3A7DBDECF2D" type="topic"></topicref>
+<topicref href="GUID-AF2E227B-C5BD-5F05-98D4-7D15530161C8.dita"
+id="GUID-4084FCE0-ECC6-4AAE-B01F-691270081990" type="topic"></topicref>
+<topicref href="GUID-583F70B4-5C8C-54FA-A869-E6F073DE1FD6.dita"
+id="GUID-355BC0A3-D4C1-467A-9989-A30EC64E5D8A" type="topic"></topicref>
+<topicref href="GUID-159BDA2E-123C-52DF-9F8B-E058379EBFB8.dita"
+id="GUID-8C8E7020-E887-40EE-97FF-3CCE324734C1" type="topic"></topicref>
+<topicref href="GUID-8B8CAEED-A89D-53B3-A311-51CF45B334B1.dita"
+id="GUID-8A4D0BF1-68C3-4A84-8366-17F95AB1877B" type="topic"></topicref>
+<topicref href="GUID-423537D5-2C8A-5C26-8D7B-60446E95F681.dita"
+id="GUID-C98E36FD-06B7-41CC-AE74-C038D2D80C94" type="topic"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-D048E187-6B1C-5A80-9CD0-89CD10688C6F.dita"
+id="GUID-421F5EA1-9032-4DEF-88DF-9B23A8C8D3AF">
+<topicref href="GUID-EB76FAF8-CD4B-5CB6-9F23-C852ED91866F.dita"
+id="GUID-70091D59-9965-4155-B3BF-EC709E41A87A">
+<topicref href="GUID-F9558573-7C79-57C5-809A-9257BF84758A.dita"
+id="GUID-BEAD78B9-72D9-476D-A14E-E0866C52B001"></topicref>
+<topicref href="GUID-110DB7EF-5E85-5BC4-9BBB-9A37B2D0C3A6.dita"
+id="GUID-E5255614-F877-4BDB-9D8C-6DBA88835656"></topicref>
+<topicref href="GUID-5C17A2E7-DE18-5CFB-A5D5-421D427CD5DD.dita"
+id="GUID-D2766A20-2F57-404E-9D2D-F4E778161430"></topicref>
+</topicref>
+<topicref href="GUID-2E42E7EA-FED8-522C-8A5F-F65D799476C9.dita"
+id="GUID-BA80DCCC-6209-4E15-B705-929B825AD6E4"></topicref>
+<topicref href="GUID-D34DB4A1-1B17-5FAF-A48B-E06D247B0A83.dita"
+id="GUID-5104482B-F377-4E8D-B694-48602D101692"></topicref>
+<topicref href="GUID-197A1071-CDAA-5A87-9981-A52FB32C084E.dita"
+id="GUID-BAF52F6C-5D03-467C-AA9F-90F0C1273185"></topicref>
+</topicref>
+<topicref href="GUID-8C22AF20-EE0E-5AD2-BEFD-FED5A7DBB09B.dita"
+id="GUID-E8234699-BBB7-4B56-9F34-17A82C33BB2B">
+<topicref href="GUID-0C3A4156-E5CF-55F9-91A0-A7961FDEE030.dita"
+id="GUID-726BEE1E-03E7-4C3C-9D89-320F2A976512"></topicref>
+<topicref href="GUID-6A4FE3A3-2E5D-51BB-8272-5995586291E9.dita"
+id="GUID-76DE83E9-7378-4D6B-9197-09E3D9CE2989"></topicref>
+<topicref href="GUID-81DD805C-90B5-5227-B62B-F2413855BD9A.dita"
+id="GUID-115D6443-90E0-4EEC-8A8D-F51EBD1CBD2E"></topicref>
+</topicref>
+<topicref href="GUID-5C223AD5-4676-58B4-B3A5-066F6B69AA4D.dita"
+id="GUID-5A63899B-01F7-4C9F-9EE2-DC22CE7EDD23">
+<topicref href="GUID-2559E3F7-314B-5DCC-A7FE-A08162A89721.dita"
+id="GUID-1FAA2C48-690A-42F8-9664-B20140D45AA2"></topicref>
+<topicref href="GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3.dita"
+id="GUID-85C4CBDA-8CFB-483C-BA1B-ABFEA93314C2"></topicref>
+<topicref href="GUID-2380FDDE-5489-5B1C-87BB-1FD882E385D2.dita"
+id="GUID-961CD5DE-7A30-42B5-A046-8542BAE10167"></topicref>
+<topicref href="GUID-E21C4AF8-852A-5BBD-A92A-5473D1DFFBB1.dita"
+id="GUID-51188FFF-5EAA-4F28-A18C-C0EEE897B839">
+<topicref href="GUID-DD568637-CD37-5E4C-AD78-4AA5AFE1E9D8.dita"
+id="GUID-E2BEFF5D-B54B-438B-84BB-62104AB65BB4"></topicref>
+<topicref href="GUID-A70A01D2-467E-5BA8-A01D-6182558F3F52.dita"
+id="GUID-92ECC5C0-512B-4F3E-9E92-2D84E224FD4C"></topicref>
+<topicref href="GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930.dita"
+id="GUID-59A01AD5-0C08-43A2-B19B-0CB8C232F179"></topicref>
+<topicref href="GUID-EBF025DB-1552-5E99-8C07-09932DB60552.dita"
+id="GUID-499D7D3E-F932-4C0F-9B94-CAE784D8767B"></topicref>
+</topicref>
+<topicref href="GUID-CAEDFD1D-ECA1-5A6F-9861-63B7BE24E9E4.dita"
+id="GUID-C0000FDB-54A8-4786-8B6F-DC3C5747EB43"></topicref>
+</topicref>
+<topicref href="GUID-79B2CF91-FB95-5E7C-81CC-235A6A660D88.dita"
+id="GUID-F0542E96-CA48-4EC6-AEAB-C3A1B5772FFE">
+<topicref href="GUID-9573F7B9-76E9-5DCB-A498-C0DE59606911.dita"
+id="GUID-1268DBA4-C3DD-4CE2-97C0-6F8277DCCE7D">
+<topicref href="GUID-058BAEDF-5E04-5BB4-928F-0E0528FD9465.dita"
+id="GUID-2FB0F1EA-497A-4EA9-965D-B3FF8D6AB228"></topicref>
+<topicref href="GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF.dita"
+id="GUID-EBD42C2B-7790-42F3-81D5-4D09D6B66D36"></topicref>
+<topicref href="GUID-C6825C8F-8020-58CF-A09E-34558B1542DE.dita"
+id="GUID-BD02B3C6-2A11-4555-83FE-4F80F97ECB81">
+<topicref href="GUID-28844FE0-AE0F-531C-826E-CDA8400A0581.dita"
+id="GUID-D5605A1A-EB5D-4CDD-A47D-3E3B40C6AE1A"></topicref>
+<topicref href="GUID-80E0DB93-A96A-54A8-A201-E11935418BE7.dita"
+id="GUID-EB2C4E60-E3DF-43D0-951D-98E491656968"></topicref>
+<topicref href="GUID-C059F39F-BC53-5C92-B05E-863B8CF22859.dita"
+id="GUID-661758DE-451F-4085-970C-974FC432E966"></topicref>
+<topicref href="GUID-73F220EA-F41F-56A5-BAEB-4A37174CFD1F.dita"
+id="GUID-151BFEE7-B888-4DB1-B7F0-41E6FBA30B45"></topicref>
+<topicref href="GUID-2281F91F-67BD-5B85-A47F-30A5E683BBF6.dita"
+id="GUID-7032BF11-9272-4A46-ABBA-15C7A19F11A7"></topicref>
+</topicref>
+<topicref href="GUID-40F2BC43-5022-5F4E-B445-56FEF43FEB8B.dita"
+id="GUID-1710CC13-1B2D-482B-B740-05A8475747C9"></topicref>
+</topicref>
+<topicref href="GUID-86082C0C-B0EE-5E7C-85B4-4A509066012F.dita"
+id="GUID-64BB60F4-1B05-4BEF-AD4E-ACD000BCD269">
+<topicref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita"
+id="GUID-AAF4C281-F48C-4B21-973B-88BABF937BC7"></topicref>
+<topicref href="GUID-180973A1-5C0A-5A85-82CC-E6B739A7F207.dita"
+id="GUID-96871FD0-BB73-4F69-9534-0A9201244C38"></topicref>
+</topicref>
+<topicref href="GUID-B6F0C909-6E58-584E-9270-8066337FCE0F.dita"
+id="GUID-A31E6A59-747A-463C-9826-6B6949BA0C97"></topicref>
+<topicref href="GUID-90B5FDD9-7D59-5035-BF53-2B177655DCD6.dita"
+id="GUID-0FBF7CCE-5C6A-4432-93F7-5E86F0A10F22"></topicref>
+<topicref href="GUID-33A7D8D4-84D6-56EA-8EAB-2A3A3ACABF77.dita"
+id="GUID-7B550356-FB22-44BE-8BC2-D18A3A6B92F6"></topicref>
+</topicref>
+<topicref href="GUID-DD9DBB55-330E-4F43-A156-621979B675BC.dita"
+id="GUID-CBF96EB5-42AE-40B7-AD2B-235314C0651A">
+<topicref href="GUID-2700AAC8-A034-5E7D-B0E0-26B49E68BB18.dita"
+id="GUID-CEF923EF-14D2-4AF1-85F8-554E3BEE4EB3"></topicref>
+<topicref href="GUID-42F8FA5A-BBE4-50DE-917E-D05755019FEC.dita"
+id="GUID-1C17B243-E8FA-4C78-A812-1936BA866372"></topicref>
+</topicref>
+<topicref href="GUID-F5430A12-D89D-4936-B846-E917B434F755.dita"
+id="GUID-A80C65A6-BC4F-487D-BDEF-80247EF041B4">
+<topicref href="GUID-10F3E16A-8CCE-420A-9D1C-F9891B3D75FE.dita"
+id="GUID-7F573CD9-6871-47FB-9031-9C1F1BB8225C">
+<topicref href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita"
+id="GUID-2B5090CA-D70C-48C1-A43C-77EDB5C63067" type="topic"></topicref>
+<topicref href="GUID-113B3755-1797-5D1B-8E07-8A18F5FE1504.dita"
+id="GUID-ACBDEC22-B315-4B29-852F-7B499AE0F577" type="topic"></topicref>
+</topicref>
+<topicref href="GUID-3773A78D-F491-52EB-AA1D-201636497F28.dita"
+id="GUID-EEBF289D-A52E-4197-B1FE-E34861BD6581">
+<topicref href="GUID-4804B6E0-9199-5F3E-984A-4B00B3984E45.dita"
+id="GUID-99B0D970-519D-4705-A6C9-E049F017A19B">
+<topicref href="GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9.dita"
+id="GUID-704A62DE-5436-4FA9-B38B-C07E91060B6E"></topicref>
+<topicref href="GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671.dita"
+id="GUID-C25F58AB-6C96-498A-B03F-4ACB89FD4DD4"></topicref>
+<topicref href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita"
+id="GUID-23A28860-47C1-448C-B2C9-843551867FC8"></topicref>
+<topicref href="GUID-E7F91A65-235D-589C-9A8C-0B207D19A24B.dita"
+id="GUID-863825F8-7285-4AEB-A402-ED4CB438E20C"></topicref>
+<topicref href="GUID-C8DF0CB0-92F4-5F9E-A8F1-7DE50954C4F1.dita"
+id="GUID-8D463F9C-55E4-45F1-9F4F-14A5EFEB5900"></topicref>
+<topicref href="GUID-66E5F769-1156-54CA-94BC-8912159A1240.dita"
+id="GUID-EACABFC7-066C-4377-A78A-93B54DD9BF4B"></topicref>
+</topicref>
+<topicref href="GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita"
+id="GUID-13401023-1EBC-40E3-84F8-8E6BA353F566"></topicref>
+<topicref href="GUID-A789E0D6-74B2-517D-B73A-F9B11794F175.dita"
+id="GUID-6A71F416-EF2C-4D50-8833-C29F8125A426"></topicref>
+<topicref href="GUID-3B6544CD-FA6E-5AB2-AA63-61186F52167D.dita"
+id="GUID-E6910B89-DC72-4B36-8359-0D1FE3BD022E"></topicref>
+<topicref href="GUID-6CE68645-D8C5-52E1-88B3-76AEFB80DE51.dita"
+id="GUID-2A32518C-16BC-4523-B512-D0C25B88A7D7"></topicref>
+<topicref href="GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC.dita"
+id="GUID-B8570EBA-DC14-4D53-90F8-B54F069C7DEA"></topicref>
+<topicref href="GUID-2E402D4E-53A9-5BA6-9FBD-B2713DBC7858.dita"
+id="GUID-473D1D0C-CE91-40EE-9625-F9BF7CDBD64B"></topicref>
+<topicref href="GUID-29B84A67-9DB7-5F4C-A4D1-A3BDC69015A8.dita"
+id="GUID-A4AB1E83-7822-4AE5-BDA5-F816C148E82D"></topicref>
+<topicref href="GUID-65CDCA83-C726-5173-8E46-B8981D1D7B02.dita"
+id="GUID-33C5C597-F599-4AF1-BF1A-13E1F38F8B49"></topicref>
+<topicref href="GUID-54042C84-6216-5930-9CBF-BAF635CECD4D.dita"
+id="GUID-D18DAD39-A791-4068-A09B-4CE3B01C0C12"></topicref>
+</topicref>
+</topicref>
+<topicref
+href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1.dita"
+id="GUID-1811B26F-B5BA-41C8-ADBE-86B9DB2D0AFC-GENID-1-2-1-8-1-1-5-1-1-20">
+</topicref>
+<topicref href="GUID-A04F46F8-1BA9-5A77-B455-59C67DD4AA36.dita"
+id="GUID-6004A8BB-96A1-4B2F-AB96-9F34EC0037DE">
+<topicref href="GUID-B345CDED-92DC-50ED-BC87-AC3C903E5E10.dita"
+id="GUID-F6DA8DF8-06A5-48DF-81FB-D5EB1FAA771E"></topicref>
+<topicref href="GUID-0C8C41EC-A8ED-5916-B944-DDDF20FADAF4.dita"
+id="GUID-F76EDDE0-6ACE-404B-8F9E-AA97F76D125D">
+<topicref href="GUID-6DE69F29-45B0-5E62-AA13-DA4041B1BC46.dita"
+id="GUID-A6E6D33C-2599-493C-B4C8-4E7CE8629156"></topicref>
+<topicref href="GUID-AB9175EB-1B61-5341-B6B9-5613A7862D74.dita"
+id="GUID-A032BC6E-1F42-40E5-89B0-2F0085B4C29A"></topicref>
+</topicref>
+<topicref href="GUID-F8E8CCB1-E239-5285-BA99-48E2168C9E31.dita"
+id="GUID-8490FA3E-E954-4C2D-B925-739097BC9758"></topicref>
+</topicref>
+<topicref href="GUID-669C77A3-89BA-5321-ABB1-4356A5FE478C.dita"
+id="GUID-DAFBE23F-F3F6-43D7-A2E5-79E128F37801">
+<topicref href="GUID-1499E635-B6E3-51A0-AE38-ADF99FF86CD6.dita"
+id="GUID-854946D6-D026-40B5-B0F8-A3DADDA414FE"></topicref>
+<topicref href="GUID-6D75968E-53CF-5436-8390-54CA12BCFDE9.dita"
+id="GUID-18BA883E-1BB8-41EE-B853-3CDD254C224E">
+<topicref href="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita"
+id="GUID-A8A8730A-A07F-41E7-BAB6-C6221DE05FBC"></topicref>
+<topicref href="GUID-ACA48BEE-FE73-5C47-B022-E50728CEDBEE.dita"
+id="GUID-18622E69-CCFE-4CCA-8043-A203AEC7E6CE"></topicref>
+<topicref href="GUID-8DC12024-7599-52E8-BCF1-D9D765EC7B9B.dita"
+id="GUID-5E71ADAA-E5FE-4F71-8DB3-45DA1B787EED">
+<topicref href="GUID-15FDDEED-89F1-5BE5-97AD-8DFD3640369A.dita"
+id="GUID-4B35BDF8-59DF-4BB9-B72B-699176060440"></topicref>
+<topicref href="GUID-4AEF7595-17C0-513E-9568-B212E6194388.dita"
+id="GUID-D1F884D4-4D41-4549-885A-A7AAEC1046C1"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-3335663A-BC11-556E-B5A6-F83622AE34C3.dita"
+id="GUID-FC94197F-2318-4B4D-B770-494DD2AEB73C">
+<topicref href="GUID-B4C05C46-F2C9-57FA-AD85-EFE6479C2FF1.dita"
+id="GUID-27CAF3A5-F640-4605-98F6-FBE0E7FB5813"></topicref>
+<topicref href="GUID-C6ABE2CA-901E-55F1-9837-7018A1612BCF.dita"
+id="GUID-4AE06F77-C7D8-48E8-B987-E4D4ECF06F97"></topicref>
+<topicref href="GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F.dita"
+id="GUID-C5B08289-EA65-4859-9033-3ACE7338F555"></topicref>
+<topicref href="GUID-AC560324-798C-5D0A-B23D-2419A7688A5B.dita"
+id="GUID-C66E4EF1-2E4D-4C9D-95CC-B64D5DAD1038"></topicref>
+</topicref>
+<topicref href="GUID-73B853D5-13E6-54E7-AA8B-C41EEDB5EA7F.dita"
+id="GUID-EAFFA332-39CD-44E7-8FAE-9A73E8CA7197"></topicref>
+<topicref href="GUID-D477EB1F-89CF-5836-BAA2-6D731D50D99F.dita"
+id="GUID-039B303E-052B-409F-BE96-C0CFE65F72CD"></topicref>
+</topicref>
+<topicref href="GUID-F84E18B8-5883-5A3A-A9DB-EC25BB86149F.dita"
+id="GUID-C5603DDA-2566-484B-9821-83F306466608" type="topic"></topicref>
+<topicref href="GUID-C06CFF3E-23E9-5E0B-99A1-51B8ED95465F.dita"
+id="GUID-948D5918-A576-4E94-8C4E-9FD6D961B239">
+<topicref href="GUID-796CB42C-29AC-5ECC-AC6E-35FC6B8CC84E.dita"
+id="GUID-1CA093E5-696A-49F0-BC2A-BAF7845EE5E9">
+<topicref href="GUID-AD195629-81CE-5E57-A59E-C67AACF7A2C2.dita"
+id="GUID-E15C86B0-A3AE-4480-BD2F-707EFF11FF7F"></topicref>
+<topicref href="GUID-ADB848FD-317A-521C-9684-BBCF20358207.dita"
+id="GUID-F244F3B3-2BF2-4514-94C5-64CEB9330F91"></topicref>
+<topicref href="GUID-834781AF-D202-5752-B81A-A51D12A4D1EC.dita"
+id="GUID-27B8E5A8-BA90-4F65-B231-85AB8B55DBF4"></topicref>
+</topicref>
+<topicref href="GUID-142C21E1-2629-5215-9FBD-B507436E17DB.dita"
+id="GUID-999E4E76-00D3-477B-B10E-5A9648373C68">
+<topicref href="GUID-529757E6-ABF2-5C5C-A995-7DED6D298F52.dita"
+id="GUID-1A2CA103-A5E4-46B4-8CBB-F357B8F075CA"></topicref>
+<topicref href="GUID-7B9D4E46-6AF9-5B77-9BE3-8B1DFAC588BD.dita"
+id="GUID-754BF5EE-4CAF-4879-9E84-42817D780140"></topicref>
+<topicref href="GUID-F20D5802-7B83-5B78-8753-A88E74E28398.dita"
+id="GUID-6E9EE509-21B7-436D-9194-394327D87CB6"></topicref>
+<topicref href="GUID-02B40662-B5F3-59BD-832B-9A28FE3B51C7.dita"
+id="GUID-CB785176-9D51-41B5-8332-851AC9BBAC0F"></topicref>
+<topicref href="GUID-F8BD699A-E926-5434-9F35-3DC6DC9FFBB6.dita"
+id="GUID-8F1692B2-7E4D-4894-9ABE-D65BB702677B"></topicref>
+<topicref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita"
+id="GUID-606DC0D1-864E-4742-A428-3857B8166F1C"></topicref>
+</topicref>
+<topicref href="GUID-ADC42B89-B061-50C3-B532-6065A0C418C3.dita"
+id="GUID-0A15B343-7F98-4C7B-ABA6-DA9B354E8378">
+<topicref href="GUID-919E48BE-6AA1-54CC-8B70-3A4B3A9C6CF1.dita"
+id="GUID-9AEDCED1-221E-4955-A18E-285BD686774C"></topicref>
+<topicref href="GUID-FDAED7A7-3D93-5B57-9879-DF8BDBE8A9BD.dita"
+id="GUID-9DD1D360-6D60-4DEA-ACAF-ED53F79364E3"></topicref>
+<topicref href="GUID-18DD4FE5-6641-5A0E-A00E-DC0C00639CE4.dita"
+id="GUID-56432425-09E2-40F9-9FB6-198BD0F7049B"></topicref>
+<topicref href="GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita"
+id="GUID-4176F59B-8CE1-4DE3-AD21-4A5211C7A329"></topicref>
+<topicref href="GUID-0A9C35DA-DF54-5885-AFE0-F4D5B3E49941.dita"
+id="GUID-F4F39757-101D-4D0B-80FC-73C2823492C2"></topicref>
+<topicref href="GUID-9597DB22-D932-5A58-9C3C-4E5FCA244253.dita"
+id="GUID-9D46B7B2-F181-43C4-BF4D-DDCDC7079A5D"></topicref>
+<topicref href="GUID-6E89E787-749D-5AC5-957D-967B4B9ACD74.dita"
+id="GUID-3A9A6144-0411-41B1-9ADC-E0F3828EF904"></topicref>
+<topicref href="GUID-4C4515EA-A5DD-56B4-94B0-EE48D66013F7.dita"
+id="GUID-7784039F-68B9-4BF1-B595-F3E6A7D76EA0"></topicref>
+<topicref href="GUID-0C80F447-B82E-5586-9B02-4BC0D365FFD6.dita"
+id="GUID-55F20FF4-A967-408A-AA1F-76576AB8F823"></topicref>
+<topicref href="GUID-BE73CFE6-D48D-5B92-AF49-E2D967ADF0EC.dita"
+id="GUID-15C3F4BC-1581-4695-8519-5DF478195C79"></topicref>
+</topicref>
+<topicref href="GUID-BF86E9F9-531A-51A1-90B4-23B51604F5B4.dita"
+id="GUID-2F9C8382-D9AE-4867-AA18-FB522119F729"></topicref>
+</topicref>
+<topicref href="GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8.dita"
+id="GUID-CD73DE4F-8B0C-457E-92C6-420892D0952E">
+<topicref href="GUID-B7C56FF9-FE1B-58C3-BBD4-7479F0BEE555.dita"
+id="GUID-AA7610B0-DBAF-4619-A1C7-37D67C9AC1FC">
+<topicref href="GUID-9D4B8CDF-60D7-5952-AAAF-94A3C1E8908F.dita"
+id="GUID-3B3A26E4-5089-4BC1-B79F-16CE818D9AF5"></topicref>
+<topicref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita"
+id="GUID-350D059F-C33B-42E0-BF1B-455CE41D2E8D"></topicref>
+</topicref>
+<topicref href="GUID-05DAF5EF-6F2E-562D-9DB1-0985AD4A1E48.dita"
+id="GUID-B64115E0-E3BB-4CBB-9F13-4E57FE515A0F">
+<topicref href="GUID-52583CC7-483E-54B5-8094-F0F61BD46B7F.dita"
+id="GUID-BD523DD2-0F5B-41A9-B8F1-5AE37A3E04CA"></topicref>
+<topicref href="GUID-124AC7EE-E227-5358-A755-628FFE257250.dita"
+id="GUID-F12BA07A-4BC2-4DDD-8A5B-5FDD2469B462"></topicref>
+<topicref href="GUID-A7ECF51F-F96A-5251-A71F-2F269C8C0664.dita"
+id="GUID-30818FFE-4F73-4B63-B447-F72125A8030D"></topicref>
+<topicref href="GUID-C661B40F-1439-587F-9E8E-DB2DFC79C040.dita"
+id="GUID-821F790A-12D6-463B-80A8-81B08B9EE955"></topicref>
+</topicref>
+<topicref href="GUID-95CE7187-66B2-581A-A5B8-6359AD431E87.dita"
+id="GUID-CADB4911-E9BE-4AFF-9CDD-659370319D49">
+<topicref href="GUID-857F981E-711B-5CA8-AB37-5C700A6140FA.dita"
+id="GUID-765F086E-3340-4FE6-B97C-4B2C0DB2FD7E"></topicref>
+<topicref href="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita"
+id="GUID-C37A0E90-6B70-4BDF-B71F-D98C39C22187"></topicref>
+<topicref href="GUID-F8B8C030-B5E1-5EB3-A672-83BF35555801.dita"
+id="GUID-361805F1-672A-49D6-8B57-F73CF9FFAF85"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-3046453A-AB3A-5491-87A0-00F3514D4768.dita"
+id="GUID-8E975352-C697-4092-8865-9CB400DE1A8F"></topicref>
+</topicref>
+<topicref href="GUID-898704CF-26A1-50F5-BEFE-1E29D85064AA.dita"
+id="GUID-01AC46DF-C2A0-4C7E-B2C9-79256939219B">
+<topicref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita"
+id="GUID-6F5E480E-0AE0-4C5F-AE2C-595DBB3E9C34"></topicref>
+<topicref href="GUID-003D2C5B-09DC-5BD1-AF45-A0FCB56F567B.dita"
+id="GUID-7D44D6FF-AE28-4DC2-9D3C-B50E6F7253EA"></topicref>
+<topicref href="GUID-BF04B68E-7F77-5D99-A0F6-2842758EFD4D.dita"
+id="GUID-75C81C3E-8D6E-4727-B487-87E72EB5A1B5"></topicref>
+<topicref href="GUID-922E4771-C1FD-5C88-9C11-57499684DB97.dita"
+id="GUID-54FD61D0-4D9F-4554-9F58-657102B8C59C"></topicref>
+<topicref href="GUID-7AB0C7E2-8B7C-5CC3-BAA5-15AA59F31181.dita"
+id="GUID-DC043E55-DCD4-4113-8FD0-71FBF38A56B0"></topicref>
+<topicref href="GUID-51C5DC6C-0CEE-5F44-8578-AEFBEF90FA4D.dita"
+id="GUID-410EAFD6-DF61-4889-A027-2CF01AB7A832"></topicref>
+<topicref href="GUID-CC04A14B-A839-5613-820D-F1E65EB2DF7F.dita"
+id="GUID-41C7FABE-4879-49E7-832E-7CAA462BB28B"></topicref>
+<topicref href="GUID-9CF985F1-C100-5999-9410-58B7865A1E18.dita"
+id="GUID-9435998E-79FC-45F2-8F31-F0FA8B11BE47">
+<topicref href="GUID-E1FEEDCE-0CD5-559C-9AE0-8090A613C166.dita"
+id="GUID-B7C975D6-2C41-4DED-B1EF-A86F72E7EA53"></topicref>
+<topicref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita"
+id="GUID-61D2AF1B-3C73-4CF0-9061-83A5FC751B23"></topicref>
+<topicref href="GUID-52702561-DA37-5381-BA0D-76D9A41B2760.dita"
+id="GUID-EAFB0FF0-53BB-4D3B-A9F0-8508D981D5BD"></topicref>
+<topicref href="GUID-E3C70135-EC0C-504C-B428-53A5750B520B.dita"
+id="GUID-722D85C4-772A-43A4-B14C-9107083D8909"></topicref>
+<topicref href="GUID-DB441DFF-0075-5122-A2EB-A6EF76375D71.dita"
+id="GUID-0F406F49-AE5A-4A4C-8DB0-865A0DC56E7B"></topicref>
+<topicref href="GUID-BBEA9F6B-2F0C-584E-BF12-256E27605499.dita"
+id="GUID-5F2B67EC-EB2C-4758-91E0-A19D4F6D37FE">
+<topicref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita"
+id="GUID-1C97A9A2-BE1A-4442-9AD6-148260CB3C1E"></topicref>
+<topicref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita"
+id="GUID-AA89E111-F777-41DF-8383-5E33C24095E7"></topicref>
+<topicref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita"
+id="GUID-6F773BB7-F8A4-4E05-A9D2-5A99D6C2BF5A"></topicref>
+<topicref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita"
+id="GUID-F4F9539F-8EA7-4EB2-9D8D-3526ADF664C2"></topicref>
+<topicref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita"
+id="GUID-78648F79-00EC-4780-8AC4-D3DFDA052DDD"></topicref>
+</topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-E96E4542-7017-4069-BD9C-97467A99F211.dita"
+id="GUID-4EA3767E-BC4E-4CFC-A371-BC1CC73AD6E9-GENID-1-2-1-8-1-1-7-1">
+<topicref
+href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1.dita"
+id="GUID-7D29CFCE-3A23-4E78-898A-CDB0B9CCE498"></topicref>
+<topicref
+href="GUID-9D26E38F-5C7B-5330-A54B-8F97D0F204D0-GENID-1-2-1-8-1-1-7-1-1-5-1.dita"
+id="GUID-9436B6C5-9044-4EB3-B251-17F02E74D647"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-CF710BE5-531D-4287-9002-39E7DE27FACA.dita"
+id="GUID-5E8DC915-2473-40D6-9750-CD862C16CBF2">
+<topicref href="GUID-73D9E2F2-5965-479E-97DB-C3773DA0D90C.dita"
+id="GUID-9AAB4773-C94A-41DB-A089-7368B8A36FD9"></topicref>
+<topicref href="GUID-79620372-BADC-4826-A3AC-7FDBCFF98DA9.dita"
+id="GUID-04060E12-A96B-4326-A197-A3339ABD0D6A">
+<topicref href="GUID-687997B5-BDFD-49D1-947B-4AB21C3AF58C.dita"
+id="GUID-44005CD0-56F8-44E7-861C-A76BF447B7A0"></topicref>
+<topicref
+href="GUID-7AB51180-7A1A-40C7-B28F-EA46314A6E5B-GENID-1-2-1-9-1-5-1-4-1.dita"
+id="GUID-6E13B858-073B-4445-992D-CDDC37A838DA"></topicref>
+<topicref href="GUID-F75F975B-A490-4EB5-96CD-B2F8DFC63C7C.dita"
+id="GUID-42D21B0B-6A97-4810-8D73-6ED61ADF28A7"></topicref>
+<topicref
+href="GUID-FD8634B8-E522-4AC4-8129-ED807A7754A2-GENID-1-2-1-9-1-5-1-6-1.dita"
+id="GUID-F53AD281-A48E-4040-9553-23601AB7F9CB"></topicref>
+</topicref>
+<topicref href="GUID-C22974D8-CFB9-4A83-BE58-CCC97EA8DF13.dita"
+id="GUID-BFECEE09-81FA-48EE-AC05-BAB266D9CDF7">
+<topicref href="GUID-CA788AFE-D425-4B72-B8A2-34D38A8C341B.dita"
+id="GUID-DFA44ED5-0F47-40EE-AF3D-0FEFEFD876B2"></topicref>
+<topicref href="GUID-0F17BCDF-CF50-40D1-9048-793DC4442B50.dita"
+id="GUID-0CC7BB86-A8CE-4EE6-949E-2CCC4112DE79">
+<topicref href="GUID-2ADB873A-1580-476A-9642-AB47D13D4A98.dita"
+id="GUID-B9D10AD5-A397-4D39-8CC1-48F322AD734F"></topicref>
+<topicref href="GUID-9B52E0C3-9EBB-44C6-A1BF-2F95711FFBA4.dita"
+id="GUID-7755993E-E905-4B3A-B176-FF5D3D770B99"></topicref>
+<topicref href="GUID-67CFF27B-55AF-42AC-95AF-E71A7C54039E.dita"
+id="GUID-CFF13F2A-611A-42C7-9571-3A0EDAFB79C0"></topicref>
+<topicref href="GUID-AF245763-EB25-49BC-90DC-0BD5F2D22AA5.dita"
+id="GUID-425BB484-70A6-41BC-BAFF-C74B9F643D71"></topicref>
+<topicref href="GUID-388004AF-6F99-4BBB-A8E0-D75DC5B6790C.dita"
+id="GUID-130BB4EC-0429-4C54-832F-6373EE854A36"></topicref>
+<topicref href="GUID-BC0936D7-7064-447D-83EF-68C65CF3D1B0.dita"
+id="GUID-6B04CE17-54DD-4B95-9AA6-8FC0AFF03E8A"></topicref>
+<topicref href="GUID-0AB3D313-79FF-4716-AFD4-FF3AA3C2E936.dita"
+id="GUID-D88CCA02-90F5-47E1-942C-A53634A7E8A2"></topicref>
+</topicref>
+<topicref href="GUID-CB3A8650-751C-4DAA-9408-7AEB3C7FD41A.dita"
+id="GUID-23BA583E-1538-47C6-A9F7-99036D800F25">
+<topicref href="GUID-C38DA704-8868-479B-AF81-375E0A2F5BCC.dita"
+id="GUID-A765849F-50F3-4EDD-AFF3-C85DC3E0364A"></topicref>
+<topicref href="GUID-B94FFCA4-1EB3-46A7-9FF9-54C55D67FFE8.dita"
+id="GUID-DF959C90-A929-484A-AFC7-85326FD91528"></topicref>
+<topicref href="GUID-DA382265-232F-40F4-92ED-C90E6DE3D709.dita"
+id="GUID-4146AD25-F4F3-4AEA-8E61-92029C766FC5"></topicref>
+<topicref href="GUID-22CCA5B5-D4AB-4ABC-94C6-CD85EC470238.dita"
+id="GUID-5631F3CE-93A5-4485-8869-C0779F841ADA"></topicref>
+<topicref href="GUID-A4179FF3-4541-44B8-A8F3-52C1318159B3.dita"
+id="GUID-A4E23011-F48B-4C47-BAD3-6B1439A1C6E3"></topicref>
+</topicref>
+<topicref href="GUID-0346036B-A470-4C18-B276-3A3485F6A069.dita"
+id="GUID-5DE2D211-FE2B-4400-9F4E-56AD72754EEE">
+<topicref href="GUID-C244D421-8BD0-4212-A5C5-47A8B1E0C1E2.dita"
+id="GUID-93D43510-5813-4FD9-AD58-5944E31361A3"></topicref>
+<topicref href="GUID-D1C5BB01-6780-41D6-B47B-43D4C983B0B6.dita"
+id="GUID-B0F107DD-DE9B-410A-80D2-FFCC2538FF6F"></topicref>
+<topicref href="GUID-65F012C2-19BA-474E-8E94-D0E89DADF7B8.dita"
+id="GUID-9FD2D932-CEF9-4F99-82CC-B6A33434D5B0"></topicref>
+<topicref href="GUID-3102F778-DD2F-4C87-A0DF-7FA44C9709D8.dita"
+id="GUID-216C856A-5327-45A0-9781-303B0C5AD409"></topicref>
+</topicref>
+<topicref href="GUID-EBF4F1F1-F76B-455B-B8EE-B7965CF0717E.dita"
+id="GUID-8198D1C9-E6D4-4020-B1B5-B75C51560E0F">
+<topicref href="GUID-D207C135-EF02-4D1A-A48C-4AB8C6703496.dita"
+id="GUID-3C0F5C6B-2CA3-4AAA-ABD3-03279EEEB390"></topicref>
+<topicref href="GUID-32B82E5C-FD53-48E6-9ABC-88F82ACF71BC.dita"
+id="GUID-63290962-F9EA-4EEC-B736-4C1D1CA97297"></topicref>
+<topicref href="GUID-D291C9E9-5207-4B23-B287-C240464087B9.dita"
+id="GUID-193B9AC4-6341-4080-9B45-30F286BE799A"></topicref>
+<topicref href="GUID-C98DF912-A903-4FDB-B27A-CC8E75E3E40F.dita"
+id="GUID-197F926B-408A-4561-B633-383C52DB99C9"></topicref>
+<topicref href="GUID-8798F896-E0CB-4B9B-8F88-3C8B58574213.dita"
+id="GUID-AB885336-020C-4457-AF70-F1F9C2F2B63E"></topicref>
+</topicref>
+<topicref href="GUID-E90DBF35-0A05-4751-904D-4F06987FFF48.dita"
+id="GUID-E5CEE289-BCDC-415A-BCD8-35B061653D07">
+<topicref href="GUID-0A6C8DB8-ED41-4243-BA96-CA691CF9CD19.dita"
+id="GUID-DEB7F170-A01F-4076-AC6A-9AEC0DA79F1F"></topicref>
+<topicref href="GUID-53649311-4465-48B5-8D07-A65515950040.dita"
+id="GUID-400FD70D-CC62-48F2-AA2B-EBACD0BB54D2"></topicref>
+<topicref href="GUID-C3C89BD7-A56D-4597-8804-01A25BC71581.dita"
+id="GUID-4AE337DB-1097-47DE-9972-F434CB032532"></topicref>
+<topicref href="GUID-D1F7D21F-BA9D-482C-9B58-7C53A680145A.dita"
+id="GUID-CD552B92-4390-4FB9-936A-B4FE248DFB2B">
+<topicref
+href="GUID-C649DB97-F138-4C90-B177-16590F2E3F19-GENID-1-2-1-9-1-6-1-8-1-7-1-3-1.dita"
+id="GUID-7FC70EE3-DFDD-4E04-A009-BC3CC8299917"></topicref>
+<topicref
+href="GUID-58AA7257-0951-42AB-9B6E-AAF63343FEFA-GENID-1-2-1-9-1-6-1-8-1-7-1-4-1.dita"
+id="GUID-D6AE2F52-C3B1-42C2-B114-D2F0A8279C09"></topicref>
+<topicref
+href="GUID-6AC01B10-92C1-4E56-813B-6853DFCF3386-GENID-1-2-1-9-1-6-1-8-1-7-1-5-1.dita"
+id="GUID-F0D5475C-5F11-452D-BDD5-7580BBE89F24"></topicref>
+<topicref
+href="GUID-C74770A5-ADD4-4AB1-946F-77105E2B8C10-GENID-1-2-1-9-1-6-1-8-1-7-1-6-1.dita"
+id="GUID-ACEF0ECB-046F-4FE1-A6DA-05528638BA04"></topicref>
+<topicref href="GUID-E7E67A52-0725-446B-A49C-CF571C4A0C64.dita"
+id="GUID-D821B751-A2A6-47EB-8A62-F4E5A9D9CA6E"></topicref>
+</topicref>
+<topicref href="GUID-132349A6-9A5F-4866-A54D-F01B6F58ABDD.dita"
+id="GUID-C1FA8310-111E-409A-BE71-E2E3AB4469EA">
+<topicref href="GUID-43782364-0865-43D0-BC89-D63BA9912FB6.dita"
+id="GUID-B1397C03-3E7C-42FE-8D8C-4A0A9A5C8927"></topicref>
+<topicref href="GUID-A87D9280-B61A-49BA-A9AF-178DB9BAECBC.dita"
+id="GUID-BE49DD4B-CFAF-4709-8232-BC4F183ED641"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-CFE0A4EB-845C-43B6-A732-AA155AFD99D6.dita"
+id="GUID-D2317797-5339-45C5-8991-A93F4AB0B468">
+<topicref href="GUID-2648B61C-6EBD-4668-AACD-EA4B2C435BB2.dita"
+id="GUID-14B6988F-BC7D-44B2-BC25-1F7AC7616CFE"></topicref>
+<topicref
+href="GUID-7AB51180-7A1A-40C7-B28F-EA46314A6E5B-GENID-1-2-1-9-1-5-1-4-1.dita"
+id="GUID-84DCF804-9E4A-4552-809C-EF2E95F83584"></topicref>
+<topicref href="GUID-4DAC39E0-2EC2-40F7-9AEF-4FDA09F1A151.dita"
+id="GUID-B06177AA-D92D-4DAB-948B-D7DE3D765693">
+<topicref href="GUID-0E93319A-439E-49D8-BF38-C809FEE4BB74.dita"
+id="GUID-8D237467-8C8E-47DD-A50D-F8B912CA6B4B"></topicref>
+<topicref href="GUID-3A785F02-F4AA-432C-9331-8827029BB384.dita"
+id="GUID-031ED607-9FB5-49B9-A08A-65BDFB851F14"></topicref>
+<topicref href="GUID-30978E00-D244-44CD-8F4E-9676DF172A52.dita"
+id="GUID-538D250E-5E18-42BF-AA0A-47A109518BC8"></topicref>
+<topicref href="GUID-F7249C66-B62F-45DF-B733-BC6D5FCDA003.dita"
+id="GUID-D306F483-3C7D-45C2-9E7B-E8D305637A26"></topicref>
+</topicref>
+<topicref href="GUID-F367F6C9-66F7-4061-81A7-0C845D8F39C4.dita"
+id="GUID-F698F361-0B2F-4A0A-9AB5-34DF138B4DD1"></topicref>
+<topicref
+href="GUID-FD8634B8-E522-4AC4-8129-ED807A7754A2-GENID-1-2-1-9-1-5-1-6-1.dita"
+id="GUID-440AEAE7-F96C-4277-9FE7-ADECE65B90F4"></topicref>
+<topicref href="GUID-B97BAC2E-04E3-4979-BACE-9C46BADE912E.dita"
+id="GUID-59A47D48-DCFB-429C-92F9-E2BCD0B8AA20"></topicref>
+<topicref href="GUID-1AFAD1C4-340B-4119-94A8-F50E9D8DA8E6.dita"
+id="GUID-EB99764E-515A-4E7F-BE9F-319345396E03">
+<topicref href="GUID-F54BB3B5-D069-4524-A215-6F2CCA372666.dita"
+id="GUID-DE4256A9-B89D-4639-AFC3-159C534B1791"></topicref>
+<topicref href="GUID-6752A77F-B1D1-49BE-A672-5DDE3B7976BF.dita"
+id="GUID-0082BE1E-F559-4D28-A981-882F4990316D"></topicref>
+</topicref>
+<topicref href="GUID-7DDF052C-2520-428D-932D-BDB476344575.dita"
+id="GUID-DE76A056-C1AE-4C3F-B9D3-F14294AD98C8"></topicref>
+</topicref>
+<topicref href="GUID-660A8E4C-F930-415C-8CCC-CB1DCCAA2442.dita"
+id="GUID-1489D6C8-7F30-4193-AE9D-99192FB48699">
+<topicref href="GUID-8FA1B2B0-5842-4D5D-BD61-C2D79B56ADC6.dita"
+id="GUID-FC64EFF4-E151-41B1-B62E-8D92C7F21117"></topicref>
+<topicref href="GUID-F09740DA-015B-449D-A124-0BEABBDDCB52.dita"
+id="GUID-0F02FEAB-4C62-4E79-A75C-E6E0FDB5AC68"></topicref>
+<topicref href="GUID-6E208C69-AC2C-4A7A-8203-2C4C3F2E54F5.dita"
+id="GUID-F55F9A23-C0CC-442D-BACE-9C24BE768E14"></topicref>
+</topicref>
+<topicref href="GUID-D003030D-8506-4210-9194-7A3819205D68.dita"
+id="GUID-93E87552-B490-4782-852C-53B3C711D98A"></topicref>
+</topicref>
+<topicref href="GUID-26714A57-B6B4-5E81-B512-FB520718482B.dita"
+id="GUID-94D17704-8F52-47F4-8F3D-53CCE34E36F1">
+<topicref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita"
+id="GUID-E2E419C9-E93E-4D8A-AAD0-709B3840B422"></topicref>
+<topicref href="GUID-892931C3-E560-54AA-A9CB-2820BF025E52.dita"
+id="GUID-EB34D5B3-CDBC-4E9A-8BE9-66B007863914"></topicref>
+<topicref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita"
+id="GUID-ABA40F5F-5F33-4D13-8D0D-24467C4868A3"></topicref>
+<topicref href="GUID-DC2CF276-95E2-5810-9B8D-EB8B72E04FEC.dita"
+id="GUID-6B96DCF4-711A-432A-9351-A7BA9E551F45"></topicref>
+<topicref href="GUID-772C2721-DD84-54A6-ACE0-ECACC6432B95.dita"
+id="GUID-8F6CC7EA-5B60-46D0-80CA-BFE668B5D765"></topicref>
+<topicref href="GUID-1E43E258-A926-5D24-B0A5-8756491C687F.dita"
+id="GUID-201FFEA7-F3C5-40E3-93DF-3831E214948B"></topicref>
+<topicref href="GUID-DA62FD4F-2E74-5B2F-B703-4A40DF5F01CA.dita"
+id="GUID-7DB6C376-BDE8-4648-B9B2-3D70DAAE37DD"></topicref>
+<topicref href="GUID-D520CBC3-FCAC-5A53-AE1A-E5254ABBC6A2.dita"
+id="GUID-F520B634-8987-4694-B0F9-15C48E9D9078"></topicref>
+<topicref href="GUID-49379616-C235-598D-AE43-668998AD072B.dita"
+id="GUID-18852E5C-BF9C-42A8-BB34-8904BF07E68A"></topicref>
+<topicref href="GUID-7ECDCF7B-3B2A-561F-9136-04BC4DAE46E4.dita"
+id="GUID-E025F533-6B85-4760-9C93-7BA1F031E9A1"></topicref>
+</topicref>
+<topicref href="GUID-DC8D3736-EDCF-54CB-A614-2AAC4664F1CA.dita"
+id="GUID-4EF3B0D2-5E50-46CC-A7D2-BE4D3373516A">
+<topicref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita"
+id="GUID-AC5DD4D8-D99B-4445-9524-B89E2C2A058A"></topicref>
+<topicref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita"
+id="GUID-AD4F0854-946D-469D-8A3A-21276E7C0868"></topicref>
+<topicref href="GUID-12EFB295-C527-5F96-81F1-6021D335D865.dita"
+id="GUID-7DBCECFE-1FC8-4EB1-B63C-98A6C84B9BFA"></topicref>
+<topicref href="GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D.dita"
+id="GUID-9139F4CF-2412-49E1-BC0E-5D382C0BA89A"></topicref>
+<topicref href="GUID-178E140F-BB15-5A82-99A6-D1BC0E11E018.dita"
+id="GUID-86A7A5AF-1E01-428D-BF62-31EA29641740"></topicref>
+<topicref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita"
+id="GUID-AB858CF0-88AF-4025-AABC-8421641984C3"></topicref>
+<topicref href="GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51.dita"
+id="GUID-DF6DFCED-C705-42EE-89B6-E28109083676"></topicref>
+<topicref href="GUID-F123D574-44DE-528A-806C-DB64229BCEA2.dita"
+id="GUID-FFE094BD-60A4-4405-94BC-C579805717E3">
+<topicref href="GUID-B35A70D2-1BC8-51DE-95BF-F315DB394582.dita"
+id="GUID-535C6E11-6E2D-403D-8C08-272C782028C4"></topicref>
+<topicref href="GUID-6F82A35E-9F11-591D-AA5C-8F60734A2827.dita"
+id="GUID-C9494F00-2DFC-40CA-AA96-76C14600D829">
+<topicref href="GUID-4AFDA3FF-38D1-5EFE-B18A-E3EAAA52EB75.dita"
+id="GUID-00E29B39-EA1D-49DE-9408-5D855135749A"></topicref>
+<topicref href="GUID-7A50630B-2B44-5D27-AA18-3BEEE1453020.dita"
+id="GUID-39B47DED-ECFC-4EDE-9ADE-14CBB720D5F1"></topicref>
+</topicref>
+<topicref href="GUID-795B8649-B6C3-5540-B52A-9B460F35A5B5.dita"
+id="GUID-9B5160D0-6EED-4482-842E-ED5516F9F2C4">
+<topicref href="GUID-1A72F75A-1930-5C32-93B7-20F4934BCFAA.dita"
+id="GUID-3716080B-393E-46FC-BC4F-C453C5D3A478"></topicref>
+<topicref href="GUID-0AFF5666-6BF9-5022-ADBC-5EFFA743B288.dita"
+id="GUID-B39A9D60-8006-44A4-AE00-84EE7039AFC9"></topicref>
+</topicref>
+<topicref href="GUID-CE9EA167-0594-5E61-9640-6B2B63A92EA7.dita"
+id="GUID-20232928-7B50-4083-8C94-D13034695CBD">
+<topicref href="GUID-E21E7992-607A-5A49-B022-189ECA9E76D1.dita"
+id="GUID-E050FBA0-CC8A-4C54-BCE7-6094227BDA70"></topicref>
+<topicref href="GUID-BDB847A2-557A-5902-AA6D-C1AE10D8E493.dita"
+id="GUID-61E143FE-C82D-476C-AF30-E6C546ABC6B6"></topicref>
+</topicref>
+<topicref href="GUID-2B7D04D9-98DE-5284-836D-01DB4FA8949D.dita"
+id="GUID-4C8137D6-7282-4B92-BB6C-FB0A1A695AB3">
+<topicref href="GUID-592B6D20-4ABA-5C79-9734-D18E2CE4A86C.dita"
+id="GUID-028A71CD-1FB6-4F29-B1BD-98AEA2458C88"></topicref>
+<topicref href="GUID-6381BC82-3060-5023-8221-79B18CCB2CDB.dita"
+id="GUID-5E4EB6C8-9EBE-4300-8F47-37C74345D7D1">
+<topicref href="GUID-ACB79CEF-CA4D-5C96-AFCD-6AD7C7C26C53.dita"
+id="GUID-97039AC1-298F-4066-9B3C-C045EA531DD9"></topicref>
+<topicref href="GUID-8A5EC98B-E9AD-5496-9909-7C3B35610785.dita"
+id="GUID-7CC4A177-E219-4506-B58E-AA9AB5A191D5"></topicref>
+<topicref href="GUID-817E0561-6165-5BB1-97F9-AD53CFCDAA56.dita"
+id="GUID-33AD1449-DFBA-41CE-9D3F-ACA12B7F8AA0"></topicref>
+<topicref href="GUID-EF73C56D-AEB1-558B-BAD1-D076BA6EA889.dita"
+id="GUID-F640CDE9-84D1-4E60-91B1-71A357741FEE"></topicref>
+<topicref href="GUID-FBE6E61F-5A2E-5A7A-BC59-51F072EBED7D.dita"
+id="GUID-892F68A2-7E01-4BB5-9583-65BBA4260458"></topicref>
+<topicref href="GUID-7C533836-0D27-5519-BC1D-7153AC8BE4C0.dita"
+id="GUID-51717262-936C-487A-8DE7-29262F1B9F10"></topicref>
+</topicref>
+<topicref href="GUID-2D8B8FF1-7A35-5E98-BDDB-2B0BD8DE6215.dita"
+id="GUID-3D0D7F24-0C3A-474F-9318-DE8931F9276F">
+<topicref href="GUID-1391CDCC-9A09-54FB-BA7D-BC7A91DB2351.dita"
+id="GUID-D9665642-2477-411C-931F-2638D610BDC3"></topicref>
+<topicref href="GUID-16423056-C435-5C4D-BE3D-4A15F95F7F68.dita"
+id="GUID-B3836685-C33A-43C1-95C5-F7123D9A136D"></topicref>
+<topicref href="GUID-6EF762B8-DE93-51C0-8A5D-89FC5289B7D0.dita"
+id="GUID-258BC0EE-1FD7-4F36-A4C6-A09D5AE683A9"></topicref>
+<topicref href="GUID-4862EA2E-6BFE-5E11-B527-7EBA94BB0EA2.dita"
+id="GUID-D642BF04-F3E0-4B75-9ECF-4C90C387CB1B"></topicref>
+<topicref href="GUID-6B9041F7-79A6-5CCA-9B4D-B8EF377FD378.dita"
+id="GUID-B2C22F4A-AA35-4DA4-8B12-71D50A4863FA"></topicref>
+<topicref href="GUID-E7C55048-5B7A-5BF2-B7F4-4D731659B88C.dita"
+id="GUID-79E4CDD2-1C99-417D-BB60-BCC1E18FE0FE"></topicref>
+<topicref href="GUID-44540C74-CD73-5D8E-A9E0-F90F46B4E7B1.dita"
+id="GUID-76B0C335-13B7-486D-A5AB-13D513BAD2BF"></topicref>
+</topicref>
+<topicref href="GUID-BA0AC9AA-A8E1-5650-9512-DEC06D77668F.dita"
+id="GUID-24827ECB-675E-44E7-837A-D938789D9659">
+<topicref href="GUID-85C18DAF-DB76-51C6-B38D-A802E314F4D1.dita"
+id="GUID-8708A3A2-A49F-4578-92C2-06A4013FCD59"></topicref>
+</topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita"
+id="GUID-F4EEDCE8-7543-44A9-B122-E26FE912EB4E"></topicref>
+<topicref href="GUID-26621CA5-B686-53FB-AF3E-96CDD38C8520.dita"
+id="GUID-0C965769-8AE9-4CC9-BC0D-BCE4123CEB45"></topicref>
+<topicref href="GUID-5E358AB4-03A7-5859-ABF2-A8B64B74AF56.dita"
+id="GUID-C3466DC8-5793-4137-95AE-8984974DFA47"></topicref>
+<topicref href="GUID-D2163920-D448-5BFC-B655-B654FD657A94.dita"
+id="GUID-CC4B9207-6A8B-4638-B7BC-AE5031B0799D"></topicref>
+<topicref
+href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1.dita"
+id="GUID-1811B26F-B5BA-41C8-ADBE-86B9DB2D0AFC-GENID-1-2-1-9-1-8-1-16">
+</topicref>
+<topicref
+href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1.dita"
+id="GUID-96EA3E19-7D36-4841-BF61-97F0163CC4DF"></topicref>
+<topicref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita"
+id="GUID-F84FEC86-86D0-4155-A31C-1F8749252367"></topicref>
+<topicref
+href="GUID-9D26E38F-5C7B-5330-A54B-8F97D0F204D0-GENID-1-2-1-8-1-1-7-1-1-5-1.dita"
+id="GUID-C8FB9274-A102-4AE9-93A4-F6AEF6883547"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-A74F0245-1A37-41C8-B0E9-63AF858EE4B6.dita"
+id="GUID-C6148EB4-F37A-4C55-973B-64CBF64A5B5B">
+<topicref href="GUID-95BD3650-08CB-407D-969E-DFDB39B2FEFC.dita"
+id="GUID-0ECC5FF9-4976-4249-B9B6-B37C7E9AA2B2"></topicref>
+<topicref href="GUID-775901A4-0262-4E14-9E9C-C4E37DFCCF2E.dita"
+id="GUID-2FE159D8-4E65-48ED-92B1-4F07D1B463A2">
+<topicref href="GUID-450BF1D4-85D7-45D4-8893-57DA8F1640E9.dita"
+id="GUID-5FE14657-CFCF-4CDB-A76C-9AFD4CDB7FC6">
+<topicref href="GUID-6060F138-CEB6-482A-B0E9-BBBE261568B0.dita"
+id="GUID-E2201790-F971-48FD-BA40-5CF5A25BF80A"></topicref>
+<topicref href="GUID-63CDD34D-936A-459C-B40B-495696204722.dita"
+id="GUID-C90DEEB4-57C2-4ADC-B12B-0809BBC8A9EC"></topicref>
+<topicref href="GUID-D7D7615F-B67D-44D0-82DF-24853159A114.dita"
+id="GUID-27897C8F-D661-416D-BD18-0AA46B7EB8BC"></topicref>
+<topicref href="GUID-F3B93325-E30E-456A-B281-5451B7C47AAE.dita"
+id="GUID-4F7A796A-725D-4A0E-9F08-25FC4539DD0D">
+<topicref href="GUID-57989FF8-5E8F-4C8A-9D38-169AFCA4C078.dita"
+id="GUID-F414CC9C-8844-4938-9CD9-E65E2F10E59A"></topicref>
+<topicref href="GUID-AE486C82-8854-463F-8CB9-B7353D6B2804.dita"
+id="GUID-4E8D3819-B0FA-4A66-B001-89C9138DA5C4"></topicref>
+<topicref href="GUID-10FD1B94-EC0C-458F-839F-B60A8E47BAD6.dita"
+id="GUID-662621ED-188A-45C2-870B-510B255E7020"></topicref>
+<topicref href="GUID-627FC480-AF4F-4B23-8671-6E0A0DABA0EF.dita"
+id="GUID-59A06B45-416A-4A54-8C62-3EBE658296EA"></topicref>
+<topicref href="GUID-37B8243E-027A-49D0-A896-27946DAC9052.dita"
+id="GUID-3A590CD8-FC5A-4B4B-999F-E734C0C848A9"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-BDFAE7E7-18B2-4B5D-8349-CC6C607B717A.dita"
+id="GUID-0262A96C-4264-478D-83E0-DACAC2D37363">
+<topicref href="GUID-092D336A-155A-4F18-AAF7-92E08473700E.dita"
+id="GUID-EC667AC6-9424-4748-BAA9-7395FD410B4C"></topicref>
+<topicref href="GUID-0804E71D-8B20-49A2-9F7C-F2D6795681D0.dita"
+id="GUID-D3D2D61E-626C-4FBF-908F-001802AABDD8"></topicref>
+<topicref href="GUID-56BD2420-EB97-4D0D-838B-4CB2CA52312E.dita"
+id="GUID-9D814589-9EC9-4BDD-9543-E5D2B76E83F5"></topicref>
+<topicref href="GUID-4E3C086B-25BE-4DAC-9E21-CFC4F8B792A5.dita"
+id="GUID-EE1EE16F-B8B3-44B3-82A9-BE2F33F7572C"></topicref>
+<topicref href="GUID-DFDB6864-0F63-41EC-B549-791B750F3EB3.dita"
+id="GUID-4135E42B-4074-4792-9861-9676A06F1442">
+<topicref href="GUID-240EE926-BAFC-4A53-A8F8-D559BA7BB672.dita"
+id="GUID-4DBDAD66-B4A8-440A-9298-380ADC30BD74"></topicref>
+<topicref href="GUID-D5ED62EB-744D-42EB-B8CF-D5623BDA5B38.dita"
+id="GUID-4FC802F2-9DFC-4CAB-B9BD-C3A6AB81F0BD"></topicref>
+<topicref href="GUID-6873E764-4132-46C8-8444-6301CF4D2033.dita"
+id="GUID-72A80003-2906-4630-A87D-DDDBF2D11CE6"></topicref>
+<topicref href="GUID-EE50283A-543C-446F-A5D1-E64043F988ED.dita"
+id="GUID-1AD06DF1-DF67-43E3-BFA5-641FD25659E2"></topicref>
+<topicref href="GUID-AB5370D9-9F0B-4583-A825-11CBF7C6365C.dita"
+id="GUID-5FA6A558-B3CE-41A0-9FBA-27836D6C3392">
+<topicref
+href="GUID-C649DB97-F138-4C90-B177-16590F2E3F19-GENID-1-2-1-9-1-6-1-8-1-7-1-3-1.dita"
+id="GUID-CA11F753-9EE7-486E-9387-B579AD33DB1D"></topicref>
+<topicref
+href="GUID-6AC01B10-92C1-4E56-813B-6853DFCF3386-GENID-1-2-1-9-1-6-1-8-1-7-1-5-1.dita"
+id="GUID-2FD34AA2-AF0B-4161-8BC0-D8F0E2CC5C81"></topicref>
+<topicref
+href="GUID-58AA7257-0951-42AB-9B6E-AAF63343FEFA-GENID-1-2-1-9-1-6-1-8-1-7-1-4-1.dita"
+id="GUID-30AD64E9-D1C8-428D-AF60-7AFFB31E0E73"></topicref>
+<topicref
+href="GUID-C74770A5-ADD4-4AB1-946F-77105E2B8C10-GENID-1-2-1-9-1-6-1-8-1-7-1-6-1.dita"
+id="GUID-15B29308-4D42-4EDF-944F-6A4F15EB944D"></topicref>
+<topicref href="GUID-FA026EBD-7867-4A2C-9FA4-EC70A5243526.dita"
+id="GUID-4259CC3B-C753-47E8-B4B8-F6D82E481138"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-EDC1C30B-4078-4434-95AC-2E37AF809A51.dita"
+id="GUID-40334577-8EDA-47DC-BA4E-4E096E78182C">
+<topicref href="GUID-95A33491-17AC-4F12-948E-A1352ADDA483.dita"
+id="GUID-4C1861B7-B25C-4D32-85D8-A450F5EA1E22"></topicref>
+<topicref href="GUID-9C05C157-D58E-4C43-87E4-82B4F310AEA9.dita"
+id="GUID-5E9520CA-B948-4314-8D14-B221CE919DC0"></topicref>
+<topicref href="GUID-535E5C2A-DCFD-4BCB-B26B-11E88BDB8A8A.dita"
+id="GUID-00E03E37-E3FF-41DE-B872-02B9351FF20F"></topicref>
+<topicref href="GUID-877EEB52-40C8-4880-87A0-9736A625F85F.dita"
+id="GUID-4CE555B1-EDFA-495B-A16F-34AD31EBFC5A"></topicref>
+<topicref href="GUID-AABC7605-9EE9-41E4-BFDF-77A589A9887B.dita"
+id="GUID-FFFD391A-6869-4275-8D66-4BD4FCF8B108"></topicref>
+<topicref href="GUID-2EC16C9C-7241-46B2-B569-B89751933C57.dita"
+id="GUID-800817C0-A87D-4989-A384-BAA3C856D8D7">
+<topicref href="GUID-10C986FD-BD56-4F8E-87EC-7B890EFCDAC7.dita"
+id="GUID-BF156514-A90B-4B6F-B0B0-8812748813E2"></topicref>
+<topicref href="GUID-FE36E7DE-7C2C-415B-BB2F-22D9E2BE49A6.dita"
+id="GUID-018CEA35-CD56-4EA7-8734-CE1B8D8FC04A"></topicref>
+</topicref>
+<topicref href="GUID-C2114C7B-705C-4527-836A-C6E72227111A.dita"
+id="GUID-08316DE1-BCAF-4957-AEB6-3E7CA2440E64"></topicref>
+<topicref href="GUID-2BDDB4F8-3175-411B-A206-FAE27DEBF678.dita"
+id="GUID-C3CF65B3-1D1C-4EF7-813E-351ED89549EC"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-5E24CFFD-1F87-4B77-B7A0-59A419ADBC90.dita"
+id="GUID-D7031E0D-BBA1-4C46-A596-CA698BFB4820">
+<topicref href="GUID-C661BFA4-6C39-476A-8DE0-08E18AA0F548.dita"
+id="GUID-F04E1E01-09AE-40B5-9C66-B9A36795A27E"></topicref>
+<topicref href="GUID-DCDD68C7-8EBE-4E91-A983-076460B2C2F3.dita"
+id="GUID-1A5E9AFB-CE38-415A-8647-022AA999AD26"></topicref>
+<topicref href="GUID-70041B11-4C03-42C6-9EC2-307E5FF0F626.dita"
+id="GUID-EACEC406-1098-4195-9696-FE1B1C9685B6"></topicref>
+<topicref href="GUID-CB0FC4F4-6DAB-4ADD-B044-0E8B9365B4D5.dita"
+id="GUID-9B27F426-B33A-46C6-AB8D-4D4A4CA526F1">
+<topicref href="GUID-B2F86F54-EF50-56DB-ADF7-15325AC9324D.dita"
+id="GUID-3D6DBC37-16D9-443A-8BD7-70BB99A1FB71"></topicref>
+<topicref href="GUID-3A30DA16-ECA8-5639-A9DC-6BE2AD55420B.dita"
+id="GUID-D3E9FC25-B9B0-437F-AA9E-A7C9A17E0EBF"></topicref>
+<topicref href="GUID-99FC067C-0AED-5373-AF63-8DB7FF5C1F7E.dita"
+id="GUID-61EED28B-9FFD-4CCB-906F-613BFB89FD10"></topicref>
+</topicref>
+<topicref href="GUID-F5DC77CD-4730-4FD8-A483-F5D22F34887E.dita"
+id="GUID-597C9144-BE41-43EA-AEA0-34DB9FFEC271">
+<topicref href="GUID-A3A3405C-C89C-5079-85CE-8CB069C8E0C0.dita"
+id="GUID-AC3E9573-55C9-4D3A-8794-7D7155E11E20"></topicref>
+<topicref href="GUID-98210124-0B65-4679-BB3A-E94B9999365C.dita"
+id="GUID-052533EB-C02E-49A4-AE7E-2A75CF2349D6"></topicref>
+<topicref href="GUID-F60E5156-38B0-4781-8088-180E6716FC63.dita"
+id="GUID-EA6E00C8-FA75-4A2B-A07B-0D2F19A52729">
+<topicref href="GUID-9986DCC6-EE73-59FB-BDAC-9B09DC64FBCE.dita"
+id="GUID-C330A32C-ABF2-4570-A101-CE03ADC45555"></topicref>
+<topicref href="GUID-F461CBB3-F8D1-5961-AD51-5741143A1CB1.dita"
+id="GUID-C0061246-7DE6-4A91-AEC9-97394CCC3DA9"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-C6647E84-7237-44FC-BD5D-2476EC161D02.dita"
+id="GUID-7A921E5D-2853-49D2-B6BE-F3065B715E18">
+<topicref href="GUID-C24A5B52-0B40-53B2-BF85-6ECC35BDCBA5.dita"
+id="GUID-3D9831B1-05F4-46C3-9B47-1E24F86DE644"></topicref>
+<topicref href="GUID-78963104-C2B0-4E19-99E5-FEAEB7EA307A.dita"
+id="GUID-F651DCF3-2828-44ED-9320-02F329EB55F7">
+<topicref href="GUID-052F58B7-117B-5EDD-A3D5-CB0DE6A4E239.dita"
+id="GUID-EFCB194F-F971-4C5B-A849-97E87ACFCC36"></topicref>
+<topicref href="GUID-0C8318B1-71D7-5384-97EB-85CBBC3E6B84.dita"
+id="GUID-E3929EA3-442C-4291-BD3D-29ECE93CBFFE"></topicref>
+<topicref href="GUID-C9644081-004E-5DA0-8133-A32EEA91EF5E.dita"
+id="GUID-7571A03E-C491-4FB2-87AF-C59EE2D10D7B"></topicref>
+</topicref>
+<topicref href="GUID-6786C7D8-34B9-496C-890E-03DE018D2DE1.dita"
+id="GUID-0BC9D1AC-54BC-48EA-9B9A-48B46558D4D2"></topicref>
+<topicref href="GUID-E9999276-6861-4ECA-B542-1B6C3471BFC9.dita"
+id="GUID-47D22FA3-C0A3-477C-8756-7844E914715F"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-E6F9A60A-0112-4C9B-A880-7E2908A74DAA.dita"
+id="GUID-0F0A9D4A-CB55-4E8F-94BF-EA1A53E25733">
+<topicref href="GUID-F4B2D20B-8F1D-4A4B-8ECB-65BE8E9824DD.dita"
+id="GUID-5B4470DE-628A-4E17-9249-B15A70749D47"></topicref>
+<topicref href="GUID-E3C7CB78-8A68-4FFA-BD00-04D27E67C1F3.dita"
+id="GUID-90D80E77-4FDE-488B-83AA-C33A7492DAC6"></topicref>
+<topicref href="GUID-654A788A-526A-4C3F-838C-05B09F0D5445.dita"
+id="GUID-C5B31AF6-4D99-47A9-82A9-636836E36D7B"></topicref>
+<topicref href="GUID-F9051D21-3E4C-4645-BD04-06606E849AEF.dita"
+id="GUID-17069BAA-2983-427E-8669-410F77121F57"></topicref>
+<topicref href="GUID-862CA4C4-C6E8-4D60-8DD0-F3590C92E15D.dita"
+id="GUID-97541F22-EE77-40F8-B8AD-A00837C1F16C">
+<topicref href="GUID-315DD62B-8669-471F-BDDC-BC4D700AEA60.dita"
+id="GUID-0885CDD2-8AFA-4566-95DE-8CBCD7E3260B"></topicref>
+<topicref href="GUID-D0F5D40A-28D2-4A2E-9B40-180537E60F56.dita"
+id="GUID-5E65CAA3-2AAB-4FA6-B5B8-8DA41852F21C"></topicref>
+<topicref href="GUID-68446E8E-129C-444A-836A-EF8F56BFE0BC.dita"
+id="GUID-0BA62462-5A88-4A6D-A5DB-1CE5F70E0C7D"></topicref>
+</topicref>
+<topicref href="GUID-5FB6BEFD-579B-4139-B54D-9CDCF2198A14.dita"
+id="GUID-158547A1-E57F-483C-95B7-8AF13E13264B">
+<topicref href="GUID-2E54DA7D-1094-41C6-AFB0-9999471991F8.dita"
+id="GUID-D80EA885-EB3D-41AF-8FE8-A7B8880BC60F"></topicref>
+<topicref href="GUID-9B66387C-B6CF-41D9-BEFC-F79E30C70F52.dita"
+id="GUID-AC2D969B-EA0E-4D54-93B1-6C9D2477C948"></topicref>
+<topicref href="GUID-2490DA46-A57B-4DFD-AA9C-2004D58486E3.dita"
+id="GUID-1812E3F8-2620-499F-AEC9-985374A6728D"></topicref>
+<topicref href="GUID-E0A0C542-2922-407D-88E9-2DC5D159E1F6.dita"
+id="GUID-5B451407-EDF4-4592-BB1A-891831AC2BBB"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-B6A21D4A-86D3-45A9-95AE-A0206D15944B.dita"
+id="GUID-EE7D7647-AD50-426A-8F4D-2A20C3EC8595">
+<topicref href="GUID-6C74A8B4-50B6-486C-A75F-A50636F4C566.dita"
+id="GUID-A042621B-0FFD-4456-8DD5-AC2E1E53BF04"></topicref>
+<topicref href="GUID-50217E69-F4A9-4B9F-8608-419783046A1E.dita"
+id="GUID-297372D8-503B-47BC-AAD9-508A2B8410D1"></topicref>
+<topicref href="GUID-8D7ED882-C61E-4B4F-8483-A323C60BFC57.dita"
+id="GUID-D18AAC32-210C-4A39-B8FA-7427ABBD1B92"></topicref>
+<topicref href="GUID-A25FFD79-0797-43EC-8975-8C23E7E539C4.dita"
+id="GUID-A016DCAC-F1E9-4F23-9278-0A822FDC63E4"></topicref>
+<topicref href="GUID-DB55C1A0-2901-4661-B6B1-3B61BF6FF4FA.dita"
+id="GUID-1E5DBAF2-833B-4DE8-AEE8-1356BAE08475"></topicref>
+<topicref href="GUID-07E0DEC0-A749-4B14-9E73-3AF8ACD28BC6.dita"
+id="GUID-43BAE0B0-656B-42CB-B96C-2DF24F8C67A7">
+<topicref href="GUID-3722B946-07CF-4AEA-B228-E50642D6B5BE.dita"
+id="GUID-AA882CF1-86D4-48E1-9697-3B96DF495072"></topicref>
+<topicref href="GUID-463915EE-25DB-4ABD-AA80-1C10CD242072.dita"
+id="GUID-33C1B87C-F73A-4919-99A9-4067A205B3EB"></topicref>
+<topicref href="GUID-C34DFF54-87C5-47F6-B0AE-3B066DC7F5A0.dita"
+id="GUID-842D5253-59A0-4461-AA07-DD35E97AA7E7"></topicref>
+<topicref href="GUID-31FFA810-129A-4E35-A47F-C6D3C1C71D5E.dita"
+id="GUID-01193D45-2F77-4C1D-AD7A-2C125465EA8D"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-788ECC4B-36B9-493C-A86E-E6C8007074B1.dita"
+id="GUID-3A681CAC-B030-430D-AEBF-2CAA41918F68">
+<topicref href="GUID-7D535B68-CA7F-4796-80FB-AE7A27642A88.dita"
+id="GUID-E56BB3DB-914F-4470-B17E-EFC03FEB2D05"></topicref>
+<topicref href="GUID-6CCF249B-DEDD-4E0B-A081-0FCD9FCCBB5A.dita"
+id="GUID-D899EBE6-EF07-4FA1-9029-FC6BA68B6C80"></topicref>
+<topicref href="GUID-BA4E634D-5B03-4848-8D42-743914D0955E.dita"
+id="GUID-5BE53BCB-4A97-4F29-8F77-DF305441659C"></topicref>
+<topicref href="GUID-D089C2E9-1BE4-4B37-B8A8-21E5B2425E6C.dita"
+id="GUID-A93D888D-71F6-4ED2-8536-338FEEB610DF"></topicref>
+<topicref href="GUID-024EE22F-4B86-48EF-A55E-C9C1C7E9BADB.dita"
+id="GUID-93FBE53B-0376-45E6-8A60-C29B5EB4DF5E">
+<topicref href="GUID-4353940E-C77B-4080-86AD-7DBE52B0A27B.dita"
+id="GUID-99149963-ABFB-46E9-AA0D-24CE21AE78E2"></topicref>
+<topicref href="GUID-12A4418A-9BC6-4BEB-993D-B55E61240A15.dita"
+id="GUID-967D8A18-7708-4D43-8BD1-9683B5B8EE33">
+<topicref
+href="GUID-535C66C9-8B45-4DF3-8404-8ED03ABB4799-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1.dita"
+id="GUID-B1BDC712-3B39-4164-85CD-EBA628F94515"></topicref>
+<topicref href="GUID-2607CCFA-3D24-4716-A447-74304F861C44.dita"
+id="GUID-419C3F7A-926F-4AEA-98A8-9F6FEA86BB9E"></topicref>
+<topicref href="GUID-360DEB3A-3E38-413A-9941-6C758BA01ADE.dita"
+id="GUID-96A4FEC1-BED7-4629-8F60-28596168BB0C"></topicref>
+<topicref href="GUID-E1277A18-7201-4856-8712-067022F92123.dita"
+id="GUID-D65D49E4-CF9C-481F-8BDE-8C7AA55EA4A3"></topicref>
+<topicref href="GUID-BDF1F32B-796B-4D3D-9C91-43FF8E9DDAF9.dita"
+id="GUID-D0123438-DB34-4B17-AD5A-6B636323317D"></topicref>
+<topicref href="GUID-BA3B42A2-141C-49D9-B513-1571C246C19B.dita"
+id="GUID-1AE2A17E-8597-4C19-81E0-26F6785793AD"></topicref>
+<topicref href="GUID-C57086D7-7672-4A52-8634-D28B37AC6290.dita"
+id="GUID-2FB1F266-198B-4079-B5D9-A4DAF54084B2"></topicref>
+<topicref
+href="GUID-535C66C9-8B45-4DF3-8404-8ED03ABB4799-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1.dita"
+id="GUID-C20B8C89-8DE0-4FF6-B56B-DD2AC2A45BE6"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-C0DC5D95-2EB5-45D9-A859-78329A4B3EF1.dita"
+id="GUID-AB8BAF23-72BB-42A1-931E-758AE005A2B0">
+<topicref href="GUID-3A1BCF46-FFBB-4E4F-A73A-6E68254B23FF.dita"
+id="GUID-F560D577-40C7-4345-AA8E-F0BC3FC399A7"></topicref>
+<topicref href="GUID-9BBDFF77-5E2C-4E13-BEB3-716CC80B3375.dita"
+id="GUID-6EB4D9F1-C91E-4DA0-B991-EB3097F7F311">
+<topicref href="GUID-7E3BBB18-3113-4312-AD91-897DE87C58BF.dita"
+id="GUID-2D45E3FF-A39C-4909-B051-7BD7ECE88231"></topicref>
+<topicref href="GUID-2344B900-5EC5-4467-BEAD-AB55C88CE63E.dita"
+id="GUID-7F564EDA-EEB0-4EE7-A7D7-B92CF4DF8DED"></topicref>
+</topicref>
+<topicref href="GUID-7E357DA2-67AD-403A-B4E1-7CB83E75136F.dita"
+id="GUID-F0DEC1BF-D2B2-48D4-AAB9-8B904886C21C"></topicref>
+<topicref href="GUID-092F414B-2279-4ADB-970F-75DAB8A80BD7.dita"
+id="GUID-A884E73E-0430-4B07-95F1-948FBE0C2C05"></topicref>
+<topicref href="GUID-6B2221F2-A598-4677-A2D3-40FF27C7373F.dita"
+id="GUID-7F50161E-50A0-491B-80FB-52857CEA99EC"></topicref>
+</topicref>
+</topicref>
+<topicref href="GUID-4C8E40EE-8CC9-4737-A28E-A18E89356718.dita"
+id="GUID-6FF50F78-CE68-4497-93DE-1FA332E5C83C">
+<topicref href="GUID-86737CAB-2A4A-4424-8856-67E0804BCD60.dita"
+id="GUID-0FBB431E-1DAA-4762-9B0A-73A6B9BB7069"></topicref>
+<topicref href="GUID-455ED16F-D288-42C9-AA7A-AE5822F7A5BC.dita"
+id="GUID-3228F34A-0E94-4B6B-8038-01D3AC624EC3"></topicref>
+<topicref href="GUID-FE77CDFC-B66B-485B-A94D-F646894FD330.dita"
+id="GUID-25056919-A7CC-4417-A806-E5885A6D9777"></topicref>
+<topicref href="GUID-8D9A9283-6E55-4AC8-89CE-DD2B55D05067.dita"
+id="GUID-377C01D3-16D9-42C4-9669-68C4593281A6"></topicref>
+<topicref href="GUID-209514AE-9457-4ED2-AFE0-FDC059CE2B30.dita"
+id="GUID-7F266CA7-779D-47E3-B8BB-66FF860E3E3C">
+<topicref href="GUID-01072199-382F-4691-AC0D-D1226EE5CF2F.dita"
+id="GUID-0F7B3B56-ED14-4759-A297-790CD58D34FF"></topicref>
+<topicref href="GUID-8D237BD6-9759-4180-B190-F1624594017F.dita"
+id="GUID-CDB55ECD-81F4-4417-9C57-9AFB6615B87E"></topicref>
+</topicref>
+<topicref href="GUID-E539FF7D-C221-4961-8227-9E94FBAA624C.dita"
+id="GUID-E1FCBEC5-0739-4BAE-B8A8-7AFFED1BB243">
+<topicref href="GUID-10D79C75-6AB9-4717-87EF-057F19CB8283.dita"
+id="GUID-04521B8F-9FF9-43D6-B45A-C98B8D2F3A67"></topicref>
+<topicref href="GUID-670B0580-B81B-4211-A4C0-23A2D8EDF96C.dita"
+id="GUID-839ACA51-CADD-470E-B358-4694C4F92308"></topicref>
+<topicref href="GUID-5F35ED29-18A0-4764-B84D-B43BF23BF44F.dita"
+id="GUID-3E0E24D7-99D4-4F2C-A653-8B273D32DC5B"></topicref>
+<topicref href="GUID-BD0D62CD-A067-4A87-8779-CC245E2C4CEA.dita"
+id="GUID-9BCD7C17-6151-43F3-9596-FCEC523A1E1F"></topicref>
+</topicref>
+</topicref>
+</topicref>
+</topicref>
+</topicref>
+</map>
+<?Pub *0000060215?>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B5657E8C-770C-4322-88B2-057AAEF62E95.ditaoriginal	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,51 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE map
+  PUBLIC "-//OASIS//DTD DITA Map//EN" "map.dtd">
+<map id="GUID-B5657E8C-770C-4322-88B2-057AAEF62E95" xml:lang="en">
+<title>Adaptation</title>
+<topicref href="GUID-59322A4F-B9CB-5997-B843-C4A80F8D42F1.dita" id="GUID-F376AD77-061F-409C-9F87-14BF7FB81D64"><topicref href="GUID-FCCF9634-0610-5199-A37A-CF2EC9B73261.dita" id="GUID-D9D46D92-915E-48E9-9D03-A5D2F5928F9A"/><topicref href="GUID-D5EE0A17-2246-4CB3-9CE5-538F1E01F8D4.dita" id="GUID-4A2B8EC1-4227-44D2-96D1-642D8C0E5D9B"/><topicref href="GUID-C9923DF3-8425-4EB4-8066-FB5A92A85F5B.dita" id="GUID-9A857DF4-8730-4112-9192-756B4E08AD05"/><topicgroup id="GUID-787A8ECA-A780-4BC0-A139-0985760A533C">
+
+<topicref href="GUID-FB063C1A-EF9F-4292-827F-A3DBC7C7F13A.dita" id="GUID-27BF45C5-9073-4E3A-8124-8ED030A19920"><topicref href="GUID-38FD682F-656B-48F7-A553-50BC4F1FB4BB.dita" id="GUID-2CFAE410-B92A-48F9-8A85-30E0E1FCBE17"/><topicref href="GUID-AC2E5824-4E69-4964-968F-839EB5D2EF4F.dita" id="GUID-B1C54550-EFD6-494F-B633-F30A70DC052A"/><topicref href="GUID-2C6B7D51-C201-453D-ABBA-C9EC6B3DBDB2.dita" id="GUID-0B87594A-4B33-46BE-A467-2E9BAC207640"/><topicref href="GUID-5BD2D468-838A-49BC-BA92-F41102D37CBC.dita" id="GUID-231674EA-F103-4DF1-96D5-9090A5F46387"/><topicref href="GUID-372D2B88-2035-44A5-82CF-57FF131DDEBE.dita" id="GUID-2167E12A-E0F2-4E32-BAD1-484DB21CD8E3"/><topicref href="GUID-CEA3343B-138E-4D6B-8E5F-A255C5C73376.dita" id="GUID-B195AFF3-25DE-46A4-B70A-C8A13149779E"/><topicref href="GUID-B8B36A53-CB13-41C1-9CCC-CA5AABE13BF6.dita" id="GUID-F1D38F5D-E7D5-4D3B-8170-FD93B57977AA"/><topicref href="GUID-7BCC0EFA-0DD5-4879-BECF-C32D04BC8A39.dita" id="GUID-29EF8ED6-CABB-4C3D-9FCC-8F44E700D8FB"/></topicref>
+</topicgroup><topicgroup id="GUID-1632EB06-EA0A-42F9-81E5-E0621FBCF113">
+
+<topicref href="GUID-0C84FD76-87B2-4AD1-B23A-2C5C8668BC4C.dita" id="GUID-9053FE48-B44A-44F2-AC3D-3DFED925816C"><topicref href="GUID-5CCF303A-B7D5-570D-9BE8-29DFBE184995.dita" id="GUID-4EA3767E-BC4E-4CFC-A371-BC1CC73AD6E9-GENID-1-2-1-8-1-1-4"/><topicgroup id="GUID-97027A86-63BE-47A3-BA41-8A80C8E25687">
+
+<topicref href="GUID-84D56A30-1E97-40AE-BFB0-E33495E95AAC.dita" id="GUID-784EF6D0-8328-43B4-A917-BF95396A5407"><topicref href="GUID-E0DCBDCF-C056-53E5-A375-778327F848E4.dita" id="GUID-57B45B32-2A1B-43CD-9357-BD375A3443C9"/><topicref href="GUID-984C2A0D-36BE-5A99-9D65-3F8791C669FF.dita" id="GUID-1D6C9BCB-1BE6-44D4-A89E-DB2B494397E4" type="topic"/><topicref href="GUID-80698E62-E310-59CA-A524-5CF44C437BE4.dita" id="GUID-48A94568-405A-4C88-A6F5-F77CDF2DBFE3"><topicref href="GUID-E5459A54-14BC-55C1-B911-63415E4C61A6.dita" id="GUID-45BF78A4-00FE-4C60-9CAB-508630246F27"><topicref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita" id="GUID-702240E8-EA8E-4073-BA6A-E18DCC676671"/><topicref href="GUID-01F1F488-8E95-56B0-818E-6096CAE4C50C.dita" id="GUID-41F6B36B-361D-4D2C-A6E2-1F14476D4718"/><topicref href="GUID-93DA75DE-096F-5E40-A47E-5A1A94C3145A.dita" id="GUID-3683C4E7-5DEF-4FEC-A0B5-F255B4BDFBC2"/></topicref><topicref href="GUID-BFE1422D-3B4A-5B25-A757-B5B68D6390F8.dita" id="GUID-01E059A9-5CE4-407F-9B74-898AA679FAE9"/><topicref href="GUID-7BB36477-0FE2-51D5-B4C0-86F7265C1B94.dita" id="GUID-BEEE41EC-8813-44B5-9765-DE741D406FC2"/></topicref><topicref href="GUID-53944506-5CA2-52BA-8D5A-9EE72092612B.dita" id="GUID-87C2AE8C-E846-47B3-8230-95EAE581086F"><topicref href="GUID-A74BC61D-85E6-5DB5-93F4-DFE4F0B93EF2.dita" id="GUID-FD2E5BCE-AC02-4EA3-B27A-5CFDAEDE1D63"><topicref href="GUID-3E85C075-436F-5D2E-B1F7-0C9EC6D382E3.dita" id="GUID-D60AD6E8-1C2A-4F28-B8AE-C80A478899B5"/><topicref href="GUID-D729BD58-D4FE-5D46-ACD4-F78B37BA833A.dita" id="GUID-74215033-14B3-46EB-BE1F-806346218A72"/><topicref href="GUID-0DC908A1-6CF6-50B5-978F-AF6C8CE04F44.dita" id="GUID-6C5F3DD9-3C12-4CA6-9AC9-DC97A35D700B"/><topicref href="GUID-306A0B41-94CD-534A-B3BA-FAECB858E9A9.dita" id="GUID-BCFD1EDD-F7F4-4390-853D-355ED8B9F5B8"/></topicref><topicref href="GUID-5EB03086-A87D-5588-8927-7A7F8DB38366.dita" id="GUID-B84A213F-40D4-43F7-BEF0-66E6DBFDDF40"><topicref href="GUID-2E4F8732-F253-5E0D-9A37-9476541E6004.dita" id="GUID-1DF5619B-628E-4AAD-81C3-BBD6D6346380"/><topicref href="GUID-08867AEC-5866-5583-9AAB-068CB51F5C18.dita" id="GUID-241259FC-49E5-486F-B0AE-1AEFC71FF223"><topicref href="GUID-F67FA7B5-F6D1-5C5C-8E10-A8E317A778E4.dita" id="GUID-9529FEBF-F55D-4104-8866-CEA008766EC6"/><topicref href="GUID-9595FD6F-1EDE-51A8-B00D-029CFDFE0F38.dita" id="GUID-30A79A3F-329B-4D04-AD86-67322C669A71"/><topicref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita" id="GUID-44B7061A-9882-4CF1-823E-6205FE02C503"/><topicref href="GUID-C92CC81A-35A1-5860-AA08-C8C08B39804C.dita" id="GUID-BDA30353-6004-400A-BE86-0E1B9C99F57D"/></topicref><topicref href="GUID-AFA1604D-FF0C-56BE-A71E-AF3C662F8943.dita" id="GUID-FFF6C8D8-6B42-421C-9886-24D66E654BE1"/></topicref><topicref href="GUID-20F8DA2A-9157-54C5-97D0-4CCA50AB0631.dita" id="GUID-CA4DD52F-D1F0-47E2-92E0-64F379F5BAD9"><topicref href="GUID-2C1B74C4-C80D-5EF9-B822-2DA2FCF9B006.dita" id="GUID-5281FA44-AB07-4EF7-AB7C-D73E4134848F"/><topicref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita" id="GUID-736F2948-C225-492A-80C8-B439ED8B3FBE"/><topicref href="GUID-36CD752C-45FE-5BFE-A695-11DF085F301F.dita" id="GUID-EFD0200A-8D6F-44F4-9976-B24FE345335A"/><topicref href="GUID-4A910E9F-E881-51D7-A84A-CBC6AC343FD1.dita" id="GUID-F9B735C8-7551-417C-8A05-38E117CBD344"/></topicref></topicref><topicref href="GUID-4993AF8E-28C3-54BA-8D27-D86E05D39CFD.dita" id="GUID-A9661C34-BC5B-4A93-A6FE-82EEE1299022" type="topic"/><topicref href="GUID-3A625B23-354E-5CB4-98CF-FF53AD724FA0.dita" id="GUID-1A37203A-FF99-4331-9345-5FE02E80C8BB"/><topicref href="GUID-E081474F-6B17-5D2E-833B-E8177778577A.dita" id="GUID-64F41689-CCB1-469E-8DA8-87697653672A" type="topic"><topicref href="GUID-6C27AAD6-EB88-53AF-8E04-921A957042CF.dita" id="GUID-5FC4F744-93E6-49E6-9B3E-8AA49C750F30" type="topic"><topicref href="GUID-F6E83530-3F8E-5930-8C6C-4D58B675E67A.dita" id="GUID-F9884B3F-4A78-4FB4-9058-969D9BBE67A0" type="topic"/><topicref href="GUID-552530EB-1287-542D-AED3-125387B485C1.dita" id="GUID-C0CC4A17-2DAE-43EE-A176-F564ABCE6F30" type="topic"/><topicref href="GUID-DBEAD516-5DD4-5E33-B6DA-657C1AE60C4B.dita" id="GUID-7B0BD144-CF82-42CC-91BD-20C5124063DA" type="topic"/></topicref><topicref href="GUID-0563266C-8B5A-5664-9AC6-A5504AB5056F.dita" id="GUID-79845C04-6955-4CDD-8AEE-AD076384D17C" type="topic"><topicref href="GUID-2C915A03-AD8C-5924-87BB-953AE323E0FA.dita" id="GUID-7F9E07AE-3927-4FF3-8E7D-8E60390A0623" type="topic"/><topicref href="GUID-7BCDDA55-1460-5411-AFCF-C4640BEB9DE4.dita" id="GUID-88C35365-217F-4744-AE54-B547597F81FC" type="topic"/><topicref href="GUID-3574BE12-9DA9-573D-8545-3B073005A139.dita" id="GUID-E9CD4D1F-5576-48B6-80D1-3543E89FC368" type="topic"/><topicref href="GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07.dita" id="GUID-B8D4E4B2-A3F0-4D47-BD21-F71889A261D4" type="topic"/><topicref href="GUID-009D71C6-481F-5EF1-B230-EB64F67047C8.dita" id="GUID-11087DBC-7B77-463C-9BD4-3683028AA317" type="topic"/></topicref><topicref href="GUID-D683DBD8-15AA-5F2F-826C-B56CCE1DC06E.dita" id="GUID-5A90C85D-9BD0-42E2-BECF-42E1CAE5CBB6" type="topic"/></topicref><topicref href="GUID-DF2F0439-AE1A-599C-91B9-6EF2177C3C7E.dita" id="GUID-6F797334-D86F-480C-AF98-34499CD68ED1" type="topic"><topicref href="GUID-81C69779-27AE-55E0-ACCF-E4F3E6657427.dita" id="GUID-D23BA7F6-E43A-4F5B-8690-BD7A7859D3A1" type="topic"><topicref href="GUID-4C5DB74E-41A5-53CB-A053-CBBEADD31AFF.dita" id="GUID-34F48400-511E-4E14-8144-FA8203735894" type="topic"/><topicref href="GUID-0D2F811C-81C3-526F-8EA4-98E50261BF4B.dita" id="GUID-194655E6-3991-4AE2-9B30-597EEC660BE0" type="topic"/></topicref><topicref href="GUID-3F47E907-975A-5739-9B03-042CB90D675D.dita" id="GUID-1573D26E-1E02-49A6-B19F-3BA423A50D35" type="topic"><topicref href="GUID-97F97D7B-D5A3-5471-A359-77B805ED198C.dita" id="GUID-A36821E5-8EBA-4A07-BFE4-9884ABD55E10" type="topic"/><topicref href="GUID-CDB2DD00-482D-5AEA-AF89-064C8F904DD9.dita" id="GUID-C54D6BBE-F1B0-4898-9DD3-A7CBC0EB0724" type="topic"/><topicref href="GUID-812DEBEB-84D0-5BD4-A5BB-5AF6B8384CCF.dita" id="GUID-6D18CAA3-2CDF-4E4E-A674-B2104DDD9B45" type="topic"/><topicref href="GUID-A4C19890-2380-5498-A5F8-3B6D95CEFEF4.dita" id="GUID-2D66EF22-0C54-4B7A-916B-0120DF259BAE" type="topic"/><topicref href="GUID-8552E66E-73D6-51DA-8F53-DDF437186CD6.dita" id="GUID-FF3E3C18-6A48-4058-8AFD-9E1D10A1EDBF" type="topic"/></topicref><topicref href="GUID-A4CCF2B6-26B7-5E8C-B738-9EE9E68A0B35.dita" id="GUID-6739E4E0-D375-433D-8D96-6EA4F1843329" type="topic"/></topicref><topicref href="GUID-7C064328-8368-4259-9CE1-B8DFE2DF4AAC.dita" id="GUID-17C9D42A-D46C-4D83-B0B0-303F677D254B"><topicref href="GUID-5B24741C-7CE0-58E8-98C9-1D1CACCD476F.dita" id="GUID-FD3F2281-3592-4004-9726-390DCF16DD1D"/><topicref href="GUID-89BCF9A5-ABBD-5523-BA76-FDB00B806A30.dita" id="GUID-AE76EA73-4694-4BC4-AB8F-44FF79C68F21"/></topicref><topicref href="GUID-BB507973-77A4-4DC1-91C0-65E3CA2CF790.dita" id="GUID-EA04BA3E-4017-46D6-877A-E657A1112668"><topicref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita" id="GUID-319D261F-76F7-41CF-87F7-A8DFF5AE8B76"/><topicref href="GUID-3C34724F-B476-5329-B0B1-6D5A34294979.dita" id="GUID-D7CCA2A0-3DC3-4660-99EA-BADCC662ADB5" type="topic"><topicref href="GUID-B9B35999-0937-51C5-BB77-91A6C039CE2F.dita" id="GUID-4B516900-97FB-4730-B3B0-02A4C9C736EF" type="topic"/><topicref href="GUID-8B7E2A72-B793-5E70-87F0-92AA0A482F23.dita" id="GUID-88830A52-125A-4588-A69F-B3A7DBDECF2D" type="topic"/><topicref href="GUID-AF2E227B-C5BD-5F05-98D4-7D15530161C8.dita" id="GUID-4084FCE0-ECC6-4AAE-B01F-691270081990" type="topic"/><topicref href="GUID-583F70B4-5C8C-54FA-A869-E6F073DE1FD6.dita" id="GUID-355BC0A3-D4C1-467A-9989-A30EC64E5D8A" type="topic"/><topicref href="GUID-159BDA2E-123C-52DF-9F8B-E058379EBFB8.dita" id="GUID-8C8E7020-E887-40EE-97FF-3CCE324734C1" type="topic"/><topicref href="GUID-8B8CAEED-A89D-53B3-A311-51CF45B334B1.dita" id="GUID-8A4D0BF1-68C3-4A84-8366-17F95AB1877B" type="topic"/><topicref href="GUID-423537D5-2C8A-5C26-8D7B-60446E95F681.dita" id="GUID-C98E36FD-06B7-41CC-AE74-C038D2D80C94" type="topic"/></topicref></topicref><topicref href="GUID-D048E187-6B1C-5A80-9CD0-89CD10688C6F.dita" id="GUID-421F5EA1-9032-4DEF-88DF-9B23A8C8D3AF"><topicref href="GUID-EB76FAF8-CD4B-5CB6-9F23-C852ED91866F.dita" id="GUID-70091D59-9965-4155-B3BF-EC709E41A87A"><topicref href="GUID-F9558573-7C79-57C5-809A-9257BF84758A.dita" id="GUID-BEAD78B9-72D9-476D-A14E-E0866C52B001"/><topicref href="GUID-110DB7EF-5E85-5BC4-9BBB-9A37B2D0C3A6.dita" id="GUID-E5255614-F877-4BDB-9D8C-6DBA88835656"/><topicref href="GUID-5C17A2E7-DE18-5CFB-A5D5-421D427CD5DD.dita" id="GUID-D2766A20-2F57-404E-9D2D-F4E778161430"/></topicref><topicref href="GUID-2E42E7EA-FED8-522C-8A5F-F65D799476C9.dita" id="GUID-BA80DCCC-6209-4E15-B705-929B825AD6E4"/><topicref href="GUID-D34DB4A1-1B17-5FAF-A48B-E06D247B0A83.dita" id="GUID-5104482B-F377-4E8D-B694-48602D101692"/><topicref href="GUID-197A1071-CDAA-5A87-9981-A52FB32C084E.dita" id="GUID-BAF52F6C-5D03-467C-AA9F-90F0C1273185"/></topicref><topicref href="GUID-8C22AF20-EE0E-5AD2-BEFD-FED5A7DBB09B.dita" id="GUID-E8234699-BBB7-4B56-9F34-17A82C33BB2B"><topicref href="GUID-0C3A4156-E5CF-55F9-91A0-A7961FDEE030.dita" id="GUID-726BEE1E-03E7-4C3C-9D89-320F2A976512"/><topicref href="GUID-6A4FE3A3-2E5D-51BB-8272-5995586291E9.dita" id="GUID-76DE83E9-7378-4D6B-9197-09E3D9CE2989"/><topicref href="GUID-81DD805C-90B5-5227-B62B-F2413855BD9A.dita" id="GUID-115D6443-90E0-4EEC-8A8D-F51EBD1CBD2E"/></topicref><topicref href="GUID-5C223AD5-4676-58B4-B3A5-066F6B69AA4D.dita" id="GUID-5A63899B-01F7-4C9F-9EE2-DC22CE7EDD23"><topicref href="GUID-2559E3F7-314B-5DCC-A7FE-A08162A89721.dita" id="GUID-1FAA2C48-690A-42F8-9664-B20140D45AA2"/><topicref href="GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3.dita" id="GUID-85C4CBDA-8CFB-483C-BA1B-ABFEA93314C2"/><topicref href="GUID-2380FDDE-5489-5B1C-87BB-1FD882E385D2.dita" id="GUID-961CD5DE-7A30-42B5-A046-8542BAE10167"/><topicref href="GUID-E21C4AF8-852A-5BBD-A92A-5473D1DFFBB1.dita" id="GUID-51188FFF-5EAA-4F28-A18C-C0EEE897B839"><topicref href="GUID-DD568637-CD37-5E4C-AD78-4AA5AFE1E9D8.dita" id="GUID-E2BEFF5D-B54B-438B-84BB-62104AB65BB4"/><topicref href="GUID-A70A01D2-467E-5BA8-A01D-6182558F3F52.dita" id="GUID-92ECC5C0-512B-4F3E-9E92-2D84E224FD4C"/><topicref href="GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930.dita" id="GUID-59A01AD5-0C08-43A2-B19B-0CB8C232F179"/><topicref href="GUID-EBF025DB-1552-5E99-8C07-09932DB60552.dita" id="GUID-499D7D3E-F932-4C0F-9B94-CAE784D8767B"/></topicref><topicref href="GUID-CAEDFD1D-ECA1-5A6F-9861-63B7BE24E9E4.dita" id="GUID-C0000FDB-54A8-4786-8B6F-DC3C5747EB43"/></topicref><topicref href="GUID-79B2CF91-FB95-5E7C-81CC-235A6A660D88.dita" id="GUID-F0542E96-CA48-4EC6-AEAB-C3A1B5772FFE"><topicref href="GUID-9573F7B9-76E9-5DCB-A498-C0DE59606911.dita" id="GUID-1268DBA4-C3DD-4CE2-97C0-6F8277DCCE7D"><topicref href="GUID-058BAEDF-5E04-5BB4-928F-0E0528FD9465.dita" id="GUID-2FB0F1EA-497A-4EA9-965D-B3FF8D6AB228"/><topicref href="GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF.dita" id="GUID-EBD42C2B-7790-42F3-81D5-4D09D6B66D36"/><topicref href="GUID-C6825C8F-8020-58CF-A09E-34558B1542DE.dita" id="GUID-BD02B3C6-2A11-4555-83FE-4F80F97ECB81"><topicref href="GUID-28844FE0-AE0F-531C-826E-CDA8400A0581.dita" id="GUID-D5605A1A-EB5D-4CDD-A47D-3E3B40C6AE1A"/><topicref href="GUID-80E0DB93-A96A-54A8-A201-E11935418BE7.dita" id="GUID-EB2C4E60-E3DF-43D0-951D-98E491656968"/><topicref href="GUID-C059F39F-BC53-5C92-B05E-863B8CF22859.dita" id="GUID-661758DE-451F-4085-970C-974FC432E966"/><topicref href="GUID-73F220EA-F41F-56A5-BAEB-4A37174CFD1F.dita" id="GUID-151BFEE7-B888-4DB1-B7F0-41E6FBA30B45"/><topicref href="GUID-2281F91F-67BD-5B85-A47F-30A5E683BBF6.dita" id="GUID-7032BF11-9272-4A46-ABBA-15C7A19F11A7"/></topicref><topicref href="GUID-40F2BC43-5022-5F4E-B445-56FEF43FEB8B.dita" id="GUID-1710CC13-1B2D-482B-B740-05A8475747C9"/></topicref><topicref href="GUID-86082C0C-B0EE-5E7C-85B4-4A509066012F.dita" id="GUID-64BB60F4-1B05-4BEF-AD4E-ACD000BCD269"><topicref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita" id="GUID-AAF4C281-F48C-4B21-973B-88BABF937BC7"/><topicref href="GUID-180973A1-5C0A-5A85-82CC-E6B739A7F207.dita" id="GUID-96871FD0-BB73-4F69-9534-0A9201244C38"/></topicref><topicref href="GUID-B6F0C909-6E58-584E-9270-8066337FCE0F.dita" id="GUID-A31E6A59-747A-463C-9826-6B6949BA0C97"/><topicref href="GUID-90B5FDD9-7D59-5035-BF53-2B177655DCD6.dita" id="GUID-0FBF7CCE-5C6A-4432-93F7-5E86F0A10F22"/><topicref href="GUID-33A7D8D4-84D6-56EA-8EAB-2A3A3ACABF77.dita" id="GUID-7B550356-FB22-44BE-8BC2-D18A3A6B92F6"/></topicref><topicref href="GUID-DD9DBB55-330E-4F43-A156-621979B675BC.dita" id="GUID-CBF96EB5-42AE-40B7-AD2B-235314C0651A"><topicref href="GUID-2700AAC8-A034-5E7D-B0E0-26B49E68BB18.dita" id="GUID-CEF923EF-14D2-4AF1-85F8-554E3BEE4EB3"/><topicref href="GUID-42F8FA5A-BBE4-50DE-917E-D05755019FEC.dita" id="GUID-1C17B243-E8FA-4C78-A812-1936BA866372"/></topicref><topicref href="GUID-F5430A12-D89D-4936-B846-E917B434F755.dita" id="GUID-A80C65A6-BC4F-487D-BDEF-80247EF041B4"><topicref href="GUID-10F3E16A-8CCE-420A-9D1C-F9891B3D75FE.dita" id="GUID-7F573CD9-6871-47FB-9031-9C1F1BB8225C"><topicref href="GUID-0C435514-EEC6-5660-BB5F-535790349632.dita" id="GUID-2B5090CA-D70C-48C1-A43C-77EDB5C63067" type="topic"/><topicref href="GUID-113B3755-1797-5D1B-8E07-8A18F5FE1504.dita" id="GUID-ACBDEC22-B315-4B29-852F-7B499AE0F577" type="topic"/></topicref><topicref href="GUID-3773A78D-F491-52EB-AA1D-201636497F28.dita" id="GUID-EEBF289D-A52E-4197-B1FE-E34861BD6581"><topicref href="GUID-4804B6E0-9199-5F3E-984A-4B00B3984E45.dita" id="GUID-99B0D970-519D-4705-A6C9-E049F017A19B"><topicref href="GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9.dita" id="GUID-704A62DE-5436-4FA9-B38B-C07E91060B6E"/><topicref href="GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671.dita" id="GUID-C25F58AB-6C96-498A-B03F-4ACB89FD4DD4"/><topicref href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita" id="GUID-23A28860-47C1-448C-B2C9-843551867FC8"/><topicref href="GUID-E7F91A65-235D-589C-9A8C-0B207D19A24B.dita" id="GUID-863825F8-7285-4AEB-A402-ED4CB438E20C"/><topicref href="GUID-C8DF0CB0-92F4-5F9E-A8F1-7DE50954C4F1.dita" id="GUID-8D463F9C-55E4-45F1-9F4F-14A5EFEB5900"/><topicref href="GUID-66E5F769-1156-54CA-94BC-8912159A1240.dita" id="GUID-EACABFC7-066C-4377-A78A-93B54DD9BF4B"/></topicref><topicref href="GUID-34D1D0BF-20DE-5677-A067-8FF9DD72E703.dita" id="GUID-13401023-1EBC-40E3-84F8-8E6BA353F566"/><topicref href="GUID-A789E0D6-74B2-517D-B73A-F9B11794F175.dita" id="GUID-6A71F416-EF2C-4D50-8833-C29F8125A426"/><topicref href="GUID-3B6544CD-FA6E-5AB2-AA63-61186F52167D.dita" id="GUID-E6910B89-DC72-4B36-8359-0D1FE3BD022E"/><topicref href="GUID-6CE68645-D8C5-52E1-88B3-76AEFB80DE51.dita" id="GUID-2A32518C-16BC-4523-B512-D0C25B88A7D7"/><topicref href="GUID-1D3E61BD-C09D-51FD-A10B-22392FDAEFEC.dita" id="GUID-B8570EBA-DC14-4D53-90F8-B54F069C7DEA"/><topicref href="GUID-2E402D4E-53A9-5BA6-9FBD-B2713DBC7858.dita" id="GUID-473D1D0C-CE91-40EE-9625-F9BF7CDBD64B"/><topicref href="GUID-29B84A67-9DB7-5F4C-A4D1-A3BDC69015A8.dita" id="GUID-A4AB1E83-7822-4AE5-BDA5-F816C148E82D"/><topicref href="GUID-65CDCA83-C726-5173-8E46-B8981D1D7B02.dita" id="GUID-33C5C597-F599-4AF1-BF1A-13E1F38F8B49"/><topicref href="GUID-54042C84-6216-5930-9CBF-BAF635CECD4D.dita" id="GUID-D18DAD39-A791-4068-A09B-4CE3B01C0C12"/></topicref></topicref><topicref href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1.dita" id="GUID-1811B26F-B5BA-41C8-ADBE-86B9DB2D0AFC-GENID-1-2-1-8-1-1-5-1-1-20"/><topicref href="GUID-A04F46F8-1BA9-5A77-B455-59C67DD4AA36.dita" id="GUID-6004A8BB-96A1-4B2F-AB96-9F34EC0037DE"><topicref href="GUID-B345CDED-92DC-50ED-BC87-AC3C903E5E10.dita" id="GUID-F6DA8DF8-06A5-48DF-81FB-D5EB1FAA771E"/><topicref href="GUID-0C8C41EC-A8ED-5916-B944-DDDF20FADAF4.dita" id="GUID-F76EDDE0-6ACE-404B-8F9E-AA97F76D125D"><topicref href="GUID-6DE69F29-45B0-5E62-AA13-DA4041B1BC46.dita" id="GUID-A6E6D33C-2599-493C-B4C8-4E7CE8629156"/><topicref href="GUID-AB9175EB-1B61-5341-B6B9-5613A7862D74.dita" id="GUID-A032BC6E-1F42-40E5-89B0-2F0085B4C29A"/></topicref><topicref href="GUID-F8E8CCB1-E239-5285-BA99-48E2168C9E31.dita" id="GUID-8490FA3E-E954-4C2D-B925-739097BC9758"/></topicref><topicref href="GUID-669C77A3-89BA-5321-ABB1-4356A5FE478C.dita" id="GUID-DAFBE23F-F3F6-43D7-A2E5-79E128F37801"><topicref href="GUID-1499E635-B6E3-51A0-AE38-ADF99FF86CD6.dita" id="GUID-854946D6-D026-40B5-B0F8-A3DADDA414FE"/><topicref href="GUID-6D75968E-53CF-5436-8390-54CA12BCFDE9.dita" id="GUID-18BA883E-1BB8-41EE-B853-3CDD254C224E"><topicref href="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita" id="GUID-A8A8730A-A07F-41E7-BAB6-C6221DE05FBC"/><topicref href="GUID-ACA48BEE-FE73-5C47-B022-E50728CEDBEE.dita" id="GUID-18622E69-CCFE-4CCA-8043-A203AEC7E6CE"/><topicref href="GUID-8DC12024-7599-52E8-BCF1-D9D765EC7B9B.dita" id="GUID-5E71ADAA-E5FE-4F71-8DB3-45DA1B787EED"><topicref href="GUID-15FDDEED-89F1-5BE5-97AD-8DFD3640369A.dita" id="GUID-4B35BDF8-59DF-4BB9-B72B-699176060440"/><topicref href="GUID-4AEF7595-17C0-513E-9568-B212E6194388.dita" id="GUID-D1F884D4-4D41-4549-885A-A7AAEC1046C1"/></topicref></topicref><topicref href="GUID-3335663A-BC11-556E-B5A6-F83622AE34C3.dita" id="GUID-FC94197F-2318-4B4D-B770-494DD2AEB73C"><topicref href="GUID-B4C05C46-F2C9-57FA-AD85-EFE6479C2FF1.dita" id="GUID-27CAF3A5-F640-4605-98F6-FBE0E7FB5813"/><topicref href="GUID-C6ABE2CA-901E-55F1-9837-7018A1612BCF.dita" id="GUID-4AE06F77-C7D8-48E8-B987-E4D4ECF06F97"/><topicref href="GUID-1138D29D-2EC5-59DF-9AA7-2D863FBC024F.dita" id="GUID-C5B08289-EA65-4859-9033-3ACE7338F555"/><topicref href="GUID-AC560324-798C-5D0A-B23D-2419A7688A5B.dita" id="GUID-C66E4EF1-2E4D-4C9D-95CC-B64D5DAD1038"/></topicref><topicref href="GUID-73B853D5-13E6-54E7-AA8B-C41EEDB5EA7F.dita" id="GUID-EAFFA332-39CD-44E7-8FAE-9A73E8CA7197"/><topicref href="GUID-D477EB1F-89CF-5836-BAA2-6D731D50D99F.dita" id="GUID-039B303E-052B-409F-BE96-C0CFE65F72CD"/></topicref><topicref href="GUID-F84E18B8-5883-5A3A-A9DB-EC25BB86149F.dita" id="GUID-C5603DDA-2566-484B-9821-83F306466608" type="topic"/><topicref href="GUID-C06CFF3E-23E9-5E0B-99A1-51B8ED95465F.dita" id="GUID-948D5918-A576-4E94-8C4E-9FD6D961B239"><topicref href="GUID-796CB42C-29AC-5ECC-AC6E-35FC6B8CC84E.dita" id="GUID-1CA093E5-696A-49F0-BC2A-BAF7845EE5E9"><topicref href="GUID-AD195629-81CE-5E57-A59E-C67AACF7A2C2.dita" id="GUID-E15C86B0-A3AE-4480-BD2F-707EFF11FF7F"/><topicref href="GUID-ADB848FD-317A-521C-9684-BBCF20358207.dita" id="GUID-F244F3B3-2BF2-4514-94C5-64CEB9330F91"/><topicref href="GUID-834781AF-D202-5752-B81A-A51D12A4D1EC.dita" id="GUID-27B8E5A8-BA90-4F65-B231-85AB8B55DBF4"/></topicref><topicref href="GUID-142C21E1-2629-5215-9FBD-B507436E17DB.dita" id="GUID-999E4E76-00D3-477B-B10E-5A9648373C68"><topicref href="GUID-529757E6-ABF2-5C5C-A995-7DED6D298F52.dita" id="GUID-1A2CA103-A5E4-46B4-8CBB-F357B8F075CA"/><topicref href="GUID-7B9D4E46-6AF9-5B77-9BE3-8B1DFAC588BD.dita" id="GUID-754BF5EE-4CAF-4879-9E84-42817D780140"/><topicref href="GUID-F20D5802-7B83-5B78-8753-A88E74E28398.dita" id="GUID-6E9EE509-21B7-436D-9194-394327D87CB6"/><topicref href="GUID-02B40662-B5F3-59BD-832B-9A28FE3B51C7.dita" id="GUID-CB785176-9D51-41B5-8332-851AC9BBAC0F"/><topicref href="GUID-F8BD699A-E926-5434-9F35-3DC6DC9FFBB6.dita" id="GUID-8F1692B2-7E4D-4894-9ABE-D65BB702677B"/><topicref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita" id="GUID-606DC0D1-864E-4742-A428-3857B8166F1C"/></topicref><topicref href="GUID-ADC42B89-B061-50C3-B532-6065A0C418C3.dita" id="GUID-0A15B343-7F98-4C7B-ABA6-DA9B354E8378"><topicref href="GUID-919E48BE-6AA1-54CC-8B70-3A4B3A9C6CF1.dita" id="GUID-9AEDCED1-221E-4955-A18E-285BD686774C"/><topicref href="GUID-FDAED7A7-3D93-5B57-9879-DF8BDBE8A9BD.dita" id="GUID-9DD1D360-6D60-4DEA-ACAF-ED53F79364E3"/><topicref href="GUID-18DD4FE5-6641-5A0E-A00E-DC0C00639CE4.dita" id="GUID-56432425-09E2-40F9-9FB6-198BD0F7049B"/><topicref href="GUID-5F614B75-056D-5798-AE06-8DA6E9ED6834.dita" id="GUID-4176F59B-8CE1-4DE3-AD21-4A5211C7A329"/><topicref href="GUID-0A9C35DA-DF54-5885-AFE0-F4D5B3E49941.dita" id="GUID-F4F39757-101D-4D0B-80FC-73C2823492C2"/><topicref href="GUID-9597DB22-D932-5A58-9C3C-4E5FCA244253.dita" id="GUID-9D46B7B2-F181-43C4-BF4D-DDCDC7079A5D"/><topicref href="GUID-6E89E787-749D-5AC5-957D-967B4B9ACD74.dita" id="GUID-3A9A6144-0411-41B1-9ADC-E0F3828EF904"/><topicref href="GUID-4C4515EA-A5DD-56B4-94B0-EE48D66013F7.dita" id="GUID-7784039F-68B9-4BF1-B595-F3E6A7D76EA0"/><topicref href="GUID-0C80F447-B82E-5586-9B02-4BC0D365FFD6.dita" id="GUID-55F20FF4-A967-408A-AA1F-76576AB8F823"/><topicref href="GUID-BE73CFE6-D48D-5B92-AF49-E2D967ADF0EC.dita" id="GUID-15C3F4BC-1581-4695-8519-5DF478195C79"/></topicref><topicref href="GUID-BF86E9F9-531A-51A1-90B4-23B51604F5B4.dita" id="GUID-2F9C8382-D9AE-4867-AA18-FB522119F729"/></topicref><topicref href="GUID-2D977A02-5928-5441-8AE7-42A722F2A4B8.dita" id="GUID-CD73DE4F-8B0C-457E-92C6-420892D0952E"><topicref href="GUID-B7C56FF9-FE1B-58C3-BBD4-7479F0BEE555.dita" id="GUID-AA7610B0-DBAF-4619-A1C7-37D67C9AC1FC"><topicref href="GUID-9D4B8CDF-60D7-5952-AAAF-94A3C1E8908F.dita" id="GUID-3B3A26E4-5089-4BC1-B79F-16CE818D9AF5"/><topicref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita" id="GUID-350D059F-C33B-42E0-BF1B-455CE41D2E8D"/></topicref><topicref href="GUID-05DAF5EF-6F2E-562D-9DB1-0985AD4A1E48.dita" id="GUID-B64115E0-E3BB-4CBB-9F13-4E57FE515A0F"><topicref href="GUID-52583CC7-483E-54B5-8094-F0F61BD46B7F.dita" id="GUID-BD523DD2-0F5B-41A9-B8F1-5AE37A3E04CA"/><topicref href="GUID-124AC7EE-E227-5358-A755-628FFE257250.dita" id="GUID-F12BA07A-4BC2-4DDD-8A5B-5FDD2469B462"/><topicref href="GUID-A7ECF51F-F96A-5251-A71F-2F269C8C0664.dita" id="GUID-30818FFE-4F73-4B63-B447-F72125A8030D"/><topicref href="GUID-C661B40F-1439-587F-9E8E-DB2DFC79C040.dita" id="GUID-821F790A-12D6-463B-80A8-81B08B9EE955"/></topicref><topicref href="GUID-95CE7187-66B2-581A-A5B8-6359AD431E87.dita" id="GUID-CADB4911-E9BE-4AFF-9CDD-659370319D49"><topicref href="GUID-857F981E-711B-5CA8-AB37-5C700A6140FA.dita" id="GUID-765F086E-3340-4FE6-B97C-4B2C0DB2FD7E"/><topicref href="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita" id="GUID-C37A0E90-6B70-4BDF-B71F-D98C39C22187"/><topicref href="GUID-F8B8C030-B5E1-5EB3-A672-83BF35555801.dita" id="GUID-361805F1-672A-49D6-8B57-F73CF9FFAF85"/></topicref></topicref><topicref href="GUID-3046453A-AB3A-5491-87A0-00F3514D4768.dita" id="GUID-8E975352-C697-4092-8865-9CB400DE1A8F"/></topicref>
+</topicgroup><topicgroup id="GUID-92B13AFF-775C-4FCF-BA8C-B8B882930B83">
+
+<topicref href="GUID-898704CF-26A1-50F5-BEFE-1E29D85064AA.dita" id="GUID-01AC46DF-C2A0-4C7E-B2C9-79256939219B"><topicref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita" id="GUID-6F5E480E-0AE0-4C5F-AE2C-595DBB3E9C34"/><topicref href="GUID-003D2C5B-09DC-5BD1-AF45-A0FCB56F567B.dita" id="GUID-7D44D6FF-AE28-4DC2-9D3C-B50E6F7253EA"/><topicref href="GUID-BF04B68E-7F77-5D99-A0F6-2842758EFD4D.dita" id="GUID-75C81C3E-8D6E-4727-B487-87E72EB5A1B5"/><topicref href="GUID-922E4771-C1FD-5C88-9C11-57499684DB97.dita" id="GUID-54FD61D0-4D9F-4554-9F58-657102B8C59C"/><topicref href="GUID-7AB0C7E2-8B7C-5CC3-BAA5-15AA59F31181.dita" id="GUID-DC043E55-DCD4-4113-8FD0-71FBF38A56B0"/><topicref href="GUID-51C5DC6C-0CEE-5F44-8578-AEFBEF90FA4D.dita" id="GUID-410EAFD6-DF61-4889-A027-2CF01AB7A832"/><topicref href="GUID-CC04A14B-A839-5613-820D-F1E65EB2DF7F.dita" id="GUID-41C7FABE-4879-49E7-832E-7CAA462BB28B"/><topicref href="GUID-9CF985F1-C100-5999-9410-58B7865A1E18.dita" id="GUID-9435998E-79FC-45F2-8F31-F0FA8B11BE47"><topicref href="GUID-E1FEEDCE-0CD5-559C-9AE0-8090A613C166.dita" id="GUID-B7C975D6-2C41-4DED-B1EF-A86F72E7EA53"/><topicref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita" id="GUID-61D2AF1B-3C73-4CF0-9061-83A5FC751B23"/><topicref href="GUID-52702561-DA37-5381-BA0D-76D9A41B2760.dita" id="GUID-EAFB0FF0-53BB-4D3B-A9F0-8508D981D5BD"/><topicref href="GUID-E3C70135-EC0C-504C-B428-53A5750B520B.dita" id="GUID-722D85C4-772A-43A4-B14C-9107083D8909"/><topicref href="GUID-DB441DFF-0075-5122-A2EB-A6EF76375D71.dita" id="GUID-0F406F49-AE5A-4A4C-8DB0-865A0DC56E7B"/><topicref href="GUID-BBEA9F6B-2F0C-584E-BF12-256E27605499.dita" id="GUID-5F2B67EC-EB2C-4758-91E0-A19D4F6D37FE"><topicref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita" id="GUID-1C97A9A2-BE1A-4442-9AD6-148260CB3C1E"/><topicref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita" id="GUID-AA89E111-F777-41DF-8383-5E33C24095E7"/><topicref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita" id="GUID-6F773BB7-F8A4-4E05-A9D2-5A99D6C2BF5A"/><topicref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita" id="GUID-F4F9539F-8EA7-4EB2-9D8D-3526ADF664C2"/><topicref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita" id="GUID-78648F79-00EC-4780-8AC4-D3DFDA052DDD"/></topicref></topicref></topicref>
+</topicgroup><topicgroup id="GUID-6738F046-FC46-4EA5-ADC3-4F825AD64C2A">
+
+<topicref href="GUID-E96E4542-7017-4069-BD9C-97467A99F211.dita" id="GUID-4EA3767E-BC4E-4CFC-A371-BC1CC73AD6E9-GENID-1-2-1-8-1-1-7-1"><topicref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1.dita" id="GUID-7D29CFCE-3A23-4E78-898A-CDB0B9CCE498"/><topicref href="GUID-9D26E38F-5C7B-5330-A54B-8F97D0F204D0-GENID-1-2-1-8-1-1-7-1-1-5-1.dita" id="GUID-9436B6C5-9044-4EB3-B251-17F02E74D647"/></topicref>
+</topicgroup></topicref>
+</topicgroup><topicref href="GUID-CF710BE5-531D-4287-9002-39E7DE27FACA.dita" id="GUID-5E8DC915-2473-40D6-9750-CD862C16CBF2"><topicref href="GUID-73D9E2F2-5965-479E-97DB-C3773DA0D90C.dita" id="GUID-9AAB4773-C94A-41DB-A089-7368B8A36FD9"/><topicref href="GUID-79620372-BADC-4826-A3AC-7FDBCFF98DA9.dita" id="GUID-04060E12-A96B-4326-A197-A3339ABD0D6A"><topicref href="GUID-687997B5-BDFD-49D1-947B-4AB21C3AF58C.dita" id="GUID-44005CD0-56F8-44E7-861C-A76BF447B7A0"/><topicref href="GUID-7AB51180-7A1A-40C7-B28F-EA46314A6E5B-GENID-1-2-1-9-1-5-1-4-1.dita" id="GUID-6E13B858-073B-4445-992D-CDDC37A838DA"/><topicref href="GUID-F75F975B-A490-4EB5-96CD-B2F8DFC63C7C.dita" id="GUID-42D21B0B-6A97-4810-8D73-6ED61ADF28A7"/><topicref href="GUID-FD8634B8-E522-4AC4-8129-ED807A7754A2-GENID-1-2-1-9-1-5-1-6-1.dita" id="GUID-F53AD281-A48E-4040-9553-23601AB7F9CB"/></topicref><topicref href="GUID-C22974D8-CFB9-4A83-BE58-CCC97EA8DF13.dita" id="GUID-BFECEE09-81FA-48EE-AC05-BAB266D9CDF7"><topicref href="GUID-CA788AFE-D425-4B72-B8A2-34D38A8C341B.dita" id="GUID-DFA44ED5-0F47-40EE-AF3D-0FEFEFD876B2"/><topicref href="GUID-0F17BCDF-CF50-40D1-9048-793DC4442B50.dita" id="GUID-0CC7BB86-A8CE-4EE6-949E-2CCC4112DE79"><topicref href="GUID-2ADB873A-1580-476A-9642-AB47D13D4A98.dita" id="GUID-B9D10AD5-A397-4D39-8CC1-48F322AD734F"/><topicref href="GUID-9B52E0C3-9EBB-44C6-A1BF-2F95711FFBA4.dita" id="GUID-7755993E-E905-4B3A-B176-FF5D3D770B99"/><topicref href="GUID-67CFF27B-55AF-42AC-95AF-E71A7C54039E.dita" id="GUID-CFF13F2A-611A-42C7-9571-3A0EDAFB79C0"/><topicref href="GUID-AF245763-EB25-49BC-90DC-0BD5F2D22AA5.dita" id="GUID-425BB484-70A6-41BC-BAFF-C74B9F643D71"/><topicref href="GUID-388004AF-6F99-4BBB-A8E0-D75DC5B6790C.dita" id="GUID-130BB4EC-0429-4C54-832F-6373EE854A36"/><topicref href="GUID-BC0936D7-7064-447D-83EF-68C65CF3D1B0.dita" id="GUID-6B04CE17-54DD-4B95-9AA6-8FC0AFF03E8A"/><topicref href="GUID-0AB3D313-79FF-4716-AFD4-FF3AA3C2E936.dita" id="GUID-D88CCA02-90F5-47E1-942C-A53634A7E8A2"/></topicref><topicref href="GUID-CB3A8650-751C-4DAA-9408-7AEB3C7FD41A.dita" id="GUID-23BA583E-1538-47C6-A9F7-99036D800F25"><topicref href="GUID-C38DA704-8868-479B-AF81-375E0A2F5BCC.dita" id="GUID-A765849F-50F3-4EDD-AFF3-C85DC3E0364A"/><topicref href="GUID-B94FFCA4-1EB3-46A7-9FF9-54C55D67FFE8.dita" id="GUID-DF959C90-A929-484A-AFC7-85326FD91528"/><topicref href="GUID-DA382265-232F-40F4-92ED-C90E6DE3D709.dita" id="GUID-4146AD25-F4F3-4AEA-8E61-92029C766FC5"/><topicref href="GUID-22CCA5B5-D4AB-4ABC-94C6-CD85EC470238.dita" id="GUID-5631F3CE-93A5-4485-8869-C0779F841ADA"/><topicref href="GUID-A4179FF3-4541-44B8-A8F3-52C1318159B3.dita" id="GUID-A4E23011-F48B-4C47-BAD3-6B1439A1C6E3"/></topicref><topicref href="GUID-0346036B-A470-4C18-B276-3A3485F6A069.dita" id="GUID-5DE2D211-FE2B-4400-9F4E-56AD72754EEE"><topicref href="GUID-C244D421-8BD0-4212-A5C5-47A8B1E0C1E2.dita" id="GUID-93D43510-5813-4FD9-AD58-5944E31361A3"/><topicref href="GUID-D1C5BB01-6780-41D6-B47B-43D4C983B0B6.dita" id="GUID-B0F107DD-DE9B-410A-80D2-FFCC2538FF6F"/><topicref href="GUID-65F012C2-19BA-474E-8E94-D0E89DADF7B8.dita" id="GUID-9FD2D932-CEF9-4F99-82CC-B6A33434D5B0"/><topicref href="GUID-3102F778-DD2F-4C87-A0DF-7FA44C9709D8.dita" id="GUID-216C856A-5327-45A0-9781-303B0C5AD409"/></topicref><topicref href="GUID-EBF4F1F1-F76B-455B-B8EE-B7965CF0717E.dita" id="GUID-8198D1C9-E6D4-4020-B1B5-B75C51560E0F"><topicref href="GUID-D207C135-EF02-4D1A-A48C-4AB8C6703496.dita" id="GUID-3C0F5C6B-2CA3-4AAA-ABD3-03279EEEB390"/><topicref href="GUID-32B82E5C-FD53-48E6-9ABC-88F82ACF71BC.dita" id="GUID-63290962-F9EA-4EEC-B736-4C1D1CA97297"/><topicref href="GUID-D291C9E9-5207-4B23-B287-C240464087B9.dita" id="GUID-193B9AC4-6341-4080-9B45-30F286BE799A"/><topicref href="GUID-C98DF912-A903-4FDB-B27A-CC8E75E3E40F.dita" id="GUID-197F926B-408A-4561-B633-383C52DB99C9"/><topicref href="GUID-8798F896-E0CB-4B9B-8F88-3C8B58574213.dita" id="GUID-AB885336-020C-4457-AF70-F1F9C2F2B63E"/></topicref><topicref href="GUID-E90DBF35-0A05-4751-904D-4F06987FFF48.dita" id="GUID-E5CEE289-BCDC-415A-BCD8-35B061653D07"><topicref href="GUID-0A6C8DB8-ED41-4243-BA96-CA691CF9CD19.dita" id="GUID-DEB7F170-A01F-4076-AC6A-9AEC0DA79F1F"/><topicref href="GUID-53649311-4465-48B5-8D07-A65515950040.dita" id="GUID-400FD70D-CC62-48F2-AA2B-EBACD0BB54D2"/><topicref href="GUID-C3C89BD7-A56D-4597-8804-01A25BC71581.dita" id="GUID-4AE337DB-1097-47DE-9972-F434CB032532"/><topicref href="GUID-D1F7D21F-BA9D-482C-9B58-7C53A680145A.dita" id="GUID-CD552B92-4390-4FB9-936A-B4FE248DFB2B"><topicref href="GUID-C649DB97-F138-4C90-B177-16590F2E3F19-GENID-1-2-1-9-1-6-1-8-1-7-1-3-1.dita" id="GUID-7FC70EE3-DFDD-4E04-A009-BC3CC8299917"/><topicref href="GUID-58AA7257-0951-42AB-9B6E-AAF63343FEFA-GENID-1-2-1-9-1-6-1-8-1-7-1-4-1.dita" id="GUID-D6AE2F52-C3B1-42C2-B114-D2F0A8279C09"/><topicref href="GUID-6AC01B10-92C1-4E56-813B-6853DFCF3386-GENID-1-2-1-9-1-6-1-8-1-7-1-5-1.dita" id="GUID-F0D5475C-5F11-452D-BDD5-7580BBE89F24"/><topicref href="GUID-C74770A5-ADD4-4AB1-946F-77105E2B8C10-GENID-1-2-1-9-1-6-1-8-1-7-1-6-1.dita" id="GUID-ACEF0ECB-046F-4FE1-A6DA-05528638BA04"/><topicref href="GUID-E7E67A52-0725-446B-A49C-CF571C4A0C64.dita" id="GUID-D821B751-A2A6-47EB-8A62-F4E5A9D9CA6E"/></topicref><topicref href="GUID-132349A6-9A5F-4866-A54D-F01B6F58ABDD.dita" id="GUID-C1FA8310-111E-409A-BE71-E2E3AB4469EA"><topicref href="GUID-43782364-0865-43D0-BC89-D63BA9912FB6.dita" id="GUID-B1397C03-3E7C-42FE-8D8C-4A0A9A5C8927"/><topicref href="GUID-A87D9280-B61A-49BA-A9AF-178DB9BAECBC.dita" id="GUID-BE49DD4B-CFAF-4709-8232-BC4F183ED641"/></topicref></topicref><topicref href="GUID-CFE0A4EB-845C-43B6-A732-AA155AFD99D6.dita" id="GUID-D2317797-5339-45C5-8991-A93F4AB0B468"><topicref href="GUID-2648B61C-6EBD-4668-AACD-EA4B2C435BB2.dita" id="GUID-14B6988F-BC7D-44B2-BC25-1F7AC7616CFE"/><topicref href="GUID-7AB51180-7A1A-40C7-B28F-EA46314A6E5B-GENID-1-2-1-9-1-5-1-4-1.dita" id="GUID-84DCF804-9E4A-4552-809C-EF2E95F83584"/><topicref href="GUID-4DAC39E0-2EC2-40F7-9AEF-4FDA09F1A151.dita" id="GUID-B06177AA-D92D-4DAB-948B-D7DE3D765693"><topicref href="GUID-0E93319A-439E-49D8-BF38-C809FEE4BB74.dita" id="GUID-8D237467-8C8E-47DD-A50D-F8B912CA6B4B"/><topicref href="GUID-3A785F02-F4AA-432C-9331-8827029BB384.dita" id="GUID-031ED607-9FB5-49B9-A08A-65BDFB851F14"/><topicref href="GUID-30978E00-D244-44CD-8F4E-9676DF172A52.dita" id="GUID-538D250E-5E18-42BF-AA0A-47A109518BC8"/><topicref href="GUID-F7249C66-B62F-45DF-B733-BC6D5FCDA003.dita" id="GUID-D306F483-3C7D-45C2-9E7B-E8D305637A26"/></topicref><topicref href="GUID-F367F6C9-66F7-4061-81A7-0C845D8F39C4.dita" id="GUID-F698F361-0B2F-4A0A-9AB5-34DF138B4DD1"/><topicref href="GUID-FD8634B8-E522-4AC4-8129-ED807A7754A2-GENID-1-2-1-9-1-5-1-6-1.dita" id="GUID-440AEAE7-F96C-4277-9FE7-ADECE65B90F4"/><topicref href="GUID-B97BAC2E-04E3-4979-BACE-9C46BADE912E.dita" id="GUID-59A47D48-DCFB-429C-92F9-E2BCD0B8AA20"/><topicref href="GUID-1AFAD1C4-340B-4119-94A8-F50E9D8DA8E6.dita" id="GUID-EB99764E-515A-4E7F-BE9F-319345396E03"><topicref href="GUID-F54BB3B5-D069-4524-A215-6F2CCA372666.dita" id="GUID-DE4256A9-B89D-4639-AFC3-159C534B1791"/><topicref href="GUID-6752A77F-B1D1-49BE-A672-5DDE3B7976BF.dita" id="GUID-0082BE1E-F559-4D28-A981-882F4990316D"/></topicref><topicref href="GUID-7DDF052C-2520-428D-932D-BDB476344575.dita" id="GUID-DE76A056-C1AE-4C3F-B9D3-F14294AD98C8"/></topicref><topicref href="GUID-660A8E4C-F930-415C-8CCC-CB1DCCAA2442.dita" id="GUID-1489D6C8-7F30-4193-AE9D-99192FB48699"><topicref href="GUID-8FA1B2B0-5842-4D5D-BD61-C2D79B56ADC6.dita" id="GUID-FC64EFF4-E151-41B1-B62E-8D92C7F21117"/><topicref href="GUID-F09740DA-015B-449D-A124-0BEABBDDCB52.dita" id="GUID-0F02FEAB-4C62-4E79-A75C-E6E0FDB5AC68"/><topicref href="GUID-6E208C69-AC2C-4A7A-8203-2C4C3F2E54F5.dita" id="GUID-F55F9A23-C0CC-442D-BACE-9C24BE768E14"/></topicref><topicref href="GUID-D003030D-8506-4210-9194-7A3819205D68.dita" id="GUID-93E87552-B490-4782-852C-53B3C711D98A"/></topicref><topicref href="GUID-26714A57-B6B4-5E81-B512-FB520718482B.dita" id="GUID-94D17704-8F52-47F4-8F3D-53CCE34E36F1"><topicref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita" id="GUID-E2E419C9-E93E-4D8A-AAD0-709B3840B422"/><topicref href="GUID-892931C3-E560-54AA-A9CB-2820BF025E52.dita" id="GUID-EB34D5B3-CDBC-4E9A-8BE9-66B007863914"/><topicref href="GUID-1E822A8F-3144-509D-A949-BDAF4BB9634A.dita" id="GUID-ABA40F5F-5F33-4D13-8D0D-24467C4868A3"/><topicref href="GUID-DC2CF276-95E2-5810-9B8D-EB8B72E04FEC.dita" id="GUID-6B96DCF4-711A-432A-9351-A7BA9E551F45"/><topicref href="GUID-772C2721-DD84-54A6-ACE0-ECACC6432B95.dita" id="GUID-8F6CC7EA-5B60-46D0-80CA-BFE668B5D765"/><topicref href="GUID-1E43E258-A926-5D24-B0A5-8756491C687F.dita" id="GUID-201FFEA7-F3C5-40E3-93DF-3831E214948B"/><topicref href="GUID-DA62FD4F-2E74-5B2F-B703-4A40DF5F01CA.dita" id="GUID-7DB6C376-BDE8-4648-B9B2-3D70DAAE37DD"/><topicref href="GUID-D520CBC3-FCAC-5A53-AE1A-E5254ABBC6A2.dita" id="GUID-F520B634-8987-4694-B0F9-15C48E9D9078"/><topicref href="GUID-49379616-C235-598D-AE43-668998AD072B.dita" id="GUID-18852E5C-BF9C-42A8-BB34-8904BF07E68A"/><topicref href="GUID-7ECDCF7B-3B2A-561F-9136-04BC4DAE46E4.dita" id="GUID-E025F533-6B85-4760-9C93-7BA1F031E9A1"/></topicref><topicref href="GUID-DC8D3736-EDCF-54CB-A614-2AAC4664F1CA.dita" id="GUID-4EF3B0D2-5E50-46CC-A7D2-BE4D3373516A"><topicref href="GUID-8EB25927-D49E-578F-BD93-294C4EECB7E7.dita" id="GUID-AC5DD4D8-D99B-4445-9524-B89E2C2A058A"/><topicref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita" id="GUID-AD4F0854-946D-469D-8A3A-21276E7C0868"/><topicref href="GUID-12EFB295-C527-5F96-81F1-6021D335D865.dita" id="GUID-7DBCECFE-1FC8-4EB1-B63C-98A6C84B9BFA"/><topicref href="GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D.dita" id="GUID-9139F4CF-2412-49E1-BC0E-5D382C0BA89A"/><topicref href="GUID-178E140F-BB15-5A82-99A6-D1BC0E11E018.dita" id="GUID-86A7A5AF-1E01-428D-BF62-31EA29641740"/><topicref href="GUID-51514A4B-0220-557B-9F7A-FB110CEFEF10.dita" id="GUID-AB858CF0-88AF-4025-AABC-8421641984C3"/><topicref href="GUID-AD2BD987-E097-5E1F-A914-B91CFB706D51.dita" id="GUID-DF6DFCED-C705-42EE-89B6-E28109083676"/><topicref href="GUID-F123D574-44DE-528A-806C-DB64229BCEA2.dita" id="GUID-FFE094BD-60A4-4405-94BC-C579805717E3"><topicref href="GUID-B35A70D2-1BC8-51DE-95BF-F315DB394582.dita" id="GUID-535C6E11-6E2D-403D-8C08-272C782028C4"/><topicref href="GUID-6F82A35E-9F11-591D-AA5C-8F60734A2827.dita" id="GUID-C9494F00-2DFC-40CA-AA96-76C14600D829"><topicref href="GUID-4AFDA3FF-38D1-5EFE-B18A-E3EAAA52EB75.dita" id="GUID-00E29B39-EA1D-49DE-9408-5D855135749A"/><topicref href="GUID-7A50630B-2B44-5D27-AA18-3BEEE1453020.dita" id="GUID-39B47DED-ECFC-4EDE-9ADE-14CBB720D5F1"/></topicref><topicref href="GUID-795B8649-B6C3-5540-B52A-9B460F35A5B5.dita" id="GUID-9B5160D0-6EED-4482-842E-ED5516F9F2C4"><topicref href="GUID-1A72F75A-1930-5C32-93B7-20F4934BCFAA.dita" id="GUID-3716080B-393E-46FC-BC4F-C453C5D3A478"/><topicref href="GUID-0AFF5666-6BF9-5022-ADBC-5EFFA743B288.dita" id="GUID-B39A9D60-8006-44A4-AE00-84EE7039AFC9"/></topicref><topicref href="GUID-CE9EA167-0594-5E61-9640-6B2B63A92EA7.dita" id="GUID-20232928-7B50-4083-8C94-D13034695CBD"><topicref href="GUID-E21E7992-607A-5A49-B022-189ECA9E76D1.dita" id="GUID-E050FBA0-CC8A-4C54-BCE7-6094227BDA70"/><topicref href="GUID-BDB847A2-557A-5902-AA6D-C1AE10D8E493.dita" id="GUID-61E143FE-C82D-476C-AF30-E6C546ABC6B6"/></topicref><topicref href="GUID-2B7D04D9-98DE-5284-836D-01DB4FA8949D.dita" id="GUID-4C8137D6-7282-4B92-BB6C-FB0A1A695AB3"><topicref href="GUID-592B6D20-4ABA-5C79-9734-D18E2CE4A86C.dita" id="GUID-028A71CD-1FB6-4F29-B1BD-98AEA2458C88"/><topicref href="GUID-6381BC82-3060-5023-8221-79B18CCB2CDB.dita" id="GUID-5E4EB6C8-9EBE-4300-8F47-37C74345D7D1"><topicref href="GUID-ACB79CEF-CA4D-5C96-AFCD-6AD7C7C26C53.dita" id="GUID-97039AC1-298F-4066-9B3C-C045EA531DD9"/><topicref href="GUID-8A5EC98B-E9AD-5496-9909-7C3B35610785.dita" id="GUID-7CC4A177-E219-4506-B58E-AA9AB5A191D5"/><topicref href="GUID-817E0561-6165-5BB1-97F9-AD53CFCDAA56.dita" id="GUID-33AD1449-DFBA-41CE-9D3F-ACA12B7F8AA0"/><topicref href="GUID-EF73C56D-AEB1-558B-BAD1-D076BA6EA889.dita" id="GUID-F640CDE9-84D1-4E60-91B1-71A357741FEE"/><topicref href="GUID-FBE6E61F-5A2E-5A7A-BC59-51F072EBED7D.dita" id="GUID-892F68A2-7E01-4BB5-9583-65BBA4260458"/><topicref href="GUID-7C533836-0D27-5519-BC1D-7153AC8BE4C0.dita" id="GUID-51717262-936C-487A-8DE7-29262F1B9F10"/></topicref><topicref href="GUID-2D8B8FF1-7A35-5E98-BDDB-2B0BD8DE6215.dita" id="GUID-3D0D7F24-0C3A-474F-9318-DE8931F9276F"><topicref href="GUID-1391CDCC-9A09-54FB-BA7D-BC7A91DB2351.dita" id="GUID-D9665642-2477-411C-931F-2638D610BDC3"/><topicref href="GUID-16423056-C435-5C4D-BE3D-4A15F95F7F68.dita" id="GUID-B3836685-C33A-43C1-95C5-F7123D9A136D"/><topicref href="GUID-6EF762B8-DE93-51C0-8A5D-89FC5289B7D0.dita" id="GUID-258BC0EE-1FD7-4F36-A4C6-A09D5AE683A9"/><topicref href="GUID-4862EA2E-6BFE-5E11-B527-7EBA94BB0EA2.dita" id="GUID-D642BF04-F3E0-4B75-9ECF-4C90C387CB1B"/><topicref href="GUID-6B9041F7-79A6-5CCA-9B4D-B8EF377FD378.dita" id="GUID-B2C22F4A-AA35-4DA4-8B12-71D50A4863FA"/><topicref href="GUID-E7C55048-5B7A-5BF2-B7F4-4D731659B88C.dita" id="GUID-79E4CDD2-1C99-417D-BB60-BCC1E18FE0FE"/><topicref href="GUID-44540C74-CD73-5D8E-A9E0-F90F46B4E7B1.dita" id="GUID-76B0C335-13B7-486D-A5AB-13D513BAD2BF"/></topicref><topicref href="GUID-BA0AC9AA-A8E1-5650-9512-DEC06D77668F.dita" id="GUID-24827ECB-675E-44E7-837A-D938789D9659"><topicref href="GUID-85C18DAF-DB76-51C6-B38D-A802E314F4D1.dita" id="GUID-8708A3A2-A49F-4578-92C2-06A4013FCD59"/></topicref></topicref></topicref><topicref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita" id="GUID-F4EEDCE8-7543-44A9-B122-E26FE912EB4E"/><topicref href="GUID-26621CA5-B686-53FB-AF3E-96CDD38C8520.dita" id="GUID-0C965769-8AE9-4CC9-BC0D-BCE4123CEB45"/><topicref href="GUID-5E358AB4-03A7-5859-ABF2-A8B64B74AF56.dita" id="GUID-C3466DC8-5793-4137-95AE-8984974DFA47"/><topicref href="GUID-D2163920-D448-5BFC-B655-B654FD657A94.dita" id="GUID-CC4B9207-6A8B-4638-B7BC-AE5031B0799D"/><topicref href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1.dita" id="GUID-1811B26F-B5BA-41C8-ADBE-86B9DB2D0AFC-GENID-1-2-1-9-1-8-1-16"/><topicref href="GUID-A90D9D85-53DC-5368-89F2-137BE5D50745-GENID-1-2-1-8-1-1-7-1-1-4-1.dita" id="GUID-96EA3E19-7D36-4841-BF61-97F0163CC4DF"/><topicref href="GUID-63456B20-3A61-554A-BBA4-C23B176E39A8.dita" id="GUID-F84FEC86-86D0-4155-A31C-1F8749252367"/><topicref href="GUID-9D26E38F-5C7B-5330-A54B-8F97D0F204D0-GENID-1-2-1-8-1-1-7-1-1-5-1.dita" id="GUID-C8FB9274-A102-4AE9-93A4-F6AEF6883547"/></topicref></topicref><topicref href="GUID-A74F0245-1A37-41C8-B0E9-63AF858EE4B6.dita" id="GUID-C6148EB4-F37A-4C55-973B-64CBF64A5B5B"><topicref href="GUID-95BD3650-08CB-407D-969E-DFDB39B2FEFC.dita" id="GUID-0ECC5FF9-4976-4249-B9B6-B37C7E9AA2B2"/><topicref href="GUID-775901A4-0262-4E14-9E9C-C4E37DFCCF2E.dita" id="GUID-2FE159D8-4E65-48ED-92B1-4F07D1B463A2"><topicgroup id="GUID-2DBE65EA-2873-4D2C-ADDB-EC4D4ECA011E">
+
+<topicref href="GUID-450BF1D4-85D7-45D4-8893-57DA8F1640E9.dita" id="GUID-5FE14657-CFCF-4CDB-A76C-9AFD4CDB7FC6"><topicref href="GUID-6060F138-CEB6-482A-B0E9-BBBE261568B0.dita" id="GUID-E2201790-F971-48FD-BA40-5CF5A25BF80A"/><topicref href="GUID-63CDD34D-936A-459C-B40B-495696204722.dita" id="GUID-C90DEEB4-57C2-4ADC-B12B-0809BBC8A9EC"/><topicref href="GUID-D7D7615F-B67D-44D0-82DF-24853159A114.dita" id="GUID-27897C8F-D661-416D-BD18-0AA46B7EB8BC"/><topicref href="GUID-F3B93325-E30E-456A-B281-5451B7C47AAE.dita" id="GUID-4F7A796A-725D-4A0E-9F08-25FC4539DD0D"><topicref href="GUID-57989FF8-5E8F-4C8A-9D38-169AFCA4C078.dita" id="GUID-F414CC9C-8844-4938-9CD9-E65E2F10E59A"/><topicref href="GUID-AE486C82-8854-463F-8CB9-B7353D6B2804.dita" id="GUID-4E8D3819-B0FA-4A66-B001-89C9138DA5C4"/><topicref href="GUID-10FD1B94-EC0C-458F-839F-B60A8E47BAD6.dita" id="GUID-662621ED-188A-45C2-870B-510B255E7020"/><topicref href="GUID-627FC480-AF4F-4B23-8671-6E0A0DABA0EF.dita" id="GUID-59A06B45-416A-4A54-8C62-3EBE658296EA"/><topicref href="GUID-37B8243E-027A-49D0-A896-27946DAC9052.dita" id="GUID-3A590CD8-FC5A-4B4B-999F-E734C0C848A9"/></topicref></topicref>
+</topicgroup><topicgroup id="GUID-3D8735FA-28EB-4107-83DB-69AB5B251761">
+
+<topicref href="GUID-BDFAE7E7-18B2-4B5D-8349-CC6C607B717A.dita" id="GUID-0262A96C-4264-478D-83E0-DACAC2D37363"><topicref href="GUID-092D336A-155A-4F18-AAF7-92E08473700E.dita" id="GUID-EC667AC6-9424-4748-BAA9-7395FD410B4C"/><topicref href="GUID-0804E71D-8B20-49A2-9F7C-F2D6795681D0.dita" id="GUID-D3D2D61E-626C-4FBF-908F-001802AABDD8"/><topicref href="GUID-6114133F-E738-4DF1-8308-B09C02B9CEEA.dita" id="GUID-EE39B8CF-E648-45FD-8B6D-D4BB94B71F24"/><topicref href="GUID-4E3C086B-25BE-4DAC-9E21-CFC4F8B792A5.dita" id="GUID-EE1EE16F-B8B3-44B3-82A9-BE2F33F7572C"/><topicref href="GUID-DFDB6864-0F63-41EC-B549-791B750F3EB3.dita" id="GUID-4135E42B-4074-4792-9861-9676A06F1442"><topicref href="GUID-240EE926-BAFC-4A53-A8F8-D559BA7BB672.dita" id="GUID-4DBDAD66-B4A8-440A-9298-380ADC30BD74"/><topicref href="GUID-D5ED62EB-744D-42EB-B8CF-D5623BDA5B38.dita" id="GUID-4FC802F2-9DFC-4CAB-B9BD-C3A6AB81F0BD"/><topicref href="GUID-6873E764-4132-46C8-8444-6301CF4D2033.dita" id="GUID-72A80003-2906-4630-A87D-DDDBF2D11CE6"/><topicref href="GUID-EE50283A-543C-446F-A5D1-E64043F988ED.dita" id="GUID-1AD06DF1-DF67-43E3-BFA5-641FD25659E2"/><topicref href="GUID-AB5370D9-9F0B-4583-A825-11CBF7C6365C.dita" id="GUID-5FA6A558-B3CE-41A0-9FBA-27836D6C3392"><topicref href="GUID-C649DB97-F138-4C90-B177-16590F2E3F19-GENID-1-2-1-9-1-6-1-8-1-7-1-3-1.dita" id="GUID-CA11F753-9EE7-486E-9387-B579AD33DB1D"/><topicref href="GUID-6AC01B10-92C1-4E56-813B-6853DFCF3386-GENID-1-2-1-9-1-6-1-8-1-7-1-5-1.dita" id="GUID-2FD34AA2-AF0B-4161-8BC0-D8F0E2CC5C81"/><topicref href="GUID-58AA7257-0951-42AB-9B6E-AAF63343FEFA-GENID-1-2-1-9-1-6-1-8-1-7-1-4-1.dita" id="GUID-30AD64E9-D1C8-428D-AF60-7AFFB31E0E73"/><topicref href="GUID-C74770A5-ADD4-4AB1-946F-77105E2B8C10-GENID-1-2-1-9-1-6-1-8-1-7-1-6-1.dita" id="GUID-15B29308-4D42-4EDF-944F-6A4F15EB944D"/><topicref href="GUID-FA026EBD-7867-4A2C-9FA4-EC70A5243526.dita" id="GUID-4259CC3B-C753-47E8-B4B8-F6D82E481138"/></topicref></topicref><topicref href="GUID-EDC1C30B-4078-4434-95AC-2E37AF809A51.dita" id="GUID-40334577-8EDA-47DC-BA4E-4E096E78182C"><topicref href="GUID-95A33491-17AC-4F12-948E-A1352ADDA483.dita" id="GUID-4C1861B7-B25C-4D32-85D8-A450F5EA1E22"/><topicref href="GUID-9C05C157-D58E-4C43-87E4-82B4F310AEA9.dita" id="GUID-5E9520CA-B948-4314-8D14-B221CE919DC0"/><topicref href="GUID-535E5C2A-DCFD-4BCB-B26B-11E88BDB8A8A.dita" id="GUID-00E03E37-E3FF-41DE-B872-02B9351FF20F"/><topicref href="GUID-877EEB52-40C8-4880-87A0-9736A625F85F.dita" id="GUID-4CE555B1-EDFA-495B-A16F-34AD31EBFC5A"/><topicref href="GUID-AABC7605-9EE9-41E4-BFDF-77A589A9887B.dita" id="GUID-FFFD391A-6869-4275-8D66-4BD4FCF8B108"/><topicref href="GUID-2EC16C9C-7241-46B2-B569-B89751933C57.dita" id="GUID-800817C0-A87D-4989-A384-BAA3C856D8D7"><topicref href="GUID-10C986FD-BD56-4F8E-87EC-7B890EFCDAC7.dita" id="GUID-BF156514-A90B-4B6F-B0B0-8812748813E2"/><topicref href="GUID-FE36E7DE-7C2C-415B-BB2F-22D9E2BE49A6.dita" id="GUID-018CEA35-CD56-4EA7-8734-CE1B8D8FC04A"/></topicref><topicref href="GUID-C2114C7B-705C-4527-836A-C6E72227111A.dita" id="GUID-08316DE1-BCAF-4957-AEB6-3E7CA2440E64"/><topicref href="GUID-2BDDB4F8-3175-411B-A206-FAE27DEBF678.dita" id="GUID-C3CF65B3-1D1C-4EF7-813E-351ED89549EC"/></topicref></topicref>
+</topicgroup><topicgroup id="GUID-BBAE894F-3D9D-4273-9077-EA64B7D9A51F">
+
+<topicref href="GUID-5E24CFFD-1F87-4B77-B7A0-59A419ADBC90.dita" id="GUID-D7031E0D-BBA1-4C46-A596-CA698BFB4820"><topicref href="GUID-C661BFA4-6C39-476A-8DE0-08E18AA0F548.dita" id="GUID-F04E1E01-09AE-40B5-9C66-B9A36795A27E"/><topicref href="GUID-DCDD68C7-8EBE-4E91-A983-076460B2C2F3.dita" id="GUID-1A5E9AFB-CE38-415A-8647-022AA999AD26"/><topicref href="GUID-70041B11-4C03-42C6-9EC2-307E5FF0F626.dita" id="GUID-EACEC406-1098-4195-9696-FE1B1C9685B6"/><topicref href="GUID-CB0FC4F4-6DAB-4ADD-B044-0E8B9365B4D5.dita" id="GUID-9B27F426-B33A-46C6-AB8D-4D4A4CA526F1"><topicref href="GUID-B2F86F54-EF50-56DB-ADF7-15325AC9324D.dita" id="GUID-3D6DBC37-16D9-443A-8BD7-70BB99A1FB71"/><topicref href="GUID-3A30DA16-ECA8-5639-A9DC-6BE2AD55420B.dita" id="GUID-D3E9FC25-B9B0-437F-AA9E-A7C9A17E0EBF"/><topicref href="GUID-99FC067C-0AED-5373-AF63-8DB7FF5C1F7E.dita" id="GUID-61EED28B-9FFD-4CCB-906F-613BFB89FD10"/></topicref><topicref href="GUID-F5DC77CD-4730-4FD8-A483-F5D22F34887E.dita" id="GUID-597C9144-BE41-43EA-AEA0-34DB9FFEC271"><topicref href="GUID-A3A3405C-C89C-5079-85CE-8CB069C8E0C0.dita" id="GUID-AC3E9573-55C9-4D3A-8794-7D7155E11E20"/><topicref href="GUID-98210124-0B65-4679-BB3A-E94B9999365C.dita" id="GUID-052533EB-C02E-49A4-AE7E-2A75CF2349D6"/><topicref href="GUID-F60E5156-38B0-4781-8088-180E6716FC63.dita" id="GUID-EA6E00C8-FA75-4A2B-A07B-0D2F19A52729"><topicref href="GUID-9986DCC6-EE73-59FB-BDAC-9B09DC64FBCE.dita" id="GUID-C330A32C-ABF2-4570-A101-CE03ADC45555"/><topicref href="GUID-F461CBB3-F8D1-5961-AD51-5741143A1CB1.dita" id="GUID-C0061246-7DE6-4A91-AEC9-97394CCC3DA9"/></topicref></topicref><topicref href="GUID-C6647E84-7237-44FC-BD5D-2476EC161D02.dita" id="GUID-7A921E5D-2853-49D2-B6BE-F3065B715E18"><topicref href="GUID-C24A5B52-0B40-53B2-BF85-6ECC35BDCBA5.dita" id="GUID-3D9831B1-05F4-46C3-9B47-1E24F86DE644"/><topicref href="GUID-78963104-C2B0-4E19-99E5-FEAEB7EA307A.dita" id="GUID-F651DCF3-2828-44ED-9320-02F329EB55F7"><topicref href="GUID-052F58B7-117B-5EDD-A3D5-CB0DE6A4E239.dita" id="GUID-EFCB194F-F971-4C5B-A849-97E87ACFCC36"/><topicref href="GUID-0C8318B1-71D7-5384-97EB-85CBBC3E6B84.dita" id="GUID-E3929EA3-442C-4291-BD3D-29ECE93CBFFE"/><topicref href="GUID-C9644081-004E-5DA0-8133-A32EEA91EF5E.dita" id="GUID-7571A03E-C491-4FB2-87AF-C59EE2D10D7B"/></topicref><topicref href="GUID-6786C7D8-34B9-496C-890E-03DE018D2DE1.dita" id="GUID-0BC9D1AC-54BC-48EA-9B9A-48B46558D4D2"/><topicref href="GUID-E9999276-6861-4ECA-B542-1B6C3471BFC9.dita" id="GUID-47D22FA3-C0A3-477C-8756-7844E914715F"/></topicref></topicref>
+</topicgroup><topicgroup id="GUID-B9CA8A1D-BC88-4FCE-BD0F-C6F8F98AA1C8">
+
+<topicref href="GUID-E6F9A60A-0112-4C9B-A880-7E2908A74DAA.dita" id="GUID-0F0A9D4A-CB55-4E8F-94BF-EA1A53E25733"><topicref href="GUID-F4B2D20B-8F1D-4A4B-8ECB-65BE8E9824DD.dita" id="GUID-5B4470DE-628A-4E17-9249-B15A70749D47"/><topicref href="GUID-E3C7CB78-8A68-4FFA-BD00-04D27E67C1F3.dita" id="GUID-90D80E77-4FDE-488B-83AA-C33A7492DAC6"/><topicref href="GUID-654A788A-526A-4C3F-838C-05B09F0D5445.dita" id="GUID-C5B31AF6-4D99-47A9-82A9-636836E36D7B"/><topicref href="GUID-F9051D21-3E4C-4645-BD04-06606E849AEF.dita" id="GUID-17069BAA-2983-427E-8669-410F77121F57"/><topicref href="GUID-862CA4C4-C6E8-4D60-8DD0-F3590C92E15D.dita" id="GUID-97541F22-EE77-40F8-B8AD-A00837C1F16C"><topicref href="GUID-315DD62B-8669-471F-BDDC-BC4D700AEA60.dita" id="GUID-0885CDD2-8AFA-4566-95DE-8CBCD7E3260B"/><topicref href="GUID-D0F5D40A-28D2-4A2E-9B40-180537E60F56.dita" id="GUID-5E65CAA3-2AAB-4FA6-B5B8-8DA41852F21C"/><topicref href="GUID-68446E8E-129C-444A-836A-EF8F56BFE0BC.dita" id="GUID-0BA62462-5A88-4A6D-A5DB-1CE5F70E0C7D"/></topicref><topicref href="GUID-5FB6BEFD-579B-4139-B54D-9CDCF2198A14.dita" id="GUID-158547A1-E57F-483C-95B7-8AF13E13264B"><topicref href="GUID-2E54DA7D-1094-41C6-AFB0-9999471991F8.dita" id="GUID-D80EA885-EB3D-41AF-8FE8-A7B8880BC60F"/><topicref href="GUID-9B66387C-B6CF-41D9-BEFC-F79E30C70F52.dita" id="GUID-AC2D969B-EA0E-4D54-93B1-6C9D2477C948"/><topicref href="GUID-2490DA46-A57B-4DFD-AA9C-2004D58486E3.dita" id="GUID-1812E3F8-2620-499F-AEC9-985374A6728D"/><topicref href="GUID-E0A0C542-2922-407D-88E9-2DC5D159E1F6.dita" id="GUID-5B451407-EDF4-4592-BB1A-891831AC2BBB"/></topicref></topicref>
+</topicgroup><topicgroup id="GUID-5F7E4C8C-CEEE-4180-9DA0-5BB7E2BD4147">
+
+<topicref href="GUID-B6A21D4A-86D3-45A9-95AE-A0206D15944B.dita" id="GUID-EE7D7647-AD50-426A-8F4D-2A20C3EC8595"><topicref href="GUID-6C74A8B4-50B6-486C-A75F-A50636F4C566.dita" id="GUID-A042621B-0FFD-4456-8DD5-AC2E1E53BF04"/><topicref href="GUID-50217E69-F4A9-4B9F-8608-419783046A1E.dita" id="GUID-297372D8-503B-47BC-AAD9-508A2B8410D1"/><topicref href="GUID-8D7ED882-C61E-4B4F-8483-A323C60BFC57.dita" id="GUID-D18AAC32-210C-4A39-B8FA-7427ABBD1B92"/><topicref href="GUID-A25FFD79-0797-43EC-8975-8C23E7E539C4.dita" id="GUID-A016DCAC-F1E9-4F23-9278-0A822FDC63E4"/><topicref href="GUID-DB55C1A0-2901-4661-B6B1-3B61BF6FF4FA.dita" id="GUID-1E5DBAF2-833B-4DE8-AEE8-1356BAE08475"/><topicref href="GUID-07E0DEC0-A749-4B14-9E73-3AF8ACD28BC6.dita" id="GUID-43BAE0B0-656B-42CB-B96C-2DF24F8C67A7"><topicref href="GUID-3722B946-07CF-4AEA-B228-E50642D6B5BE.dita" id="GUID-AA882CF1-86D4-48E1-9697-3B96DF495072"/><topicref href="GUID-463915EE-25DB-4ABD-AA80-1C10CD242072.dita" id="GUID-33C1B87C-F73A-4919-99A9-4067A205B3EB"/><topicref href="GUID-C34DFF54-87C5-47F6-B0AE-3B066DC7F5A0.dita" id="GUID-842D5253-59A0-4461-AA07-DD35E97AA7E7"/><topicref href="GUID-31FFA810-129A-4E35-A47F-C6D3C1C71D5E.dita" id="GUID-01193D45-2F77-4C1D-AD7A-2C125465EA8D"/></topicref></topicref>
+</topicgroup><topicgroup id="GUID-7364DC0E-B74A-49F2-8A2A-CA8A27D6E232">
+
+<topicref href="GUID-788ECC4B-36B9-493C-A86E-E6C8007074B1.dita" id="GUID-3A681CAC-B030-430D-AEBF-2CAA41918F68"><topicref href="GUID-7D535B68-CA7F-4796-80FB-AE7A27642A88.dita" id="GUID-E56BB3DB-914F-4470-B17E-EFC03FEB2D05"/><topicref href="GUID-6CCF249B-DEDD-4E0B-A081-0FCD9FCCBB5A.dita" id="GUID-D899EBE6-EF07-4FA1-9029-FC6BA68B6C80"/><topicref href="GUID-BA4E634D-5B03-4848-8D42-743914D0955E.dita" id="GUID-5BE53BCB-4A97-4F29-8F77-DF305441659C"/><topicref href="GUID-D089C2E9-1BE4-4B37-B8A8-21E5B2425E6C.dita" id="GUID-A93D888D-71F6-4ED2-8536-338FEEB610DF"/><topicref href="GUID-024EE22F-4B86-48EF-A55E-C9C1C7E9BADB.dita" id="GUID-93FBE53B-0376-45E6-8A60-C29B5EB4DF5E"><topicref href="GUID-4353940E-C77B-4080-86AD-7DBE52B0A27B.dita" id="GUID-99149963-ABFB-46E9-AA0D-24CE21AE78E2"/><topicref href="GUID-12A4418A-9BC6-4BEB-993D-B55E61240A15.dita" id="GUID-967D8A18-7708-4D43-8BD1-9683B5B8EE33"><topicref href="GUID-535C66C9-8B45-4DF3-8404-8ED03ABB4799-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1.dita" id="GUID-B1BDC712-3B39-4164-85CD-EBA628F94515"/><topicref href="GUID-2607CCFA-3D24-4716-A447-74304F861C44.dita" id="GUID-419C3F7A-926F-4AEA-98A8-9F6FEA86BB9E"/><topicref href="GUID-360DEB3A-3E38-413A-9941-6C758BA01ADE.dita" id="GUID-96A4FEC1-BED7-4629-8F60-28596168BB0C"/><topicref href="GUID-E1277A18-7201-4856-8712-067022F92123.dita" id="GUID-D65D49E4-CF9C-481F-8BDE-8C7AA55EA4A3"/><topicref href="GUID-BDF1F32B-796B-4D3D-9C91-43FF8E9DDAF9.dita" id="GUID-D0123438-DB34-4B17-AD5A-6B636323317D"/><topicref href="GUID-BA3B42A2-141C-49D9-B513-1571C246C19B.dita" id="GUID-1AE2A17E-8597-4C19-81E0-26F6785793AD"/><topicref href="GUID-C57086D7-7672-4A52-8634-D28B37AC6290.dita" id="GUID-2FB1F266-198B-4079-B5D9-A4DAF54084B2"/><topicref href="GUID-535C66C9-8B45-4DF3-8404-8ED03ABB4799-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-4-1.dita" id="GUID-C20B8C89-8DE0-4FF6-B56B-DD2AC2A45BE6"/></topicref></topicref><topicref href="GUID-C0DC5D95-2EB5-45D9-A859-78329A4B3EF1.dita" id="GUID-AB8BAF23-72BB-42A1-931E-758AE005A2B0"><topicref href="GUID-3A1BCF46-FFBB-4E4F-A73A-6E68254B23FF.dita" id="GUID-F560D577-40C7-4345-AA8E-F0BC3FC399A7"/><topicref href="GUID-9BBDFF77-5E2C-4E13-BEB3-716CC80B3375.dita" id="GUID-6EB4D9F1-C91E-4DA0-B991-EB3097F7F311"><topicref href="GUID-7E3BBB18-3113-4312-AD91-897DE87C58BF.dita" id="GUID-2D45E3FF-A39C-4909-B051-7BD7ECE88231"/><topicref href="GUID-2344B900-5EC5-4467-BEAD-AB55C88CE63E.dita" id="GUID-7F564EDA-EEB0-4EE7-A7D7-B92CF4DF8DED"/></topicref><topicref href="GUID-7E357DA2-67AD-403A-B4E1-7CB83E75136F.dita" id="GUID-F0DEC1BF-D2B2-48D4-AAB9-8B904886C21C"/><topicref href="GUID-092F414B-2279-4ADB-970F-75DAB8A80BD7.dita" id="GUID-A884E73E-0430-4B07-95F1-948FBE0C2C05"/><topicref href="GUID-6B2221F2-A598-4677-A2D3-40FF27C7373F.dita" id="GUID-7F50161E-50A0-491B-80FB-52857CEA99EC"/></topicref></topicref>
+</topicgroup><topicgroup id="GUID-02BDBA95-FCD9-438F-95B5-89B337784C2C">
+
+<topicref href="GUID-4C8E40EE-8CC9-4737-A28E-A18E89356718.dita" id="GUID-6FF50F78-CE68-4497-93DE-1FA332E5C83C"><topicref href="GUID-86737CAB-2A4A-4424-8856-67E0804BCD60.dita" id="GUID-0FBB431E-1DAA-4762-9B0A-73A6B9BB7069"/><topicref href="GUID-455ED16F-D288-42C9-AA7A-AE5822F7A5BC.dita" id="GUID-3228F34A-0E94-4B6B-8038-01D3AC624EC3"/><topicref href="GUID-FE77CDFC-B66B-485B-A94D-F646894FD330.dita" id="GUID-25056919-A7CC-4417-A806-E5885A6D9777"/><topicref href="GUID-8D9A9283-6E55-4AC8-89CE-DD2B55D05067.dita" id="GUID-377C01D3-16D9-42C4-9669-68C4593281A6"/><topicref href="GUID-209514AE-9457-4ED2-AFE0-FDC059CE2B30.dita" id="GUID-7F266CA7-779D-47E3-B8BB-66FF860E3E3C"><topicref href="GUID-01072199-382F-4691-AC0D-D1226EE5CF2F.dita" id="GUID-0F7B3B56-ED14-4759-A297-790CD58D34FF"/><topicref href="GUID-8D237BD6-9759-4180-B190-F1624594017F.dita" id="GUID-CDB55ECD-81F4-4417-9C57-9AFB6615B87E"/></topicref><topicref href="GUID-E539FF7D-C221-4961-8227-9E94FBAA624C.dita" id="GUID-E1FCBEC5-0739-4BAE-B8A8-7AFFED1BB243"><topicref href="GUID-10D79C75-6AB9-4717-87EF-057F19CB8283.dita" id="GUID-04521B8F-9FF9-43D6-B45A-C98B8D2F3A67"/><topicref href="GUID-670B0580-B81B-4211-A4C0-23A2D8EDF96C.dita" id="GUID-839ACA51-CADD-470E-B358-4694C4F92308"/><topicref href="GUID-5F35ED29-18A0-4764-B84D-B43BF23BF44F.dita" id="GUID-3E0E24D7-99D4-4F2C-A653-8B273D32DC5B"/><topicref href="GUID-BD0D62CD-A067-4A87-8779-CC245E2C4CEA.dita" id="GUID-9BCD7C17-6151-43F3-9596-FCEC523A1E1F"/></topicref></topicref>
+</topicgroup></topicref></topicref></topicref>
+</map>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B6A21D4A-86D3-45A9-95AE-A0206D15944B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-B6A21D4A-86D3-45A9-95AE-A0206D15944B" xml:lang="en"><title>Register Access </title><shortdesc>Describes the Register Access platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B6F0C909-6E58-584E-9270-8066337FCE0F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,74 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-B6F0C909-6E58-584E-9270-8066337FCE0F" xml:lang="en"><title>Client
+Tutorial</title><shortdesc>Explains how to use the MMC Controller interfaces to use MMC hardware.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-388CEB1C-BA81-593F-81D3-C0BD72A405E0"><title>Client interfaces</title> <p>The
+following diagram shows the relationship between the Controller and its clients,
+and also shows aspects of the relationship between the constituent parts.
+In this case, the client is the MultiMediaCard driver, although in general
+this could be some other device driver. </p><fig id="GUID-FF02FE34-4E77-42DE-89BC-4D789E6A310D">
+<image href="GUID-6597A895-37D5-51D1-86B3-E74F6E845899_d0e23392_href.png" placement="inline"/>
+</fig> <p>The session is used to pass commands either to the entire stack,
+i.e. a broadcast command, or to individual cards in the stack. </p> <p>The
+session provides access to the stack of cards, via a pointer to a stack object,
+the <codeph>iStackP</codeph> private member. The session is used to pass commands
+either to the entire stack, i.e. a broadcast command, or to individual cards
+in the stack. An individual card can be accessed via a pointer to the card
+object, the <codeph>iCardP</codeph> private member. The card objects, <xref href="GUID-913FA896-4237-3E47-996F-547E325550AD.dita"><apiname>TMMCCard</apiname></xref> types,
+are data members of the card array object, <xref href="GUID-A460F779-52AB-3ED0-AF13-41B9BC5B2A71.dita"><apiname>TMMCardArray</apiname></xref>,
+which, in turn is a data member of the stack object. </p> </section>
+<section id="GUID-A0B4E830-24DD-5C9C-A76B-CD1DE372A9FE"><title>Using the MultiMediaCard
+stack</title> <p>Clients of the MMC Controller such as the MMC Media Driver
+uses the MMC Controller as follows: </p> <ul>
+<li id="GUID-F4C2C756-5793-59BE-9DAB-E7960B4E5F8D"><p>requests a pointer to
+the stack object, through which the client can obtain pointers to the individual
+card objects and interrogate the cards, finding out their media type, capacity,
+and capability (via the card’s <xref href="GUID-C6858312-FC9A-34C9-B442-557F7558B5C4.dita"><apiname>TCSD</apiname></xref> object), and whether
+the card is present or ready. </p> </li>
+<li id="GUID-592769F9-B9B0-583E-A76C-DF8EB0A5A4B2"><p>creates a session object,
+an instance of the <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita"><apiname>DMMCSession</apiname></xref> class, providing a callback
+function for its constructor. The callback is encapsulated as a <xref href="GUID-F59F1805-95FB-3BDD-97A5-4FD6048DE2E8.dita"><apiname>TMMCCallBack</apiname></xref> object. </p> </li>
+<li id="GUID-66E909B9-8B32-5036-BCAA-486A7F047BBD"><p>initiates the session
+with the pointer to the stack object: <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita#GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A/GUID-72859BCF-4979-37F3-BF32-45181F64755F"><apiname>DMMCSession::SetStack()</apiname></xref> . </p> </li>
+</ul> <p>The client interacts with the stack in the following manner: </p> <ol id="GUID-AE800793-AEF9-5F11-9CF2-A6FEB6827265">
+<li id="GUID-2957F643-771C-5279-821F-875843F42CAC"><p>it sets the session
+up with the pointer to the card object, by calling <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita#GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A/GUID-60FAAA31-A5E1-3DCF-93AE-459BCC8C9730"><apiname>DMMCSession::SetCard()</apiname></xref>. </p> </li>
+<li id="GUID-4B117791-3B0D-552F-81AC-85D0905EEB91"><p>it sets the session
+up to do a specific job, such as a MultiMediaCard macro command, or a lower
+level card command, using the API provided by <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita"><apiname>DMMCSession</apiname></xref>. </p> </li>
+<li id="GUID-0F43C846-6E62-5539-99E1-1DBCF4E911CE"><p>it presents the session
+to the stack for execution, by calling <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita#GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A/GUID-8DA6B49E-FED0-3E83-8D2F-EA7B61C28015"><apiname>DMMCSession::Engage()</apiname></xref>. </p> </li>
+<li id="GUID-BF673228-633B-5E99-9396-0CE6ABE3360E"><p>On completion, the stack
+calls the client’s callback function. The client then can repeat the cycle
+from step 1 or 2. </p> </li>
+</ol> <p>The client can override the default bus configuration settings, i.e.
+change the bus clock, enable retries, change time-out values, restore defaults
+etc., using the session's stack configuration object, <xref href="GUID-89631250-7D11-3E89-9785-7DF779B2AB38.dita"><apiname>TMmCStackConfig</apiname></xref>,
+although in practice, there is rarely a need to do this. </p> </section>
+<section id="GUID-6638C350-37FE-5CF7-AF0B-0EF763936DF3"><title>Locking the
+MultiMediaCard stack</title> <p>The <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita"><apiname>DMMCSession</apiname></xref> API includes
+general lower level functions to issue any single command or series of commands
+including those currently unknown to the controller. This allows application
+specific commands to be supported. It also allows the controller to support
+new commands introduced in later versions of the specification (e.g. commands
+to support I/O cards). </p> <p>When issuing a series of application specific
+commands, the client will want to lock the stack, preventing any other client
+from generating bus activity during this period. This is accomplished by calling <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita#GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A/GUID-BA7DE143-BDE0-31DB-8C85-1073F0D6175C"><apiname>DMMCSession::SetupCIMLockStack()</apiname></xref> and
+then engaging that session. If successful, the stack will be locked until <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita#GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A/GUID-5F153F42-9527-3561-AB05-B36DD28201A1"><apiname>DMMCSession::UnlockStack()</apiname></xref> is
+called. </p> <p>As it may take time for the controller to lock the stack for
+that session, the mechanism for locking the stack involves submitting a session
+even though no bus activity results. If this session completes successfully
+then the stack is locked. The client can then go ahead and invoke its series
+of commands - configuring that same session object as necessary each time
+and submitting it. </p> </section>
+<section id="GUID-4B239C05-3CCF-4FB5-BD11-DA7DFF52DA95"><title>See also</title> <p> <xref href="GUID-9573F7B9-76E9-5DCB-A498-C0DE59606911.dita">Concepts</xref> </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B7C56FF9-FE1B-58C3-BBD4-7479F0BEE555.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-B7C56FF9-FE1B-58C3-BBD4-7479F0BEE555" xml:lang="en"><title>Concepts</title><shortdesc>Describes the technology and architecture, and behaviour of the
+User-Side Hardware Abstraction component.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/><related-links>
+<link href="GUID-05DAF5EF-6F2E-562D-9DB1-0985AD4A1E48.dita"><linktext>Port   Implementation
+Tutorial</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-B7E7E6D6-7824-505C-BA0B-B7861897E78F-master.png has changed
Binary file Adaptation/GUID-B7E7E6D6-7824-505C-BA0B-B7861897E78F_d0e13349_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B8B36A53-CB13-41C1-9CCC-CA5AABE13BF6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE reference
+  PUBLIC "-//OASIS//DTD DITA Reference//EN" "reference.dtd">
+<reference id="GUID-B8B36A53-CB13-41C1-9CCC-CA5AABE13BF6" xml:lang="en"><title>SHAI Interface</title><shortdesc>The boundary between the generic implementation and the
+SHAI implementation. </shortdesc><prolog><metadata><keywords/></metadata></prolog><refbody>
+<section id="GUID-0C82A741-8EEE-4CE9-9955-0C9C013D09EC"> 			<p>The
+SHAI Interface can include two types of services (also known as calls):</p><ul>
+<li><p>SHAI abstraction services (or down calls) which are implemented
+as part of the adaptation software.</p></li>
+<li><p>SHAI adaptation services (or up calls) which are used within
+the adaptation software.</p></li>
+</ul> 		</section>
+</refbody></reference>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B94FFCA4-1EB3-46A7-9FF9-54C55D67FFE8.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-B94FFCA4-1EB3-46A7-9FF9-54C55D67FFE8" xml:lang="en"><title>Entry
+Points</title><shortdesc>This document describes the entry points for each type of device
+driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-EC57B8B7-3E77-4A64-B9AC-CBED913D2957">       <title>Driver
+entry points</title>       <p>The Device Driver framework supports the following
+device driver models: </p> <ul>
+<li id="GUID-FB4AE82F-9C3F-50D0-A200-3CC9A71C9906"><p>The <i>LDD-PDD</i> model:
+drivers of this type must be loaded by a user application. </p> </li>
+<li id="GUID-DCF980DE-5FDE-50E1-AC31-5D6B3B399DFB"><p>The <i>kernel extension</i> model:
+drivers of this type are loaded by the Kernel at boot up. </p> </li>
+<li id="GUID-F39C7C76-7AA5-5627-8800-42DCE485EABB"><p>The <i>combined</i> model
+is a combination of the kernel extension and LDD-PDD models. This is used
+when the driver must perform some initialization at the time of boot up. </p> </li>
+</ul> <p>For each model, the Kernel provides a standard API for the entry
+points to the driver. </p>     </section>
+<section id="GUID-66F7B632-038B-495C-9915-7AB9B395919E"><title>Standard LDD</title><p>For a standard LDD-PDD driver, the
+driver entry points are defined by the following macros: </p><p>For LDDs,
+use <xref href="GUID-B5DA78FD-07CA-3C9F-9154-D29A04E5E1E7.dita"><apiname>DECLARE_STANDARD_LDD</apiname></xref>. For example: </p> <codeblock id="GUID-DD6FC801-02BF-5754-AE4B-F62308849A88" xml:space="preserve">// LDD entry point
+DECLARE_STANDARD_LDD()
+    {
+    // create LDD factory object
+    return new DExDriverLogicalDevice;
+    }</codeblock></section>
+<section id="GUID-D82513D8-BC48-4547-A519-3C2B1FEC4717"><title>Standard PDD</title><p>For PDDs, use <xref href="GUID-73947402-2F32-35C7-94C4-22B4D63D5FB3.dita"><apiname>DECLARE_STANDARD_PDD</apiname></xref>.
+For example: </p><codeblock id="GUID-55E287D4-40A3-55FD-A0F5-6428078BFE55" xml:space="preserve">// PDD entry point
+DECLARE_STANDARD_PDD()
+    {
+    // create PDD factory object
+    return new DExH4PhysicalDevice;
+    }</codeblock> </section>
+<section id="GUID-362A4BF6-D882-4626-9F67-69E29737F27A"><title>Kernel extension</title><p>For a kernel extension, the entry
+point is defined by the macro <xref href="GUID-8B6DF6D7-4995-3564-9303-272500D7E747.dita"><apiname>DECLARE_STANDARD_EXTENSION</apiname></xref>. </p></section>
+<section id="GUID-1556D0A6-B997-4365-9B6F-419676EF25F8"><title>Combined model</title><p>For drivers with a combined model,
+the entry points are defined by the following macros: </p> <ul>
+<li id="GUID-5F50D02B-7DFB-54CB-9C2E-F416938BD424"><p>For LDDs, use <xref href="GUID-38771B51-195D-3148-A462-277DA3696117.dita"><apiname>DECLARE_EXTENSION_LDD</apiname></xref>. </p> </li>
+<li id="GUID-25600E44-0C16-571E-B087-4DB08A3C9A40"><p>For PDDs, use <xref href="GUID-52853C0D-CA98-3B92-B7D4-FF1C1F06C1A6.dita"><apiname>DECLARE_EXTENSION_PDD</apiname></xref>. </p> </li>
+</ul> <p>A driver creates factory objects in the entry point routines. </p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,238 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A" xml:lang="en"><title>Keyword reference (A-C)</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This page lists the keywords starting from A to C. </p>
+<section id="GUID-51EA4180-A0FC-5DCE-8CEA-C43EA24330E4"><title>##</title> <codeblock id="GUID-A7F1E72D-6C4D-55A2-8AC3-54793C208B16" xml:space="preserve">##</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Performs textual substitution.
+All subsequent instances of the two characters ## are replaced with
+an empty string. </p> <p>Note that there is no UNDEFINE facility and
+substitutions are applied in an unspecified order. </p> </section>
+<section id="GUID-56A2AC12-CA1A-531C-94DB-E493735D70C8"><title>ABI_DOWNGRADE</title> <codeblock id="GUID-8C1D1941-8B89-581B-A10D-04EC11A72A3E" xml:space="preserve">ABI_DOWNGRADE   from-&gt;to</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Allows <codeph>BUILDROM</codeph> to substitute a compatible executable if a specified source file
+is not available. </p> <p>The use of this keyword is not appropriate
+for production devices, but is useful in the development environment
+as it increases the chances of producing a ROM in the presence of
+build problems. </p> <p>For example, </p> <codeblock id="GUID-C72215D5-AADE-56EF-A04D-5B0AF7D66244" xml:space="preserve">ABI_DOWNGRADE   THUMB-&gt;ARMI</codeblock> <p>This substitutes \ARMI\ for \THUMB\ if a specified source file
+cannot be found. </p> <p>Another example is in localisation support.
+Problem suppression allows <codeph>BUILDROM</codeph> to handle a missing <filepath>source.Enn</filepath> file by specifying <filepath>source.EXT</filepath> instead. In a final pass, if any file is still not available after
+applying these downgrades, then <codeph>BUILDROM</codeph> will simply
+comment out the line in the <filepath>.oby</filepath> file in the
+hope that the missing file is not vital to the ROM. If this behaviour
+is not appropriate, then the command line option <codeph>-s</codeph> can be used to enforce stricter behaviour and cause <codeph>BUILDROM</codeph> to terminate after the final pass if files are missing. </p> </section>
+<section id="GUID-7CE887E7-C2C3-5F87-AB40-AFA571A68A23"><title>alias[[HWVD]]</title> <codeblock id="GUID-87077748-C01D-542D-8DD1-D22CDA0EEB07" xml:space="preserve">alias[[HWVD]] = &lt;existing-file&gt; &lt;destination-file&gt; [ directory-attribute-list ]</codeblock> <p> <i>rombuild and rofsbuild</i>  </p> <p>Creates an additional
+filesystem entry, which refers to an existing file. <codeph>rombuild</codeph> allows directory aliases to preserve the guarantee that the ROM
+filesystem should not contain cycles. The existing-file must not be
+hidden, and both names are now available to resolve DLL static linkage. </p> </section>
+<section id="GUID-F5A15F4D-2CD5-530D-8031-51546EE28E1C"><title>align</title> <codeblock id="GUID-7B53F30F-B034-545F-AA0F-D7D42567FDE6" xml:space="preserve">align = &lt;hex-number&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Specifies the alignment boundary
+for the file that follows immediately after the <codeph>align</codeph> statement. </p> </section>
+<section id="GUID-50B4683F-C796-577A-8444-D75465BC9563"><title>area</title> <codeblock id="GUID-2D0D97FA-353E-5910-B9C8-78C1D70E1E1C" xml:space="preserve">area = &lt;name&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Defines the area in which the
+executable will be relocated. The specified name must have been previously
+defined in the <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-0FA9D55F-4081-5A46-ABD7-C95406827730">area</xref> control statement. </p> </section>
+<section id="GUID-0FA9D55F-4081-5A46-ABD7-C95406827730"><title>area</title> <codeblock id="GUID-B8BCB889-06B1-53D3-907C-85A1BED9B59F" xml:space="preserve">area = &lt;name&gt; &lt;run-address&gt; &lt;maxlength&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>Defines a new relocation area.
+The area is identified by the specified name. Executable files placed
+in this area will be relocated so that they run in the address range <codeph>X</codeph>, where <codeph>X</codeph> is defined as: </p> <p> <codeph>&lt;run-address&gt;</codeph> &lt;= <codeph>X</codeph> &lt; <codeph>&lt;run-address&gt;</codeph> + <codeph>&lt;maxlength&gt;</codeph>. </p> <p>The Bootstrap is required
+to copy the relevant subset of ROM to the run address at Boot time.
+The main purpose of this is to relocate time-critical executables
+to internal or tightly-coupled RAM. </p> </section>
+<section id="GUID-A97C37B0-8909-58FA-9BC2-2BD68F25A8B0"><title>ascii</title> <codeblock id="GUID-86D82203-CD9C-53F9-8D19-10731894D9C8" xml:space="preserve">ascii</codeblock> <p> <i>rombuild only</i>  </p> <p>Indicates that this is not a Unicode
+build. </p> </section>
+<section id="GUID-19D49CB3-C180-5F32-9488-63C71A3D5991"><title>attrib</title> <codeblock id="GUID-7A831599-A874-5EC7-864A-063E0A0FD04A" xml:space="preserve">attrib = [ s | S ][ h | H ][ r | R | w | W ] | hide</codeblock> <p> <i>rombuild and rofsbuild</i>  </p> <p>Files may have the System,
+Hidden, read-only and writable attributes. </p> <p>File attributes
+are copied from the source file and are then overridden by the attributes
+specified by this keyword. Specifying <codeph>S</codeph>, <codeph>H</codeph>, or <codeph>R</codeph> sets the corresponding attribute;
+specifying <codeph>s</codeph>, <codeph>h</codeph> or <codeph>r</codeph> clears it. </p> <p> <codeph>W</codeph> and <codeph>w</codeph> are
+synonyms for <codeph>R</codeph> and r respectively. To mark a file
+in the ROM as being writable, specify <codeph>attrib=W</codeph>. </p> <p>As this is a ROM, the file cannot be physically modified even
+if the read-only attribute is cleared, but it is useful to mark files
+as writeable so that copies are made writeable, for example on a CF
+card or a RAM file system. </p> <p>Using the <codeph>hide</codeph> attribute indicates that the file should be included in the ROM
+but not recorded in the ROM filesystem. If the file is a DLL it will
+be available for resolving static links from other files in the same
+ROM, but not available to RAM-loaded software or DLLs in an extension
+ROM. </p> </section>
+<section id="GUID-34A37221-7BCF-5C6C-AC15-BD9C2E9B0465"><title>AUTO-BITMAP</title> <codeblock id="GUID-986754B7-966A-5987-8DEA-D3DA3B957450" xml:space="preserve">AUTO-BITMAP=&lt;source&gt; &lt;dest&gt;</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Either selects a compressed MBM
+file if generating an XIP ROM image, or the original source file if
+generating a non-XIP ROM image </p> <p>This statement translates to <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-F68BF5AB-9C25-5736-9EF6-496548D08C74">COMPRESSED-BITMAP</xref> for XIP ROMs and to <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-23851F44-7FAC-5B99-8D15-44099A61A4E4">data</xref> for non-XIP ROMs. </p> </section>
+<section id="GUID-BEB026CF-0136-545D-9348-78A8C559EBB1"><title>autosize</title> <codeblock id="GUID-38F40AFF-9C04-5CA6-B33C-2703FEFBD1D3" xml:space="preserve">autosize = &lt;block size&gt;</codeblock> <p> <i>rofsbuild only</i>  </p> <p>Reduces the size to a whole number
+of blocks where &lt;block size&gt; defines the granularity. </p> <p>For
+example if <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-208C0FE4-DFC0-55C3-B6D7-F18C74F1A699">rofsize</xref> is set to 0x30000 and the actual image size is 0x1234,
+then the generated image size <i>without</i> the autosize option is
+0x30000. If autosize is set to 0x1000, then the generated image size
+is 0x2000. </p> </section>
+<section id="GUID-3ECB9A8C-7F90-5556-936A-ACFB5A3630C5"><title>BINARY_SELECTION_ORDER</title> <codeblock id="GUID-51ACF277-7DDF-51E5-8951-958E86B36BFF" xml:space="preserve">BINARY_SELECTION_ORDER=&lt;source-build1&gt;,&lt;source-build2&gt;,..</codeblock> <p>This causes the tools to check the given locations for files
+in the specified order: </p> <codeblock id="GUID-82BC7A3E-7B6D-59C0-8D23-9CB94D8D76D0" xml:space="preserve">BINARY_SELECTION_ORDER=GCCE, ARMV5_ABIv2</codeblock> <p>causes <codeph>buildrom</codeph> to first check the GCCE directory
+for files and then if not found there, to look in the <codeph>ARMV5_ABIv2</codeph> directory. </p> </section>
+<section id="GUID-9CF1F2B0-A9F2-5463-8308-787A91F74742"><title>BITMAP</title> <codeblock id="GUID-B06CF354-3CD4-58F8-B1D8-F9BA2D013929" xml:space="preserve">BITMAP=&lt;source&gt; &lt;dest&gt;</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Generates an <i>uncompressed</i> Symbian platform XIP ROM format MBM file from the &lt;source&gt; MBM
+file and copies it into the ROM at &lt;dest&gt;. </p> </section>
+<section id="GUID-A24CE761-5675-575A-A85C-74D16A7A17FC"><title>bootbinary</title> <codeblock id="GUID-DBEC685B-EC83-5E67-81E9-60DD87BCDC2E" xml:space="preserve">bootbinary = &lt;boot-file-name&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>The file name of the ROM's bootstrap
+code, which on ARM CPUs appears at physical address 0x00000000 when
+the machine is booted. </p> </section>
+<section id="GUID-8964BB60-D323-56F3-9093-DA623CA56500"><title>BTrace</title> <codeblock id="GUID-6D3AD725-2F25-59AD-BCF4-0C2AA7EF8388" xml:space="preserve">BTrace = N1 [N2 [N3 [N4 [N5 [N6 [N7 [N8]]]]]]]</codeblock> <p> <i>rombuild only</i>  </p> <p>A keyword for configuring the
+behaviour of the Symbian platform mechanism for generating and capturing
+trace information (<xref href="GUID-5BF17780-AD31-30CF-AFD9-915CBDA74441.dita"><apiname>BTrace</apiname></xref>). </p> <p>Each trace
+has a category which is an 8-bit value. The kernel implements a filter
+that enables traces in each category to be either discarded (disabled)
+or passed to the trace handler (enabled). This keyword sets the initial
+state of that filter, i.e. to indicate whether a trace category is
+enabled or disabled. </p> <p>A trace category is one of the <xref href="GUID-5BF17780-AD31-30CF-AFD9-915CBDA74441.dita#GUID-5BF17780-AD31-30CF-AFD9-915CBDA74441/GUID-E26B390F-390C-372B-B60F-9F788119A98B"><apiname>BTrace::TCategory</apiname></xref> enum values. </p> <p>The BTrace keyword
+takes up to eight 32-bit integers, representing a set of 256 bits.
+Each bit in the set is associated with a single category: If a bit
+is set it means that the corresponding category is enabled - if a
+bit is not set it means that the corresponding category is disabled. </p> <p>The rule for mapping the bits in these eight integers to the <xref href="GUID-5BF17780-AD31-30CF-AFD9-915CBDA74441.dita#GUID-5BF17780-AD31-30CF-AFD9-915CBDA74441/GUID-E26B390F-390C-372B-B60F-9F788119A98B"><apiname>BTrace::TCategory</apiname></xref> values is as follows: to turn on trace
+category <codeph>C</codeph>, where <codeph>C</codeph> is one of the <xref href="GUID-5BF17780-AD31-30CF-AFD9-915CBDA74441.dita#GUID-5BF17780-AD31-30CF-AFD9-915CBDA74441/GUID-E26B390F-390C-372B-B60F-9F788119A98B"><apiname>BTrace::TCategory</apiname></xref> enum values, set bit position <codeph>C%32</codeph> to one in integer <codeph>Nx where x = C/32</codeph>. </p> <fig id="GUID-A1108376-F661-5105-B87E-26274FA497EC">
+<image href="GUID-EE7086B4-A60A-55B2-85DC-28F07F9E227E_d0e55772_href.png" placement="inline"/>
+</fig> <p>For example to turn on the trace category <xref href="GUID-103470F8-577A-37B4-80A2-A0CD61B9FF7D.dita"><apiname>ECodeSegs</apiname></xref>, (i.e. the trace generated when code segments are created and destroyed
+mapped into out of processes, and when memory is committed and decommitted)
+you would specify: </p> <codeblock id="GUID-F4B5636C-5E7F-5EF1-8C3C-3FA723593C4C" xml:space="preserve">BTrace 0x00000200</codeblock> <p>which turns on bit position 9 (counting from zero and starting
+at the right hand side of the integer). Note that there is no need
+to specify the remaining 7 integers if they all have zero values,
+as zero is assumed by default. </p> <p>See also <xref href="..\..\guide\Base-subsystem-guide\d\Base_How_to_BTrace.html" scope="external">Base How To BTrace</xref>. </p> </section>
+<section id="GUID-95B716E3-EC86-5B3A-9784-2930AC6B1E8B"><title>BTraceBuffer</title> <codeblock id="GUID-CE1E4478-FC49-55B0-97E6-73C5FFFCF49A" xml:space="preserve">BTraceBuffer = N</codeblock> <p> <i>rombuild only</i>  </p> <p>A keyword for configuring the
+behaviour of the Symbian platform trace handler. </p> <p>Use this
+keyword to set the initial size for any memory buffer used to store
+trace data. </p> <p>See also <xref href="..\..\guide\Base-subsystem-guide\d\Base_How_to_BTrace.html" scope="external">Base How To BTrace</xref>. </p> </section>
+<section id="GUID-3D917AF7-F4FF-54F4-8CDB-5647B440137D"><title>BTraceMode</title> <codeblock id="GUID-E28E7DEB-83B7-59B5-87DB-8008A2037E7A" xml:space="preserve">BTraceMode = N</codeblock> <p> <i>rombuild only</i>  </p> <p>A keyword for configuring the
+behaviour of the Symbian platform trace handler. </p> <p>Use this
+keyword to set the initial mode of the trace handler. This BTRaceBuffer
+keyword takes a single integer that specifies the mode. For the default
+trace handler supplied with Symbian platform, this will be one of
+the <codeph>RBTrace::TMode</codeph> enum values defined in the header
+file <filepath>d32btrace.h</filepath>. </p> <p>See also <xref href="..\..\guide\Base-subsystem-guide\d\Base_How_to_BTrace.html" scope="external">Base How To BTrace</xref>. </p> </section>
+<section id="GUID-03F5D906-B29F-4375-9EA4-BDEEFE53645F"><title>capability</title><codeblock xml:space="preserve">capability = &lt;capability-names&gt;</codeblock><p><i>rombuild
+only</i></p><p>This keyword overrides platform security capabilities
+of the executable specified in the OBY file. For information on the
+use of capabilities and current capability set, see <xref href="GUID-EA20E614-C911-4EE9-92B5-C8F9B657D59E.dita">Platform security
+architecture</xref> in the <xref href="GUID-2FC268F3-5EC2-40DB-B3EA-0E2D5C6EFCAD.dita">Symbian C++ Developer
+Library</xref>.</p></section>
+<section id="GUID-4DE045B8-CD31-43DF-8136-63FB9FB65003"><title>clustersize</title><codeblock xml:space="preserve">clustersize=&lt;cluster-size&gt;</codeblock><p>This keyword
+specifies the cluster size for a FAT image generated by the ROM tools.
+The keyword must be specified in the <codeph>DATA_IMAGE[x]</codeph> section of the OBY file. If it is not specified in the <codeph>DATA_IMAGE[x]</codeph> section, a warning is displayed. </p><p>The value of the cluster
+size must meet the following conditions:</p><p><ul>
+<li><p>The cluster size must be between 512 bytes and 32KB (sector
+size).</p><ul>
+<li><p>For a FAT16 image, the cluster size must be in the range 4101–
+65508 bytes.</p></li>
+<li><p>For a FAT32 image, the cluster size must be greater than 65541
+bytes.</p></li>
+</ul></li>
+<li><p>The cluster size must belong to the geometric progression series,
+512, 1024, 2048, 4096, and so on. A geometric progression series is
+a sequence of numbers where each term after the first is found by
+multiplying the previous one by a fixed number called common ratio.
+In this series, the first number of the series is 512 and the common
+ratio is 2.</p></li>
+</ul></p></section>
+<section id="GUID-255FE5A6-B1F7-59E3-AB5A-65F990F96103"><title>code-align</title> <codeblock id="GUID-0D61CEC0-4E3F-5ABF-AA63-CD7FFAA03B55" xml:space="preserve">code-align = &lt;hex-number&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>This keyword specifies the alignment
+for the executable's code. It indicates the start address of a code
+segment that must be aligned to a specified value. If the original
+address of the code segment does not match the alignment, the whole
+executable file is relocated to meet alignment. After the image is
+loaded in RAM a block of memory is unused. </p> <p>The code alignment
+is an optimisation depending on the hardware the ROM is being built
+for. Setting the code align can allow the ROM to be built in such
+a way that it reduces the work for the CPU when loading the code that
+is, it can be loaded in one pass. This improves the performance. If
+it is unaligned it can take multiple passes. </p> <p>For example: </p> <ul>
+<li id="GUID-BE0872C9-330C-5812-9D89-6051B8848616"><p>Define an <filepath>.oby</filepath> file: </p> <codeblock id="GUID-D2CD9719-3B20-556B-9805-622172B73D3C" xml:space="preserve">file=\epoc32\release\armv5\urel\helloworld.exe sys\bin\helloworld.exe code-align = 0x1000</codeblock> </li>
+<li id="GUID-60585DD9-6935-5291-A8DC-F4822C668750"><p>Build ROM with
+the above <filepath>.oby</filepath> file. </p> </li>
+<li id="GUID-49388D88-A033-5A3C-9915-E09A92C8B682"><p>The log file
+is: </p> <codeblock id="GUID-37EBFA91-4977-5C5B-A336-CF4046A9AAAB" xml:space="preserve">Code Align to 8161f000.  Skipped 2296 bytes
+
+    ********************************************************************
+    Processing file \epoc32\release\armv5\urel\helloworld.exe
+    Load Address:            8161ef88
+    Size:                    000004a8
+    Uids:                    1000007a e8000047 00000000 0dcafc2f
+    Entry point:             8161f000
+    Code start addr:         8161f000</codeblock> </li>
+</ul> <p>In the log file, we can find that the code start address
+of <filepath>helloworld.exe</filepath> matches the alignment <codeph>0x1000</codeph>. To do that, a gap is generated before <filepath>helloworld.exe</filepath> that is,after the image is loaded in RAM
+a block of memory is unused. </p> <p>It is unique for <filepath>ekern.exe</filepath>, which is at least page aligned. If the value of <codeph>code-align</codeph> is less than page size, <filepath>ekern.exe</filepath> will be aligned
+as page size. Otherwise, <filepath>ekern.exe</filepath> will be aligned
+as the value of <codeph>code-align</codeph>. </p> <p> <b>Note:</b> If an <filepath>.oby</filepath> file includes this keyword, the
+size of ROM image is same. But the size loaded in RAM is slightly
+larger than the original. </p> </section>
+<section id="GUID-70AAC0A2-5865-5378-998B-199B5FA60C50"><title>coffwrapper</title> <codeblock id="GUID-038904AC-E274-5D55-8A1D-B18C8722F6A1" xml:space="preserve">coffwrapper</codeblock> <p> <i>rombuild only</i>  </p> <p>Indicates that a COFF ROM wrapper
+is required. </p> </section>
+<section id="GUID-C4BD2116-A9A2-5EB6-8795-AD7AB3230640"><title>collapse</title> <codeblock id="GUID-9DB36B1E-85AA-5C4E-821E-92AEC021E928" xml:space="preserve">collapse = &lt;cpu&gt; &lt;compiler&gt; &lt;mode&gt;</codeblock> <p> <i>rombuild only</i>  </p> <p>This is only supported when the
+&lt;cpu&gt; is ARM and the &lt;compiler&gt; is GCC. </p> <p>The &lt;mode&gt;
+can take one of the following values: </p> <table id="GUID-68DF266C-4A53-53AE-8D08-A8FED4B90330">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>1</p> </entry>
+<entry><p>collapse import thunks only </p> </entry>
+</row>
+<row>
+<entry><p>2</p> </entry>
+<entry><p>collapse import thunks and vtables </p> </entry>
+</row>
+<row>
+<entry><p>3</p> </entry>
+<entry><p>collapse branches </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-FDED610B-0483-54F8-9129-123047536445"><title>compress</title> <codeblock id="GUID-9EB3C403-9AE7-588A-8C0D-0803D81F8CC0" xml:space="preserve">compress</codeblock> <p> <i>rombuild only</i>  </p> <p>Compresses the resulting ROM image
+using the Deflate, Huffman+LZ77 algorithm. </p> </section>
+<section id="GUID-F68BF5AB-9C25-5736-9EF6-496548D08C74"><title>COMPRESSED-BITMAP</title> <codeblock id="GUID-6F0FF54A-1F93-584B-B0FF-150BC4DE32F2" xml:space="preserve">COMPRESSED-BITMAP=&lt;source&gt; &lt;dest&gt;</codeblock> <p> <i>BUILDROM only</i>  </p> <p>Generates a <i>compressed</i> Symbian
+platform XIP ROM format MBM file from the &lt;source&gt; MBM file and
+copies it into the ROM at &lt;dest&gt;. </p> </section>
+<section id="GUID-2322ABCF-3771-5965-8FBE-6AE58240ED2D"><title>coreimage</title> <codeblock id="GUID-EA3E1E01-05E1-5265-A461-1C8B3825409A" xml:space="preserve">coreimage = &lt;core image file&gt;</codeblock> <p> <i>rofsbuild only</i>  </p> <p>This tells rofsbuild that the
+generation of the core image is not required and that the specified
+core image should be used to as the base for generating the extension
+image. </p> </section>
+<section id="GUID-20A2663B-FE05-5E0A-ACF9-669EDDC8317C"><title>codepagingoverride</title> <codeblock id="GUID-294656EC-7B3F-56AE-B2AB-51C6C0155CE9" xml:space="preserve">codepagingoverride [NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED | DEFAULTPAGED]</codeblock> <p> <i>rombuild and rofsbuild </i>  </p> <p>This keyword sets the
+page attributes of executables at a global level. It is applicable
+to all executables in ROM or ROFS partitions. It takes a single argument,
+which can be one of the following: </p> <table id="GUID-BB8AD876-102A-5A66-AAA5-886CE2FAE68B">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<thead>
+<row>
+<entry>Argument</entry>
+<entry>Purpose</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p> <i>NOPAGING</i>  </p> </entry>
+<entry><p>All executables are marked as unpaged, irrespective of whether
+they are marked as paged or unpaged in the <filepath>MMP</filepath> file. </p> </entry>
+</row>
+<row>
+<entry><p> <i>ALWAYSPAGE</i>  </p> </entry>
+<entry><p>All executables are marked as paged, irrespective of whether
+they are marked as paged or unpaged in the <filepath>MMP</filepath> file. </p> </entry>
+</row>
+<row>
+<entry><p> <i>DEFAULTUNPAGED</i>  </p> </entry>
+<entry><p>All executables that are not marked as paged or unpaged
+are marked as unpaged by default. </p> </entry>
+</row>
+<row>
+<entry><p> <i>DEFAULTPAGED</i>  </p> </entry>
+<entry><p>All executables that are not marked as paged or unpaged
+are marked as paged by default. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>For example, the following entry in the Obey file marks
+all the executables as unpaged: </p> <codeblock id="GUID-1E03583B-EEF5-59AC-B7AF-6C56D7239781" xml:space="preserve">codepagingoverride NOPAGING</codeblock> </section>
+<section id="GUID-9F070479-77D7-57E0-B142-64B3A23BBB1F"><title>codepagingpolicy</title> <codeblock id="GUID-E31A0AA2-9839-5D41-BC01-CCAB9719E086" xml:space="preserve">codepagingpolicy [NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED | DEFAULTPAGED]</codeblock> <p> <i>rombuild and rofsbuild </i>  </p> <p>This sets a flag in
+the ROM when it is built, and the loader in the kernel decides a policy
+for executables that are in default state (neither marked as paged
+nor as unpaged). This keyword takes a single argument, which can be
+one of the possible values listed in <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-20A2663B-FE05-5E0A-ACF9-669EDDC8317C">codepagingoverride</xref>. The default value for codepagingpolicy
+is <codeph>DEFAULTPAGED</codeph>. </p> <p>For example, the following
+entry in the Obey file instructs the loader not to page the executables
+in default state: </p> <codeblock id="GUID-E1F72061-2E1F-5045-BABC-174DEC56B011" xml:space="preserve">codepagingpolicy NOPAGING</codeblock> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B97BAC2E-04E3-4979-BACE-9C46BADE912E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,106 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-B97BAC2E-04E3-4979-BACE-9C46BADE912E" xml:lang="en"><title>Deferred Function Calls</title><shortdesc>This document describes how Deferred Function Calls are
+used to implement asynchronous requests.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-1F20014A-5F1E-48B3-AEB8-ED1922452A84"><title>Deferred
+function calls</title> <p>Asynchronous request processing is normally
+done in a Deferred Function Call (DFC). The second stage of interrupt
+handling is deferred to run as a DFC, which runs in a non-critical
+context. </p> <p>Different asynchronous requests can be handled using
+a single or multiple DFCs. The number of DFCs to be created must be
+decided when the driver is designed. For example, a driver that handles
+at the same time an asynchronous receive request and a transmit request
+would create two DFCs, one each for receive and transmit. </p><p>There
+are two main types of deferred function call:<ul>
+<li><p>standard Deferred Function Call (DFC)</p></li>
+<li><p>Immediate Deferred Function Call (IDFC).</p></li>
+</ul></p><p>A DFC is a kernel object that specifies a function to
+be run in a thread, which is processing a DFC queue. A DFC is added
+to a DFC queue that is associated with a given thread, where it is
+cooperatively scheduled with other DFCs on that queue.  Queued DFCs
+are run in order of their priority, followed by the order they where
+queued.  When the DFC gets to run, the function is run kernel side,
+and no other DFC in this queue will get to run until it completes.
+A DFC can be queued from any context.</p><p>An IDFC is run as soon
+as the scheduler is next run, which is:</p><table id="GUID-CCA45A6C-BB16-41D1-B16C-E3491BEF8B7B">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry align="center" valign="top">Scheduler</entry>
+<entry align="center" valign="top">IDFC runs</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry>queued from an Interrupt Service Routine (ISR)</entry>
+<entry>during the IRQ postamble.</entry>
+</row>
+<row>
+<entry>queued from an IDFC</entry>
+<entry>when the currently-running IDFC completes.</entry>
+</row>
+<row>
+<entry>queued from thread context</entry>
+<entry>when the kernel is next unlocked.</entry>
+</row>
+</tbody>
+</tgroup>
+</table><p>Unlike a DFC, the IDFC is not run from a thread context,
+and its execution time must be much smaller.  For these reasons, IDFCs
+are rarely used directly, but are used for implementation of the kernel
+and RTOS personality layers.  An important use of IDFCs is in the
+implementation of queuing DFCs from an ISR context.  IDFCs are run
+with interrupts enabled but the kernel locked.</p></section>
+<section id="GUID-5439E26D-754A-46F3-B607-D229BF5B8A8C"><title>Creation</title> <p>DFCs are created using <xref href="GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB.dita"><apiname>TDfc</apiname></xref> objects. </p> <p>The DFC is initialized with a DFC callback function, a pointer to
+an object to be passed to the callback function, and a priority. It
+can also provide the DFC queue to be used by this DFC at the time
+of construction. </p> <codeblock id="GUID-B3918CAB-F168-5992-BFA9-868648D07083" xml:space="preserve">TDfc iRxDfc;
+/* RxDataDfc is a function pointer to a static function, "this" is passed as a parameter */
+iRxDfc(RxDataDfc,this,1); // This implements an DFC using the standard queue and priority 1.
+iRxDfc(RxDataDfc,this,iDfcQ,1); // This implements an DFC on a user-specified queue with a priority of 1.
+iRxDfc(RxDataDfc,this); // This implements an IDFC.</codeblock><note>DFCs are created with a priority which is 0 to (<xref href="GUID-483DF06F-0236-36C0-8F59-475BB38344E5.dita"><apiname>KNumDfcPriorities</apiname></xref>—1), which is typically 0..7. Using a higher priority value is an
+error. IDFCs are created by not specifying a priority. </note></section>
+<section id="GUID-886457DF-0DB5-4447-BC9B-EB43060A5C6B"><title>Queuing</title> <p>To initiate the process of DFC functionality, the DFC object
+must be queued to the DFC queue associated with the Kernel thread. </p> <p>Before adding the DFC to a DFC queue of the thread, it must be
+associated with the queue (<xref href="GUID-24B2FEDB-9273-351F-A1C6-6F5F91BF83B7.dita"><apiname>TDfcQue</apiname></xref>) object. This
+can be either done at the time of construction, or can be set later,
+by calling <xref href="GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB.dita#GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB/GUID-E3458CD4-7A1C-3FBD-A7FB-488A9C92AE42"><apiname>TDfc::SetDfcQ()</apiname></xref>. </p> <codeblock id="GUID-B57B1C37-A1A5-5C85-AED8-FDD8DBE84280" xml:space="preserve">...
+// Associate the Tx and Rx DFCs with the same queue set to receive 
+// the client messages for this driver. SetDfcQ() sets up the DFC 
+// queue for the DFCs constructed for Tx and Rx
+//
+iRxDfc.SetDfcQ(iDfcQ);
+...</codeblock> <p> <xref href="GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB.dita#GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB/GUID-18073EBB-D91B-3AC8-87A2-424AEDD4D7A4"><apiname> TDfc::Add()</apiname></xref> or <xref href="GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB.dita#GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB/GUID-F6F0C858-8EB2-387B-AE1A-F04B51CE4CED"><apiname>TDfc::Enque()</apiname></xref> is used to add the DFC object to the DFC queue. From an ISR, <xref href="GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB.dita#GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB/GUID-18073EBB-D91B-3AC8-87A2-424AEDD4D7A4"><apiname>TDfc::Add()</apiname></xref> is used. From a thread, <xref href="GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB.dita#GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB/GUID-F6F0C858-8EB2-387B-AE1A-F04B51CE4CED"><apiname>TDfc::Enque()</apiname></xref> is used. If preemption is disabled, <codeph>TDfc::Add()</codeph> could also be used. </p> <codeblock id="GUID-9FBB6881-4BA9-534E-86C7-3A0167E9159C" xml:space="preserve">// TDfc::Add() will queue an IDFC or a DFC from an ISR. This function 
+// is the only way to queue an IDFC and is the only way to queue a 
+// DFC from an ISR. To queue a DFC from an IDFC or a thread either 
+// TDfc::Enque() or TDfc::DoEnque() should be used. This function 
+// does nothing if the IDFC/DFC is already queued.
+//
+iRxDfc.Add();
+</codeblock></section>
+<section id="GUID-E0B9073A-1554-4085-BE24-E27633B7EDF2"><title>Callback
+function</title> <p>The DFC callback function is a static function
+called when a DFC is executed. A pointer to this function is provided
+at the time of DFC object creation. This function implements the deferred
+functionality of an asynchronous request, such as reading or writing
+data from or to an I/O peripheral. It would then either complete the
+request or start another operation. </p> <codeblock id="GUID-5682EDE1-8397-592D-82CE-78DF11487512" xml:space="preserve">static void RxDataDfc(TAny* aPtr);</codeblock></section>
+<section id="GUID-A57C3C99-3032-48CD-A800-E9EE7DCDF4E3"><title>Cancellation</title> <p>A DFC function must be cancelled while cleaning up resources,
+for example, when closing the channel. The function <xref href="GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB.dita#GUID-A14562A5-3E91-3113-AB3C-71DBEA9D58EB/GUID-9851B90B-8D05-3C86-B083-44C4564AC140"><apiname>TDfc::Cancel()</apiname></xref> cancels the DFC if it is already queued. It does nothing if a DFC
+is not queued. It must be called to avoid orphaned DFCs. </p> <codeblock id="GUID-CD926E3D-13E8-51C4-B224-8150FD4D70DB" xml:space="preserve">...
+// If it is a Transmit request, cancel the Transmit DFC. 
+// TDfc::Cancel() cancels the DFC if it is already queued. It 
+// does nothing if DFC is not queued.
+//
+iTxDfc.Cancel();
+...</codeblock></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-B9B35999-0937-51C5-BB77-91A6C039CE2F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-B9B35999-0937-51C5-BB77-91A6C039CE2F" xml:lang="en"><title>ISR Table and Interrupt IDs</title><shortdesc>The ISR Table and Interrupt IDs must be defined by the
+ASSP/Variant. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-1342D8AC-CE52-488F-84BE-B87D4018B873"><title>ISR
+Table</title> <p>Decide on the number of interrupts that exist in
+the system. If the port is split into a core ASSP layer, and a device
+Variant layer, the core layer should include only those interrupts
+that exist on the ASSP. </p> <p>In the core ASSP implementation, declare
+a static <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-77E83634-BBF6-5190-9434-9FB700547CD0">ISR table</xref>, of type <xref href="GUID-2C9B6510-D045-3FA1-AD65-B544E30D34C7.dita"><apiname>SInterruptHandler</apiname></xref> with
+the same number of entries that you have just worked out. </p> <p>In the template port, for example, this table is static member of
+the <codeph>TemplateInterrupt</codeph> class: </p> <codeblock id="GUID-733FA201-2D43-5044-AAEA-D98D26BF3B36" xml:space="preserve">const TInt KNumTemplateInts=EAsspIntIdZ+1;
+
+class TemplateInterrupt : public Interrupt
+    {
+ ...
+ public:
+     static SInterruptHandler Handlers[KNumTemplateInts];
+    };
+            </codeblock> <p> <codeph>SInterruptHandler</codeph> is
+defined in <filepath>...\e32\include\kernel\arm\assp.h</filepath>,
+and <codeph>TemplateInterrrupt</codeph> is defined in <filepath>...\template_assp\template_assp_priv.h</filepath>. </p> </section>
+<section id="GUID-1AC207D8-5395-4583-BCF1-7C952609D227"><title>Interrupt
+IDs</title> <p>Declare an enum in an exported header file that provides
+labels for each of the possible <xref href="GUID-76A30EC4-4B99-5471-9E80-F853C91485BC.dita#GUID-76A30EC4-4B99-5471-9E80-F853C91485BC/GUID-8E58F4C9-0290-55E0-A4FD-B6C2361BE205">Interrupt ID</xref>s in the table. </p> <p>For example, in the template
+port, the interrupt IDs are defined by the <codeph>TTemplateAsspInterruptId</codeph> enum, defined in <filepath>...\template_assp\template_assp.h</filepath>, and is part of the ASSP layer: </p> <codeblock id="GUID-9E221131-1A5C-5969-8A1B-945D943D70E0" xml:space="preserve">// Enumerate here all ASSP interrupt sources. It could be a good idea to enumerate them in a way that facilitates
+// operating on the corresponding interrupt controller registers (for example, using their value as a shift count)
+//
+// EXAMPLE ONLY
+enum TTemplateAsspInterruptId
+    {
+    // ASSP or first-level Interrupt IDs
+    EAsspIntIdA=0,
+    EAsspIntIdB=1,
+    EAsspIntIdC=2,
+    EAsspIntIdD=3,
+    EAsspIntIdE=4,
+    // ...
+    EAsspIntIdUsb=11,
+    EAsspIntIdDma=12,
+    // ...
+    EAsspIntIdZ=25
+    };</codeblock> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-BA0AC9AA-A8E1-5650-9512-DEC06D77668F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-BA0AC9AA-A8E1-5650-9512-DEC06D77668F" xml:lang="en"><title>Writable Data
+Paging Developer Tips</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Contains a collection of developer tips. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-BA3B42A2-141C-49D9-B513-1571C246C19B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,107 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-BA3B42A2-141C-49D9-B513-1571C246C19B" xml:lang="en"><title>TSDIOCard
+Class Tutorial</title><shortdesc>Describes the <codeph>TSDIOCard</codeph> class.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-B373ECD1-7524-4498-838E-E5E0D5922BFB"><title>Description</title><p>The <xref href="GUID-731522ED-8259-3CBA-9AD3-09DDAE23257D.dita"><apiname>TSDIOCard</apiname></xref> class
+provides access to the individual IO functions available on the SDIO card.
+It also, provides various methods for reading the card capabilities and the
+Common Card Control Registers (CCCR) on the SDIO card.</p><table id="GUID-CE22150C-48E7-4764-A5D3-26FA0F241F1F">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p>Header file</p></entry>
+<entry><p><filepath>sdiocard.h</filepath></p></entry>
+</row>
+<row>
+<entry><p>Source code file</p></entry>
+<entry><p><filepath>sdiocard.cpp</filepath></p></entry>
+</row>
+<row>
+<entry><p>Required libraries</p></entry>
+<entry><p>EPBUSSDIO</p></entry>
+</row>
+<row>
+<entry><p>Class declaration</p></entry>
+<entry><p><codeph>class TSDIOCard : public TSDCard</codeph></p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-6596C6D7-7912-4E8A-A317-1D7086EF36D7"><title>FunctionCount()</title><p>The
+function declaration for the <xref href="GUID-3A8CD17F-D6AB-3424-BB22-152E8D0CEA88.dita"><apiname>FunctionCount()</apiname></xref> method is:</p><codeblock xml:space="preserve">inline TUint8 FunctionCount() const;</codeblock><p><b>Description</b></p><p>This method returns the number of IO functions that are present on
+the SDIO card.</p><p><b>Parameters</b></p><p>None</p><p><b>Return value</b></p><table id="GUID-47FB3FA5-729A-4361-BCA4-A8CDE1A4BEB1">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint8</codeph></p></entry>
+<entry><p>The number of IO functions present of the SDIO card.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-6C999579-DE97-446B-9C7F-4C43B4A602B4"><title>IoFunction()</title><p>The
+function declaration for the <xref href="GUID-EB683982-C6EC-38B3-84B5-B2514687EE0B.dita"><apiname>IoFunction()</apiname></xref> method is:</p><codeblock xml:space="preserve">inline TSDIOFunction* IoFunction(TUint8 aFunctionNo) const;</codeblock><p><b>Description</b></p><p>This returns a pointer to the class that carries
+out the required SDIO function.</p><p><b>Parameters</b></p><table id="GUID-C818B43D-BF71-4DAD-8AE4-5A8A3690D831">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TUint8 aFunctionNo</codeph></p></entry>
+<entry><p>The ID of the SDIO function.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><table id="GUID-83EDD6EB-FB46-4F80-8F8F-DFE456795FDD">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TSDIOFunction*</codeph></p></entry>
+<entry><p>The pointer to the class that performs the SDIO function.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-E17E970F-D020-4A38-A321-B25F11717ABE"><title>FindFunction()</title><p>The
+function declaration for the <xref href="GUID-9B98BE63-FC7F-3CD9-9111-B88CDEAEDE89.dita"><apiname>FindFunction()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TSDIOFunction* FindFunction(TSDIOFunctionCaps&amp; aCaps, TUint32 aMatchFlags, TSDIOFunction* aFunctionP = NULL) const;</codeblock><p><b>Description</b></p><p>This method provides support for the validation
+and the enumeration of the card functions.</p><p>This method finds the function
+that can carry out the required capabilities and either returns a function
+pointer to it (if it exists), or NULL, if it does not. See <xref href="GUID-12A4418A-9BC6-4BEB-993D-B55E61240A15.dita">Using
+the SDIO Interface in a Device Driver</xref> for example code which uses this
+function.</p><p><b>Parameters</b></p><table id="GUID-7A53C0AB-2AA0-4C80-801E-C3951451BC9F">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TSDIOFunctionCaps&amp; aCaps</codeph></p></entry>
+<entry><p>The <xref href="GUID-103CBB8D-F965-3C71-B033-72423F95D2A8.dita"><apiname>TSDIOFunctionCaps</apiname></xref> class that contains the
+desired capabilities.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TUint32 aMatchFlags</codeph></p></entry>
+<entry><p>A bitmask that specifies the capabilities that are to be matched.</p></entry>
+</row>
+<row>
+<entry><p><codeph>TSDIOFunction* aFunctionP</codeph></p></entry>
+<entry><p>A pointer to the currently matched function.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>Return value</b></p><table id="GUID-31D8A918-2A00-4DC3-9020-A57C3127C0B8">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TSDIOFunction*</codeph></p></entry>
+<entry><p>A pointer to the next matching function. This value is NULL, if
+there are no more matching functions.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-BA4E634D-5B03-4848-8D42-743914D0955E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,65 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-BA4E634D-5B03-4848-8D42-743914D0955E" xml:lang="en"><title>SDIO Interface Overview</title><shortdesc>Provides a summary of the SDIO platform service interface.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-E68D39FA-6CA3-42F6-972A-C98010174AEC">         
+   <title>Stack implementation</title>             <p>The SDIO stack
+is created by implementing the following functions of the <xref href="GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91.dita"><apiname>DSDIOStack</apiname></xref> class. </p><table id="GUID-86F939E6-A78E-456D-A73B-C3E9F770F979">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91.dita#GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91/GUID-C4395EDB-2CB8-3BA7-A1C6-6B65A3A1FC46"><apiname>DSDIOStack::IssueMMCCommandSM()</apiname></xref></entry>
+<entry>Function to handle the commands to the bus and must also extend
+the support of the SDIO protocol.</entry>
+</row>
+<row>
+<entry><xref href="GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91.dita#GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91/GUID-F547703F-62A6-359D-9AC6-818689DDE2DB"><apiname>DSDIOStack::EnableSDIOInterrupt()</apiname></xref></entry>
+<entry> Function to enable or disable SDIO interrupts.</entry>
+</row>
+<row>
+<entry><xref href="GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91.dita#GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91/GUID-CE55D746-6F55-316B-86F3-6799F29F19B4"><apiname>DSDIOStack::MaxBlockSize()</apiname></xref></entry>
+<entry>Get the maximum block size of the data that can be transferred
+on a SDIO bus.</entry>
+</row>
+</tbody>
+</tgroup>
+</table>         </section>
+<section id="GUID-7A309FAE-CB39-4C3D-9814-13642749FFD0"><title>PSU
+implementation</title><p>The Power Supply Unit (PSU) functionality
+is provided by the <xref href="GUID-9BF2FEAC-F6B8-3071-A4AB-976E33354F1D.dita"><apiname>DSDIOPsu</apiname></xref> class. </p><table id="GUID-D09F19E2-D07B-4B3A-9499-7F81E35397D5">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-9BF2FEAC-F6B8-3071-A4AB-976E33354F1D.dita#GUID-9BF2FEAC-F6B8-3071-A4AB-976E33354F1D/GUID-C99157B6-2E06-3C37-8955-05046E2C08FF"><apiname>DSDIOPsu::PsuInfo(TPBusPsuInfo&amp; anInfo)</apiname></xref></entry>
+<entry>Fills the <xref href="GUID-E3BB783F-423F-352A-9B6E-FD23EC80AA8D.dita"><apiname>TPBusPsuInfo</apiname></xref> object with platform
+specific information.</entry>
+</row>
+</tbody>
+</tgroup>
+</table><p>The header file for the SDIO can be found <xref href="http://developer.symbian.org/xref/oss/xref/MCL/sf/os/kernelhwsrv/kernel/eka/drivers/pbus/mmc/sdcard/sdcard3c/sdio/sdio.h.dita">here</xref>.</p></section>
+</conbody><related-links>
+<link href="GUID-E0AE0AE2-572B-485F-87C6-BDCE55DDC808.dita"><linktext>Power
+Management Services Client Interface guide</linktext></link>
+<link href="GUID-C2068400-B0EF-4451-8F64-76A8E2DAF313.dita"><linktext>Power
+Management Services Implementation Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-BB507973-77A4-4DC1-91C0-65E3CA2CF790.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-BB507973-77A4-4DC1-91C0-65E3CA2CF790" xml:lang="en"><title>Interrupt dispatcher</title><shortdesc>Provides background information about the interrupt dispatcher.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-BBEA9F6B-2F0C-584E-BF12-256E27605499.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-BBEA9F6B-2F0C-584E-BF12-256E27605499" xml:lang="en"><title>Keyword
+Reference</title><shortdesc>This section lists the keywords understood by the ROM building
+tools in alphabetical order. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-BC0936D7-7064-447D-83EF-68C65CF3D1B0.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-BC0936D7-7064-447D-83EF-68C65CF3D1B0" xml:lang="en"><title> On-Target
+Debugging</title><shortdesc>This document describes how to build a device driver to enable
+stop mode debugging.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-664F0388-0A89-476F-B784-57E956C07779">       <title> On-target
+debugging</title>       <p>Device Driver debugging is similar to kernel-mode
+debugging, as drivers run as part of the Kernel. Debug versions of the drivers
+can be debugged using debug tools such as Lauterbach through a JTAG interface
+or an IDE. Other debug tools such as Metro TRK can also be used. </p> <p>Most
+of the hardware platforms supported by Symbian platform are ICE-enabled. Kernel
+developers and those porting the operating system to new hardware often have
+access to development boards exposing the JTAG interface, which allows the
+use of CPU-level debuggers. Using a host PC debugger, such as Carbide.c++
+or CodeWarrior configured for remote debugging, a debug ROM image (including
+drivers) can be downloaded to the target and debugged over a JTAG interface. </p> <p>For
+debugging, debug versions drivers are built, and the ROM image is built to
+include the kernel debug DLL, which enables kernel-side (stop mode) debugging.
+This is done by using the <codeph>STOP_MODE_DEBUGGING</codeph> flag while
+building the ROM image. For example: </p> <p><userinput>rom –v=h4hrp –I=armv5
+–define=STOP_MODE_DEBUGGING</userinput> </p> <p>This includes the kernel extension <filepath>kdebug.dll</filepath> in
+the ROM image, which provides a stop mode debugger API. </p> <p>When the ROM
+image is downloaded to the target, the system boots up and the Kernel or driver
+can be debugged using the host based IDE interface. Code can be stepped through
+and halted, and memory on the target can be viewed. </p> <p>Symbian also provide
+a debug monitor (sometimes called the crash debugger) to provide information
+on Kernel crashes. See <xref href="GUID-26714A57-B6B4-5E81-B512-FB520718482B.dita">Debug
+Monitor Tool</xref> for more details. </p>     </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-BD0D62CD-A067-4A87-8779-CC245E2C4CEA.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-BD0D62CD-A067-4A87-8779-CC245E2C4CEA" xml:lang="en"><title>Time Tools Guide</title><shortdesc>Describes the tools required for the Time platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There are no specific tools required to use or implement the Time
+platform service.</p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-BDB847A2-557A-5902-AA6D-C1AE10D8E493.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,126 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-BDB847A2-557A-5902-AA6D-C1AE10D8E493" xml:lang="en"><title>Code
+Paging Guide</title><shortdesc>Code paging is the application of demand paging to executable code. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-CD6AC3BC-AF81-4342-9B66-34ACDD573093"><title>Purpose</title> <p>This document explains the principles of
+code paging in Symbian platform. </p> <p><b>Intended
+Audience:</b> </p> <p>This document is intended to be read by those interested
+in the Symbian platform kernel. </p> </section>
+<section id="GUID-FC1B1DC9-133A-43BA-BAEC-711718817B82"><title>Basics of code paging</title> <p>Code paging means the use
+of demand paging to executable code. Demand paging increases the apparent
+size of available RAM on a device by loading data into RAM when needed. Since
+the memory locations used by the code cannot be determined before it is loaded,
+the code needs to be modified when it is paged into RAM. </p> <p>Classes explained
+here. </p> <p>Executable code is paged in and out of memory in accordance
+with the demand paging algorithm which is discussed in the document. The algorithm
+involves four basic operations: </p> <ul>
+<li id="GUID-AE260EC1-A9F4-53B9-A0B7-1681FAFA42A5"><p>paging in, </p> </li>
+<li id="GUID-F870B9A6-6B57-5988-93D7-C87A58B8F94D"><p>aging, </p> </li>
+<li id="GUID-4C9897F4-8A64-556E-939A-0687E775E4EC"><p>rejuvenating, and </p> </li>
+<li id="GUID-E9CF60A1-162C-540A-839A-475D99802B85"><p>freeing. </p> </li>
+</ul> <p>The remainder of this document discusses the kernel side implementation
+of each of these operations in turn. Most of the work is done by the <xref href="GUID-B718F920-45E2-3DD6-927F-0465B156993D.dita"><apiname>MemModelDemandPaging</apiname></xref> class. </p> </section>
+<section id="GUID-FC5D5EE4-EEE2-4630-8321-0BB3855CB300"><title>Paging in paged code</title> <p>When a program accesses an
+item of paged code for the first time the code needs to be paged into RAM.
+The initial call generates a data abort: this is caught by the exception handler
+which calls the <xref href="GUID-1AA89F20-7D14-35DB-92FE-06670B2BA484.dita"><apiname>HandleFault()</apiname></xref> function of the <xref href="GUID-B718F920-45E2-3DD6-927F-0465B156993D.dita"><apiname>MemModelDemandPaging</apiname></xref> class.
+The function call performs the paging in as follows. </p> <ul>
+<li id="GUID-B944B6DF-3DC9-5FF4-92B1-2F6A5298767A"><p>Checks the MMU page
+table entry for the address which caused the data abort. If the entry is not <xref href="GUID-4C8E5466-82E2-3B45-81C5-980FC521DD3A.dita"><apiname>KPteNotPresentEntry</apiname></xref> then
+there is no memory mapped at that address and it may need paging in. </p> </li>
+<li id="GUID-DB0C8B0C-A38D-555C-98F7-08040771AD65"><p>Verifies that the exception
+was caused by an access to the code chunk memory region. </p> </li>
+<li id="GUID-F00DF257-8807-5F31-9FED-4626746ED421"><p>Finds the code segment
+which is at the current address. </p> </li>
+<li id="GUID-7A5442AF-A66D-56CA-8921-B7BA3907B624"><p>Verifies that the code
+segment is the one being demand paged. </p> </li>
+</ul> <p>The <xref href="GUID-1AA89F20-7D14-35DB-92FE-06670B2BA484.dita"><apiname>HandleFault()</apiname></xref> function of <xref href="GUID-B718F920-45E2-3DD6-927F-0465B156993D.dita"><apiname>MemModelDemandPaging</apiname></xref> then
+calls the <xref href="GUID-A7C5F674-CF18-308B-A07F-6C057AB29180.dita"><apiname>PageIn()</apiname></xref> function of <xref href="GUID-B718F920-45E2-3DD6-927F-0465B156993D.dita"><apiname>MemModelDemandPaging</apiname></xref>,
+which performs the following steps. </p> <ul>
+<li id="GUID-EAE80357-A36C-5DF6-BCA5-C1F704388DCF"><p>Obtains a <xref href="GUID-535DF46C-C681-3167-9AE1-E927D3B3B928.dita#GUID-535DF46C-C681-3167-9AE1-E927D3B3B928/GUID-E9132C24-94CE-35FE-8E32-943C2134BD1C"><apiname>DemandPaging::DPagingRequest</apiname></xref> object
+by calling <xref href="GUID-535DF46C-C681-3167-9AE1-E927D3B3B928.dita#GUID-535DF46C-C681-3167-9AE1-E927D3B3B928/GUID-D70D74D4-EEDD-3F58-AF6D-160E9DF707DC"><apiname>DemandPaging::AcquireRequestObject()</apiname></xref>. </p> </li>
+<li id="GUID-08CE4C36-B2BD-5DB8-BBB5-D3259D63C496"><p>Obtains a physical page
+of RAM by calling <xref href="GUID-535DF46C-C681-3167-9AE1-E927D3B3B928.dita#GUID-535DF46C-C681-3167-9AE1-E927D3B3B928/GUID-BF59E426-A1C8-3491-9AC8-929A1DF8EE42"><apiname>DemandPaging::AllocateNewPage()</apiname></xref>. </p> </li>
+<li id="GUID-33BA3BF8-999B-5691-B8A6-8905ED3E7B61"><p>Maps the RAM at the
+temporary location <xref href="GUID-E9132C24-94CE-35FE-8E32-943C2134BD1C.dita#GUID-E9132C24-94CE-35FE-8E32-943C2134BD1C/GUID-53AF13F7-94B7-3EDE-B0FF-6F33FF16D208"><apiname>DemandPaging::DPagingRequest::iLoadAddr</apiname></xref>. </p> </li>
+<li id="GUID-5AA0C439-42E3-5E70-BC65-B2E7D7C38909"><p>Reads the correct contents
+into the RAM page by calling <xref href="GUID-535DF46C-C681-3167-9AE1-E927D3B3B928.dita#GUID-535DF46C-C681-3167-9AE1-E927D3B3B928/GUID-4CBDC66C-B779-3894-9B32-726911E3D9E2"><apiname>DemandPaging::ReadCodePage()</apiname></xref>. </p> </li>
+<li id="GUID-4217C1A9-5930-505E-9E8C-864691C68B35"><p>Initialises the <xref href="GUID-C5F2C8BC-9C8E-3BC1-AB24-99E23A38152B.dita"><apiname>SPageInfo</apiname></xref> structure
+for the physical page of RAM and marks it as type <xref href="GUID-BB093184-8193-3157-883B-9264CD6389C7.dita"><apiname>EPagedCode</apiname></xref>. </p> </li>
+<li id="GUID-13948D5A-1C02-5A0D-A1F7-0C13E8B700F2"><p>Maps the page at the
+correct address in the current process. </p> </li>
+<li id="GUID-903E5F84-C4C2-509A-BB31-073780C895A7"><p>Adds the <xref href="GUID-C5F2C8BC-9C8E-3BC1-AB24-99E23A38152B.dita"><apiname>SPageInfo</apiname></xref> to
+the beginning of the live page list. </p> </li>
+</ul> <p>When these calls have completed they return control to the program
+which caused the data abort. </p> </section>
+<section id="GUID-C6956FFF-0138-45B9-87AA-66B7609B2B3E"><title>Aging paged code</title> <p>The demand paging algorithm defines
+pages in the live list to be either young or old. When a page changes status
+from young to old, the kernel changes the MMU mappings for the page to make
+it inaccessible. It does so by calling the <xref href="GUID-2625AEBC-E316-3CC4-B840-DF2148BCAD65.dita"><apiname>SetOld()</apiname></xref> function
+of the <xref href="GUID-B718F920-45E2-3DD6-927F-0465B156993D.dita"><apiname>MemModelDemandPaging</apiname></xref> class. The implementation of
+this procedure is different in the Moving Memory Model and the Multiple Memory
+Model. </p> <p>In the Moving Memory Model, the call to <xref href="GUID-2625AEBC-E316-3CC4-B840-DF2148BCAD65.dita"><apiname>SetOld()</apiname></xref> acts
+as follows: </p> <ul>
+<li id="GUID-B01591FD-2D3F-5752-B38B-5BC69B9FAE49"><p>Finds the MMU page table
+entry for the page and clears the bits <xref href="GUID-37E290ED-FFF8-3A6B-9CA9-07863E340F0D.dita"><apiname>KPtePresentMask</apiname></xref>. </p> </li>
+</ul> <p>In the Multiple Memory Model, <xref href="GUID-2625AEBC-E316-3CC4-B840-DF2148BCAD65.dita"><apiname>SetOld()</apiname></xref> calls the
+kernel function <xref href="GUID-EAF2FEE1-BA70-32E5-8D6A-E55F0A814E4B.dita"><apiname>DoSetCodeOld()</apiname></xref> which acts as follows: </p> <ul>
+<li id="GUID-7573F92E-441B-55AD-AB0D-D4341AF22E3A"><p>Examines the bit array <xref href="GUID-DD3F8638-685C-3246-A493-34C8BBA51566.dita#GUID-DD3F8638-685C-3246-A493-34C8BBA51566/GUID-241CBE5A-0A84-3F26-BAFD-7FCC33F788E7"><apiname>DMemModelCodeSegMemory::iOsAsid</apiname></xref> s
+to determine the processes into which the code segment is loaded. </p> </li>
+<li id="GUID-3AFE85EA-6967-5E89-B277-CDBD17315B06"><p>Updates each mapping
+in turn. </p> </li>
+</ul> <p>The status of a page may change during a call to <xref href="GUID-EAF2FEE1-BA70-32E5-8D6A-E55F0A814E4B.dita"><apiname>DoSetCodeOld()</apiname></xref>,
+either because it has been rejuvenated or paged out. In these cases <xref href="GUID-EAF2FEE1-BA70-32E5-8D6A-E55F0A814E4B.dita"><apiname>DoSetCodeOld()</apiname></xref> simply
+ends, as the aging operation is no longer appropriate. </p> </section>
+<section id="GUID-1B0F49F2-4B9C-4B60-AFA6-521C33951576"><title>Rejuvenating paged code</title> <p>When a program accesses
+a program held in an old page, it generates a data abort because the kernel
+made the page inaccessible when it was set to old. The data abort is caught
+by the exception handler which calls the <xref href="GUID-1AA89F20-7D14-35DB-92FE-06670B2BA484.dita"><apiname>HandleFault()</apiname></xref> function
+of the <xref href="GUID-B718F920-45E2-3DD6-927F-0465B156993D.dita"><apiname>MemModelDemandPaging</apiname></xref> class. It is this call which
+performs the rejuvenation as follows. </p> <ul>
+<li id="GUID-4494FF5B-8F24-5973-9178-F1134A3B7313"><p>Gets the MMU page table
+entry for the address which caused the abort. If the bits <xref href="GUID-37E290ED-FFF8-3A6B-9CA9-07863E340F0D.dita"><apiname>KPtePresentMask</apiname></xref> are
+clear then the page needs rejuvenating. If all the bits are clear then the
+page needs to be paged in, not rejuvenated. </p> </li>
+<li id="GUID-4708382F-4E31-5448-B958-A919C1E2C31A"><p>Finds the <xref href="GUID-C5F2C8BC-9C8E-3BC1-AB24-99E23A38152B.dita"><apiname>SPageInfo</apiname></xref> for
+the page, using the physical address stored in the page table entry. </p> </li>
+<li id="GUID-E235D0FB-7A9B-5A1C-BC84-782A9F8A29FD"><p>If it finds that the
+state of the page is <xref href="GUID-9C190095-2B44-31A5-A898-E362FCC19EDC.dita"><apiname>EStatePagedDead</apiname></xref> then the page is dead
+rather than old and needs to be paged in, not rejuvenated. </p> </li>
+<li id="GUID-B1AE6505-05B7-5ACA-B284-C95AF360AADE"><p>Updates the page table
+entry to make the page accessible. </p> </li>
+<li id="GUID-D39CCEFF-087C-5F07-B935-B52877D35817"><p>Moves the <xref href="GUID-C5F2C8BC-9C8E-3BC1-AB24-99E23A38152B.dita"><apiname>SPageInfo</apiname></xref> for
+the page to the beginning of the live list, making it the youngest page in
+the list. </p> </li>
+</ul> <p>These steps are performed with the system lock held. </p> </section>
+<section id="GUID-C53B418C-46BC-43C5-940D-94667DD00872"><title>Freeing paged code</title> <p>When a physical page of RAM
+holding demand-paged code is needed for other purposes, it must be freed up.
+The kernel does this by calling the <xref href="GUID-9C1DEEB8-2C7E-3AD1-97B1-58E64AAAF1B1.dita"><apiname>SetFree()</apiname></xref> function
+of the <xref href="GUID-B718F920-45E2-3DD6-927F-0465B156993D.dita"><apiname>MemModelDemandPaging</apiname></xref> class. The implementation of
+this procedure is different in the Moving Memory Model and the Multiple Memory
+Model. </p> <p>In the Moving Memory Model, the call to <xref href="GUID-9C1DEEB8-2C7E-3AD1-97B1-58E64AAAF1B1.dita"><apiname>SetFree()</apiname></xref> acts
+as follows: </p> <ul>
+<li id="GUID-57E4C0C5-0D5D-5C0F-B324-46F4E7AD6739"><p>Finds the MMU page table
+entry for the page and sets it to <xref href="GUID-4C8E5466-82E2-3B45-81C5-980FC521DD3A.dita"><apiname>KPteNotPresentEntry</apiname></xref>. </p> </li>
+</ul> <p>In the Multiple Memory Model, the call to <xref href="GUID-9C1DEEB8-2C7E-3AD1-97B1-58E64AAAF1B1.dita"><apiname>SetFree()</apiname></xref> calls
+the kernel function <xref href="GUID-D16A900C-A40C-3D6A-A77E-4008376DBAAE.dita"><apiname>DoSetCodeFree()</apiname></xref> which acts as follows: </p> <ul>
+<li id="GUID-F1CDC949-F1FC-5E87-A4B2-A5F12F099B9A"><p>Examines the bit array <xref href="GUID-DD3F8638-685C-3246-A493-34C8BBA51566.dita#GUID-DD3F8638-685C-3246-A493-34C8BBA51566/GUID-30F9613A-C06F-3185-94B5-4CAE20B7A052"><apiname>DMemModelCodeSegMemory::iOsAsids</apiname></xref> to
+determine the processes into which the code segment is loaded. </p> </li>
+<li id="GUID-4D104936-767C-514C-9253-1F8CC80B92A9"><p>Makes each page inaccessible
+in turn. </p> </li>
+</ul> </section>
+</conbody><related-links>
+<link href="GUID-E21E7992-607A-5A49-B022-189ECA9E76D1.dita"><linktext>Code Paging
+Overview</linktext></link>
+<link href="GUID-B35A70D2-1BC8-51DE-95BF-F315DB394582.dita"><linktext>Demand Paging
+Overview</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-BDF1F32B-796B-4D3D-9C91-43FF8E9DDAF9.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-BDF1F32B-796B-4D3D-9C91-43FF8E9DDAF9" xml:lang="en"><title>SDIO
+Commands Tutorial</title><shortdesc>Lists commands to the SD bus that are specific to SDIO.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The SDIO hardware interface extends the functionality of SD devices. The
+combination of SD card with I/O is usually found in devices that can be ported
+easily and make heavy demands on memory. </p>
+<table id="GUID-0DC73E53-1A1E-4849-8166-D5FACA2377BE"><title>SDIO Hardware
+Interface</title>
+<tgroup cols="3"><colspec colname="col1" colwidth="0.66*"/><colspec colname="col2" colwidth="0.67*"/><colspec colname="col3" colwidth="1.67*"/>
+<thead>
+<row>
+<entry valign="top">Supported SDIO Command</entry>
+<entry valign="top">Interface functions</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p>CMD5</p></entry>
+<entry><p><codeph>IO_OP_COND</codeph></p></entry>
+<entry><p>Used during initialization to determine the presence of an SDIO
+card and set the voltage.</p></entry>
+</row>
+<row>
+<entry><p>CMD52</p></entry>
+<entry><p><codeph>IO_RW_DIRECT</codeph></p></entry>
+<entry><p>Used to address and access a single register.</p></entry>
+</row>
+<row>
+<entry><p>CMD53</p></entry>
+<entry><p><codeph>IO_RW_EXTENDED</codeph></p></entry>
+<entry><p>Used to address multiple registers with a single SDIO command. This
+is called by the <codeph>IssueMMCCardCommand()</codeph> function.</p></entry>
+</row>
+<row>
+<entry><p>R4</p></entry>
+<entry><p><codeph>IO_SEND_OP_COND</codeph></p></entry>
+<entry><p>The SDIO response. <xref href="GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91.dita#GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91/GUID-FFD5A33A-73D2-3D19-94EF-638049B8B6E7"><apiname>DSDIOStack::ExtractSendOpCondResponse(aResponse,aFunctionCount)</apiname></xref> is
+used to extract the SDIO operation response.)</p></entry>
+</row>
+<row>
+<entry><p>R5</p></entry>
+<entry><p><codeph>IO_RW_DIRECT</codeph></p></entry>
+<entry><p>The SDIO response, handled by TSDIORseponseR5. It also provides
+information about the current state of the SDIO bus, error state, and the
+byte order the data is read.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></conbody><related-links>
+<link href="GUID-9BBDFF77-5E2C-4E13-BEB3-716CC80B3375.dita"><linktext>SDIO Implementation
+Overview</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-BDFAE7E7-18B2-4B5D-8349-CC6C607B717A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-BDFAE7E7-18B2-4B5D-8349-CC6C607B717A" xml:lang="en"><title>DMA</title><shortdesc>Describes the Direct Memory Access (DMA) Platform Service.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,105 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF" xml:lang="en"><title>MMC
+Controller Architecture</title><shortdesc>Describes the class architecture of the MMC Controller.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-50AB2022-B205-525B-83F9-0DE0275EC3EF"><title>Introduction</title> <p>The
+MultiMediaCard media driver defines and implements the standard media driver
+interface derived from <xref href="GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC.dita"><apiname>DMediaDriver</apiname></xref>. This is the client
+of the MultiMediaCard controller. </p> <fig id="GUID-6F516C8A-9114-50A1-A714-8BA9DD081C08">
+<image href="GUID-DF3045C7-4BDA-53AF-85E4-A8AAD99F40F7_d0e18806_href.png" placement="inline"/>
+</fig> <p>Requests to the controller can also come from other device drivers.
+This means that the architectural picture can be extended as shown below: </p> <fig id="GUID-D84379AB-36E2-5679-B154-40FDDF6FE334">
+<image href="GUID-5686E787-537F-5B32-B719-34EF5B7F0D37_d0e18814_href.png" placement="inline"/>
+</fig> <p>The controller currently supports a single stack capable of holding
+up to 4 cards. In a future development, it may become capable of supporting
+more than 1 stack. Note however, that Symbian platform allows more than one
+peripheral bus controller. </p> <p>The controller can handle multiple requests
+outstanding simultaneously, i.e. multiple drivers each with a session engaged
+(a session is a unit of work for the MMC stack). Internally, it schedules
+these requests onto the bus, automatically putting the appropriate card into
+the transfer state etc. </p> <p>A platform containing a card socket is expected
+to provide a means of detecting when a card is inserted or removed from the
+stack (e.g. a media door interrupt). The controller does not attempt to initialize
+and identify newly inserted cards immediately. Instead, cards remain unidentified
+until they are interrogated by a client. </p> <p>For hardware interfaces that
+allow multiple cards in a single stack, the MultiMediaCard system supplies
+no means of identifying a particular socket position within the stack. As
+cards are inserted and removed, the potential exists for those cards which
+remain to be allocated different card numbers (and ultimately a different
+drive letter than that allocated previously) once the stack is re-initialized.
+To avoid this, the controller maintains a fixed card number for a given card
+for as long as it remains in the Symbian platform device (by storing the CID
+of each card present). This means that a card will have a constant drive letter
+for as long it remains in the Symbian platform device. However, if a card
+is removed, and then subsequently re-inserted into exactly the same slot in
+the stack, then there is no guarantee that it will be allocated the same card
+number, and therefore, no guarantee that it will have the same drive letter
+as before. </p> </section>
+<section id="GUID-92F5EBE4-C9AD-5D9A-A80E-9AFD1A09B6B3"><title>Class architecture</title> <p>The
+following diagram gives a more detailed view of the MultiMediaCard controller
+in terms of the socket, stack, session, power supply and media change objects. </p> <fig id="GUID-17F345F3-B579-5D78-BE22-0CA50A88FAAE">
+<image href="GUID-431A08D4-46DD-5A9D-B2A4-3D58C9B1E9E7_d0e18839_href.png" placement="inline"/>
+</fig> <p id="GUID-BA12AC03-4A9C-5B1A-BC06-D171BCAB9DB2"><b>The socket</b> </p> <p>The
+Symbian platform implementation of MultiMediaCard uses the idea of a socket.
+A socket corresponds to a physical device on a given peripheral bus. </p> <p>In
+general, a socket is associated with its own thread. However, although each
+card in a MultiMediaCard stack has its own individual slot, the bus architecture
+prevents more than one card from being accessed at any one time. Further,
+all cards in a stack must be powered up at the same time. All this suggests
+that having a separate thread for each card in a multi-card slot would not
+offer much benefit, and indeed would probably lead to conflicting hardware
+accesses between the threads. This means that a single socket object is allocated
+to represent for all cards in MultiMediaCard stack. </p> <p>The socket is
+the highest level object in the MultiMediaCard controller, and is an instance
+of a <xref href="GUID-45B97680-1756-3559-8A2D-2F2E851AD6A7.dita"><apiname>DMMCSocket</apiname></xref> class. It oversees the power supply functionality,
+the media change functionality, and the object that controls access to the
+card stack. </p> <p>You can define and implement a derived class in the variant
+DLL, <filepath>epbusmv.dll</filepath>, although it may rarely be necessary. </p> <p id="GUID-F3455C81-8A2D-557F-B3C0-6116B4756960"><b>The stack</b> </p> <p>Access
+to the card stack is handled by an instance of a <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita"><apiname>DMMCStack</apiname></xref> class,
+and is owned by the socket. The <codeph>DMMCStack</codeph> class is designed
+to implement the set of "macros" defined by the MultiMediaCard Association.
+These "macros" are a predefined set of command sequences that perform complex
+bus operations. </p> <p>You will normally define and implement a derived class
+in the variant DLL, <filepath>epbusmv.dll</filepath>. </p> <p id="GUID-55C54B59-3502-5338-8DD5-EC0488B53B8B"><b>The session</b> </p> <p>A
+session is an instance of a <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita"><apiname>DMMCSession</apiname></xref> class, and represents
+a unit of work for the MMC stack. It is, in effect, the main client interface
+to the MultiMediaCard Controller. Each client (i.e. the MultiMediaCard media
+driver or any other device driver) creates its own instance of this class.
+The client can then make MultiMediaCard requests on the stack by putting the
+appropriate information into the session object (configuring the session),
+and then submitting this session object to the stack; this is also referred
+to as engaging the session, and is invoked by calling <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita#GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A/GUID-8DA6B49E-FED0-3E83-8D2F-EA7B61C28015"><apiname>DMMCSession::Engage()</apiname></xref>.
+Once submitted, the session is then scheduled - see <xref href="GUID-28844FE0-AE0F-531C-826E-CDA8400A0581.dita">Sessions
+and Request Management</xref> for more background information on this. </p> <p>The <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita"><apiname>DMMCSession</apiname></xref> class
+contains functions for initiating macro functions as laid down by the MultiMediaCard
+Association as well as lower level functions that allow a client to control
+the stack in a more explicit manner. </p> <p id="GUID-65EAFEA0-74A4-514C-82B8-9BD7A4D34FB3"><b>Power supply unit</b> </p> <p>The
+behavior of the power supply unit (PSU) is represented by the <xref href="GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B.dita"><apiname>DMMCPsu</apiname></xref> class. </p> <p>You
+will normally define and implement a derived class in the variant DLL, <filepath>epbusmv.dll</filepath>. </p> <p><b> Media change</b> </p> <p>The behavior that deals with media change events
+is represented by the <xref href="GUID-2F974AD8-551B-35F0-B72C-99122913714D.dita"><apiname>DMMCMediaChange</apiname></xref> class. </p> <p>You
+will normally define and implement a derived class in the variant DLL, <filepath>epbusmv.dll</filepath>. </p> <p id="GUID-26CFDD03-A4C4-5C96-88D4-5E750FDF69A3"><b>The controller factory</b> </p> <p>The
+controller factory, also known as the controller interface, is a <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita"><apiname>TMMCardControllerInterface</apiname></xref> derived
+class that creates instances of your platform specific: stack class, power
+supply unit class, socket class, and media change class. It also allows you
+to perform platform specific initialization. </p> <p>You create an instance
+of your factory class in the kernel extension entry point code in your DLL.
+This normally calls <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-2C6EA849-1B62-3158-A328-DB2A7149346C"><apiname>TMMCardControllerInterface::Create()</apiname></xref> on
+the object, a Symbian platform supplied function, which calls your implementations
+of the <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita"><apiname>TMMCardControllerInterface</apiname></xref> pure virtual functions,
+to create the instances of your classes. </p> <p>Note that these functions
+are only called for sockets that are associated with MultiMediaCard devices. <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-2C6EA849-1B62-3158-A328-DB2A7149346C"><apiname>TMMCardControllerInterface::Create()</apiname></xref> iterates
+through all possible socket numbers, from 0 to <xref href="GUID-2C5A5F8F-381C-3B99-AADE-44474E629CC4.dita"><apiname>KMaxPBusSockets</apiname></xref>,
+calling <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-5EC9F2EE-5D14-37F9-9EFE-95BD1062C681"><apiname>TMMCardControllerInterface::IsMMCSocket()</apiname></xref> for each
+socket number to determine whether the socket number is a MultiMediaCard socket. </p> <fig id="GUID-53AF7993-0A93-5728-9609-0133E66AED78">
+<image href="GUID-13664BB9-7D05-594E-95D4-49C0D31D3734_d0e18989_href.png" placement="inline"/>
+</fig> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-BE73CFE6-D48D-5B92-AF49-E2D967ADF0EC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE task
+  PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
+<task xml:lang="en" id="GUID-BE73CFE6-D48D-5B92-AF49-E2D967ADF0EC"><title>Close and Unload the Driver </title><shortdesc>A short tutorial describing how to close and unload the shared chunk, close the USB channel and unload the USB Logical Device Driver (LDD). </shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody><steps id="GUID-1F63BD2D-A29C-5AC1-9013-07D16187F577"><step id="GUID-764B04E1-B796-570F-A99E-AD0463506EA7"><cmd>Close the handle to the shared chunk using <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita#GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07/GUID-76D5B03B-4DF5-3CD7-80E9-8C113B87A613"><apiname>RChunk::Close()</apiname></xref>. </cmd> <stepxmp><codeblock id="GUID-D52CC11A-493B-51AB-B7C2-AFA0C86F9AC0" xml:space="preserve">// Close chunk handle
+gChunk.Close();</codeblock> </stepxmp> </step> <step id="GUID-34E995EC-C70B-5835-8CF6-FB382B6B61E5"><cmd/><info>Close the handle to the USB channel using <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-1EB060E0-FFCF-3C37-AEE3-E33AA7ED37B4"><apiname>RDevUsbcScClient::Close()</apiname></xref>. </info> <stepxmp><codeblock id="GUID-72F64F85-F315-580E-B1E2-25B5418D10AF" xml:space="preserve">// Close USB Channel
+gPort.Close();</codeblock> </stepxmp> </step> <step id="GUID-1AE8A45A-E066-5401-9B9D-9B209C65AB6C"><cmd/><info>Unload the USB logical device driver using <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-240D1DA3-BF23-3042-A636-D08E0AA62E49"><apiname>User::FreeLogicalDevice()</apiname></xref>. </info> <stepxmp><codeblock id="GUID-A5655563-5134-5E4E-9D49-BCAF196C095A" xml:space="preserve">User::FreeLogicalDevice(KUsbDeviceName);</codeblock> </stepxmp> </step> </steps> </taskbody></task>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-BF04B68E-7F77-5D99-A0F6-2842758EFD4D.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,185 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-BF04B68E-7F77-5D99-A0F6-2842758EFD4D" xml:lang="en"><title>ROFSBUILD</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>ROFSBUILD is the Symbian platform non-XIP (execute-in-place) ROM
+builder. It is normally invoked through <xref href="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita">BUILDROM</xref>,
+the Symbian platform ROM configuration tool that acts as a front-end
+to ROFSBUILD. </p>
+<p>ROFSBUILD understands a sub-set of the BUILDROM OBEY file syntax. </p>
+<section id="GUID-492BCD7C-64FD-46A7-BAAD-170AE46FDF2A"> </section>
+<section id="GUID-B6CB21A1-2D96-5AF1-9193-FC03F4511080"><title>ROFSBUILD
+command syntax</title><p>If the OBY files are encoded in UTF-8 with
+non-ASCII character support, use the following the ROFSBUILD command
+syntax:</p><codeblock id="GUID-379818BF-A17B-5CAF-A311-3EE4142EE51D-GENID-1-2-1-8-1-1-6-1-1-6-1-2-4-3" xml:space="preserve">ROFSBUILD [options] [–oby-charset=utf-8 &lt;obyfile&gt;] </codeblock><p>If the OBY files are encoded in local character set with non-ASCII
+characters support, use the following the ROFSBUILD command syntax:</p><codeblock id="GUID-B3A01582-9631-57C6-A654-D5539DF1AE54-GENID-1-2-1-8-1-1-6-1-1-6-1-2-4-5" xml:space="preserve">ROFSBUILD [options] &lt;obeyfile&gt;</codeblock><p> <codeph>options</codeph> can be one or more
+of the following: </p> <table id="GUID-FC77DA02-6ECE-5817-9550-A6004A8592AC">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>–argfile=&lt;parameter file&gt;</codeph>  </p> </entry>
+<entry><p>Accepts a parameter file, which contains a list of command-line
+parameters specific to the ROM tools, as input. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-v</codeph>  </p> </entry>
+<entry><p>Verbose mode. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-?</codeph>  </p> </entry>
+<entry><p>Displays more detailed help for the command. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-s[log|screen|both] </codeph>  </p> </entry>
+<entry><p>Displays a summary of the size to the specified destination,
+i.e. to the log, to the screen or to both the log and the screen. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> -d&lt;bitmask&gt;</codeph>  </p> </entry>
+<entry><p>Sets the trace bitmask; this only applies to debug builds. </p> <p>The simplest way of specifying this is to use a string of hexadecimal
+characters starting with 0x (e.g 0x01234567). However, any string
+that can be interpreted and translated into a valid TUint value may
+be used. See the standard C function strtoul(). </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-compress</codeph>  </p> </entry>
+<entry><p>Compresses executable files where possible using the inflate
+(Deflate, Huffman+LZ77) algorithm unless the <codeph>-compressionmethod</codeph> keyword is used to override the default. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-compressionmethod [none | inflate | bytepair] </codeph>  </p> </entry>
+<entry><p>Can be used either with the <codeph>-compress</codeph> keyword
+or alone. </p> <p><table id="GUID-9D1C2D75-A0F5-5A60-ADC1-7357287B3B43">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>none </codeph>  </p> </entry>
+<entry><p>No compression is used. </p> </entry>
+</row>
+<row>
+<entry><p>I<codeph>nflate</codeph>  </p> </entry>
+<entry><p>Compresses executable files using the default (Deflate,
+Huffman+LZ77) algorithm. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>bytepair </codeph>  </p> </entry>
+<entry><p>Compresses executable files using the bytepair algorithm.
+Bytepair compression allows faster decompression than the default
+Deflate, Huffman+LZ77 algorithm and supports demand paging by performing
+compression and decompression of code in independent 4 KB pages. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-coreimage &lt;core image file&gt; </codeph>  </p> </entry>
+<entry><p>Uses the specified core image file as the basis for creating
+the extension. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-datadrive=&lt;obeyfile_1&gt;,[...,&lt;obeyfile_n&gt;]</codeph> </p> </entry>
+<entry><p>Specifies the data drive description IBY or OBY file. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-lowmem</codeph>  </p> </entry>
+<entry><p>Reduces the physical memory consumption during image generation. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-loglevel&lt;level&gt;</codeph>  </p> </entry>
+<entry><p>Level of information to log file. The following valid log
+levels are available: </p> <p><table id="GUID-D14FA9B9-5FD9-5F43-A980-313E08E9E5A0">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>0</codeph>  </p> </entry>
+<entry><p>Default level of information to log file. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>1</codeph>  </p> </entry>
+<entry><p>Logs the host or the ROM filenames, the file size, and the
+hidden attribute in addition to the <codeph>loglevel 0</codeph> information. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>2</codeph>  </p> </entry>
+<entry><p>Logs the E32 file header attributes such as UIDs, data size,
+heap size, stack size, VID, SID, and priority in addition to the <codeph>loglevel 1</codeph> information. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-wstdpath</codeph>  </p> </entry>
+<entry><p>Displays a warning if a file is placed in a non-standard
+directory when <codeph>PlatSecEnforceSysBin</codeph> is set to <codeph>OFF</codeph>.  </p><p> For example, the following instruction in
+OBY file leads to a warning when <codeph>-wstdpath</codeph> is used
+and <codeph>PlatSecEnforceSysBin</codeph> is <codeph>OFF</codeph>:</p><p><codeph>File=ABI_DIR/BUILD_DIR/hello.exe myfolder/bin/hello.exe</codeph></p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-j&lt;NUM_OF_WORKING_THREADS&gt;</codeph>  </p> </entry>
+<entry><p>Specifies the number of working threads that can run concurrently
+to create a ROFS image. The <codeph>&lt;NUM_OF_WORKING_THREADS&gt;</codeph> must be an integer in the range 1-128. </p> <p>If the <codeph>-j</codeph> option is not specified or an invalid value is specified, ROFSBUILD
+automatically takes the number of working threads in the following
+ways: </p> <ul>
+<li id="GUID-4EE0BEB1-C6AE-559A-99E6-4713F721DDB6"><p>If the <codeph>NUMBER_OF_PROCESSORS</codeph> environment variable is set properly,
+ROFSBUILD uses the number of processors as the number of working threads. </p> </li>
+<li id="GUID-541008FB-8416-5582-86E2-254FA001FC00"><p>If the <codeph>NUMBER_OF_PROCESSORS</codeph> environment variable is not set or
+is invalid, the default value <codeph>8</codeph> is used as the number
+of working threads. </p> </li>
+</ul> </entry>
+</row>
+<row>
+<entry><p> <codeph>-cache</codeph>  </p> </entry>
+<entry><p>Enables cache mechanism. It ensures that ROFSBUILD uses
+cached executable files while creating a ROFS image. This allows ROFSBUILD
+to reuse or generate cached files. </p> <p> <b>Notes</b>: </p> <ul>
+<li id="GUID-9B7056D4-EF5B-533B-9E9F-50AD9A7BF498-GENID-1-2-1-8-1-1-6-1-1-6-1-2-4-7-1-3-14-2-3-1"><p>The cache mechanism
+is disabled by default. </p> </li>
+<li id="GUID-AF355401-C732-5FB5-A472-D7EEB294E4E0-GENID-1-2-1-8-1-1-6-1-1-6-1-2-4-7-1-3-14-2-3-2"><p>The cached files
+are stored on the hard disk. </p> </li>
+<li id="GUID-7EEA01CD-E155-535B-915B-DE22C42FEDD0-GENID-1-2-1-8-1-1-6-1-1-6-1-2-4-7-1-3-14-2-3-3"><p>The cache command
+line options (<codeph>-cache</codeph>, <codeph>-nocache</codeph>,
+and <codeph>-cleancache</codeph>) are mutually exclusive. This means
+that you can use only one cache option at a time. </p> </li>
+</ul> </entry>
+</row>
+<row>
+<entry><p> <codeph>-nocache</codeph>  </p> </entry>
+<entry><p>Disallows ROFSBUILD from using cached files while creating
+a ROFS image. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>-cleancache</codeph>  </p> </entry>
+<entry><p>Deletes all cached files from the hard disk. </p> </entry>
+</row>
+<row>
+<entry><p><codeph>-symbols</codeph></p></entry>
+<entry><p>Generates symbols for each data or executable specified
+in the OBY file. </p><p><b>Note</b>: The symbols file is not generated
+by default.</p></entry>
+</row>
+<row>
+<entry><p><codeph>-smr=&lt;smrhcr_rofsbuild_obeyfile_1&gt;,[…,  &lt;smrhcr_rofsbuild_obeyfile_n&gt;]</codeph></p></entry>
+<entry><p>Creates SMR partition images.</p></entry>
+</row>
+<row>
+
+<entry><p><codeph>-prependepocroot</codeph></p></entry>
+<entry><p>Prepends EPOCROOT to the file location, if the specified
+location starts from <codeph>\epoc32</codeph> without <codeph>EPOCROOT</codeph>.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p> <codeph>&lt;obeyfile&gt;</codeph> is a standard text file
+containing statements that are used to control the operation of the
+tool. </p> <p>See the <xref href="GUID-9CF985F1-C100-5999-9410-58B7865A1E18.dita">OBEY files</xref> reference for the full syntax. </p> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-BF157EE2-B680-554A-AE32-69C652B61FA6-master.png has changed
Binary file Adaptation/GUID-BF157EE2-B680-554A-AE32-69C652B61FA6_d0e29926_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-BF86E9F9-531A-51A1-90B4-23B51604F5B4.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,103 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-BF86E9F9-531A-51A1-90B4-23B51604F5B4" xml:lang="en"><title>Reference</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This topic provides a summary of related documentation for the USB Client
+Driver to which you can refer. </p>
+<section id="GUID-40972A82-4DE0-5A24-A00D-9F8DDA872B68"><title>API Reference</title> <p><b>Kernel Architecture </b> </p> <table id="GUID-1F30412D-631A-53C7-811C-9A9BE462D9BC">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Item</b>  </p> </entry>
+<entry><p> <b>Header</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B1E32178-3B7C-3B00-A0AF-62ECE40E8598.dita"><apiname>RDevUsbcClient</apiname></xref>  </p> </entry>
+<entry><p> <filepath>d32usbc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-BD848FB9-532D-34E1-876C-66064D50B761.dita"><apiname>TCapsDevUsbc</apiname></xref>  </p> </entry>
+<entry><p> <filepath>d32usbc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-4BA5287B-69D8-3714-BA3A-D4DBA4DD6AE8.dita"><apiname>TUsbcClassInfo</apiname></xref>  </p> </entry>
+<entry><p> <filepath>d32usbc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-4ADDF113-0392-39EE-82C7-F070A7D0BA35.dita"><apiname>TUsbcEndpointCaps</apiname></xref>  </p> </entry>
+<entry><p> <filepath>d32usbc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6FBACF89-444D-325B-B56D-59FDBEA0BFC3.dita"><apiname>TUsbcEndpointData</apiname></xref>  </p> </entry>
+<entry><p> <filepath>d32usbc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-468AF207-365F-33DB-A42F-847FEF0652BF.dita"><apiname>TUsbcEndpointInfo</apiname></xref>  </p> </entry>
+<entry><p> <filepath>d32usbc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita"><apiname>DUsbClientController</apiname></xref>  </p> </entry>
+<entry><p> <filepath>usbc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita"><apiname>TUsbcRequestCallback</apiname></xref>  </p> </entry>
+<entry><p> <filepath>usbc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-0E2BBD18-FD98-3010-9B3D-6719FC47EBF3.dita"><apiname>TUsbcSetup</apiname></xref>  </p> </entry>
+<entry><p> <filepath>usbc.h</filepath>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>Note: <codeph>DUsbClientController</codeph> is mostly internal.
+There are 39 pure virtual functions that need to be implemented in your platform-specific
+layer: </p> <ul>
+<li id="GUID-0272220C-9E61-516C-B9CC-A60DC2C87945"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-03A4F9CC-B666-3110-A997-719C7E661495"><apiname>DUsbClientController::SignalRemoteWakeup()</apiname></xref>  </p> </li>
+<li id="GUID-6769C4EF-F9DB-5296-9BC8-CB992F2ABAA9"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-43A1A895-02D0-3210-B29D-DCBEC711BD66"><apiname>DUsbClientController::DumpRegisters()</apiname></xref>  </p> </li>
+<li id="GUID-9ADC21F2-F16F-592C-B870-CF6C5C19FDDE"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-7A581253-0727-3FA4-880C-AE519305DCFC"><apiname>DUsbClientController::DfcQ()</apiname></xref>  </p> </li>
+<li id="GUID-8B0B24EA-B15C-50EB-8268-32EBCF461337"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-41B9C6B0-4F99-3145-9165-FC23B91F9E4D"><apiname>DUsbClientController::SetDeviceAddress()</apiname></xref>  </p> </li>
+<li id="GUID-6E9BE22A-89EB-557C-9002-46D3C60301EF"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-0A97EDCD-386F-3AB6-9617-174070FCBB64"><apiname>DUsbClientController::ConfigureEndpoint()</apiname></xref>  </p> </li>
+<li id="GUID-5448449F-C54B-5F6A-BE8F-1AA34D3F7AA6"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-515AC24A-C52B-3F83-A7FA-80C9B77646C2"><apiname>DUsbClientController::DeConfigureEndpoint()</apiname></xref> <xref href="GUID-6BD89347-671F-3518-9777-55801A090C79.dita"><apiname/></xref>  </p> </li>
+<li id="GUID-10B2CA22-5DA3-5902-BE32-163C4234611E"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-D8C18443-2FF8-37FF-ADE1-4995D49C4A94"><apiname>DUsbClientController::AllocateEndpointResource()</apiname></xref> </p> </li>
+<li id="GUID-A42A3373-9C49-5F71-8E4E-C725EEAF3DED"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-B5AA7790-27C5-3BB0-973E-A3361F492B8B"><apiname>DUsbClientController::DeAllocateEndpointResource()</apiname></xref> </p> </li>
+<li id="GUID-C613DDF5-E4D5-50D5-B103-E8B698D62746"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-6857A47B-D80C-3DA6-9F0C-EB12E4481718"><apiname>DUsbClientController::QueryEndpointResource()</apiname></xref>  </p> </li>
+<li id="GUID-7B355024-49BF-5B9C-ADF0-C4E8BAF6CCDC"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-907F6988-4336-3160-BD41-7FBECE9C6E88"><apiname>DUsbClientController::SetupEndpointRead()</apiname></xref>  </p> </li>
+<li id="GUID-23F90152-951B-5D43-8555-4D5D51F6408B"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-F7880D1C-7E7D-3214-BF84-8811DA935B0C"><apiname>DUsbClientController::SetupEndpointWrite()</apiname></xref>  </p> </li>
+<li id="GUID-78DBF8CC-EE87-5408-8D1D-56231CD1643D"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-0ED52450-A396-3658-9839-9491DAB2E3C1"><apiname>DUsbClientController::CancelEndpointRead()</apiname></xref>  </p> </li>
+<li id="GUID-9F0DDAD1-AF75-5AB6-BDDB-3369A1406F43"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-F97633DE-6FFA-3E2D-8C6D-31597DE30572"><apiname>DUsbClientController::CancelEndpointWrite()</apiname></xref>  </p> </li>
+<li id="GUID-76AE42E7-7BB4-5EA0-89D8-0F047194C37A"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-B3B4793E-7B75-3C40-A6FA-CD17B460CC73"><apiname>DUsbClientController::SetupEndpointZeroRead()</apiname></xref>  </p> </li>
+<li id="GUID-46A1A126-F889-5181-A017-EC3996C8CA72"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-DBE7AC29-8B85-3D98-BAF9-8EF059B33331"><apiname>DUsbClientController::SetupEndpointZeroWrite()</apiname></xref> </p> </li>
+<li id="GUID-291FFD18-611B-5285-A957-23305ABAFDCA"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-95CCCE69-C8AA-39B1-8152-37AA0A7B9CEB"><apiname>DUsbClientController::SendEp0ZeroByteStatusPacket()</apiname></xref> </p> </li>
+<li id="GUID-B648B3AA-6FBF-5503-8C68-A5D7ED5B5A3D"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-B45BBE54-463B-3B54-9025-7CACB947995E"><apiname>DUsbClientController::StallEndpoint()</apiname></xref>  </p> </li>
+<li id="GUID-66B3E4EB-939E-5B66-8B5E-8B9F46F0AB9C"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-D6AF3F08-3CFC-3EEE-BF5F-8DA8A6C189DD"><apiname>DUsbClientController::ClearStallEndpoint()</apiname></xref>  </p> </li>
+<li id="GUID-8B3C1645-1319-524F-AC76-87C98CA1AC70"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-63169150-EEAC-34CE-909D-D985739B555D"><apiname>DUsbClientController::EndpointStallStatus()</apiname></xref>  </p> </li>
+<li id="GUID-BC1E6F3A-ED0D-52A4-AE9A-CA5F36BC0D48"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-F94B97E0-07DB-3468-8E97-EB2C0ED3C899"><apiname>DUsbClientController::EndpointErrorStatus()</apiname></xref>  </p> </li>
+<li id="GUID-ECCF863F-E650-5A30-BEAB-279ADAFF6DFA"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-514602A1-880E-36C7-B3A4-73B91AD12C14"><apiname>DUsbClientController::ResetDataToggle()</apiname></xref>  </p> </li>
+<li id="GUID-51E53D00-0681-5793-89EB-17DA5DE4D805"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-E6B2CF9C-B385-3398-AFAC-95508084371A"><apiname>DUsbClientController::SynchFrameNumber()</apiname></xref>  </p> </li>
+<li id="GUID-9663CBFA-CCE1-5444-B08B-D253A35FEC00"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-2D73F325-E968-350F-B1BB-C8B9B693CF5B"><apiname>DUsbClientController::SetSynchFrameNumber()</apiname></xref>  </p> </li>
+<li id="GUID-E63FBA1A-3B07-549C-824A-8A5F7C4C166D"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-E70BC002-5DC7-3985-B493-379C612B8392"><apiname>DUsbClientController::StartUdc()</apiname></xref>  </p> </li>
+<li id="GUID-948CAB64-C914-509D-91A2-532284E87E1F"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-D3939179-8129-33D1-BD53-9D3D551FB43E"><apiname>DUsbClientController::StopUdc()</apiname></xref>  </p> </li>
+<li id="GUID-54FA4620-BC5C-53FE-9AC5-3EC40CFF85ED"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-837EAD41-64E9-326D-BCAE-434A2E4D9B16"><apiname>DUsbClientController::UdcConnect()</apiname></xref>  </p> </li>
+<li id="GUID-C76D184E-15F7-5028-AA2D-E998031768D8"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-4C703AAE-454A-397F-8F00-71CC9FB6BAFE"><apiname>DUsbClientController::UdcDisconnect()</apiname></xref>  </p> </li>
+<li id="GUID-A91F46EC-55AB-51E1-928A-CBE5DEE8F8F8"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-A2719A78-DAB2-386C-9F65-DE7C1AAEF35F"><apiname>DUsbClientController::UsbConnectionStatus()</apiname></xref>  </p> </li>
+<li id="GUID-F37C1850-D743-5FCF-AF8A-0250B1CBA2BD"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-ECC83E6D-AD55-381B-BC20-F1F5EAF5F93C"><apiname>DUsbClientController::UsbPowerStatus()</apiname></xref>  </p> </li>
+<li id="GUID-3C9C295D-4F26-5FD6-A19E-B4A4095A44FD"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-040A2266-23DB-3261-94A4-40E8905A6C47"><apiname>DUsbClientController::DeviceSelfPowered()</apiname></xref>  </p> </li>
+<li id="GUID-E93E1006-824C-5B49-BA24-5CFED068A654"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-5B09B251-44E8-3DFB-8C03-B25CC6EEE515"><apiname>DUsbClientController::DeviceEndpointCaps()</apiname></xref>  </p> </li>
+<li id="GUID-99813D6D-5F8A-5E72-9CD3-10754893FC75"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-38F1A77F-E8EE-3426-865A-B369BB54DE30"><apiname>DUsbClientController::DeviceTotalEndpoints()</apiname></xref>  </p> </li>
+<li id="GUID-CCDD65CC-3B82-57E0-8577-021AFA43691B"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-CF2E5992-CA28-3D66-BE87-EB040CFE423D"><apiname>DUsbClientController::SoftConnectCaps()</apiname></xref>  </p> </li>
+<li id="GUID-5CB10AED-CDBB-51F6-926D-D1E340F6B10A"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-83DFAE51-6ADB-3B67-8620-9C5A9088DB48"><apiname>DUsbClientController::DeviceStateChangeCaps()</apiname></xref>  </p> </li>
+<li id="GUID-43891A8B-3ECA-5396-8358-D9FEE2CA52F7"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-8C625079-9E35-3DAA-A735-E76F0CCD3310"><apiname>DUsbClientController::Suspend()</apiname></xref>  </p> </li>
+<li id="GUID-0C69380C-EB69-5D93-B216-C8782D90C023"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-4E6F1260-1701-3572-962F-61FC0D5A7D01"><apiname>DUsbClientController::Resume()</apiname></xref>  </p> </li>
+<li id="GUID-49B914A8-3B60-5438-8458-809E457C4B90"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-DD4D0541-6FA5-37EB-A04B-5FE7DBEA89C6"><apiname>DUsbClientController::Reset()</apiname></xref>  </p> </li>
+<li id="GUID-4945A0DC-1252-5A5C-B5BC-846C58B1D409"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-CE068BED-F7BF-3EE6-BDE0-6E6D7CC367A7"><apiname>DUsbClientController::Ep0ReadSetupPktProceed()</apiname></xref> </p> </li>
+<li id="GUID-7E46EC76-83E5-50BC-A5E8-47898F759D59"><p> <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-07830DF4-23D1-38BA-B95B-EF8D480EE773"><apiname>DUsbClientController::Ep0ReceiveProceed()</apiname></xref>  </p> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-BFE1422D-3B4A-5B25-A757-B5B68D6390F8.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,84 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-BFE1422D-3B4A-5B25-A757-B5B68D6390F8" xml:lang="en"><title>Port
+Implementation Tutorial</title><shortdesc>This topic describes how to customize the Base Starter. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-9F925D19-DFAB-5C2A-8A04-E82963F2D221"><title>Creating local
+drive mapping files</title> <ol id="GUID-B20B8E9B-2FA5-57F2-9F06-88ED21D24E87">
+<li id="GUID-BD13EA0C-81E2-5174-BFB0-1857B17BE85B"><p>Create an ASCII text
+file containing your local drive mapping records; see <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-2B95B775-1BD1-5256-86D3-CD3FA12447B9">create local drive mapping files</xref> for information about the syntax
+of the file. </p> </li>
+<li id="GUID-03BE3694-C78E-5A46-B4FF-FCAF55CED8D4"><p>Put this text file into
+your variant source tree. The source tree is typically of the form <filepath>sf/os/boardsupport/.../&lt;your
+                variant&gt;/estart/</filepath> . Depending on your port, you
+might need more than one local drive mapping file. </p> </li>
+<li id="GUID-1850EBF2-71EB-53D6-A2AC-2FE33AEC8AE8"><p>In the <filepath>kernel.iby</filepath> file
+for your variant, you need to add lines to make sure that your local drive
+mapping files are copied into the ROM's <filepath>\sys\data\</filepath> directory
+when the ROM is built. For example include a lines in the form </p> <codeblock id="GUID-B7C15498-DB7E-51CF-83D9-25013ABEC3B8" xml:space="preserve">data=\epoc32\rom\youvariant\ESTARTCOMP.TXT              \Sys\Data\ESTARTCOMP.TXT</codeblock> </li>
+<li id="GUID-2808A5CB-D270-56D7-BE0E-BA476A31AFC6"><p>If you need more than
+one mapping file, or your single mapping file has a name other than <filepath>ESTART.TXT</filepath>,
+then you need to customise the function <xref href="GUID-9A65BCC6-FC1B-349E-BF8C-AEDE8F2549B7.dita#GUID-9A65BCC6-FC1B-349E-BF8C-AEDE8F2549B7/GUID-F46A932C-8CC0-3F39-8C68-38C2660F86E7"><apiname>TFSStartUp::LocalDriveMappingFileName()</apiname></xref> so
+that you can return the appropriate file name at run time. </p> </li>
+</ol> </section>
+<section id="GUID-51FBCDD1-7DB4-556D-9599-5F8B54837852"><title>Making use
+of auto detection</title> <p>To make use of auto-detection, you need to ensure
+that your variant cannot find local drive mapping files in your ROM's <filepath>\sys\data\</filepath> directory.
+If you are using the default version of <xref href="GUID-9A65BCC6-FC1B-349E-BF8C-AEDE8F2549B7.dita#GUID-9A65BCC6-FC1B-349E-BF8C-AEDE8F2549B7/GUID-F46A932C-8CC0-3F39-8C68-38C2660F86E7"><apiname>TFSStartUp::LocalDriveMappingFileName()</apiname></xref>,
+then make sure that no file exists with the full path name <filepath>Z:\sys\data\estart.txt</filepath>. </p> </section>
+<section id="GUID-AA916F3A-E8DF-522D-BDD6-18C2FD82AC16"><title>Customising
+code</title> <p>The most common customisation is to provide your own implementation
+of the <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartup</apiname></xref> virtual functions. To do this: </p> <ol id="GUID-7C709736-88C7-5770-8799-44C5DE9B78A2">
+<li id="GUID-A5CB09C7-C008-5ADA-BC1C-BFDC268570B9"><p>Take a copy of <filepath>ESTARTMAIN.CPP</filepath> from <filepath>sf/os/kernelhwsrv/userlibandfileserver/fileserver/estart/</filepath>, and insert your code into this copy. Typically this will include, but is
+not limited to, your implementation of the <xref href="GUID-7A6C0343-7B98-3429-9162-4C0357594230.dita"><apiname>TFSStartup</apiname></xref> virtual
+functions. </p> </li>
+<li id="GUID-A67D8EB7-A4A7-54DE-A46C-BF44FC6F173C"><p>Place the copy into
+your variant's source tree. This is typically of the form <filepath>sf/os/boardsupport/.../&lt;your
+variant&gt;/estart/</filepath>. This is the general pattern for the other ports
+supplied with Symbian platform. </p> </li>
+<li id="GUID-24536FD8-EABF-5E4D-A691-F36FEEBB604C"><p>Create a <filepath>.mmp</filepath> file
+to build your variant's version of the Base Starter. This is usually placed
+in the <filepath>\&lt;youvariant&gt;\</filepath> directory. The general pattern
+looks like this: <filepath>sf/os/boardsupport/.../&lt;your               
+ variant&gt;/estart/estart.mmp</filepath>. Ports to other hardware variants and
+the emulator (WINS) variant follow the same general pattern. </p> </li>
+<li id="GUID-41111731-D21E-53E8-9728-1F2E8B2977B9"><p>Your <filepath>.mmp</filepath> file
+should pick up the Symbian platform generic code from <filepath>sf/os/kernelhwsrv/userlibandfileserver/fileserver/estart/estart.cpp</filepath>,
+but should pick up your variant's customised source code from <filepath>sf/os/boardsupport/.../&lt;your
+variant&gt;/estart/estartmain.cpp</filepath>. The general pattern is to give
+the resulting executable the name <filepath>e32strt.exe</filepath>. </p> </li>
+<li id="GUID-FBBE887B-69D6-5904-8BD6-7E67F1B049B7"><p>In the <filepath>kernel.iby</filepath> file
+for your variant, you need to add a line that copies your executable into
+the ROM's <filepath>\sys\bin\</filepath> directory when the ROM is built.
+For example, include a line of the form: </p> <codeblock id="GUID-DF458ADA-69B8-5AC3-92D1-F57B9C14C326" xml:space="preserve">file=\Epoc32\Release\##MAIN##\##BUILD##\_##VARIANT##_e32strt.exe        sys\bin\estart.exe HEAPMAX(0x2000)</codeblock> </li>
+</ol> </section>
+<section id="GUID-92EE546A-2945-55EC-A0C3-4CE2ED7926CF"><title>Removing auto
+detect from the Base Starter</title> <p>You do this only if you need to save
+code space, and you do not need the autodetect functionality. </p> <p>See
+also <xref href="GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D.dita#GUID-8BA1EEC2-78A3-54CC-95D9-81BF2659963D/GUID-A195BD51-80C7-5D87-ABA2-8878CC509B84">Use
+automatic local drive mapping</xref>. </p> <ol id="GUID-6B18F11A-5271-5E04-A246-3143A856722B">
+<li id="GUID-D86AD2FB-EDF7-5A95-949E-3C7BE9B609F0"><p>Create a <filepath>.mmp</filepath> file
+to build your variant's version of the Base Starter. This is usually placed
+in the <filepath>sf/os/boardsupport/.../&lt;your variant&gt;/estart/</filepath> directory.
+This shows the general pattern. Ports to other hardware variants and the emulator
+(WINS) variant follow the same general pattern. </p> </li>
+<li id="GUID-CFA6F952-2637-5999-8C06-191B8C9B81EB"><p>In your <filepath>.mmp</filepath> file,
+define the macro: </p> <codeblock id="GUID-7DCF288E-CF86-550F-95BB-33CDAF342C66" xml:space="preserve">MACRO AUTODETECT_DISABLE</codeblock> </li>
+<li id="GUID-3CD0D0C9-5CA5-5CCA-A918-5076DD38C576"><p>The location of all
+source files in the <filepath>.mmp</filepath> file will be <filepath>sf/os/kernelhwsrv/userlibandfileserver/fileserver/estart/</filepath>. </p> </li>
+<li id="GUID-9D679A09-134A-5E09-9A29-79D52B6BE975"><p>In the <filepath>kernel.iby</filepath> file
+for your variant, you need to add a line to make sure that your executable
+is copied into the ROM's <filepath>\sys\bin\</filepath> directory when the
+ROM is built. For example, include a line of the form </p> <codeblock id="GUID-F893D88D-212A-5396-AB64-918CB48A37A1" xml:space="preserve">file=\Epoc32\Release\##MAIN##\##BUILD##\_##VARIANT##_e32strt.exe        sys\bin\estart.exe HEAPMAX(0x2000)</codeblock> <p>This is the general pattern for the other ports supplied with Symbian
+platform. </p> </li>
+</ol> </section>
+<section id="GUID-251E3B54-AB58-4FE4-8E81-0ED48484C1FD"><title>See also</title> <p><xref href="GUID-E5459A54-14BC-55C1-B911-63415E4C61A6.dita">Concepts</xref>  </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C059F39F-BC53-5C92-B05E-863B8CF22859.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C059F39F-BC53-5C92-B05E-863B8CF22859" xml:lang="en"><title>Command
+Objects</title><shortdesc>The MultiMediaCard controller uses a <codeph>TMMCCommandDesc</codeph> object
+to contain command and parameter information when issuing a command over the
+bus.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> This object is also used to contain response information resulting from
+the execution of that command. </p>
+<p>As it can sometimes be necessary to temporarily save current command and
+parameter information, the controller implements a small stack of <xref href="GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A.dita"><apiname>TMMCCommandDesc</apiname></xref> objects.
+The controller then has the concept of a <i>current</i> command information
+object. </p>
+<p>The platform independent layer provides three functions through which command
+and parameter information can be set up: </p>
+<ul>
+<li id="GUID-2E6A2192-CC7E-519C-9918-F9A21A340D7B"><p>Two variants of <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-DBD4FF2D-5443-3993-B63E-A19606D07C92"><apiname>DMMCStack::CurrentSessFillCmdDesc()</apiname></xref> </p> </li>
+<li id="GUID-95BD9ED0-773A-588E-801E-F248745A2160"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-0629AAB8-4F6D-363D-ACCD-EAD31B884211"><apiname>DMMCStack::CurrentSessFillCmdArgs()</apiname></xref> </p> </li>
+</ul>
+<p>These functions are used to fill the <i>current</i> <xref href="GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A.dita"><apiname>TMMCCommandDesc</apiname></xref> object. </p>
+<p>The controller executes a single command by calling the state machine function <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-A48C1C16-B465-3DDA-9C83-00DEB8D27B68"><apiname>DMMCStack::IssueMMCCommandSM()</apiname></xref>;
+this is implemented by the platform specific layer as part of the porting
+activity. </p>
+<p>It calls <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita#GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A/GUID-931547BD-665D-326A-92B5-909B2D57F8C6"><apiname>DMMCSession::Command()</apiname></xref> to access the <i>current</i> command
+and parameter information. </p>
+<section id="GUID-0F16D5E0-9A9F-597C-9865-4D44C39BD78E"><title>The command
+stack</title> <p>Internally, the command stack is implemented as a simple
+array of <xref href="GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A.dita"><apiname>TMMCCommandDesc</apiname></xref> objects; this is the <codeph>DMMCSession::iCommand[]</codeph> private
+data member. The stack is <codeph>KMaxMMCCommandStackDepth</codeph> deep.
+Internally, the current command information object is identified and accessed
+through the <codeph>DMMCSession::iCmdSP</codeph> data member, which indexes
+into the array and acts as a pointer to the current command information object. </p> <p>The
+platform independent layer provides two protected functions that the platform
+specific layer can use to change the command information object that is current: </p> <ul>
+<li id="GUID-6DAD8BE5-666C-5C4D-AC45-D5D8BA4E952F"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-FE93890C-249A-3344-BC93-57E690A432C4"><apiname>DMMCStack::CurrentSessPushCmdStack()</apiname></xref> </p> </li>
+<li id="GUID-302438B8-7501-50DE-96FE-8AE7BA3D88B1"><p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-7B55B7E8-373D-39BE-BB15-A9F41E6A0255"><apiname>DMMCStack::CurrentSessPopCmdStack()</apiname></xref> </p> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C06CFF3E-23E9-5E0B-99A1-51B8ED95465F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C06CFF3E-23E9-5E0B-99A1-51B8ED95465F" xml:lang="en"><title>USB
+Client Driver</title><shortdesc>The USB Client Driver is a device driver for USB device
+(client) functionality. This section describes how to create a port
+of it for your phone hardware. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Symbian platform provides a logical device driver, and a generic
+Platform Independent Layer for the physical device driver. The physical
+device driver is called the USB client controller. You must provide
+a Platform Specific Layer of the USB client controller to implement
+the interface to the USB hardware on your phone. </p>
+<p>The USB Manager component in the Short Link Services module provides
+a higher-level framework that can be used to implement and control
+the USB device functions on a phone. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C0DC5D95-2EB5-45D9-A859-78329A4B3EF1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C0DC5D95-2EB5-45D9-A859-78329A4B3EF1" xml:lang="en"><title>SDIO
+Implementation</title><shortdesc>Landing page for SDIO implementation documents.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C2114C7B-705C-4527-836A-C6E72227111A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,139 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C2114C7B-705C-4527-836A-C6E72227111A" xml:lang="en"><title>DMA Testing Guide</title><shortdesc>Describes the required and optional testing for the DMA
+framework.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>You can use the same set of source code to build the following
+DMA test harnesses: </p>
+<ol>
+<li id="GUID-95B78247-5B32-479A-B013-A3FD4D04477E"><p><b>Simulation
+PSL</b>: T_DMASIM.EXE, D_DMASIM.LDD, and DMASIM.DLL. This is a software-simulated
+implementation of DMA that is used mainly for debugging and validating
+the PIL (platform-independent layer), as it simulates all types of
+DMA controller. </p></li>
+<li id="GUID-4090D5D9-7D03-4E68-9870-FA035058F50B"><p><b>User-side
+harness</b>: T_DMA.EXE. </p></li>
+</ol>
+<section id="GUID-34FD4B72-0481-46A3-9EB7-50CA55D01FF9">       <title>DMA test source files</title>       <p>The following test code are
+available to test a DMA port.</p><table id="GUID-999C6533-DEEA-42DA-AAAD-5F9F2E3DB794">
+<tgroup cols="4"><colspec colname="col1"/><colspec colname="col2"/>
+<colspec colname="col3"/><colspec colname="COLSPEC0" colwidth="1.00*"/>
+<thead>
+<row>
+<entry valign="top">File</entry>
+<entry valign="top">Description</entry>
+<entry valign="top">Location</entry>
+<entry valign="top">Usage</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry>t_dma.exe</entry>
+<entry>User-side test harness to test the DMA framework</entry>
+<entry><filepath>/e32test/dma/t_dma.cpp</filepath></entry>
+<entry>Mandatory</entry>
+</row>
+<row>
+<entry>d_dma.ldd</entry>
+<entry>Simulation PSL to test the DMA framework</entry>
+<entry><filepath>/e32test/dma/d_dma.cpp</filepath></entry>
+<entry>Mandatory</entry>
+</row>
+<row>
+<entry>dmasim.dll</entry>
+<entry>Software simulation of DMA controller and the SHAI implemetation</entry>
+<entry><filepath>e32test/dma/dmasim.cpp</filepath></entry>
+<entry>Optional, only used to test software simulated DMA controller.</entry>
+</row>
+<row>
+<entry>t_dmasim.exe</entry>
+<entry>User-side test harness to test the simulated DMA controller</entry>
+<entry><filepath>/e32test/dma/t_dma.cpp</filepath></entry>
+<entry>Optional, only used to test software simulated DMA controller.</entry>
+</row>
+<row>
+<entry>d_dmasim.ldd</entry>
+<entry>Kernel-side test harness to test the simulated DMA controller</entry>
+<entry><filepath>/e32test/dma/d_dma.cpp</filepath></entry>
+<entry>Optional, only used to test software simulated DMA controller.</entry>
+</row>
+</tbody>
+</tgroup>
+</table>     <p><filepath>T_DMA.EXE</filepath> is a user-side harness,
+and is an automatic test included in the <codeph>E32TEST</codeph> suite.
+It assumes that the underlying DMA controller supports memory to memory
+transfers. This executable delegates most of the work to <filepath>D_DMA.LDD</filepath> , a logical device driver that acts as a client
+for the DMA Framework. <filepath>D_DMA.LDD</filepath> links statically
+against <filepath>DMA.DLL</filepath>, the DMA Framework kernel extension
+must be built from the variant.</p><p><filepath>T_DMA.EXE</filepath> delegates most of the work to <filepath>D_DMA.LDD</filepath>, which
+is a logical device driver that acts as a client for the DMA Framework.
+D_DMA.LDD links statically against DMA.DLL, the DMA Framework kernel
+extension must be built from the variant. In practice, this means
+that D_DMA.LDD must be specified in the test <codeph>bld.inf</codeph> for the variant being ported. For an example of this, see <filepath>...\template_variant\test\bld.inf</filepath>. </p><p><filepath>D_DMA.LDD</filepath> calls the <xref href="GUID-3D0A9A03-E210-30EE-A1A1-7DA06E668CAA.dita"><apiname>DmaTestInfo()</apiname></xref> function in the PSL to
+obtain the information on which channels are available to be used
+by T_DMA to allow it to run multiple DMA channels simultaneously.
+This is the template implementation: </p><codeblock xml:space="preserve">struct TDmaTestInfo
+     {
+     /** Maximum transfer size in bytes for all channels (ie. the minimum of all channels' maximum size)*/
+     TInt iMaxTransferSize;
+     /** 3-&gt;Memory buffers must be 4-byte aligned, 7-&gt;8-byte aligned, ... */
+     TUint iMemAlignMask;
+     /** Cookie to pass to DDmaRequest::Fragment for memory-memory transfer*/
+     TUint32 iMemMemPslInfo;
+     /** Number of test single-buffer channels */
+     TInt iMaxSbChannels;
+     /** Pointer to array containing single-buffer test channel ids */
+     TUint32* iSbChannels;
+     /** Number of test double-buffer channels */
+     TInt iMaxDbChannels;
+     /** Pointer to array containing double-buffer test channel ids */
+     TUint32* iDbChannels;
+     /** Number of test scatter-gather channels */
+     TInt iMaxSgChannels;
+     /** Pointer to array containing scatter-gather test channel ids */
+     TUint32* iSgChannels;
+     };
+
+TDmaTestInfo TestInfo = {0, 0, 0, 0, NULL, 0, NULL, 0, NULL};
+
+
+EXPORT_C const TDmaTestInfo&amp; DmaTestInfo()
+//...
+    {
+    return TestInfo;
+    }
+
+</codeblock></section>
+<section id="GUID-A4207DD8-1DE4-4F4C-8EAB-BDEBF2D2A7F0"><title>Test
+application use cases</title><p>The DMA test application is used to
+test:</p><ul>
+<li><p>one shot single buffer transfer</p></li>
+<li><p>one shot double buffer transfer</p></li>
+<li><p>one shot scatter/gather transfer</p></li>
+<li><p>streaming single buffer transfer</p></li>
+<li><p>streaming double buffer transfer</p></li>
+<li><p>streaming scatter/gather transfer</p></li>
+</ul><p>The DMA test application can be used on both reference hardware
+platform and software simulated DMA.</p></section>
+<section id="GUID-DA97B733-2449-4A74-B4A9-0682C8A4DCE0"><title>Limitations</title><p>The DMA test application has the following known limitations:</p><ul>
+<li><p> only supports one shot and streaming data transfer</p></li>
+<li><p>many parameters such as the number of buffers, the transfer
+size and the number of fragments are fixed</p></li>
+<li><p>does not support performance measurements like CPU usage, setup
+time and transfer time</p></li>
+<li><p>does not support memory to peripheral data transfer</p></li>
+<li><p>does not support SMP related testing like allocating DFC on
+same core or different core.</p></li>
+</ul></section>
+</conbody><related-links>
+<link href="GUID-95A33491-17AC-4F12-948E-A1352ADDA483.dita"><linktext>DMA
+Implementation Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C22974D8-CFB9-4A83-BE58-CCC97EA8DF13.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C22974D8-CFB9-4A83-BE58-CCC97EA8DF13" xml:lang="en"><title>Device
+Driver Writing Guide</title><shortdesc>This set of documents explains how to write a device driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C244D421-8BD0-4212-A5C5-47A8B1E0C1E2.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C244D421-8BD0-4212-A5C5-47A8B1E0C1E2" xml:lang="en"><title>Kernel
+Extension</title><shortdesc>This document describes how to implement a device driver as a kernel
+extension.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-D3EEB917-368E-45A3-866E-C63490994C59">             <p>Device
+drivers can also be kernel extensions, which means that they are loaded by
+the Kernel when it boots. They are used for extending the Kernel, as the name
+suggests. Generally, kernel extensions provide early initialisation of devices
+that must be permanently available, such as LCD, DMA, and I2C and other peripheral
+bus controllers. Because kernel extensions are loaded by the Kernel, they
+are never unloaded and so their destructors are never called. </p> <p>The <codeph>DECLARE_STANDARD_EXTENSION</codeph> macro
+is used to provide an entry point for a kernel extension (see <xref href="GUID-B94FFCA4-1EB3-46A7-9FF9-54C55D67FFE8.dita">Entry
+Points</xref>). </p> <p>Extensions are built into the ROM image, by specifying
+the <codeph>extension</codeph> keyword in the <filepath>.iby</filepath> file.
+This enables the ROM build tool to build the ROM header. The extensions are
+loaded in the order specified in the <filepath>kernel.iby</filepath> file. </p> <codeblock id="GUID-1AABD1B3-BF5A-50FC-9B1F-86E657F9890D" xml:space="preserve">extension[VARID]=\Epoc32\Release\&lt;assp&gt;\urel\KDEBUG.DLL \System\Bin\kdebug.dll</codeblock> <p>A
+kernel extension's interface to other Kernel side components is usually exported
+using a static interface. Clients can access this interface by using the global
+instance of the object created and initialised in the <codeph>DECLARE_STANDARD_EXTENSION</codeph> entry
+point. They then use this object to call the exported API. </p> <p>Kernel
+extensions can also be implemented that let user code open channels on them
+to use the interface. This model is used for devices where initialisation
+has to be done at system boot up, but which can then be used by the clients,
+for example, the media driver <filepath>elocd.ldd</filepath>. </p> <p>To do
+this, drivers have to declare <xref href="GUID-38771B51-195D-3148-A462-277DA3696117.dita"><apiname>DECLARE_EXTENSION_LDD</apiname></xref> in
+addition to the <xref href="GUID-8B6DF6D7-4995-3564-9303-272500D7E747.dita"><apiname>DECLARE_STANDARD_EXTENSION</apiname></xref> macro. In this
+model, extensions generally call <xref href="GUID-671F731F-428F-379D-8260-D9F18CAC25CF.dita#GUID-671F731F-428F-379D-8260-D9F18CAC25CF/GUID-ADB60188-13D4-3245-96D0-4D44CB983551"><apiname>Kernel::InstallLogicalDevice()</apiname></xref> /<xref href="GUID-671F731F-428F-379D-8260-D9F18CAC25CF.dita#GUID-671F731F-428F-379D-8260-D9F18CAC25CF/GUID-703E2FAD-A71C-377B-86F0-D19643D4CDA9"><apiname>Kernel::InstallPhysicalDevice()</apiname></xref> to
+install the logical device. Later clients can open channels on this driver
+and use the interface in the same way as a standard driver. </p> <codeblock id="GUID-29B10898-2CCA-5D03-B14A-CAD3C56EB73F" xml:space="preserve">DECLARE_STANDARD_EXTENSION()
+    {
+    ...
+    // Create factory object
+    DExDriverLogicalDevice* device = new DExDriverLogicalDevice;
+    if (device==NULL)
+        r=KErrNoMemory;
+    else
+        {
+        // Installs the logical device by calling the second
+        // phase constructor
+        r=Kern::InstallLogicalDevice(device);
+        }
+    return r;
+    }
+
+DECLARE_EXTENSION_LDD()
+    {
+    return new DExDriverLogicalDevice;
+    }</codeblock>     </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C24A5B52-0B40-53B2-BF85-6ECC35BDCBA5.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,116 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C24A5B52-0B40-53B2-BF85-6ECC35BDCBA5" xml:lang="en"><title>IIC Implementation Guide</title><shortdesc>Describes how to implement the IIC platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This document describes the overview of how to implement the IIC
+platform service APIs and directs you to more specific documentation. </p>
+<section id="GUID-16DD5496-C5F7-43C3-9C90-119E32AD50FE"><title>Purpose</title> <p>The IIC platform service APIs provides a means of accessing devices
+that are connected onto a multi-wire bus within the phone. These platform
+service APIs rely on hardware-specific implementation in the SHAI
+implementation layer of the IIC implementation. This hardware-specific
+implementation is primarily creating concrete hardware-specific implementations
+of functions defined in the Platform Independent Layer (PIL),.</p> <p><b>Intended Audience:</b> </p> <p>This document is intended for
+hardware device implementers who want to write adaptation software
+to use their specific serial bus hardware with IIC. </p> </section>
+<section id="GUID-A0142A52-534D-4C0D-8145-85C0A84DDBB5"><title>Background</title><p>There are two main forms of IIC operation: </p><ul>
+<li><p>Master operation</p></li>
+<li><p>Slave mode </p></li>
+</ul><p>A master node on a bus controls transactions and is responsible
+for sending commands along the bus to select the slave node which
+is to send or receive the commands and data. A slave node receives
+instructions from a master node and sends or receives commands and
+data. The OS device drivers may act as a slave or a master node, or
+in some bus technologies, the role of master and slave can be exchanged.</p><p>IIC has channels, which represent a connection between two nodes
+on the bus. The channel has a queue for commands and will process
+each command in turn. </p><p>A device driver can either use the IIC
+Controller to access channels, or if there is a dedicated node that
+is going to be used by a particular device driver, then the device
+driver can talk directly to that node through IIC without using the
+IIC Controller.</p> </section>
+<section id="GUID-5CF49F33-E7B8-4FE6-AB97-A6B5EB38F9FF"><title>The
+IIC platform service API</title> <p>The <codeph>IicBus</codeph> class
+provides the platform service API for device drivers that want to
+use the IIC Controller. For Controller-less operation, the platform
+service API is formed by the <codeph>DIicBusChannelMaster</codeph>, <codeph>DIicBusChannelSlave</codeph> and <codeph>DIicBusChannelMasterSlave</codeph> classes.</p> <p>A summary of methods in the <codeph>IicBus</codeph> class are : </p> <table id="GUID-C77D090D-F2CA-500A-9E75-EDF80CB60CA5">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Method</b>  </p> </entry>
+<entry><p> <b>Purpose</b>  </p> </entry>
+</row>
+<row>
+<entry><p>QueueTransaction(TInt aBusId, TIicBusTransaction* aTransaction) </p> </entry>
+<entry><p>Queues a transaction for synchronous completion. </p> </entry>
+</row>
+<row>
+<entry><p>QueueTransaction(TInt aBusId, TIicBusTransaction* aTransaction,
+TIicBusCallback* aCallback) </p> </entry>
+<entry><p>Queues a transaction for asynchronous completion. </p> </entry>
+</row>
+<row>
+<entry><p>CancelTransaction(TInt aBusId, TIicBusTransaction* aTransaction) </p> </entry>
+<entry><p>Cancels a previously queued transaction (if the transaction
+was queued asynchronously). </p> </entry>
+</row>
+<row>
+<entry><p>CaptureChannel(TInt aBusId, TDes8* aConfigHdr, TIicBusSlaveCallback*
+aCallback, TInt&amp; aChannelId, TBool aAsynch=EFalse) </p> </entry>
+<entry><p>Capture a slave channel. </p> <p>The aAsynch parameter indicates
+if this is to be done synchronously or asynchronously. The default
+is synchronous. </p> </entry>
+</row>
+<row>
+<entry><p>ReleaseChannel(TInt aChannelId) </p> </entry>
+<entry><p>Release a previously captured Slave channel. </p> </entry>
+</row>
+<row>
+<entry><p>RegisterRxBuffer(TInt aChannelId, TPtr8 aRxBuffer, TInt8
+aBufGranularity, TInt8 aNumWords, TInt8 aOffset) </p> </entry>
+<entry><p>Register a receive buffer with this slave channel. </p> </entry>
+</row>
+<row>
+<entry><p>RegisterTxBuffer(TInt aChannelId, TPtr8 aTxBuffer, TInt8
+aBufGranularity, TInt8 aNumWords, TInt8 aOffset) </p> </entry>
+<entry><p>Register a transmit buffer with this slave channel. </p> </entry>
+</row>
+<row>
+<entry><p>SetNotificationTrigger(TInt aChannelId, TInt aTrigger) </p> </entry>
+<entry><p>For a transmit operation, this sets the notification trigger,
+sets the receive path and starts a transmit operation (if the node
+is being addressed). For a receive operation, this sets the notification
+trigger. </p> </entry>
+</row>
+<row>
+<entry><p>StaticExtension(TUint aId, TUint aFunction, TAny* aParam1,
+TAny* aParam2) </p> </entry>
+<entry><p>Interface to provide extended functionality. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>The platform service APIs for controller-less operation
+are almost exactly the same, but with the addition of channel constructors
+and destructors.<note> Please refer to <filepath>iic.h</filepath>, <filepath>iic_channel.cpp</filepath>and <filepath>iic_channel.h</filepath> for
+more details on these APIs. </note> </p> </section>
+<section id="GUID-7A8667A0-6061-446C-AE93-6BD3E0DB4952"><title>Implementation
+details</title><p>You must next read:<ul>
+<li><p><xref href="GUID-052F58B7-117B-5EDD-A3D5-CB0DE6A4E239.dita">IIC
+SHAI Implementation Layer: Generic Considerations</xref></p></li>
+<li><p><xref href="GUID-0C8318B1-71D7-5384-97EB-85CBBC3E6B84.dita">IIC
+SHAI Implementation Layer: Master Channel</xref></p></li>
+<li><p><xref href="GUID-C9644081-004E-5DA0-8133-A32EEA91EF5E.dita">IIC
+SHAI Implementation Layer: Slave Channel</xref></p></li>
+</ul></p><p/></section>
+</conbody><related-links>
+<link href="GUID-C661BFA4-6C39-476A-8DE0-08E18AA0F548.dita"><linktext>IIC
+Overview</linktext></link>
+<link href="GUID-CB0FC4F4-6DAB-4ADD-B044-0E8B9365B4D5.dita"><linktext>IIC
+Concepts Overview</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C34DFF54-87C5-47F6-B0AE-3B066DC7F5A0.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C34DFF54-87C5-47F6-B0AE-3B066DC7F5A0" xml:lang="en"><title>Register Access Testing Guide</title><shortdesc>Describes the test suites required to test the Register
+Access platform service implementation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There is no specific test suite available for Register Access platform
+service.</p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C38DA704-8868-479B-AF81-375E0A2F5BCC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C38DA704-8868-479B-AF81-375E0A2F5BCC" xml:lang="en"><title>Name</title><shortdesc>This document describes how names are assigned to device drivers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-905BD0EF-85EB-4568-B810-0D0D40B3CFDA">             <p>Each
+Symbian platform device driver has a name. When the driver is
+loaded by the user, LDDs and PDDs register themselves using a name. LDDs and
+PDDs have different names, which are used to identify the logical device and
+physical device objects. </p> <p>The following shows how the example device
+drivers set their names: </p> <codeblock id="GUID-83FA2EE4-2193-5D76-A5F8-BA26DCFEBE06" xml:space="preserve">_LIT(KDriverPddName," d_expio.pdd");
+
+// Called while loading PDD
+TInt DExH4PhysicalDevice::Install()
+    {
+    return SetName(&amp;KDriverPddName);
+    }</codeblock> <codeblock id="GUID-B0A503EE-F823-51F4-B7BD-A9852E1B0864" xml:space="preserve">_LIT(KDriverName, " d_expio");
+
+// Called while loading LDD
+TInt DExDriverLogicalDevice::Install()
+    {    
+    return SetName(&amp;KDriverName);
+    }</codeblock> <p>The framework uses driver names to identify the PDDs
+that can be used with a given LDD. This can happen in two ways: </p> <ul>
+<li id="GUID-0801CDDD-D1FB-531A-9361-97707C35C2D1"><p>The framework uses the
+name of the PDD factory object passed by the user while creating the logical
+channel. This requires a PDD with that name to be already loaded, and its
+factory object created. The framework searches for a PDD factory object with
+the specified name. </p> </li>
+<li id="GUID-A6049F4E-7DC1-5ED9-B40B-1985FF837469"><p>If the user does not
+pass the PDD name explicitly, then the framework searches all PDD factory
+objects that have a name in the form of x.y, where x is the name of the LDD
+factory object. </p> </li>
+</ul>     </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C3C89BD7-A56D-4597-8804-01A25BC71581.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C3C89BD7-A56D-4597-8804-01A25BC71581" xml:lang="en"><title>Data
+Transfer between LDD and PDD</title><shortdesc>This document describes how LDDs and PDDs exchange data.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-F65FC583-DDC7-40B6-B875-44A8D11A2971">      
+      <p>The device driver framework supplies each LDD with a pointer, <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita#GUID-E7550422-5121-3393-A85E-BB797969CD2A/GUID-CF58D3F1-8185-3A91-A7E8-338B43D329A5"><apiname>DLogicalChannelBase::iPdd</apiname></xref>,
+through which it can access PDD functions. The pointer is initialised by the
+Kernel while creating a physical channel. </p> <p>An example of this pointer
+in use: </p> <codeblock id="GUID-55814834-E7CD-5F19-BA09-B91DA25C8FE3" xml:space="preserve">inline DExUartPhysicalChannel * DExDriverLogicalChannel::Pdd()
+    { return (DExUartPhysicalChannel *)iPdd; }
+
+// example use
+Pdd()-&gt;SetDfcQ();</codeblock> <p>Similarly, a PDD can access a LDD, though
+this access must be initialised by the LDD. In the following example, the
+physical channel declares a pointer to a logical channel, which the LDD sets.
+Callbacks to the LDD are done using this pointer. </p> <codeblock id="GUID-A4A52268-B5B9-53D4-9F69-B506F268201D" xml:space="preserve">// PDD channel class
+class DExH4PhysicalChannel: public DBase
+    {
+    ...
+public:
+    DExDriverLogicalChannel* iLdd;
+    }
+
+// Second stage constructor of Logical channel
+TInt DExDriverLogicalChannel::DoCreate(TInt /*aUnit*/, const TDesC8*
+        /*anInfo*/, const TVersion&amp; aVer)
+    {
+    ...
+    Pdd()-&gt;iLdd=this;
+    }
+
+// example use in PDD
+iLdd-&gt;ReceiveDataComplete(KErrNone);</codeblock> <p>The logical channel class, <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita"><apiname>DLogicalChannelBase</apiname></xref>,
+also has pointers to a logical device (<codeph>iDevice</codeph>) and a physical
+device (<codeph>iPhysicalDevice</codeph>). These pointers are initialised
+during the driver loading and channel open operations, so they can also be
+used to pass information between the LDD and PDD. </p> <codeblock id="GUID-4B86BED0-22CB-53BC-A1C7-9BEB0CEA1EDE" xml:space="preserve">class DLogicalChannelBase: public DObject
+    {
+    ...
+public:
+    DLogicalDevice* iDevice;
+    DPhysicalDevice* iPhysicalDevice;
+    DBase* iPdd;
+    }
+
+// example use
+TDynamicDfcQue* DExUartPhysicalChannelH4::DfcQ(TInt aUnit)
+    {    
+    ...
+    return ((DExH4PhysicalDevice*)
+            (iLdd-&gt;iPhysicalDevice))-&gt;iDfcQueue;    
+    }</codeblock>     </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-C3CE35FF-240E-5385-9088-38EF926ABB7B-master.png has changed
Binary file Adaptation/GUID-C3CE35FF-240E-5385-9088-38EF926ABB7B_d0e29836_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C57086D7-7672-4A52-8634-D28B37AC6290.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,144 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C57086D7-7672-4A52-8634-D28B37AC6290" xml:lang="en"><title>TSDIOFunction
+Class Tutorial</title><shortdesc>Describes the TSDIOFunction API Class.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-9F2D54BC-A431-4FB0-BA25-740229443A4D"><title>Description</title><p>The <xref href="GUID-1342EC36-363F-3E7D-9B5F-4AFD3BAC98C8.dita"><apiname>TSDIOFunction</apiname></xref> class
+provides access to functionality common to all SDIO functions. It may be used
+as a base class for particular functions such as UART.</p><table id="GUID-9BD7FCBC-1B44-4E95-BEDD-6FA72435466A">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p>Header file</p></entry>
+<entry><p><filepath>function.h</filepath></p></entry>
+</row>
+<row>
+<entry><p>Source code file</p></entry>
+<entry><p><filepath>function.cpp</filepath></p></entry>
+</row>
+<row>
+<entry><p>Required libraries</p></entry>
+<entry><p>EPBUSSDIO</p></entry>
+</row>
+<row>
+<entry><p>Class declaration</p></entry>
+<entry><p><codeph>class TSDIOFunction</codeph></p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-DBB544CC-A118-4954-A1BF-EED915A0D69E-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-10-1-3-2"><title>Enable()</title><p>The
+function declaration for the <xref href="GUID-1B8F9258-D611-39DC-B0A7-8BB634915752.dita"><apiname>Enable()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt Enable(TBool aPollReady = ETrue);</codeblock><p><b>Description</b></p><p>Enables the function by writing to the appropriate
+register in the CCCR.</p><p><b>Parameters</b></p><p><table id="GUID-089FA8D7-150A-4D56-9629-034C5A1176E7">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TBool aPollReady</codeph></p></entry>
+<entry>If <codeph>aPollReady == ETrue</codeph>, then the  function shall attempt
+to enable the function, then poll for the recommended enable period until
+the function is enabled, or times out.  Otherwise, flow returns control to
+the calling function who should be responsible for polling the IO_READY bit
+(using <codeph>TSDIOFunction::IsReady</codeph>)</entry>
+</row>
+</tbody>
+</tgroup>
+</table></p><p><b>Return value</b></p><p><codeph>KErrNone</codeph> if successful,
+otherwise a standard Symbian platform error code.</p></section>
+<section id="GUID-DBB544CC-A118-4954-A1BF-EED915A0D69E-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-10-1-3-3"><title>Disable()</title><p>The
+function declaration for the <codeph>Disable()</codeph> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt Disable();</codeblock><p><b>Description</b></p><p>Disables
+the function by writing to the appropriate register in the CCCR.</p><p><b>Parameters</b></p><p>None</p><p><b>Return
+value</b></p><p><codeph>KErrNone</codeph> if successful, otherwise a standard
+Symbian platform error code.</p></section>
+<section id="GUID-DBB544CC-A118-4954-A1BF-EED915A0D69E-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-10-1-3-4"><title>IsReady()</title><p>The
+function declaration for the <xref href="GUID-3ADC7E12-92D2-3BC2-86AC-F11549D171F2.dita"><apiname>IsReady()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt IsReady(TBool&amp; aIsReady);</codeblock><p><b>Description</b></p><p>Disables the function by writing to the appropriate register in the
+CCCR.</p><p><b>Parameters</b></p><p><table id="GUID-A9A28DB1-1BAB-4D62-A35B-3B428EDA2855">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TBool&amp; aIsReady</codeph></p></entry>
+<entry>Returns the current state of the function.</entry>
+</row>
+</tbody>
+</tgroup>
+</table></p><p><b>Return value</b></p><p><codeph>KErrNone</codeph> if successful,
+otherwise a standard Symbian platform error code.</p></section>
+<section id="GUID-DBB544CC-A118-4954-A1BF-EED915A0D69E-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-10-1-3-5"><title>RegisterClient()</title><p>The
+function declaration for the <xref href="GUID-DDAB5214-FCA7-31FC-AE05-EC615D3033A3.dita"><apiname>RegisterClient()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt RegisterClient(DBase* aHandle, DMutex* aMutexLockP = NULL);</codeblock><p><b>Description</b></p><p>Registers the client with the function.</p><p><b>Parameters</b></p><p><table id="GUID-A641F0CF-B691-48D8-9CC5-D5549D2AA8AC">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>DBase* aHandle</codeph></p></entry>
+<entry>The unique Client ID</entry>
+</row>
+<row>
+<entry><p><codeph>DMutex* aMutexLockP</codeph></p></entry>
+<entry>The client's data access mutex which locks access to the register interface.
+Use of the mutex is optional and the parameter is initialized to NULL.</entry>
+</row>
+</tbody>
+</tgroup>
+</table></p><p><b>Return value</b></p><p><codeph>KErrNone</codeph> if successful,
+otherwise a standard Symbian platform error code.</p></section>
+<section id="GUID-DBB544CC-A118-4954-A1BF-EED915A0D69E-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-10-1-3-6"><title>DeregisterClient()</title><p>The
+function declaration for the <xref href="GUID-26EF04A7-86EA-3BB0-89A6-BAB007DF6789.dita"><apiname>DeregisterClient()</apiname></xref> method
+is:</p><codeblock xml:space="preserve">IMPORT_C TInt DeregisterClient(DBase* aHandle);</codeblock><p><b>Description</b></p><p>Deregisters
+the client from the function.</p><p><b>Parameters</b></p><p><table id="GUID-5A5C241A-CF86-4322-9393-554D9E14D866">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>DBase* aHandle</codeph></p></entry>
+<entry>The unique Client ID.</entry>
+</row>
+</tbody>
+</tgroup>
+</table></p><p><b>Return value</b></p><p><codeph>KErrNone</codeph> if successful,
+otherwise a standard Symbian platform error code.</p></section>
+<section id="GUID-DBB544CC-A118-4954-A1BF-EED915A0D69E-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-10-1-3-7"><title>SetPriority()</title><p>The
+function declaration for the <xref href="GUID-A2BDF5F7-06F0-3788-905E-D53FC9C67446.dita"><apiname>SetPriority()</apiname></xref> method is:</p><codeblock xml:space="preserve">IMPORT_C TInt SetPriority(TSDIOFunctionPriority aPriority);</codeblock><p><b>Description</b></p><p>This sets the priority of accesses to the function.
+   It is intended to allow the suspend/resume protocol to determine whether
+an access to a lower  priority function should become suspended while a higher
+priority function is accessed.  Note that the Suspend/Resume protocol is not
+currently implemented, but may be in a future release.</p><p><b>Parameters</b></p><p><table id="GUID-07E6378A-389D-4D47-83D4-24341B2BDE54">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>TSDIOFunctionPriority aPriority</codeph></p></entry>
+<entry>The requested function priority.</entry>
+</row>
+</tbody>
+</tgroup>
+</table></p><p><b>Return value</b></p><p><codeph>KErrNone</codeph> if successful,
+otherwise a standard Symbian platform error code.</p></section>
+<section id="GUID-DBB544CC-A118-4954-A1BF-EED915A0D69E-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-10-1-3-8"><title>RegisterInterface()</title><p>The
+function declaration for the <xref href="GUID-151B6393-D5BC-3A21-B87C-B88F65816473.dita"><apiname>RegisterInterface()</apiname></xref> method
+is:</p><codeblock xml:space="preserve">inline DSDIORegisterInterface* RegisterInterface(DBase* aHandle) const;</codeblock><p><b>Description</b></p><p>Returns
+a pointer to an instance of a <xref href="GUID-CC5352E2-DB21-393F-A7A4-108AA3684460.dita"><apiname>DSDIORegInterface</apiname></xref> class that
+may be used by a client to talk to the Function Specific Registers.</p><p><b>Parameters</b></p><p><table id="GUID-E2E3AEFE-C385-4022-80A0-4C0091F1273D">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p><codeph>DBase* aHandle</codeph></p></entry>
+<entry>The ID of the client as registered using <xref href="GUID-DDAB5214-FCA7-31FC-AE05-EC615D3033A3.dita"><apiname>RegisterClient()</apiname></xref>.</entry>
+</row>
+</tbody>
+</tgroup>
+</table></p><p><b>Return value</b></p><p>A pointer to the <xref href="GUID-6BD11B5F-2269-3317-A40D-6547042CA463.dita"><apiname>DSDIORegisterInterface</apiname></xref> associated
+with this function.</p></section>
+<section id="GUID-DBB544CC-A118-4954-A1BF-EED915A0D69E-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-10-1-3-9"><title>Interrupt()</title><p>The
+function declaration for the <xref href="GUID-95ABF84D-AF13-3B31-A3D2-D099F6C87C64.dita"><apiname>Interrupt()</apiname></xref> method is:</p><codeblock xml:space="preserve">inline TSDIOInterrupt&amp; Interrupt();</codeblock><p><b>Description</b></p><p>Returns a reference to a TSDIOInterrupt class that may be used by
+the client to enable the use of interrupts for the function.</p><p><b>Parameters</b></p><p>None</p><p><b>Return
+value</b></p><p>A reference to the interrupt class associated with this function.</p></section>
+<section id="GUID-DBB544CC-A118-4954-A1BF-EED915A0D69E-GENID-1-2-1-10-1-5-1-9-1-1-7-1-4-1-10-1-3-10"><title>Capabilities()</title><p>The
+function declaration for the <xref href="GUID-5EF2EECD-B9A0-3A76-A7F1-3C196AABFC40.dita"><apiname>Capabilities()</apiname></xref> method is:</p><codeblock xml:space="preserve">inline const TSDIOFunctionCaps&amp; Capabilities() const;</codeblock><p><b>Description</b></p><p>Returns information about the basic capabilities
+of the function (function number, function type etc.).</p><p><b>Parameters</b></p><p>None</p><p><b>Return
+value</b></p><p>A pointer to the <xref href="GUID-6BD11B5F-2269-3317-A40D-6547042CA463.dita"><apiname>DSDIORegisterInterface</apiname></xref> associated
+with this function.</p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C649DB97-F138-4C90-B177-16590F2E3F19-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-3-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C649DB97-F138-4C90-B177-16590F2E3F19-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-3-1" xml:lang="en"><title>DMA Channels</title><shortdesc>Describes how device drivers use DMA channels.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The DMAC has different DMA channels that can be configured for
+different DMA transfers. For some peripherals, such as the Camera
+and the Display controller, there can be dedicated DMA channels that
+cannot be configured for DMA transfers by other peripherals. However,
+drivers generally initialize and open a multi-purpose DMA channel
+and use that channel to perform the DMA transfers.</p>
+<p>Initialization and opening of DMA channels is done using the interface <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref>. </p>
+<note>This class is designed only for single-thread client access.
+When used by multi-threaded clients, synchronization mechanisms should
+be provided by the driver. </note>
+<p>DMA channels must be opened before use and closed after completion
+of DMA operations. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C649DB97-F138-4C90-B177-16590F2E3F19-GENID-1-2-1-9-1-6-1-8-1-7-1-3-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C649DB97-F138-4C90-B177-16590F2E3F19-GENID-1-2-1-9-1-6-1-8-1-7-1-3-1" xml:lang="en"><title>DMA Channels</title><shortdesc>Describes how device drivers use DMA channels.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The DMAC has different DMA channels that can be configured for
+different DMA transfers. For some peripherals, such as the Camera
+and the Display controller, there can be dedicated DMA channels that
+cannot be configured for DMA transfers by other peripherals. However,
+drivers generally initialize and open a multi-purpose DMA channel
+and use that channel to perform the DMA transfers.</p>
+<p>Initialization and opening of DMA channels is done using the interface <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref>. </p>
+<note>This class is designed only for single-thread client access.
+When used by multi-threaded clients, synchronization mechanisms should
+be provided by the driver. </note>
+<p>DMA channels must be opened before use and closed after completion
+of DMA operations. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C661B40F-1439-587F-9E8E-DB2DFC79C040.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C661B40F-1439-587F-9E8E-DB2DFC79C040" xml:lang="en"><title>HAL Groups</title><shortdesc>Description of HAL groups to add new attributes.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>You can extend <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-366CC4B8-C6BD-5DCC-B55D-6D87CD5C8E64">HAL groups</xref> to add new attributes and new types of hardware. </p>
+<section id="GUID-7ACAB5F0-08A8-4D53-9F47-9E77642F7337"><title>Extending
+an existing hardware type</title> <p>Each HAL group has an associated
+set of function numbers. For example, the enumerators of <codeph>TDisplayHalFunction</codeph>, in <filepath>u32std.h</filepath> define the functions associated
+with the HAL group <codeph>EHalGroupDisplay</codeph>. </p> <p>In this
+specific case, new state can be represented by a new function number,
+and by changing the <xref href="GUID-124AC7EE-E227-5358-A755-628FFE257250.dita">HAL handler implementation</xref> to deal with the new function number. </p> <p>It is
+important to note that any new function numbers should not follow
+consecutively from those defined by Symbian. Instead, choose high
+values so that they are guaranteed not to clash with any future Symbian
+extensions. Symbian will always use new values that follow consecutively
+from previous Symbian defined values. </p> </section>
+<section id="GUID-A819D9EA-A16F-4806-B8E8-C7ED008C6D31"><title>New
+hardware type</title> <p>Although up to 32 HAL groups can be defined,
+Symbian platform does not use all 32. This leaves some values that
+can be used for new hardware. </p> <p>In this case choose a HAL group
+number at the high end of the range, so that it is guaranteed not
+to clash with any future Symbian extensions. Symbian will always use
+new values that follow consecutively from previous Symbian defined
+values. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C661BFA4-6C39-476A-8DE0-08E18AA0F548.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C661BFA4-6C39-476A-8DE0-08E18AA0F548" xml:lang="en"><title>IIC Overview</title><shortdesc>Provides a basic summary of the Inter-Integrated Circuit
+(IIC) platform service. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The IIC is a technology-independent interface for serial bus technologies.
+The IIC supports multi-master and multi-slave serial interfaces, used
+by the low power peripherals to exchange control information between
+devices attached to the bus. The IIC supports different modes of data
+transfer.</p>
+<section id="GUID-E67D9AC2-DD3D-48FD-9E48-B79BC73FFE6A-GENID-1-2-1-10-1-5-1-6-1-1-3-1-3-2"><title>What
+is the IIC platform service</title>             <p>The IIC platform
+service provides a set of functions for device drivers to be able
+to use serial interfaces without needing to know the details of the
+actual chipset implementing the particular serial interface technology,
+for example I2C or SPI. The client will however need to understand
+how to configure headers for the particular interface technology.</p><p>For the technical details about IIC, see the <xref href="GUID-DCDD68C7-8EBE-4E91-A983-076460B2C2F3.dita">IIC Quick Start</xref>.</p>         </section>
+<section id="GUID-C0FC9485-8B8C-4F4B-99C0-DAA48FB5E85D"><title>Need
+for the IIC platform service</title><p>IIC is used in a number of
+different areas in the OS. These may include:</p><ul>
+<li><p>controlling flash memory devices</p></li>
+<li><p>controlling the LCD</p></li>
+<li><p>reading data from the Real Time Clock.</p></li>
+</ul><p>The IIC platform service gives a common set of functions to
+initiate a connection and to transfer the data.</p></section>
+<section id="GUID-CEAC0FBB-77F6-48FF-AB70-0E2AB78CA972"><title>IIC
+users</title><p>The IIC documentation covers two types of user: </p><p><ul>
+<li><p>those that want to write device drivers </p></li>
+<li><p>those that need to write SHAI implementation code to interface
+to their particular IIC chipset.</p></li>
+</ul></p></section>
+<section id="GUID-0D17421E-77CC-47CC-A50A-DE9F8E7020BF"><title>Limitations</title><p>IIC is an abstraction interface for several different serial bus
+communication technologies. There may be features of a particular
+technology that are not available through IIC. IIC imposes no throughput
+limitations. </p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C6647E84-7237-44FC-BD5D-2476EC161D02.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C6647E84-7237-44FC-BD5D-2476EC161D02" xml:lang="en"><title>IIC Implementation</title><shortdesc>Describes how to implement the IIC platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C6825C8F-8020-58CF-A09E-34558B1542DE.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C6825C8F-8020-58CF-A09E-34558B1542DE" xml:lang="en"><title>MMC Controller
+Operation</title><shortdesc>This section describes the detailed structure and operation of
+the MMC Controller. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C6ABE2CA-901E-55F1-9837-7018A1612BCF.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C6ABE2CA-901E-55F1-9837-7018A1612BCF" xml:lang="en"><title>Set Up</title><shortdesc>Describes how to use the template port to start your port.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The code for the template port Sound Driver is split into two files: </p>
+<ul>
+<li id="GUID-6CF84764-1EE7-5891-8212-33A1548958B8"><p>This file holds the
+code for the record driver channel </p> <p> <filepath> ...\template\template_variant\specific\soundsc_rx.cpp</filepath>  </p> </li>
+<li id="GUID-3309787F-7D0E-5E9A-A7B0-B55E0A7AA0FB"><p>This file holds code
+for the playback driver channel together with code which is common to both
+channels. </p> <p> <filepath>...\template\template_variant\specific\soundsc_tx.cpp</filepath>  </p> </li>
+</ul>
+<p>The header file for the above can be found in: </p>
+<p> <filepath>...\template\template_variant\inc\soundsc_plat.h</filepath>  </p>
+<p>The template <filepath>.mmp</filepath> file can be found in: </p>
+<p> <filepath>...\template\template_variant\soundsctemplate.mmp</filepath>  </p>
+<p>Following the general pattern, your implementation is contained in the
+directory: </p>
+<p> <filepath>path to your variant\specific</filepath>  </p>
+<p>For example, <filepath>...\omap_hrp\h4\specific</filepath>  </p>
+<p>Now complete these steps: </p>
+<ul>
+<li id="GUID-77DD9781-8D04-50F9-A372-BCED22354FC3"><p>create a copy of the
+template port implementation files <filepath>soundsc_rx.cpp</filepath> and <filepath>soundsc_tx.cpp</filepath>,
+copy them into your variant specific directory </p> </li>
+<li id="GUID-A6A250DB-F4D6-58F5-88A0-C86A919C7076"><p>create a copy of the
+header file <filepath>soundsc_plat.h</filepath>, copy it to the include directory
+for your variant </p> </li>
+<li id="GUID-785D0DF1-7251-5408-ADEA-5BE2CF9CD4F6"><p>rename the Sound Driver
+PDD factory class <filepath>DTemplateSoundScPddFactory</filepath>, to reflect
+the name of your device </p> </li>
+<li id="GUID-0D45F6BD-AB06-5F04-BCC7-D3A7B16FCE20"><p>rename the classes <filepath>DTemplateSoundScRxPdd</filepath> and <filepath>DTemplateSoundScTxPdd</filepath> to reflect the name of your device. </p> </li>
+</ul>
+<p><note> You should also be prepared to add your own private data and functions
+to the Sound Driver. </note></p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C74770A5-ADD4-4AB1-946F-77105E2B8C10-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-6-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,167 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C74770A5-ADD4-4AB1-946F-77105E2B8C10-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-6-1" xml:lang="en"><title>DMA Request Operations</title><shortdesc>Describes the operations which a device driver performs
+on a DMA request.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>After doing the required DMA initialisation, a driver can start
+a DMA operation. To do this, the driver fragments the request and
+then queues the request. </p>
+<section id="GUID-24567A76-814B-4E1C-81CA-61D9142B442B-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-6-1-3-2"><title>Fragment</title> <p>A DMA request must be split into different fragments that are
+small enough to be transferred by the DMAC in a single transaction.
+The size of each fragment is smaller than or equal to the maximum
+transfer size supported by the DMAC. To fragment a DMA request, a
+source and destination address, and the size of data to be transferred,
+must be provided. If the source and/or destination is in memory, each
+fragment points to memory which is physically contiguous. </p> <p>The kind of transfer to perform is specified using a set of flags
+and hardware-specific information. The flags can be: </p> <table id="GUID-52098463-21DE-5D42-8F35-9B6D67CE93BC-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-6-1-3-2-4">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>KDmaMemSrc</codeph>  </p> </entry>
+<entry><p>Source is the address of a memory buffer </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KDmaMmeDest</codeph>  </p> </entry>
+<entry><p>Destination is the address of a memory buffer </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KDmaIncSrc</codeph>  </p> </entry>
+<entry><p>Source address must be post-incremented during transfer </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KDmaIncDest</codeph>  </p> </entry>
+<entry><p>Destination address must be post-incremented during transfer </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KDmaPhysAddrSrc</codeph>  </p> </entry>
+<entry><p>Source address is a physical address (as opposed to a linear
+one) </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KDmaPhysAddrDest</codeph>  </p> </entry>
+<entry><p>Destination address is a physical address (as opposed to
+a linear one) </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>The following shows an example of fragmenting a DMA request: </p> <codeblock id="GUID-E2DE10F1-7E22-5EA6-A05C-1A76B98D1F91-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-6-1-3-2-6" xml:space="preserve">/**
+ Start the DMA transfer. This function fragments the DMA request and 
+ queues it for processing and actually triggers the DMA transfer.
+ 
+ @param    aSource
+        Source address for DMA transfer
+         
+    @param    aCount
+         Size of data to be transferred            
+             
+ @return    KErrNone on success, else standard error code on failure
+ */    
+TInt DExDriverUartTxDma::Start(const TUint8* aSource, TInt aCount)
+    {
+    ...
+    // Fragment the DMA request. DDmaRequest::Fragment() creates 
+    // the DMA descriptor with source, destination address, size 
+    // and attributes.
+    // 
+    // Flags KDmaMemSrc|KDmaIncSrc or KDmaMemDest|KDmaIncDest 
+    // should be set if the source/destination is a memory buffer, 
+    // or cleared if the source/destination is a peripheral. If the address 
+    // specified is physical address instead of linear, 
+    // then specify KDmaPhysAddrSrc or KDmaPhysAddrDest accordingly.
+    //
+    TInt retval = iTxDmaRequest-&gt;Fragment((TUint32)buf,
+            (TUint32)(iUartComm-&gt;iPortAddr + KHoUART_THR), aCount,
+            KDmaMemSrc |KDmaIncSrc, // source is a buffer
+            0 ); // no HW Flags    
+    if(retval != KErrNone)
+        {
+        return retval;
+        }
+    ...
+    }</codeblock> </section>
+<section id="GUID-72984A7F-C2C4-48E5-8656-638D472A2ACD-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-6-1-3-3"><title>Queue</title> <p>DMA transfer is initiated by queuing the DMA request. A device
+driver queues the request by calling <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-0A83F782-DB62-39ED-8D32-DBD5949C8D3F"><apiname>DDmaRequest::Queue()</apiname></xref> after fragmenting the DMA request. This is an asynchronous call
+and the transfer of DMA will actually start once the request is scheduled. </p> <codeblock id="GUID-FD225A28-4AFA-5CE0-A341-2261C97E7D1A-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-6-1-3-3-3" xml:space="preserve">/**
+ Start the DMA transfer. This function fragments the DMA request and 
+ queues it for processing and actually triggers the DMA transfer.
+ @param    aSource Source address for DMA transfer
+ @param    aCount Size of data to be transferred            
+ @return    KErrNone on success, else standard error code on failure
+ */
+TInt DExDriverUartTxDma::Start(const TUint8* aSource, TInt aCount)
+    {
+    ...
+
+    // Queue the DMA request. DDmaRequest::Queue() queues the 
+    // request on the DFCQ. DMA operation starts at this point.
+    //
+    iTxDmaRequest-&gt;Queue();
+
+    ...
+    }</codeblock> <p>If the request channel is idle when a request
+is queued, the request is transferred immediately. Otherwise, it is
+queued and transferred later. The client is responsible for ensuring
+cache consistency before and/or after the transfer if necessary. </p></section>
+<section id="GUID-FA035D89-F593-49C5-84EC-BC5019C63F0B-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-6-1-3-4"><title>Completion
+notification</title><p>This is done by the DMA service callback function.
+The completion notification is as follows:</p> <p>Once the DMA request
+is handled by the DMAC, the DMA service callback function is called
+by the DMA driver. This runs in a DFC context, that is scheduled from
+a DMA interrupt service routine. </p> <p>The DMA service callback
+function pointer must be provided while creating the DMA request: </p> <codeblock id="GUID-0A15F944-F066-52E2-BFB6-D008DF690BA6-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-6-1-3-4-5" xml:space="preserve">iTxDmaRequest = new DDmaRequest(*iTxDmaChannel, TxDmaService, this);</codeblock> <p>The DMA callback function is called for both success and failure
+of the request, so it needs to check the request result. On success,
+the function should either initiate another DMA request, or stop DMA
+and close the request. On failure, the function should stop DMA. </p> <codeblock id="GUID-BD28E559-FA5B-564E-BC00-3BD98C61F201-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-6-1-3-4-7" xml:space="preserve">/**
+ DMA service callback function for transmit. This static function is 
+ called on the completion of DMA transfer request. This function 
+ pointer is provided while creating the DMA request, i.e. in     
+ DDmaRequest(). After the request is queued, the System DMA controller 
+ completes the request and calls this service function. Here, we do 
+ the processing that needs to be done post the DMA request  
+ completion.
+ 
+ This function shall be called both when the DMA request succeeds or fails, 
+    so both must be handled appropriately.
+ 
+ @param    aResult    
+     DMA result, can be DDmaRequest::EOk in case of success, else error
+             
+ @param    aArg pointer passed at time of registration, typically &lt;this&gt; 
+        pointer
+ 
+ @return    none 
+ */
+static void TxDmaService(DDmaRequest::TResult aResult, TAny* aArg)
+    {
+    // Check the result of DMA service function call. It can be 
+    // either of the DDmaRequest::TResult enumerated values.
+    //
+    if ( aResult != DDmaRequest::EOk)
+        {
+        // DMA request failed, so stop the DMA. 
+        Stop ();
+
+        // Notify request completion with an error result
+        ...
+        }
+    else
+        {
+        // DMA request was successful. 
+     // The program can start another DMA request, or stop 
+        // the DMA, if no more DMA requests are needed.
+        // Notify request operation complete with success.
+        ...
+        }
+    }</codeblock></section>
+</conbody><related-links>
+<link href="GUID-6AC01B10-92C1-4E56-813B-6853DFCF3386-GENID-1-2-1-9-1-6-1-8-1-7-1-5-1.dita"><linktext>DMA
+Requests</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C74770A5-ADD4-4AB1-946F-77105E2B8C10-GENID-1-2-1-9-1-6-1-8-1-7-1-6-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,167 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C74770A5-ADD4-4AB1-946F-77105E2B8C10-GENID-1-2-1-9-1-6-1-8-1-7-1-6-1" xml:lang="en"><title>DMA Request Operations</title><shortdesc>Describes the operations which a device driver performs
+on a DMA request.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>After doing the required DMA initialisation, a driver can start
+a DMA operation. To do this, the driver fragments the request and
+then queues the request. </p>
+<section id="GUID-24567A76-814B-4E1C-81CA-61D9142B442B-GENID-1-2-1-9-1-6-1-8-1-7-1-6-1-3-2"><title>Fragment</title> <p>A DMA request must be split into different fragments that are
+small enough to be transferred by the DMAC in a single transaction.
+The size of each fragment is smaller than or equal to the maximum
+transfer size supported by the DMAC. To fragment a DMA request, a
+source and destination address, and the size of data to be transferred,
+must be provided. If the source and/or destination is in memory, each
+fragment points to memory which is physically contiguous. </p> <p>The kind of transfer to perform is specified using a set of flags
+and hardware-specific information. The flags can be: </p> <table id="GUID-52098463-21DE-5D42-8F35-9B6D67CE93BC-GENID-1-2-1-9-1-6-1-8-1-7-1-6-1-3-2-4">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>KDmaMemSrc</codeph>  </p> </entry>
+<entry><p>Source is the address of a memory buffer </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KDmaMmeDest</codeph>  </p> </entry>
+<entry><p>Destination is the address of a memory buffer </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KDmaIncSrc</codeph>  </p> </entry>
+<entry><p>Source address must be post-incremented during transfer </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KDmaIncDest</codeph>  </p> </entry>
+<entry><p>Destination address must be post-incremented during transfer </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KDmaPhysAddrSrc</codeph>  </p> </entry>
+<entry><p>Source address is a physical address (as opposed to a linear
+one) </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>KDmaPhysAddrDest</codeph>  </p> </entry>
+<entry><p>Destination address is a physical address (as opposed to
+a linear one) </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>The following shows an example of fragmenting a DMA request: </p> <codeblock id="GUID-E2DE10F1-7E22-5EA6-A05C-1A76B98D1F91-GENID-1-2-1-9-1-6-1-8-1-7-1-6-1-3-2-6" xml:space="preserve">/**
+ Start the DMA transfer. This function fragments the DMA request and 
+ queues it for processing and actually triggers the DMA transfer.
+ 
+ @param    aSource
+        Source address for DMA transfer
+         
+    @param    aCount
+         Size of data to be transferred            
+             
+ @return    KErrNone on success, else standard error code on failure
+ */    
+TInt DExDriverUartTxDma::Start(const TUint8* aSource, TInt aCount)
+    {
+    ...
+    // Fragment the DMA request. DDmaRequest::Fragment() creates 
+    // the DMA descriptor with source, destination address, size 
+    // and attributes.
+    // 
+    // Flags KDmaMemSrc|KDmaIncSrc or KDmaMemDest|KDmaIncDest 
+    // should be set if the source/destination is a memory buffer, 
+    // or cleared if the source/destination is a peripheral. If the address 
+    // specified is physical address instead of linear, 
+    // then specify KDmaPhysAddrSrc or KDmaPhysAddrDest accordingly.
+    //
+    TInt retval = iTxDmaRequest-&gt;Fragment((TUint32)buf,
+            (TUint32)(iUartComm-&gt;iPortAddr + KHoUART_THR), aCount,
+            KDmaMemSrc |KDmaIncSrc, // source is a buffer
+            0 ); // no HW Flags    
+    if(retval != KErrNone)
+        {
+        return retval;
+        }
+    ...
+    }</codeblock> </section>
+<section id="GUID-72984A7F-C2C4-48E5-8656-638D472A2ACD-GENID-1-2-1-9-1-6-1-8-1-7-1-6-1-3-3"><title>Queue</title> <p>DMA transfer is initiated by queuing the DMA request. A device
+driver queues the request by calling <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita#GUID-780F4D53-5546-3B69-B328-0226C70EBDE2/GUID-0A83F782-DB62-39ED-8D32-DBD5949C8D3F"><apiname>DDmaRequest::Queue()</apiname></xref> after fragmenting the DMA request. This is an asynchronous call
+and the transfer of DMA will actually start once the request is scheduled. </p> <codeblock id="GUID-FD225A28-4AFA-5CE0-A341-2261C97E7D1A-GENID-1-2-1-9-1-6-1-8-1-7-1-6-1-3-3-3" xml:space="preserve">/**
+ Start the DMA transfer. This function fragments the DMA request and 
+ queues it for processing and actually triggers the DMA transfer.
+ @param    aSource Source address for DMA transfer
+ @param    aCount Size of data to be transferred            
+ @return    KErrNone on success, else standard error code on failure
+ */
+TInt DExDriverUartTxDma::Start(const TUint8* aSource, TInt aCount)
+    {
+    ...
+
+    // Queue the DMA request. DDmaRequest::Queue() queues the 
+    // request on the DFCQ. DMA operation starts at this point.
+    //
+    iTxDmaRequest-&gt;Queue();
+
+    ...
+    }</codeblock> <p>If the request channel is idle when a request
+is queued, the request is transferred immediately. Otherwise, it is
+queued and transferred later. The client is responsible for ensuring
+cache consistency before and/or after the transfer if necessary. </p></section>
+<section id="GUID-FA035D89-F593-49C5-84EC-BC5019C63F0B-GENID-1-2-1-9-1-6-1-8-1-7-1-6-1-3-4"><title>Completion
+notification</title><p>This is done by the DMA service callback function.
+The completion notification is as follows:</p> <p>Once the DMA request
+is handled by the DMAC, the DMA service callback function is called
+by the DMA driver. This runs in a DFC context, that is scheduled from
+a DMA interrupt service routine. </p> <p>The DMA service callback
+function pointer must be provided while creating the DMA request: </p> <codeblock id="GUID-0A15F944-F066-52E2-BFB6-D008DF690BA6-GENID-1-2-1-9-1-6-1-8-1-7-1-6-1-3-4-5" xml:space="preserve">iTxDmaRequest = new DDmaRequest(*iTxDmaChannel, TxDmaService, this);</codeblock> <p>The DMA callback function is called for both success and failure
+of the request, so it needs to check the request result. On success,
+the function should either initiate another DMA request, or stop DMA
+and close the request. On failure, the function should stop DMA. </p> <codeblock id="GUID-BD28E559-FA5B-564E-BC00-3BD98C61F201-GENID-1-2-1-9-1-6-1-8-1-7-1-6-1-3-4-7" xml:space="preserve">/**
+ DMA service callback function for transmit. This static function is 
+ called on the completion of DMA transfer request. This function 
+ pointer is provided while creating the DMA request, i.e. in     
+ DDmaRequest(). After the request is queued, the System DMA controller 
+ completes the request and calls this service function. Here, we do 
+ the processing that needs to be done post the DMA request  
+ completion.
+ 
+ This function shall be called both when the DMA request succeeds or fails, 
+    so both must be handled appropriately.
+ 
+ @param    aResult    
+     DMA result, can be DDmaRequest::EOk in case of success, else error
+             
+ @param    aArg pointer passed at time of registration, typically &lt;this&gt; 
+        pointer
+ 
+ @return    none 
+ */
+static void TxDmaService(DDmaRequest::TResult aResult, TAny* aArg)
+    {
+    // Check the result of DMA service function call. It can be 
+    // either of the DDmaRequest::TResult enumerated values.
+    //
+    if ( aResult != DDmaRequest::EOk)
+        {
+        // DMA request failed, so stop the DMA. 
+        Stop ();
+
+        // Notify request completion with an error result
+        ...
+        }
+    else
+        {
+        // DMA request was successful. 
+     // The program can start another DMA request, or stop 
+        // the DMA, if no more DMA requests are needed.
+        // Notify request operation complete with success.
+        ...
+        }
+    }</codeblock></section>
+</conbody><related-links>
+<link href="GUID-6AC01B10-92C1-4E56-813B-6853DFCF3386-GENID-1-2-1-9-1-6-1-8-1-7-1-5-1.dita"><linktext>DMA
+Requests</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,301 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C8217A7B-D741-5452-B95B-57B8978AD152" xml:lang="en"><title>Validation</title><shortdesc>Symbian platform provides test code that you can run to
+validate a USB client port. This topic describes the USB client test
+code.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-9769035E-68E8-59E2-85EA-3F6129AD27D3"><title>Requirements</title> <p>For testing the port, you will need: </p> <ul>
+<li id="GUID-0FFD84ED-C745-551E-BDB7-DD145609928E"><p>A Symbian platform
+text shell ROM image for the device that also contains the USB drivers
+(the LDD and the PDD), and the unit test applications <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-62006D61-5222-5C83-86EC-54CECD4FED18">T_USB</xref> and <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-78E25906-2FF3-572E-B24D-2F064B9DBD89">T_USBAPI</xref>. On a slow CPU you may need to use release (UREL)
+versions of the driver binaries to avoid exceeding the time-out limits
+of the USB protocol. </p> </li>
+<li id="GUID-8E195CED-52E6-53A2-9313-4CF4C0951AB5"><p>A computer running
+either MS Windows 98 or above to run the Symbian host-side
+test program USBRFLCT, or MS Windows 2000 to run, in addition, the <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-E8A9B4BD-E60F-5A08-A588-527347239118">USB Command Verifier (USBCV)</xref> R1.2.1 compliance test program.
+On MS Windows XP you will also be able to run the USBCV R1.3 compliance
+test program. </p> </li>
+<li id="GUID-798B9CED-B0AB-505A-9098-40441F8B79C2"><p>A USB driver
+disk (or some other location accessible to the PC) containing the <filepath>.inf</filepath> file that matches the device to be tested, and the
+driver binary file that will be installed for the device. Note that
+for <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-AC6E3928-C027-56E5-985E-6B7699216FDE">USBRFLCT</xref>, both items are included in the binary program distribution. </p> </li>
+</ul> <p>In addition, a USB analyser, like the ones made by <i>LeCroy</i> formerly CATC, is invaluable for this kind of work. Without this
+equipment it may be impossible to be sure that the port has been fully
+successful. </p> </section>
+<section id="GUID-D77DF810-212A-5C12-B039-4FC785BA01B9"><title>Test
+steps</title> <p>These are the recommended steps for testing the port: </p> <ul>
+<li id="GUID-53C8E7F5-F98F-571B-98D2-FCF2F8E75039"><p>Run <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-78E25906-2FF3-572E-B24D-2F064B9DBD89">T_USBAPI</xref> on the unconnected USB device and get it to pass. </p> </li>
+<li id="GUID-F2B15A4A-AB54-50E8-A5A0-5F4D5B67258D"><p>Use a USB cable
+to connect the device under test to a PC and start <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-62006D61-5222-5C83-86EC-54CECD4FED18">T_USB</xref> on the device (use T_USB menu options '0','1','1' and
+'1'). See if the device successfully delivers all the information
+(descriptors) that the host asks for. If so, a dialogue box pops up
+on the PC, saying “New hardware found” and offering certain options.
+Point the OS to the location of the <filepath>.inf</filepath> files
+and the driver files (the USB driver disk) and have it pick and install
+the correct driver. Afterwards you should see the new USB device in
+the Windows Device Manager under the category <i>Symbian platform
+controlled USB devices</i> as <i>USBRFLCT - Device</i>. If things
+don’t work as expected at this early stage, the USB analyser will
+prove invaluable. </p> </li>
+<li id="GUID-A4E3EB99-B189-54C3-A4FD-BF7F8F65E2DA"><p>Try and run <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-AC6E3928-C027-56E5-985E-6B7699216FDE">USBRFLCT</xref> and <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-AC6E3928-C027-56E5-985E-6B7699216FDE">T_USB</xref> together. First start T_USB on the device, choose the
+four numbered program options (but this time the first menu option
+must not be '0'), and then start USBRFLCT on the PC. The program pair
+should run indefinitely, in any mode. If the program halts after a
+while then this almost certainly indicates either a hardware problem
+associated with the USB device controller or an incorrect handling
+of the controller in the PSL. If the halt occurs after a long time,
+then this could point to a resource problem, such as a memory leak.
+This test will verify that at least one bulk IN endpoint and one bulk
+OUT endpoint are working correctly, and that data can be transferred
+over the USB link. </p> </li>
+<li id="GUID-B88EBB38-3ACE-5F51-802D-360EA919DE5A"><p>Run the USB
+Implementers Forum's <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-E8A9B4BD-E60F-5A08-A588-527347239118">USBCV</xref> compliance test suite and go through the “Chapter 9
+Tests”. You will first need to start <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-62006D61-5222-5C83-86EC-54CECD4FED18">T_USB</xref> on the device end, as <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-E8A9B4BD-E60F-5A08-A588-527347239118">USBCV</xref> needs a successfully enumerated device as a target (choose
+'0' as the first T_USB option). These tests should all pass. It is
+important to run <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-E8A9B4BD-E60F-5A08-A588-527347239118">USBCV</xref> to verify that endpoint-0 is behaving correctly, and
+that the device is compliant with the USB Specification 2.0. </p> </li>
+</ul> </section>
+<section id="GUID-A5CA6D74-1204-5C9C-9396-D51A8E58A952"><title>The
+USBIO driver</title> <p>The host (PC) side test program: <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-3F7462D9-EF86-5CC9-AEC5-EB755049B7CF">USBRFLCT</xref> uses the services of a USB client driver, <filepath>USBIO.SYS</filepath>. This driver is loaded by the OS as part of
+the enumeration once the USB device on test is connected to the PC. </p> <p>The generic USB device driver USBIO is a product developed and
+marketed by the German company <i>Thesycon</i> [USBIO Software Development
+Kit for Windows; see <xref href="http://www.thesycon.de/usbio/eng/usbio.htm" scope="external">http://www.thesycon.de/usbio/eng/usbio.htm</xref>]. </p> <p>The driver
+provides Win32 applications with direct access to USB devices which
+are otherwise only accessible from kernel-mode. It can be used with
+any kind of USB device, enabling application developers to control
+devices without having to develop a kernel-mode WDM driver. Symbian
+owns a licence to the driver and its development package, and is entitled
+to ship renamed copies of the driver binary to licensees and partners
+as part of its own development kits, usually adopting the name of
+the application that uses it. </p> </section>
+<section id="GUID-78E25906-2FF3-572E-B24D-2F064B9DBD89"><title>T_USBAPI</title> <p>This is a device-side only, stand-alone test program. It is used
+to verify the proper working of some basic USB API functionality.
+For T_USBAPI to run, the device doesn’t need to be USB-connected to
+a PC although if it is then some additional tests are performed. Tests
+run by T_USBAPI include: </p> <ul>
+<li id="GUID-ED9F5656-C992-54D4-B625-66B427966AF1"><p>loading the
+USB LDD and opening a channel </p> </li>
+<li id="GUID-314942D9-4A66-52D1-AD07-DE193D639647"><p>searching for
+suitable endpoints and setting up an interface </p> </li>
+<li id="GUID-33DF3016-49D1-5591-A103-5931237FF760"><p>searching for
+suitable endpoints and creating an 'alternate setting' for that interface
+(if supported). </p> </li>
+<li id="GUID-A76EDCE6-3629-5516-8920-B62962EC6FD4"><p>querying and
+allocating endpoint resources (DMA and double buffering) </p> </li>
+<li id="GUID-30E05336-A92E-5614-B365-90D4BCF3AF64"><p>powering up
+the UDC and connecting it to the bus. </p> </li>
+<li id="GUID-A75AEAEA-7328-517C-807B-59ECD051FB1B"><p>manipulating
+(modifying) USB descriptors (Device, Device_Qualifier, Configuration,
+Other_Speed_Configuration, Interface, Endpoint, String) </p> </li>
+<li id="GUID-9D7AAEA0-5E85-56D0-8A11-52C2089A2C60"><p>testing the
+USB OTG API extensions </p> </li>
+<li id="GUID-3601CC5C-752E-5E29-ADA5-3590976F5B43"><p>requesting and
+releasing <i>Device Control</i>  </p> </li>
+<li id="GUID-D6BB7C90-9B9F-5111-83F6-5FC3E15FDBF3"><p>some static
+state notification tests (alternate device status, endpoint status). </p> </li>
+<li id="GUID-46858A91-D4DB-5A62-B791-66615745BDC9"><p>setting and
+clearing endpoint Halt condition (where supported in unconfigured
+state) </p> </li>
+<li id="GUID-F8A0D0C3-CEF9-5226-9F04-2DB232F66CD7"><p>closing the
+channel and freeing the LDD </p> </li>
+</ul> <p>Most of these tests verify the functioning of the platform-independent
+code (i.e. platform-independent layer + LDD). However, some of this
+code relies on platform-specific layer functionality, such as the
+stall state and the maximum packet size of endpoints. Therefore, a
+working, or a partially working platform-specific layer is required
+for T_USBAPI to pass. </p> <p>When called normally, T_USBAPI runs
+once and then exits. It can also run endlessly in a loop, provided
+it is not failing, by adding the parameter <i>soak</i> to the command
+line. Once the program is running in endless mode, it can be stopped
+at any time by pressing the <userinput>Esc</userinput> key, in which
+case the program finishes the current set of tests and then exits.
+This loop mode can be useful for the detection of memory leaks in
+the USB stack, although the main functionality exercised lies in the
+platform-independent layer and the LDD, not in the platform-specific
+layer. </p> <p>T_USBAPI is a standalone program which can be safely
+run on a UDEB image. Choose to display error messages and warnings
+specific to the USB components using the appropriate kernel debug
+flags (<codeph>KPANIC</codeph>, <codeph>KUSBPSL</codeph> and <codeph>KUSB</codeph>). The following example shows the E32 shell commands
+to set <codeph>KPANIC</codeph>, <codeph>KUSBPSL</codeph> and <codeph>KUSB</codeph> in that order: </p> <p><userinput>C:\&gt;trace 80000000</userinput> </p> <p><userinput>C:\&gt;trace 3 1</userinput> </p> <p>"trace 3 1"
+means "set (bit 1|bit 0) at index 1" (<codeph>KUSBPSL=33</codeph>, <codeph>KUSB=32</codeph>) </p> </section>
+<section id="GUID-AC6E3928-C027-56E5-985E-6B7699216FDE"><title>USBRFLCT
+and T_USB</title> <p>These are the host and device side parts, respectively,
+of a reflector-like USB test program. They are normally used together,
+but T_USB can also be used to create a simple USB device to allow
+USBCV to execute. </p> <p> <note>Since this program suite is subject to continual development    
+      and improvement, in order for them to work properly together,
+both parts must           always come from the same Symbian platform
+delivery. </note>  </p> <p>To ensure proper internetworking, <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-3F7462D9-EF86-5CC9-AEC5-EB755049B7CF">USBRFLCT</xref> and <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-62006D61-5222-5C83-86EC-54CECD4FED18">T_USB</xref> exchange their version numbers after startup, and either
+program will quit if the other does not provide a suitable minimum
+version number. </p> <p id="GUID-3F7462D9-EF86-5CC9-AEC5-EB755049B7CF"><b>USBRFLCT</b> </p> <p>This is the host-side part of a reflector-like USB test program.
+This is normally used together with <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-62006D61-5222-5C83-86EC-54CECD4FED18">T_USB</xref>, the device-side part. </p> <p>The directory <filepath>...\e32test\win32\usbrflct\</filepath> contains its source code. </p> <p>The directory <filepath>...\e32test\win32\usbrflct_distribution\</filepath> contains a binary distribution of the program, including the <filepath>USBRFLCT.SYS</filepath> driver and a <filepath>USBRFLCT.INF</filepath> file for the installation of the driver. </p> <p>The syntax for
+invoking this is: </p> <codeblock id="GUID-823D06EF-4C96-53E3-8740-F8D996AA2372" xml:space="preserve">usbrflct [options]</codeblock> <p>where <codeph>options</codeph> can be <i>one</i> of the following: </p> <table id="GUID-D5A56CC6-6B60-52C6-8387-85935E1B5747">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>/[r|t] </p> </entry>
+<entry><p>receive|transmit only; default is to loop with statistics
+printed every 1024th iteration </p> </entry>
+</row>
+<row>
+<entry><p>/l </p> </entry>
+<entry><p>loop mode with statistics printed for every iteration </p> </entry>
+</row>
+<row>
+<entry><p>/v </p> </entry>
+<entry><p>verbose driver &amp; program output </p> </entry>
+</row>
+<row>
+<entry><p>/[h|?] </p> </entry>
+<entry><p>displays this help text </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>Three modes of operation are available: </p> <ul>
+<li id="GUID-3AA40354-D26E-5DA0-A69F-B3766D84AEC1"><p>Loop mode. </p> <p>Data chunks are read from the USB device and then immediately
+written back to it. Successive data chunks are read, each being one
+byte larger than the one before, starting with size 0 until a specified
+maximum size has been reached. This maximum size value is specified
+on the device using <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-62006D61-5222-5C83-86EC-54CECD4FED18">T_USB</xref>. After the maximum size has been reached, the size of
+the data chunk is reset back to its starting value. </p> <p>A preamble
+packet is sent by the device before each data chunk, containing the
+size of the chunk that is to follow. This kind of protocol is necessary,
+because the host side driver has to specify the exact number of bytes
+that it needs to read from the device. </p> <p>Every 1024th loop,
+the program displays statistics about the test run. For example, the
+total number of bytes transferred, and the current average data throughput
+in bytes/sec. </p> </li>
+<li id="GUID-4F50A5A8-E52C-54ED-BE12-4F751A4B5223"><p>Receive-only
+mode. </p> <p>In this mode, a single preamble packet containing the
+size of the data chunks that are to follow is sent from the device.
+The host-side program subsequently, and continuously, reads data chunks
+of that size from the device. This mode can be used to determine the
+raw transfer performance of the USB connection in the device upstream
+direction. </p> </li>
+<li id="GUID-757B0CD8-CB5E-5BF1-86B1-8626F73604E3"><p>Transmit-only
+mode. </p> <p>In this mode, no preamble packet is sent. Instead, maximum
+(constant) sized data chunks are sent. This mode can be used to determine
+the raw transfer performance of the USB connection in the device downstream
+direction. </p> </li>
+<li id="GUID-13B049DB-1955-5D3E-8404-C375ABEE2F06"><p>Verbose mode. </p> <p>In this mode, the driver and program output are both displayed.
+Use this to track down problems that occur when trying to get <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-3F7462D9-EF86-5CC9-AEC5-EB755049B7CF">USBRFLCT</xref> and <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-62006D61-5222-5C83-86EC-54CECD4FED18">T_USB</xref> to work together. This may help in the following circumstances: </p> <ul>
+<li id="GUID-11167D82-09B9-5D60-B1F6-AB14B633D56D"><p>the first time
+you test a port of the platform specific layer </p> </li>
+<li id="GUID-67F387AE-42B2-5EA6-8A76-B212D82EE2B9"><p>after installation
+changes on the PC </p> </li>
+</ul> <p>The error messages are particularly helpful, a list of error
+codes together with explanations for the USBRFLCT.SYS driver can be
+found in the USBIO Reference Manual. These codes are also available
+on <i>Thesycon</i>'s website at <xref href="http://www.thesycon.de/usbio/usbioman.pdf" scope="external">http://www.thesycon.de/usbio/usbioman.pdf</xref>. Do not use this
+mode during loop or throughput testing to avoid program slowdown which
+could affect these tests. </p> </li>
+</ul> <p id="GUID-62006D61-5222-5C83-86EC-54CECD4FED18"><b>T_USB</b> </p> <p>This is the device-side part of a reflector-like USB test program.
+This is normally used together with <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-3F7462D9-EF86-5CC9-AEC5-EB755049B7CF">USBRFLCT</xref>, the host-side part. </p> <p>The source for this
+program can be found in: </p> <ul>
+<li id="GUID-468F6A61-75FE-509A-BCEE-B979F8D5E5C8"><p> <filepath>...\e32test\device\t_usb.h</filepath>  </p> </li>
+<li id="GUID-84E8F05C-51C9-5CB1-94AB-0FB63AA9C15B"><p> <filepath>...\e32test\device\t_usb.cpp</filepath>  </p> </li>
+<li id="GUID-8A286F35-65EE-5FAC-B4B4-A014E0698308"><p> <filepath>...\e32test\device\t_usbco2.cpp</filepath>  </p> </li>
+</ul> <p>After starting the program, you are prompted to choose a
+maximum size for a single transfer. </p> <p> <b>Note: </b> The maximum
+transfer size is not the same as the maximum packet size. </p> <p>The prompt appears as follows: </p> <p><userinput>++++Choose max
+transfer size++++</userinput> </p> <p><userinput>'0' - Set up USB
+device for USBCV</userinput> </p> <p><userinput>'1' - 32 bytes</userinput> </p> <p><userinput>'2' - 1024 bytes</userinput> </p> <p><userinput>'3' - 64 kbytes</userinput> </p> <p><userinput>'4' - 1 Mbyte</userinput> </p> <p>Once you have chosen the maximum transfer size you are prompted
+to choose a bandwidth priority for the interface that will be created
+and used for the tests. All options except '0' are used when <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-62006D61-5222-5C83-86EC-54CECD4FED18">T_USB</xref> is run together with <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-3F7462D9-EF86-5CC9-AEC5-EB755049B7CF">USBRFLCT</xref>. The program carries out dynamic version number checking
+of the two programs to ensure compatibility . Option '0' sets up a
+static USB device that can be used to perform other tests, including
+compliance testing with <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-E8A9B4BD-E60F-5A08-A588-527347239118">USBCV</xref>. This option also circumvents dynamic version checking.
+Most of the other menu options have no meaning in this mode. </p> <p>Choose a bandwidth priority from the following menu for the interface
+specifically created for the tests. All tests will be carried out
+over this interface. </p> <p><userinput>++++ Choose Bandwidth Priority
+++++</userinput> </p> <p><userinput>'1' - Economical buffering - default</userinput> </p> <p><userinput>'2' - More memory than default buffering - Plus1</userinput> </p> <p><userinput>'3' - More memory than Plus1 buffering - Plus2</userinput> </p> <p><userinput>'4' - Maximum memory for buffering</userinput> </p> <p>Choose endpoint options from the following two configuration
+menus: </p> <p><userinput>++++ Choose Endpoint I/O Transfer Mode ++++</userinput> </p> <p><userinput>'1' - Interrupt Mode</userinput> </p> <p><userinput>'2' - DMA Mode (recommended)</userinput> </p> <p> </p> <p><userinput>++++ Choose Endpoint FIFO Mode ++++</userinput> </p> <p><userinput>'1' - Normal Buffering Mode</userinput> </p> <p><userinput>'2' -
+Double Buffering Mode (recommended)</userinput> </p> <p>A message
+prompts the user to start the host side test program USBRFLCT. </p>  <p>Once host enumeration
+and <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-3F7462D9-EF86-5CC9-AEC5-EB755049B7CF">USBRFLCT</xref> configuration completes, the program's main menu
+is displayed as follows: </p> <p><userinput>++++ Select Program Option
+++++</userinput> </p> <p><userinput>'L'oop test</userinput> </p> <p><userinput> Loop test with data 'C'ompare</userinput> </p> <p><userinput>'R'eceive-only test (we receive, host transmits)</userinput> </p> <p><userinput>'T'ransmit-only test</userinput> </p> <p><userinput> Receive and 'P'ut (write) to File</userinput> </p> <p><userinput> Transmit and 'G'et (read) from File</userinput> </p> <p><userinput> Signal Remote - 'W'akeup to the host</userinput> </p> <p><userinput>'S'top current transfer</userinput> </p> <p><userinput> Re'E'numerate
+device</userinput> </p> <p><userinput>'Q'uit</userinput> </p> <p>Choose
+one of the six main test modes. The selected mode should correspond
+with the mode in which the host-side program is running. For example,
+device-side <codeph>Receive</codeph> matches host-side <codeph>Transmit</codeph>. </p> <p>The Loop test with <codeph>Compare</codeph> is just like
+the normal <codeph>Loop</codeph>, except that the received data is
+compared with the data that was previously sent, allowing any transmission
+errors to be detected. The purpose of the non-comparing mode is performance
+(throughput) assessment of the USB link, in this mode the slow down
+of the application introduced by the byte-by-byte checking of the
+compare operation is not desirable. Note: The non-comparing mode does
+do some checking, specifically it compares the received transfer number
+(4 bytes at the start of each buffer) against the expected value. </p> <p>The standard 'Receive-only' test mode <userinput>R</userinput> immediately discards the data received, similarly the standard 'Transmit-only'
+mode <userinput>T</userinput> creates random data on the fly to send
+to the device. These tests are useful for checking the maximum throughput
+of the link, however they do not reflect normal usage. In a real world
+scenario, transmitted data would be read from a file and received
+data would be written to a file. </p> <p>There are two further tests
+which include file I/O. These are: </p> <ul>
+<li id="GUID-079843BA-A985-5E00-AD1C-44E965EADF17"><p>'Receive' mode <userinput>P</userinput>, where data received from the link is written to a
+newly created file. </p> </li>
+</ul> <ul>
+<li id="GUID-895EBD5E-1008-56C7-8AC2-68F534338893"><p>'Transmit' mode <userinput>G</userinput>, where data is read from a newly created file and sent
+across the link. </p> </li>
+</ul> <p>In both cases you must first enter a source or destination
+from the list of available drives. </p> <p> <userinput>S</userinput> stops an ongoing transfer at any time </p> <p> <userinput>W</userinput> issues a Remote Wake-up signal to the host; this is needed, for
+example, when running <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-E8A9B4BD-E60F-5A08-A588-527347239118">USBCV</xref>. </p> <p> <userinput>E</userinput> re-enumerates the
+USB device by first disconnecting it from, and then reconnecting it
+to the bus. </p> <p> <userinput>ESC</userinput> or <userinput>Q</userinput> quits the program after tearing down the device configuration and
+freeing all used resources. </p> </section>
+<section id="GUID-8F2961A1-03B6-5642-82A7-3D2504436D0E"><title>USBIOAPP</title> <p> <i>Thesycon</i> provide this Win32 GUI application. Like <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-3F7462D9-EF86-5CC9-AEC5-EB755049B7CF">USBRFLCT</xref> it works on top of the <filepath>USBRFLCT.SYS</filepath> driver (otherwise known as <filepath>USBIOAPP.EXE</filepath>). The
+source code for this program is part of the USBIO development kit.
+You can find the compiled executable <filepath>USBIOAPP.EXE</filepath> in the same directory as <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-3F7462D9-EF86-5CC9-AEC5-EB755049B7CF">USBRFLCT</xref> and the host side drivers: <filepath>...\e32test\win32\usbflct_distribution\</filepath>. </p> <p>Use <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-8F2961A1-03B6-5642-82A7-3D2504436D0E">USBIOAPP</xref> to exercise and test the low-level functionality
+of an attached USB device. In this case, the Symbian platform device
+running the USB device stack which includes the port of the platform-specific
+layer. </p> <p>The following steps describe an example test: </p> <ul>
+<li id="GUID-AAC49CFA-A077-52B6-8811-F18145B78787"><p>Connect the
+Symbian platform USB device to a PC on which the <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-3F7462D9-EF86-5CC9-AEC5-EB755049B7CF">USBRFLCT</xref> driver has been installed. </p> </li>
+<li id="GUID-FEEDB45F-36D9-5AB6-9F3D-C36DB85AAC5A"><p>Start <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-62006D61-5222-5C83-86EC-54CECD4FED18">T_USB</xref> on the device to create a USB device (use option '0'
+for the transfer size). </p> </li>
+<li id="GUID-CD6A4F22-1B47-5E50-A684-124616A6B0C7"><p>Launch <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-8F2961A1-03B6-5642-82A7-3D2504436D0E">USBIOAPP</xref> on the PC. </p> </li>
+<li id="GUID-3DC6299D-FBE4-542B-A9CE-2C6D05BCD9B5"><p>Press the <userinput>Scan for USBIO devices</userinput> button. The device should be detected
+by <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-8F2961A1-03B6-5642-82A7-3D2504436D0E">USBIOAPP</xref>. </p> </li>
+<li id="GUID-CAC741CF-76EF-5418-94F6-923BF1F1E2A0"><p>Test and exercise
+the USB device using the different options provided by the <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-8F2961A1-03B6-5642-82A7-3D2504436D0E">USBIOAPP</xref> program. </p> </li>
+</ul> <p>Further details can be found in the USBIO manual, which contains
+a chapter on the <xref href="GUID-C8217A7B-D741-5452-B95B-57B8978AD152.dita#GUID-C8217A7B-D741-5452-B95B-57B8978AD152/GUID-8F2961A1-03B6-5642-82A7-3D2504436D0E">USBIOAPP</xref>. See <xref href="http://www.thesycon.de/usbio/usbioman.pdf" scope="external">http://www.thesycon.de/usbio/usbioman.pdf</xref> </p> </section>
+<section id="GUID-E8A9B4BD-E60F-5A08-A588-527347239118"><title>USB
+Command Verifier (USBCV)</title> <p>This test program is written and
+maintained by the USB Implementers Forum, Inc, (also referred to as
+the “USB Forum” or “USB IF”). It can be used to check compatibility
+of the USB device with the USB specification (currently version 2.0).
+It contains a collection of different test suites, but the only tests
+that are of interest regarding the platform-specific layer port are
+the “Chapter 9 Tests”. Even though most of the "Chapter 9" request
+processing is done by the platform-independent layer, the tests can
+help to uncover potential problems with endpoint-0 controlling platform-specific
+layer code. The tests will also show whether or not the platform-specific
+layer and the platform-independent layer work together without problems. </p> <p>This program runs on Windows 2000 and Windows XP (English Version)
+only. At the time of writing, the version of the package is R1.2.1,
+and can be obtained from <xref href="http://www.usb.org/developers/tools/USBCV121.msi" scope="external">http://www.usb.org/developers/tools/USBCV121.msi</xref>. </p> </section>
+<section id="GUID-DA56677C-28D2-5CC2-BBA6-9CCF02C64FBF"><title>USBMSAPP
+(USB Mass Storage Application)</title> <p>This is not a dedicated
+test program, but it can be used to check that the USB driver stack
+is operating correctly. Since it is not a test program USBMSAPP is
+not normally included in ROMs with any of the <filepath>...\e32tests\f32tests\alltests
+rom.bat</filepath> options. The source can be found <filepath>...\e32ustils\usbmsapp\</filepath>. If you want to include it, use the command line macro below. </p> <p> <b>Note: </b> Add this macro to <filepath>\e32\rombuild</filepath>: </p> <p><userinput>rom --variant=h4hrp --inst=armv5 --build=urel
+--type=alltests --symbol --define=ROMOPT_USBMSAPP --name=H4HRPARMV5.IMG</userinput> </p> <p>Start the program from the command prompt with a drive letter
+as a parameter: </p> <p><userinput>C:\&gt; usbmsapp d:</userinput> </p> <p>This mounts the specified drive with the Mass Storage file system
+('MSFS'). Check that you can see it as a Read/Write disk drive on
+the USB host computer. The drive name on the host computer will be
+the first free drive letter available. </p> <p> <b>Note: </b> You
+can only mount drives marked as 'removable' as USB Mass Storage devices.
+The C: drive cannot be marked as 'removable'. Internal drives made
+available for USB Mass Storage must be marked as 'removable' for reasons
+of platform security. </p> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-C8450E58-A603-5CF8-993E-053C990DDA19-master.png has changed
Binary file Adaptation/GUID-C8450E58-A603-5CF8-993E-053C990DDA19_d0e9181_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C8DF0CB0-92F4-5F9E-A8F1-7DE50954C4F1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C8DF0CB0-92F4-5F9E-A8F1-7DE50954C4F1" xml:lang="en"><title>Debugging
+the PRM</title><shortdesc>This document describes how to debug the PRM using internal macros.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-CA939F43-E904-4285-9CBA-BB0D9767555A"><title>Purpose</title> <p>Use the provided KTrace and BTrace macros
+to debug your PRM implementation. </p> <p><b>Introduction</b> </p> <p>These
+kernel services allow you to generate and capture trace information in a manner
+designed to minimise the impact on a running system. </p> </section>
+<section id="GUID-86D96673-D319-4791-9256-E3C79B8CCA26"><title>Using KTrace </title> <p>Use the <xref href="GUID-C4D86928-8806-3FF4-AE84-F2846B846B73.dita"><apiname>KTRACE</apiname></xref> macro
+with <codeph>KRESMANAGER</codeph> for debug print messages in the code. </p> <codeblock id="GUID-D193E79B-5908-5419-AAD1-69C1FA223B08" xml:space="preserve">__KTRACE_OPT(KRESMANAGER,Kern::Printf("&gt;DH4PowerResourceController::DoInitController\n”))</codeblock> </section>
+<section id="GUID-4476C500-FAB6-5A2F-B3E0-F85A171A59B3"><title>Using the kernel
+trace tool</title> <p>The <codeph>BTRACE</codeph> category, <xref href="GUID-24FEA283-108A-3693-8DA6-C2A85CB11DB0.dita#GUID-24FEA283-108A-3693-8DA6-C2A85CB11DB0/GUID-3E994A9D-6849-31FB-80B6-088ED5E0C7B9"><apiname>TCategory::EResourceManager</apiname></xref>,
+and a number of sub categories are defined and used to trace the progress
+of all operations on the PRM. All tracing sub categories are wrapped with
+a macro definition. Implement macro definitions in <filepath>e32\include\drivers\rescontrol_trace.h</filepath> to
+replace <codeph>BTrace</codeph> with other tracing methods. </p> </section>
+</conbody><related-links>
+<link href="GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9.dita"><linktext>Porting the
+Power Resource Manager</linktext></link>
+<link href="GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671.dita"><linktext>Implement
+the controllable power resources</linktext></link>
+<link href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita"><linktext>Implement
+the PSL for the target</linktext></link>
+<link href="GUID-E7F91A65-235D-589C-9A8C-0B207D19A24B.dita"><linktext>Port client
+drivers to use the PRM</linktext></link>
+<link href="GUID-66E5F769-1156-54CA-94BC-8912159A1240.dita"><linktext>Testing the
+PRM PSL</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C92CC81A-35A1-5860-AA08-C8C08B39804C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,96 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C92CC81A-35A1-5860-AA08-C8C08B39804C" xml:lang="en"><title>Boot
+Table MMU Permission and Cache Attribute Definitions</title><shortdesc>Lists MMU attributes that the bootstrap implementation must provide.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The definitions are summarised in the following table. Each entry type
+is identified by its <codeph>TBootTableEntry</codeph> enumerator value that
+defines its position within the table. This group of entries always follows
+the function entries. </p>
+<table id="GUID-6145893A-57CA-5E96-A61B-18AF2DF44EC3">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Enumerator symbol</b>  </p> </entry>
+<entry><p> <b>Summary description</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> BTP_Rom</codeph>  </p> </entry>
+<entry><p>Defines permissions for XIP ROM areas, including RAM used as ROM. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> BTP_Kernel</codeph>  </p> </entry>
+<entry><p>Defines permissions for kernel data, initial kernel stack and initial
+kernel heap. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> BTP_SuperCPU</codeph>  </p> </entry>
+<entry><p>Defines permissions for super page and CPU page. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> BTP_PageTable</codeph>  </p> </entry>
+<entry><p>Defines permissions for page directory and page tables. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> BTP_Vector</codeph>  </p> </entry>
+<entry><p>Defines permissions for ARM exception vector mapping. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BTP_Hw</codeph>  </p> </entry>
+<entry><p>Defines permissions for I/O mappings. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> BTP_MiniCache</codeph>  </p> </entry>
+<entry><p>Defines permissions for mini cache flush area, if required. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>BTP_MainCache</codeph>  </p> </entry>
+<entry><p>Defines permissions for main cache flush area, if required. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> BTP_PtInfo</codeph>  </p> </entry>
+<entry><p>Defines permissions for page table info and, for the multiple memory
+model, ASID info. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> BTP_User</codeph>  </p> </entry>
+<entry><p>Defines permissions for user memory area in direct memory model. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> BTP_Temp</codeph>  </p> </entry>
+<entry><p>Defines permissions for temporary identity mapping of code while
+enabling MMU. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph> BTP_Uncached</codeph>  </p> </entry>
+<entry><p>Defines permissions for dummy uncached area mapping on moving or
+multiple model and for identity RAM mapping on direct memory model. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table>
+<p>Each entry is defined using the <xref href="GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C.dita#GUID-25941CD2-D124-55DD-8716-ACC93E3F1D6C/GUID-B5EC22B5-B995-5D54-8F33-1B6FCE11BB3F">BTP_ENTRY</xref> macro. See this macro for a detailed description of the syntax and meanings. </p>
+<p>Take the template port, in <filepath>os/kernelhwsrv/bsptemplate/asspandvariant/template_variant/bootstrap/template.s</filepath> as
+an example. The first two entries, at position <codeph>BTP_Rom</codeph> and
+position <codeph>BTP_Kernel</codeph> in the boot table, follow the last function
+entry at position <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-37E8A845-6326-52F1-9607-5488B1E009A8">BTF_EnableMMU</xref> within
+the table. This gives the following code: </p>
+<codeblock id="GUID-CB1D0496-61E0-5C48-BDA4-D3D64FEFE967" xml:space="preserve">BootTable
+        DCD    DoWriteC                    ; output a debug character
+        ...
+    
+IF    CFG_MMUPresent
+
+        BTP_ENTRY    CLIENT_DOMAIN, PERM_RORO, CACHE_WTRA,    0    ; ROM
+        BTP_ENTRY    CLIENT_DOMAIN, PERM_RWNO, CACHE_WBRA,    0    ; kernel data/stack/heap
+        ...
+</codeblock>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C9644081-004E-5DA0-8133-A32EEA91EF5E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,180 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C9644081-004E-5DA0-8133-A32EEA91EF5E" xml:lang="en"><title>IIC SHAI Implementation Layer: Slave Channel</title><shortdesc>This document explains how to implement a slave channel
+in the SHAI implementation layer of IIC. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-48EF587B-8C61-47FA-B311-18594D3B54CD"><title>Purpose</title> <p>This document explains how to implement a slave channel in the
+SHAI implementation layer of IIC. </p> <p><b>Intended Audience</b> </p> <p>Base porting engineers. </p> <p><b>Introduction</b> </p> <p>IIC buses (a term used in this document to represent serial inter-chip
+buses that IIC can operate on) are a class of bus used to transmit
+non time-critical data between components of a hardware system</p> </section>
+<section id="GUID-5AF2B3DD-0A5B-4E3E-AF8A-D1522E540D7A"><title>Implementing
+a slave channel</title> <p>To implement the SHAI implementation layer
+of an IIC channel as slave you must write a class extending <xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita"><apiname>DIicBusChannelSlave</apiname></xref>. You must implement certain pure virtual
+functions of the parent class in the subclass. Those functions and
+any other functions which you write in the subclass are called the
+SHAI implementation layer. The functions inherited from the parent
+class are called the Platform Independent Layer (PIL). </p> <p>The
+four functions you must implement are: </p> <ul>
+<li id="GUID-107E2432-19BB-55D8-9100-A0F27D0C7ED2"><p> <xref href="GUID-11C2715E-409F-3F24-AE8F-89CF5A893B80.dita"><apiname>DoCreate()</apiname></xref>  </p> </li>
+<li id="GUID-567D0C13-D99B-5901-8833-F0E7FE4EA24E"><p> <xref href="GUID-9D910016-5611-30DD-A139-EE46705A4912.dita"><apiname>DoRequest()</apiname></xref>  </p> </li>
+<li id="GUID-4B0653EC-AF4F-53C9-92F4-C9950D58C742"><p> <xref href="GUID-2958D2DF-696B-3493-985D-E6DE4BBCD74C.dita"><apiname>ProcessData()</apiname></xref>  </p> </li>
+<li id="GUID-028033AA-63D9-5AB0-9645-7F9397EEEEA7"><p> <xref href="GUID-A5E66E7E-E03B-3249-A5E5-F0E5DFC3B3EB.dita"><apiname>CheckHdr()</apiname></xref>  </p> </li>
+</ul> <p>You must also provide the following functionality: </p> <ul>
+<li id="GUID-546A43C9-03BC-54D9-B77A-B88D9D74F817"><p>From the constructor,
+call the constructor of the base class <xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita"><apiname>DIicBusChannelSlave</apiname></xref> with arguments for bus type and duplex settings, </p> </li>
+<li id="GUID-B26256C0-3CC0-59DA-9A5E-99B6EEACBDA6"><p>assign the channel
+number (if you are using the IIC Controller) and channel ID, and </p> </li>
+<li id="GUID-D9031D14-27DF-5A2D-B0FB-E79D28E4DECE"><p>report events
+signalled by the hardware by calling the <xref href="GUID-5111CCD6-E449-30B7-844F-8273FBCA97DE.dita"><apiname>NotifyClient()</apiname></xref> callback function with the appropriate trigger. </p> </li>
+</ul> <p>Your implementation of the SHAI implementation layer will
+need to call functions of the PIL. You are restricted to using a certain
+subset of these. </p> <p><b>Implementing the Platform Specific Layer</b> </p> <p><b>Implementing DoCreate()</b> </p> <p> <xref href="GUID-11C2715E-409F-3F24-AE8F-89CF5A893B80.dita"><apiname> DoCreate()</apiname></xref> is the second phase constructor of your class. Implement it with
+functionality including: </p> <ul>
+<li id="GUID-A06C90F8-F423-5FD0-BE3A-DC5072503F16"><p>If you are using
+the IIC controller, set the channel number, </p> </li>
+<li id="GUID-5740E282-41F2-5128-A2AB-5429D959F270"><p>call the <xref href="GUID-741A0FD7-5A5A-31B0-BB5F-763B5795009C.dita"><apiname>Init()</apiname></xref> method of the base class, and </p> </li>
+<li id="GUID-202230E9-C634-5384-8ADF-3C8DD8AF9FFD"><p>set the <xref href="GUID-D389A526-3974-3EB5-95F5-50EAFE7B48E0.dita"><apiname>iChannelId</apiname></xref> member to an ID to be returned to the SHAI implementation
+layer, which will use it to create a channel ID which is unique with
+respect to other opened slave channels. </p> </li>
+</ul> <p><b>Implementing DoRequest()</b> </p> <p> <xref href="GUID-9D910016-5611-30DD-A139-EE46705A4912.dita"><apiname> DoRequest()</apiname></xref> is the gateway function to the SHAI implementation layer. Implement
+it with functionality including: </p> <ul>
+<li id="GUID-1671D196-1C71-58EF-892F-6F723133300B"><p>configure the
+interface, </p> </li>
+<li id="GUID-7085B7DE-B6DD-5964-952A-4F956C9836D5"><p>set triggers
+and initiate transfers, and </p> </li>
+<li id="GUID-8C59A6CE-4980-5F6F-90AD-551064EE8A92"><p>disable interrupts
+in the event of an abort. </p> </li>
+</ul> <p> <xref href="GUID-9D910016-5611-30DD-A139-EE46705A4912.dita"><apiname> DoRequest()</apiname></xref> shall be called with an
+argument representing one of various possible operations. </p> <ul>
+<li id="GUID-2D0A07D3-95E1-5AF0-B960-A9558DA2935C"><p>The argument
+is <xref href="GUID-C504873A-5B30-39C6-90A8-618B42C409D5.dita"><apiname>EAsyncConfigPwrUp</apiname></xref> when the client called the
+client API with instructions to complete asynchronously. The SHAI
+implementation layer should power up and configure the hardware and
+then call <xref href="GUID-23D0DB11-0820-3C5A-B4E9-D10398E8FAC3.dita"><apiname>ChanCaptureCallback()</apiname></xref> with the result
+as argument. </p> </li>
+<li id="GUID-94087E4A-F192-56B6-A03C-22895E90F039"><p>The argument
+is <xref href="GUID-A79F9A93-984F-3024-92F0-544D0A2D8BBA.dita"><apiname>ESyncConfigPwrUp</apiname></xref> when the client called client
+called the client API with instructions to complete synchronously.
+The SHAI implementation layer should power up and configure the hardware
+and return the result. </p> </li>
+<li id="GUID-8747FA9D-E03C-545C-941E-38657E943339"><p>The argument
+is <xref href="GUID-59D9D3BE-400C-3B61-9208-535D55D59BF3.dita"><apiname>EPowerDown</apiname></xref> when the client called client called
+the client API. The SHAI implementation layer should disable the interrupts,
+stop any ongoing or outstanding operations and stop or reset the hardware
+to its initial state. </p> </li>
+<li id="GUID-D5E42E03-5016-57E7-B816-3777B0207660"><p>The argument
+is <xref href="GUID-5CE38A1F-7AA1-3377-BFBB-4871730B1590.dita"><apiname>ETransmit</apiname></xref> when the client called <xref href="GUID-74BA3796-65DE-39A1-A50F-78394AA0632E.dita#GUID-74BA3796-65DE-39A1-A50F-78394AA0632E/GUID-CB8904EA-474D-3AFB-8519-248F104A10AB"><apiname>Iic::SetNotificationTrigger()</apiname></xref> with any of the transmit triggers as argument. The SHAI implementation
+layer should initialize the hardware and set up transmission buffers.
+In a typical implementation, if the transmission has not yet started
+it should also fill up the transmit FIFO and enable interrupts to
+prepare for transmission, but this is not necessary if the transmission
+is ongoing and the argument <xref href="GUID-5CE38A1F-7AA1-3377-BFBB-4871730B1590.dita"><apiname>ETransmit</apiname></xref> was passed
+because of a transmit underrun. </p> </li>
+<li id="GUID-2F7EA8A0-423A-5296-AF96-2A63377F55DE"><p>The argument
+is <xref href="GUID-5BA7AA55-E78D-3807-A6E3-4596A106B94B.dita"><apiname>EReceive</apiname></xref> if the client called <xref href="GUID-74BA3796-65DE-39A1-A50F-78394AA0632E.dita#GUID-74BA3796-65DE-39A1-A50F-78394AA0632E/GUID-B88F5929-78F3-3CFD-B288-93B2EE883463"><apiname>Iic::SetNotificationTrigger</apiname></xref> with any of the receive triggers as argument. The SHAI implementation
+layer should initialize the hardware and set up receive buffers. In
+a typical implementation, if the transmission has not yet started
+it should also flush or fill the receive FIFO and enable interrupts,
+but this is not necessary if the transmission is ongoing and the argument <xref href="GUID-5BA7AA55-E78D-3807-A6E3-4596A106B94B.dita"><apiname>EReceive</apiname></xref> was passed because of a receive overrun. </p> </li>
+<li id="GUID-9692F677-FD7E-589F-BF8B-9CAB97764202"><p>The argument
+is <xref href="GUID-966F7C7B-F8B1-334E-998B-BAC4C6BF86DA.dita"><apiname>EAbort</apiname></xref> if the timer of the master activity has
+expired. The SHAI implementation layer should stop the transfer by
+disabling interrupts, stopping ongoing and outstanding operations
+and resetting the hardware and return failure. </p> </li>
+</ul> <p><b>Implementing ProcessData()</b> </p> <p>The easiest way
+to understand this, is to review the template port at <filepath>\os\kernelhwsrv\bsptemplate\asspandvariant\template_assp\iic\iic_slave</filepath>.</p><p><xref href="GUID-2958D2DF-696B-3493-985D-E6DE4BBCD74C.dita"><apiname>ProcessData()</apiname></xref> is the function called by
+the platform independent layer in response to <xref href="GUID-5111CCD6-E449-30B7-844F-8273FBCA97DE.dita"><apiname>NotifyClient()</apiname></xref>. It has two arguments representing a trigger <codeph>aTrigger</codeph> and a callback <codeph>aCb</codeph>. You implement it to modify
+the callback </p> <ul>
+<li id="GUID-0BB2E7AA-4648-5006-81BF-78B83462C73F"><p> <xref href="GUID-334979E2-7CC0-3736-BFE2-8F92305CC47B.dita"><apiname>aTrigger</apiname></xref>, a trigger of class <xref href="GUID-7A2A43EC-6125-3BFE-834B-23C37F7B40D5.dita"><apiname>TInt</apiname></xref>, and </p> </li>
+<li id="GUID-3EE01C52-1D50-5514-A95B-7ED30558BC8C"><p> <xref href="GUID-68BD6AE8-7FF5-310D-A8A0-D28FA3994B3A.dita"><apiname>aCb</apiname></xref>, a callback of class <xref href="GUID-7D3ABED1-42FE-3A89-8898-C3854D201BC9.dita"><apiname>TIicBusSlaveCallback</apiname></xref>. </p> </li>
+</ul> <p>You implement the function to update the callback according
+to the value of the trigger. </p> <ul>
+<li id="GUID-ADFFED1D-C9D1-5EFA-B846-4B6537E2F408"><p>If the trigger
+is a receive trigger, update the callback with the number of words
+already received to the buffer by calling </p> <codeblock id="GUID-2C227263-5A41-5FCD-9206-C8DEB775CB4F" xml:space="preserve">aCb-&gt;SetRxWords(numWordsReceived);</codeblock> </li>
+<li id="GUID-2A567339-C9BB-56D1-8E3B-71DA3CDAEC4C"><p>If the trigger
+is a transmit trigger, update the callback with the number of words
+already transmitted (moved to the hardware transmit FIFO) by calling </p> <codeblock id="GUID-D92F489C-9214-5D4A-BF29-AAEBCE3353AE" xml:space="preserve">aCb-&gt;SetTxWords(numWordsTransmitted);</codeblock> </li>
+<li id="GUID-B447C1B5-FEA0-5764-8507-55041088194E"><p>Whether the
+trigger is receive or transmit, update the trigger member of the callback
+containing the accumulated event history by calling </p> <codeblock id="GUID-377BA25F-3FE5-5A3A-B671-7F5CA007FB2D" xml:space="preserve">aCb-&gt;SetTrigger(trigger | aCb-&gt;GetTrigger());</codeblock> <p>where <codeph>trigger</codeph> is one of the receive or transmit
+triggers or <xref href="GUID-1D10124D-F27E-33C3-B803-FEBDEB2B7964.dita"><apiname>EGeneralBusError</apiname></xref>. </p> </li>
+</ul> <p><b>Implementing CheckHdr()</b> </p> <p>Implement <xref href="GUID-B44147A7-D880-3510-A3F1-D73E9B5F8230.dita"><apiname>CheckHdr().</apiname></xref> This is the function which is called if the
+client tries to capture the channel. Implement it with the following
+functionality: </p> <ul>
+<li id="GUID-53140F3D-A4B6-5AA8-955E-55DE3C69E063"><p>check if the
+specified configuration  is valid. </p> </li>
+</ul> <p><b>Using the Platform Independent Layer</b> </p> <p>You can
+only use certain functions of the PIL. They provide functionality
+which is generic to IIC buses. They are: </p> <ul>
+<li id="GUID-3195CC6D-84CF-5FD8-93F7-CC8E4F88FCFB"><p> <xref href="GUID-0A25EDF8-8DC6-33A0-8CD3-880898D2E61E.dita"><apiname>DIicBusChannelSlave()</apiname></xref>. The constructor of the superclass DIicBusChannelSlave. </p> </li>
+<li id="GUID-47BA511F-1430-5B13-ABEC-972238B8C4C7"><p> <xref href="GUID-741A0FD7-5A5A-31B0-BB5F-763B5795009C.dita"><apiname>Init()</apiname></xref>. Initializes <xref href="GUID-22FF70C1-A805-3EBB-B142-15FD16D00837.dita"><apiname>DIicBusChannelSlave</apiname></xref>. </p> </li>
+<li id="GUID-695E3D51-2E28-5AC6-B960-D911A8BB679C"><p> <xref href="GUID-23D0DB11-0820-3C5A-B4E9-D10398E8FAC3.dita"><apiname>ChanCaptureCallback()</apiname></xref>. Called with the error code when asynchronous channel capture has
+completed in response to <xref href="GUID-6612D537-67B8-30E1-AB97-4B75A866DB6F.dita"><apiname>DoRequest(EAsyncConfigPwrUp)</apiname></xref>. </p> </li>
+<li id="GUID-9979C465-5988-5710-BD4D-428417234185"><p> <xref href="GUID-5111CCD6-E449-30B7-844F-8273FBCA97DE.dita"><apiname>NotifyClient()</apiname></xref>. Called to notify the PIL (which then notifies the client) that
+a hardware event of the passed in type has occurred. </p> </li>
+<li id="GUID-9547DCEE-13C9-5045-8910-2A8BD0FECC58"><p> <xref href="GUID-1BC13C5C-A0A5-3D7C-953E-8499B14B2E93.dita"><apiname>SetMasterWaitTime()</apiname></xref>. Sets the timeout for the master to respond after the transmission
+has been started. </p> </li>
+<li id="GUID-CBF88624-1DFE-5B20-9220-0DE9176620F5"><p> <xref href="GUID-B8BAB30F-A1C7-3F33-B5B0-C2ADFB83D941.dita"><apiname>GetMasterWaitTime()</apiname></xref>. Gets the timeout for the master to respond after the transmission
+has been started. </p> </li>
+<li id="GUID-468FEE59-6570-5C9F-9774-09C540B6B8A3"><p> <xref href="GUID-04E9F6A6-B3A0-3216-B09E-25AAF79DC7DD.dita"><apiname>SetClientWaitTime()</apiname></xref>. Sets the client wait time within which it is expected to respond
+with the next operation. </p> </li>
+<li id="GUID-4EE6EAC2-66A8-5BFC-BD25-D376CA790120"><p> <xref href="GUID-C3046454-F0ED-3D7B-93BC-02211B2470C8.dita"><apiname>GetClientWaitTime()</apiname></xref>. Gets the client wait time within which it is expected to respond
+with the next operation. </p> </li>
+</ul> <p><b>Implementing event notification</b> </p> <p>A slave channel
+reports events on the hardware by calling the PIL function <xref href="GUID-5111CCD6-E449-30B7-844F-8273FBCA97DE.dita"><apiname>NotifyClient()</apiname></xref> to pass the following notifications under
+the stated conditions. </p> <ul>
+<li id="GUID-F3CDDE98-9DEF-55A9-B1A5-8E84C26A3EE3"><p>Pass <xref href="GUID-6E213643-B02E-35F0-AF1F-BF79134DA8E1.dita"><apiname>ERxAllBytes</apiname></xref> if the transmission has stopped with all bytes
+received. </p> </li>
+<li id="GUID-9FFE9AE8-DF13-5A1E-BBCB-315AA8DA377D"><p>Pass <xref href="GUID-1FFA3657-452F-3BB2-88C7-663395757613.dita"><apiname>ETxAllBytes</apiname></xref> if the transmission has stopped with all bytes
+transmitted. </p> </li>
+<li id="GUID-66E08813-61B8-5300-BDD9-CBC3C779C290"><p>Pass <xref href="GUID-8CC48D05-A472-3A95-AEDC-1208F1522B5F.dita"><apiname>ERxUnderrun</apiname></xref> if the transmission has been stopped but the
+receive buffer provided by the client is not full, indicating that
+the master has sent less data than expected. </p> </li>
+<li id="GUID-1E7D1FD4-D97B-59B3-8C2B-AF17073F7166"><p>Pass <xref href="GUID-90F30E77-211E-333E-AF0B-DA2A62761A11.dita"><apiname>ERxOverrun</apiname></xref> if the transmission has not been stopped but
+the receive buffer provided by the client is full. The client should
+respond to a receive overrun by </p> <ul>
+<li id="GUID-B426810A-8137-5221-8965-4EDA901331D0"><p>providing new
+receive buffer, and </p> </li>
+<li id="GUID-7F452F0B-FC12-5FF2-AD9B-5A267F96692F"><p>resetting its
+receive notification triggers for instance by calling <codeph>SetNotificationTrigger(ERxAllBytes)</codeph>. </p> </li>
+</ul> <p>To make this possible the SHAI implementation layer should
+try to keep the receive hardware FIFO at the lowest possible level. </p> </li>
+<li id="GUID-1ED0E6C5-94D0-5AA1-9D3D-318391C167F4"><p>Pass <xref href="GUID-F51FDBA8-E904-3091-BFF1-43B968389C68.dita"><apiname>ETxUnderrun</apiname></xref> if the transmission has not been stopped but
+all the data in the transmit buffer provided by the client has been
+transferred. The client should respond to a transmit underrun by </p> <ul>
+<li id="GUID-C898DAD3-B7A6-5E35-B0D2-F7919FD402A1"><p>providing new
+transmit buffer, and </p> </li>
+<li id="GUID-0CC17326-1FFF-5B45-A4D9-6182B2A46C8E"><p>resetting its
+transmit notification triggers for instance by calling <codeph>SetNotificationTrigger(ETxAllBytes)</codeph>. </p> </li>
+</ul> <p>To make this possible the SHAI implementation layer should
+try to keep the transmit hardware FIFO at the highest possible level. </p> </li>
+<li id="GUID-3D823BF3-5AB5-565C-83B3-F7E7C4550EEA"><p>Pass <xref href="GUID-C29FA887-BBDA-35D2-9ED2-58083F85AD87.dita"><apiname>ETxOverrun</apiname></xref> if the transmission has been stopped but not
+all the data in the transmit buffer provided by the client has been
+transferred. This indicates that the client specified a bigger buffer
+for the transmission than the master needed to read from the slave. </p> </li>
+<li id="GUID-1CA68D76-14AF-5FF9-883A-60B6BC2A72F2"><p>Pass <xref href="GUID-1D10124D-F27E-33C3-B803-FEBDEB2B7964.dita"><apiname>EGeneralBusError</apiname></xref> if a bus error has occurred, that is if
+an interrupt signals a bus overrun or underrun indicating data corruption. </p> </li>
+</ul> </section>
+</conbody><related-links>
+<link href="GUID-052F58B7-117B-5EDD-A3D5-CB0DE6A4E239.dita"><linktext>IIC
+SHAI Implementation Layer: Generic Considerations</linktext></link>
+<link href="GUID-0C8318B1-71D7-5384-97EB-85CBBC3E6B84.dita"><linktext>IIC
+SHAI Implementation Layer: Master Channel</linktext></link>
+<link href="GUID-9986DCC6-EE73-59FB-BDAC-9B09DC64FBCE.dita"><linktext>Client
+of Master Channel Tutorial</linktext></link>
+<link href="GUID-F461CBB3-F8D1-5961-AD51-5741143A1CB1.dita"><linktext>Client
+of Slave Channel Tutorial</linktext></link>
+<link href="GUID-B2F86F54-EF50-56DB-ADF7-15325AC9324D.dita"><linktext>IIC
+Concepts</linktext></link>
+<link href="GUID-3A30DA16-ECA8-5639-A9DC-6BE2AD55420B.dita"><linktext>I2C
+Technology Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C98DF912-A903-4FDB-B27A-CC8E75E3E40F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C98DF912-A903-4FDB-B27A-CC8E75E3E40F" xml:lang="en"><title>The
+Logical Channel</title><shortdesc>This document describes how device driver code is accessed through
+a logical channel.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-62823FF9-984A-4A28-9E8E-98C7033C34B9">    
+     <p>All interaction between user code and the driver code takes place
+through a logical channel. On the user side, a channel is encapsulated by
+a <codeph>RBusLogicalChannel</codeph> derived class; on the Kernel side, a
+channel is encapsulated by a <codeph>DLogicalChannelBase</codeph> or a <codeph>DLogicalChannel</codeph> derived
+class, constructed by the <codeph>DLogicalDevice</codeph> factory object. </p> <fig id="GUID-E27A3A17-366D-5551-A26E-FC8E0853D72A">
+<title>                 Device driver logical channel classes            
+  </title>
+<image href="GUID-F4E04E00-D9C6-5E8F-9EC6-F90BC951D4D0_d0e63912_href.png" placement="inline"/>
+</fig>     </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-C9923DF3-8425-4EB4-8066-FB5A92A85F5B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,92 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-C9923DF3-8425-4EB4-8066-FB5A92A85F5B" xml:lang="en"><title>Adaptation Process Guide</title><shortdesc>Adaptation is the process of porting a platform on to a
+new hardware configuration. The existing process requires developers
+to write new hardware abstractions for any changes in the hardware
+configuration. Platform services provide a simple standard interface
+that reduces the adaptation time for a given hardware component.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-2CD8042D-F591-430B-8A07-B22502C908DD"><title>Hardware </title><p>A hardware component can be added to introduce a new feature or
+create a new variant of an existing feature. Mobile phones are developed
+with various form factors, a new variant is created for each form
+factor. </p><p>A particular new piece of hardware may require several
+platform services to be used to support all the functionality of that
+hardware. A camera may provide photos and video streams and require
+the use of a GPIO platform service to configure the camera resolution,
+to set focal distance, or to trigger the shutter.</p><fig id="GUID-D88555D3-7BC1-49AA-BC14-0FAE8BDE0475">
+<title>Basic blocks of an adaptation</title>
+<image href="GUID-5392507E-45FF-4B20-B257-E58E23685295_d0e410_href.png" placement="inline"/>
+</fig></section>
+<section id="GUID-90AED82D-2F1B-4FF4-8484-EDF00743A58A"><title>Platform
+services</title><p>Platform services are intended to be platform agnostic
+and aim to reduce the porting time of hardware adaptation from one
+platform to other. Platform services can be broadly classified into
+two categories:</p><ol>
+<li id="GUID-AC4E61B7-7124-46C6-A4CE-D79AAE733CD6"><p>Platform services
+that provide a service to other platform services.</p></li>
+<li id="GUID-8F6EF6E1-C8A5-4470-A913-54DB04FB833E"><p>Platform services
+that use various kernel services and other platform services to drive
+a hardware component.</p></li>
+</ol><fig id="GUID-BAF6CE9B-80C3-4BC2-B495-FB24F871ED00">
+<title> Types of platform service</title>
+<image href="GUID-14B65BE7-A166-48B6-B43D-DFF267F87F9E_d0e433_href.png" placement="inline"/>
+</fig><p>The adaptation developer should identify the platform services
+ required to implement the new hardware. Some platform services may
+already be implemented for other hardware and so it may be a simple
+matter of reusing another implementation with minor modifications
+for your particular component.</p></section>
+<section id="GUID-39421865-C5D6-4FA6-8821-DE09FA1F4837"><title>Hardware
+configurations</title><p>The adaptation will use certain hardware
+configurations and some of the configuration parameters can be reused.
+Reusable hardware configurations can be stored in a repository called
+the Hardware Configuration Repository (HCR). The HCR allows the configurations
+to be stored in the repository during various stages of the device
+creation. The HCR platform service provides APIs to the kernel and
+device drivers to read the values stored in the repository. For more
+information, see the <xref href="GUID-14F5433A-16F4-4F01-8A7B-C8E26F46C98B.dita">HCR Platform Service</xref> documentation.</p></section>
+<section id="GUID-6E9C4D9C-E0ED-44E8-84BE-49383DA26A15"><title>Implementation</title><p>The adaptation developer needs to know the specifications to implement
+a hardware on the device. The implementation process involves the
+identification of other services that must be implemented to support
+a hardware. The other services may be provided by other platform services,
+kernel extensions or drivers of other hardware components.</p></section>
+<section id="GUID-1AE8935F-E212-4D13-B7D7-47A5C7D14101"><title>Platform
+service compliance</title><p>Once the hardware component is implemented,
+the developer must ensure that the implementation conforms to the
+relevant platform service compliance testing. If the test fails then
+the adaptation code should be modified until the tests pass. </p></section>
+<section id="GUID-1E15BAC5-45DC-4550-AFC3-5CF72B72E2E5"><title>Adaptation
+process</title><p>The adaptation process can be summarized as:</p><ol>
+<li id="GUID-14817153-B03B-40EE-BACB-EAF2D66D3575"><p>Identify the
+hardware</p></li>
+<li id="GUID-3D250941-5BC5-4310-AB66-FFE520D381FB"><p>Identify the
+platform services required to implement the hardware component</p></li>
+<li id="GUID-A66BEC8A-7096-4506-9F5D-30AB793E165E"><p>Identify the
+dependencies</p></li>
+<li id="GUID-F381E27C-27B0-44D1-9592-350F73C1C63F"><p>Identify the
+required interfaces to be implemented</p></li>
+<li id="GUID-FD30A917-2A08-4575-8FE5-D8A50FF0779A"><p>Implement the
+required interfaces</p></li>
+<li id="GUID-F161C4E8-922F-41B1-A1BF-F9AB4B1339CA"><p>Build and test
+the interfaces</p></li>
+<li id="GUID-B7747558-12DD-420E-824C-7B6C0524E781"><p>Modify the implementation,
+if required</p></li>
+</ol><fig id="GUID-F0B99DE7-32BF-4C55-B3A4-5632D89DAF39">
+<title>Adaptation process flowchart</title>
+<image href="GUID-04FF36CE-DEFA-45DC-BAAF-77F3BB649AFF_d0e499_href.png" placement="inline"/>
+</fig></section>
+</conbody><related-links>
+<link href="GUID-D5EE0A17-2246-4CB3-9CE5-538F1E01F8D4.dita"><linktext>What
+is Adaptation?</linktext></link>
+<link href="GUID-95BD3650-08CB-407D-969E-DFDB39B2FEFC.dita"><linktext>What
+is a Platform Service?</linktext></link>
+<link href="GUID-A74F0245-1A37-41C8-B0E9-63AF858EE4B6.dita"><linktext>Platform
+Services</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-CA788AFE-D425-4B72-B8A2-34D38A8C341B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,43 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-CA788AFE-D425-4B72-B8A2-34D38A8C341B" xml:lang="en"><title>Device
+Driver Writing Guide Quick Start</title><shortdesc>Conceptual information that a developer should know before creating
+a device driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>A device driver is a program that controls a particular type of device
+that is attached to a base port. Writing a device driver requires an in-depth
+understanding of how the hardware and the software of a given platform function.
+The Device Driver writing guide tells you what you need and how to create
+a device driver.</p>
+<section id="GUID-7DDE15F6-CF58-40EB-9A97-AC70CEE9AF8A">       <ul>
+<li><p>For information about the parameters needed to create a valid Symbian
+platform device driver, see <xref href="GUID-CB3A8650-751C-4DAA-9408-7AEB3C7FD41A.dita">Minimal
+Driver Requirements</xref>.</p></li>
+</ul><ul>
+<li><p>For information about high-level implementation designs for your device
+driver, see <xref href="GUID-0346036B-A470-4C18-B276-3A3485F6A069.dita">Design
+Options</xref>.</p> </li>
+</ul><ul>
+<li><p>For information about how device drivers are implemented as logical
+device drivers (LDDs) and physical device drivers (PDDs), see <xref href="GUID-EBF4F1F1-F76B-455B-B8EE-B7965CF0717E.dita">The
+LDD/PDD Model</xref>.</p> </li>
+</ul><ul>
+<li><p>For information about organizing memory, managing data transfer across
+memory boundaries and the data transfer between LDD and PDD, see <xref href="GUID-E90DBF35-0A05-4751-904D-4F06987FFF48.dita">Memory
+Management</xref>.</p> </li>
+</ul><ul>
+<li><p>For information about the user-side requests to a driver and the synchronization
+methods used by the driver, see <xref href="GUID-CFE0A4EB-845C-43B6-A732-AA155AFD99D6.dita">User
+Requests and Synchronization</xref>.</p> </li>
+</ul><ul>
+<li><p>For information about how device drivers use interrupts, see <xref href="GUID-660A8E4C-F930-415C-8CCC-CB1DCCAA2442.dita">Interrupts</xref> .</p> </li>
+</ul>           </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-CAEDFD1D-ECA1-5A6F-9861-63B7BE24E9E4.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,60 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-CAEDFD1D-ECA1-5A6F-9861-63B7BE24E9E4" xml:lang="en"><title>Reference</title><shortdesc>Summary of related documentation for the Local Media Subsystem. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-12BD8537-821C-5598-B7D7-F474BF19A334"><title>API Reference</title> <p><b>Kernel
+Architecture 2 </b> </p> <table id="GUID-779C59D7-0920-53DC-AC60-9132925C9166">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Item</b>  </p> </entry>
+<entry><p> <b>Header</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-720001A0-79E6-3E25-B5F0-4B39EAF95D12.dita#GUID-720001A0-79E6-3E25-B5F0-4B39EAF95D12/GUID-0559A1ED-05A1-386E-B728-0D500ED4E3EA"><apiname>DLocalDrive::TRequestId</apiname></xref>  </p> </entry>
+<entry><p> <filepath>locmedia.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-918D17D8-B751-35EE-A592-4F0EAB005EC7.dita"><apiname>DMedia</apiname></xref>  </p> </entry>
+<entry><p> <filepath>locmedia.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC.dita"><apiname>DMediaDriver</apiname></xref>  </p> </entry>
+<entry><p> <filepath>locmedia.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-3715787E-9ADD-39E7-B22A-62CBBD2CEF1B.dita"><apiname>DPrimaryMediaBase</apiname></xref>  </p> </entry>
+<entry><p> <filepath>locmedia.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-9E60E8D9-619E-3A76-BAC8-93A60D62C7DF.dita"><apiname>LocDrv</apiname></xref>  </p> </entry>
+<entry><p> <filepath>locmedia.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-FC0F974E-9ABB-348B-9AE9-778B3A1F413A.dita"><apiname>SMediaDeviceInfo</apiname></xref>  </p> </entry>
+<entry><p> <filepath>locmedia.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita"><apiname>TLocDrvRequest</apiname></xref>  </p> </entry>
+<entry><p> <filepath>locmedia.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A1D73DDB-3729-31D2-B4F3-7638AEE72B54.dita"><apiname>TPartitionEntry</apiname></xref>  </p> </entry>
+<entry><p> <filepath>locmedia.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-00D1DAB7-C23A-30F4-B5A3-B47EED5A5DD3.dita"><apiname>TPartitionInfo</apiname></xref>  </p> </entry>
+<entry><p> <filepath>locmedia.h</filepath>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-CB0FC4F4-6DAB-4ADD-B044-0E8B9365B4D5.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-CB0FC4F4-6DAB-4ADD-B044-0E8B9365B4D5" xml:lang="en"><title>IIC Technology</title><shortdesc>Describes the technology that is used within IIC.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-CB3A8650-751C-4DAA-9408-7AEB3C7FD41A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-CB3A8650-751C-4DAA-9408-7AEB3C7FD41A" xml:lang="en"><title>Minimal
+Driver Requirements</title><shortdesc>This section explains how to make a valid Symbian Platform driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-CC04A14B-A839-5613-820D-F1E65EB2DF7F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,54 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-CC04A14B-A839-5613-820D-F1E65EB2DF7F" xml:lang="en"><title>MAKSYM/MAKSYMROFS</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>MAKSYM/MAKSYMROFS tool is used to create a symbol file, which lists
+the addresses of every global and exported function in the ROM. It
+reads a log file to generate the symbol file. The log file contains
+information about the contents of the ROM or ROFS image. </p>
+<p>MAKSYM reads the log file which is created by ROMBUILD when building
+a ROM image. MAKSYMROFS reads the log file which is created by ROFSBUILD
+when building a ROFS image. The command syntax for MAKSYM and MAKSYMROFS
+is the same. </p>
+<section id="GUID-4ABD6DC7-7B5F-5E81-81F6-408F02FB8EA2"><title>MAKSYM
+command syntax</title> <codeblock id="GUID-80510A94-15C8-55C3-99D9-5C82DEBF9269" xml:space="preserve">MAKSYM &lt;logfile&gt; [&lt;outfile&gt;]</codeblock> <table id="GUID-977669AC-2133-5573-9287-6B3741A86C8C">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>&lt;logfile&gt;</codeph>  </p> </entry>
+<entry><p>This is the name of the log file generated by the <xref href="GUID-003D2C5B-09DC-5BD1-AF45-A0FCB56F567B.dita">ROMBUILD</xref> tool. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>&lt;outfile&gt;</codeph>  </p> </entry>
+<entry><p>This is the name for the MAKSYM output file. If not specified,
+it defaults to <filepath>&lt;ROMimagename&gt;.symbol</filepath>. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>By default, ROMBUILD produces a log file called <filepath>ROMBUILD.LOG</filepath>, which is passed to MAKSYM tool in the following
+way: </p> <p><userinput>MAKSYM rombuild.log</userinput> </p> <p>This
+will generate an output text file (Symbolic information file) called <filepath>&lt;romimagename&gt;.symbol</filepath>. </p> <p>The file contains all
+the global variables along with their address and length. For example,
+the start of <filepath>EKERN.EXE</filepath> looks like this: </p> <codeblock id="GUID-74AEE387-D6D3-51C6-8658-78B2A2DA0FF4" xml:space="preserve">From    \Epoc32\Release\Misa\UREL\ekern.exe
+
+50003040    0094    _E32Startup
+500030d4    002c    ImpDma::Init1(void)
+50003100    0004    ImpDma::Init3(void)
+50003104    0008    ImpDma::MaxBlockSize(void)
+</codeblock> <p>In this example, the function <codeph>ImpDma::Init1()</codeph> starts at address <codeph>0x500030d4</codeph> and is <codeph>0x2c</codeph> bytes long. </p> <p> <b>Notes</b>: </p> <ul>
+<li id="GUID-BD48C930-4051-5276-AB78-8CC5BADD65ED"><p>If you are distributing
+ROM images for testing, it is also useful to supply the symbolic information
+file for that image. </p> </li>
+<li id="GUID-2B694850-0513-52B8-B477-78A08F4B83AE"><p>If you re-build
+the ROM image you must also rebuild the symbolic information file
+using MAKSYM. </p> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-CDB2DD00-482D-5AEA-AF89-064C8F904DD9.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-CDB2DD00-482D-5AEA-AF89-064C8F904DD9" xml:lang="en"><title>Set Up</title><shortdesc>Describes how to use the template port to start your port.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There is a template DMA Framework consisting of the source file <filepath>dmapsl.cpp</filepath>, and the mmp file <filepath>dma.mmp</filepath> located in the directory <filepath>...\template\dma</filepath> that
+can be used as the starting point for your DMA PSL port. You need
+to: </p>
+<ul>
+<li id="GUID-2BDEC332-6B6C-5FF4-9B61-C915E43345F5"><p>Decide which
+directory your DMA PSL and associated <filepath>.mmp</filepath> file
+are to be stored in. You would normally choose the variant or the
+ASSP directory. </p> </li>
+<li id="GUID-C971FA47-8535-504C-AC37-37280C3EA9DE"><p>Copy the template
+framework into your chosen location. Be aware that the template <filepath>dma.mmp</filepath> file contains relative paths that must be updated. </p> </li>
+<li id="GUID-D18C8A72-9371-5467-ABA4-DC0D76B10D90"><p>Change the variant's <filepath>bld.inf</filepath> file to include a reference to your
+mmp file. </p> </li>
+</ul>
+<p>The remainder of this porting guide refers to the implementation
+of the DMA Framework for the template ASSP, which forms the basis
+for the template reference board; the source file can be found in <filepath>..\template_assp\dmapsl.cpp</filepath> and the mmp file in <filepath>...\template_assp\dma.mmp</filepath>. </p>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-CDDD8189-D532-5179-92F6-74264C2E3D81-master.png has changed
Binary file Adaptation/GUID-CDDD8189-D532-5179-92F6-74264C2E3D81_d0e35308_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-CE9EA167-0594-5E61-9640-6B2B63A92EA7.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-CE9EA167-0594-5E61-9640-6B2B63A92EA7" xml:lang="en"><title>Code Paging</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Demand paging documentation related to code demand paging. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-CEA3343B-138E-4D6B-8E5F-A255C5C73376.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE reference
+  PUBLIC "-//OASIS//DTD DITA Reference//EN" "reference.dtd">
+<reference id="GUID-CEA3343B-138E-4D6B-8E5F-A255C5C73376" xml:lang="en"><title>SHAI Implementation</title><shortdesc>Adaptation software providing a realization of the SHAI
+Interface. The SHAI Implementation is also known as the Platform Specific
+Layer (PSL).</shortdesc><prolog><metadata><keywords/></metadata></prolog><refbody>
+<section id="GUID-6A3505FC-C4D6-44FD-99F7-9FDC8A89F6A6"> 			 		</section>
+</refbody></reference>
\ No newline at end of file
Binary file Adaptation/GUID-CEDA0EFF-A1D4-53FE-9BF2-DB9AA857BCF5-master.png has changed
Binary file Adaptation/GUID-CEDA0EFF-A1D4-53FE-9BF2-DB9AA857BCF5_d0e3163_href.png has changed
Binary file Adaptation/GUID-CF252B09-335E-5831-94A6-0B16B64C5030-master.png has changed
Binary file Adaptation/GUID-CF252B09-335E-5831-94A6-0B16B64C5030_d0e10851_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-CF710BE5-531D-4287-9002-39E7DE27FACA.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-CF710BE5-531D-4287-9002-39E7DE27FACA" xml:lang="en"><title>Device
+Driver</title><shortdesc>Device Drivers provide a standard interface between Applications
+and hardware.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-CFE0A4EB-845C-43B6-A732-AA155AFD99D6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-CFE0A4EB-845C-43B6-A732-AA155AFD99D6" xml:lang="en"><title>User
+Requests and Synchronisation</title><shortdesc>This document introduces user requests and synchronisation methods
+used by device drivers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-B206AAEC-9750-44BB-B2FC-70613D3AEAB9">       <title>Types
+of user request</title>       <p>User-side requests to a driver can be of
+three types: synchronous, asynchronous, and cancellation of an asynchronous
+request. User requests can be handled in two different ways, based on the
+logical channel model used by the device driver. A channel implementation
+is derived from either: </p> <ul>
+<li id="GUID-7FB5FD8B-A33D-5AC2-9913-F741AB04853F"><p> <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita"><apiname>DLogicalChannelBase</apiname></xref>:
+the driver developer decides how a request is handled. </p> </li>
+<li id="GUID-0E2BF6E4-4B7C-5B8D-8A56-0E7607BB53EB"><p> <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita"><apiname>DLogicalChannel</apiname></xref>:
+this is derived from <codeph>DLogicalChannelBase</codeph>, and implements
+a basic mechanism for handling requests. </p> </li>
+</ul> <p>In the <codeph>DLogicalChannel</codeph> derived model, requests from
+user threads to the driver are queued as messages and handled sequentially
+by a single Kernel side DFC. This is the model described in this section.
+More details on the differences between the models can be found in<xref href="GUID-0956CE5E-C02B-5EEE-890A-5E8E84A8D9A1.dita">Logical
+Channel</xref> documentation. </p> <p>All requests from the user result in
+a call to a single function <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita#GUID-E7550422-5121-3393-A85E-BB797969CD2A/GUID-FD4DA73F-45E7-37BE-9380-1D8ED36114F7"><apiname>DLogicalChannelBase::Request()</apiname></xref>.
+In this function the driver determines the type of the request, i.e. synchronous,
+asynchronous, or cancel, and implements handling of the requests. </p>   
+ </section>
+<section id="GUID-0C209A93-7FFE-4C63-A362-A6674D941E9C"><title>Synchronisation
+methods</title><p>A driver uses the following synchronisation methods.</p><ul>
+<li>Deferred Function Calls</li>
+<li>Timers</li>
+<li>Generated Events</li>
+</ul></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D003030D-8506-4210-9194-7A3819205D68.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D003030D-8506-4210-9194-7A3819205D68" xml:lang="en"><title>Hardware
+Registers</title><shortdesc>This document describes how device drivers use hardware registers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-47A733FB-8AC9-40A0-B879-C8C01B0AB1ED">           <p>The
+APIs to access hardware peripheral registers are provided by a Symbian base
+port. For example, the base port for the OMAP 2420 provides the <codeph>TOmap::SetRegister()</codeph> and <codeph>TOmap::GetRegister()</codeph> functions
+to access its peripheral controller registers. Peripheral drivers would generally
+use these APIs. Some examples: </p> <ol id="GUID-78156A20-8B2F-52FB-8A9F-159B6EE8714E">
+<li id="GUID-330A1D4C-E054-5DC3-A1F5-D85A9F600834"><p>To set the UART LCR
+register: </p> <codeblock id="GUID-35EE35C4-B89B-52D1-AC25-13C63BA55435" xml:space="preserve">TOmap::SetRegister8(iPortAddr+KHoUART_LCR, KHbUartLCRFifoConfig);</codeblock> </li>
+<li id="GUID-06BE62D4-4ED7-5186-A191-9908C10B1C7E"><p>To get the UART MDR
+register: </p> <codeblock id="GUID-64F8101B-CDDF-57E9-93D4-08B4BBA117CB" xml:space="preserve">TOmap::Register8(iPortAddr+KHoUART_MDR1)</codeblock> </li>
+<li id="GUID-D549BAC4-5842-5E8D-B086-28A5366DBC4D"><p>To modify only the specified
+bits of the register: here, the UART LCR register bit 6 is being set to 0
+(LCR[6] = 0) </p> <codeblock id="GUID-C705FB36-1D4E-557F-B30D-6B6AD21E5B5C" xml:space="preserve">TOmap::ModifyRegister8(iPortAddr+KHoUART_LCR,
+                  (TUint8)KHtUartLCRBreakEnable,
+                  (TUint8)KSetNone);</codeblock> </li>
+</ol>     </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D048E187-6B1C-5A80-9CD0-89CD10688C6F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D048E187-6B1C-5A80-9CD0-89CD10688C6F" xml:lang="en"><title>Keyboard
+Driver</title><shortdesc>A Keyboard Driver is a kernel extension that gets input
+from keyboard hardware, and makes these events available to other
+parts of the operating system and applications. This section describes
+how to implement a driver for your phone hardware. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>A Keyboard Driver is platform-specific, and is implemented
+by the base port. Symbian platform provides template code for a driver.
+A base port must also implement a keyboard mapping library, which
+is used by user-side components to translate the codes used for hardware
+keys into logical key codes. </p>
+</conbody><related-links>
+<link href="GUID-6A6D5DC5-3B5C-5A26-8D7F-C280AA4D5F18.dita"><linktext>Key
+  Codes</linktext></link>
+<link href="GUID-0C4B86B5-530A-5839-86C1-46E7ABE281E0.dita"><linktext>Window
+  Server Component</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D089C2E9-1BE4-4B37-B8A8-21E5B2425E6C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,45 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D089C2E9-1BE4-4B37-B8A8-21E5B2425E6C" xml:lang="en"><title>SDIO
+Technology Guide</title><shortdesc>Provides information about the concepts and the uses of the SDIO
+card.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-075122CD-EA1E-4567-9D0F-5DFA548DA883">       <title>Purpose</title> 
+     <p>The Secure Digital Input/Output (SDIO) protocol is based on the SD
+memory card protocols. The SDIO bus enables high speed data transfers between
+the host and a card. The SDIO consumes low power and is efficient for use
+in mobile devices. SDIO cards like SD cards use star topology that have dedicated
+command and data signals. The purpose of the SDIO APIs is to enable easy porting
+of the Symbian SDIO services for a particular SDIO controller.</p> 
+   </section>
+<section id="GUID-57C125FF-4196-40D7-B1E5-DDA292076916"><title>Key concepts</title><ul>
+<li><p><b>SDIO controller:</b></p> is the executable that manages access to
+the SDIO card hardware interface and provides an API for class drivers to
+access SDIO card functions.</li>
+</ul><ul>
+<li><p><b> Stack:</b></p>handles multiple requests simultaneously.  It internally
+schedules the requests on to the bus and allocates the appropriate card to
+transfer data accordingly.</li>
+</ul><ul>
+<li><p><b>Session:</b></p> sets up a session object to perform SDIO specific
+command sequences.</li>
+</ul><ul>
+<li><p><b>Register interface:</b></p> allows single byte read/write operations
+to a given register address together with the corresponding ones for multi-byte
+access. </li>
+</ul></section>
+<section id="GUID-16D2B044-0E5A-4126-ADAC-B297C4B616F8"><title>Typical Uses</title><ul>
+<li><p>Powering up stack containing a single SDIO Card.</p></li>
+<li><p>Sending a command to PSL.</p></li>
+<li><p>Acquiring new cards into the SDIO stack.</p></li>
+<li><p>Configuring an SDIO card.</p></li>
+</ul></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D0F5D40A-28D2-4A2E-9B40-180537E60F56.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,87 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D0F5D40A-28D2-4A2E-9B40-180537E60F56" xml:lang="en"><title>Interrupt Client Interface Guide</title><shortdesc>Provides information to handle and control interrupts in
+the system.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The purpose of this document is to describe interrupt specific
+functions for the kernel side device drivers. </p>
+<section id="GUID-FBAD05E8-650D-4B1A-B0EF-A300436D890A">         
+   <title>Interface classes</title>             <table id="GUID-BEFE92DD-C363-4D72-A1A2-63BD8DE6B91B">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p><xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita"><apiname>Interrupt</apiname></xref></p></entry>
+<entry><p>Exports interrupt functionality to device
+drivers and other kernel-side code</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table>         </section>
+<section id="GUID-3395229E-189B-4182-A18E-67DB99B65DDD"><title>Interrupt
+class</title><p>The <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita"><apiname>Interrupt</apiname></xref> class provides functions
+for using interrupts. The Symbian platform defines this class and
+the implementation for each of the functions is defined by at the
+hardware level.</p><p>The Interrupt class provides the following functions.</p><table id="GUID-7E7372AA-2D00-4D74-ABB4-E1AC0116AA86">
+<tgroup cols="3"><colspec colname="COLSPEC0" colwidth="1.00*"/><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">Function		</entry>
+<entry valign="top">Return Type</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p><xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-118AE209-BBFA-367D-89EE-A79722207532"><apiname>Interrupt:: Bind(TInt anId, TIsr anIsr, TAny* aPtr)</apiname></xref></p></entry>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>Associates the specified Interrupt Service Routine (ISR)
+function with the specified interrupt Id.</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-AE029812-8220-3970-80F6-6322B9D933BC"><apiname>Interrupt::Unbind(TInt anId)</apiname></xref></p></entry>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>Unbinds the ISR function from the specified interrupt Id.</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-A0D94710-E832-36F9-B324-823BFA537C2E"><apiname>Interrupt::Enable(TInt anId)</apiname></xref></p></entry>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>Enables the specified interrupt.</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-410A0ED1-CA83-396C-921B-766C4D0BEFF6"><apiname>Interrupt::Disable(TInt anId)</apiname></xref></p></entry>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>Disables the specified interrupt.</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-63C93F0D-F236-35D0-8E21-9FF1F96074B3"><apiname>Interrupt::Clear(TInt anId)</apiname></xref></p></entry>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>Clears the interrupt pending signal at the interrupt controller
+hardware level.</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-CD40CF24-7732-34FB-8FA1-34E0DCB9B474"><apiname>Interrupt::SetPriority(TInt anId, TInt aPriority)</apiname></xref></p></entry>
+<entry><p><codeph>TInt</codeph></p></entry>
+<entry><p>Changes the priority of the specified interrupt to the new
+specified value.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+</conbody><related-links>
+<link href="GUID-654A788A-526A-4C3F-838C-05B09F0D5445.dita"><linktext>Interrupt
+Technology Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D1C5BB01-6780-41D6-B47B-43D4C983B0B6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D1C5BB01-6780-41D6-B47B-43D4C983B0B6" xml:lang="en"><title>API Export</title><shortdesc>This document discusses how to export a device driver API.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>A driver can export its API to be used by other Kernel code by
+using IMPORT_C in the declaration and EXPORT_C in the definition.
+When the driver is built, these functions are exported to a <filepath>.def</filepath> file. The <filepath>.def</filepath> file is specific
+to the platform to which the driver is built. </p>
+<codeblock id="GUID-3E732A29-D285-5A51-AF25-9B4B06049632" xml:space="preserve">// Kernel extension internal API
+class DExController: public DBase
+    {
+    …
+    void MyExAPI();
+    …
+    };
+
+// Client interface API
+class TExClientInterface
+    {
+    …
+    // static function being exported, this API will go into def file 
+    // generated while building
+    IMPORT_C static void MyExAPI();
+    …
+    };
+
+// Global instance of the object
+DExController *ExController = NULL; 
+
+// Implementation of the kernel extension's exported function
+EXPORT_C void TExClientInterface::MyExAPI()
+    {
+    …
+    ExController-&gt;MyExAPI();
+    …
+    }</codeblock>
+<p>Kernel extensions can also provide information to user programs
+by setting attributes that can be read through the system HAL (Hardware
+Abstration Layer) API. See<xref href="GUID-124AC7EE-E227-5358-A755-628FFE257250.dita"> Handler Implementation</xref> for more information on this. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D1F7D21F-BA9D-482C-9B58-7C53A680145A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D1F7D21F-BA9D-482C-9B58-7C53A680145A" xml:lang="en"><title>DMA</title><shortdesc>This document introduces the Symbian platform DMA framework.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D207C135-EF02-4D1A-A48C-4AB8C6703496.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D207C135-EF02-4D1A-A48C-4AB8C6703496" xml:lang="en"><title>Device
+Driver Structure</title><shortdesc>This document describes the structures used to implement device
+drivers as LDDs and PDDs.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Both LDDs and PDDs are DLLs. </p>
+<p>They implement a specific interface that allows the kernel to initialise
+them, and for user-side code to communicate with them. </p>
+<p>An LDD must implement: </p>
+<ul>
+<li id="GUID-A57D8838-EF0B-5096-99EC-D9197C58EE35"><p>A <codeph>DLogicalChannel</codeph> or <codeph>DLogicalChannelBase</codeph> derived
+class, representing the logical channel, which handles user requests. </p> </li>
+<li id="GUID-1E3CD4B7-15BC-59B1-939B-2AF34F0438BB"><p>A <codeph>DLogicalDevice</codeph> derived
+class, which provides a factory for the logical channel objects, called the
+LDD factory. </p> </li>
+<li id="GUID-2342FF0C-4CC0-561F-81CB-2643E09351B4"><p>A DLL entry point function
+at ordinal 1, which constructs the LDD factory object. </p> <p>It is possible
+that a device driver is also an extension, in which case the entry point will
+also be used for extension initialisation. </p> </li>
+</ul>
+<p>A PDD must implement: </p>
+<ul>
+<li id="GUID-0D5220C0-764F-5711-970F-60D19AD21320"><p>A <codeph>DBase</codeph> derived
+class representing the physical channel, which is the interface between the
+logical device and the physical device. </p> </li>
+<li id="GUID-BEC551B8-AED6-5EEC-8FDA-C742B4C1F7DC"><p>A <codeph>DPhysicalDevice</codeph> derived
+class, which provides a factory for the physical channel objects, called the
+PDD factory. </p> </li>
+<li id="GUID-9D72BF3C-6D13-5D9F-A8E3-D376D445AC08"><p>A DLL entry point function
+at ordinal 1, which constructs the PDD factory object. </p> </li>
+</ul>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D2163920-D448-5BFC-B655-B654FD657A94.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D2163920-D448-5BFC-B655-B654FD657A94" xml:lang="en"><title>Level
+2 Cache</title><shortdesc>Level 2 cache is cache memory that is external to the microprocessor.
+The kernel provides functions to perform operations on this cache. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>In general, the presence of Level 2 cache is transparent to device drivers.
+The cache is physically indexed and physically tagged, and this means that
+L2 cache is not affected by the remapping of virtual-to-physical addresses
+in the MMU. </p>
+<p>However, where data is being transferred using DMA, then cached information
+in the data buffers involved in a DMA transfer must be flushed before a DMA
+write operation, for example when transferring data from memory to a peripheral,
+and both before and after a DMA read operation, for example when transferring
+data from a peripheral into memory. </p>
+<p>The kernel provides three functions for this: </p>
+<ul>
+<li id="GUID-031134D4-1CF6-503F-9DBD-75836242A0BD"><p> <xref href="GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F.dita#GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F/GUID-5F08DEAA-1237-32DE-AE41-CE7B18230972"><apiname>Cache::SyncMemoryBeforeDmaWrite()</apiname></xref>  </p> </li>
+<li id="GUID-0E0BBB26-1F1C-5A64-A9D3-506B5D6783EA"><p> <xref href="GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F.dita#GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F/GUID-3FF3C567-C1BD-3D4E-97E1-B036456A374E"><apiname> Cache::SyncMemoryBeforeDmaRead()</apiname></xref>  </p> </li>
+<li id="GUID-DB3947C1-1BB7-5678-A337-48C74B903496"><p> <xref href="GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F.dita#GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F/GUID-78E6DE46-61F0-3840-B555-6926D21141BF"><apiname> Cache::SyncMemoryAfterDmaRead()</apiname></xref>  </p> </li>
+</ul>
+<p>All three functions are defined and implemented as part of the <xref href="GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F.dita"><apiname>Cache</apiname></xref> class,
+defined in <filepath>...\e32\e32\include\kernel\cache.h.</filepath>  </p>
+<p>See also <xref href="GUID-18EFC99D-68B6-51E1-8520-272DC278E82A.dita#GUID-18EFC99D-68B6-51E1-8520-272DC278E82A/GUID-F9DA4E5B-5675-55D3-9793-0D8404FAA7B6"> DMA
+buffers</xref> in the <xref href="GUID-18EFC99D-68B6-51E1-8520-272DC278E82A.dita">Device
+Driver Tutorial</xref>. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D291C9E9-5207-4B23-B287-C240464087B9.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,76 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D291C9E9-5207-4B23-B287-C240464087B9" xml:lang="en"><title>The
+PDD Entry Point and Factory</title><shortdesc>This document describes how PDDs are created.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-1099A347-6D77-4231-BAF5-B0EAAEA560B7">           <p>A PDD
+must define an entry point function using the macro <xref href="GUID-73947402-2F32-35C7-94C4-22B4D63D5FB3.dita"><apiname>DECLARE_STANDARD_PDD</apiname></xref>,
+or <xref href="GUID-52853C0D-CA98-3B92-B7D4-FF1C1F06C1A6.dita"><apiname>DECLARE_EXTENSION_PDD</apiname></xref> in the case of kernel extensions.
+This must create a PDD factory object derived from <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita"><apiname>DPhysicalDevice</apiname></xref>: </p><codeblock id="GUID-895AE2E1-A739-5FDB-8039-D382E7ACF245" xml:space="preserve">DECLARE_STANDARD_PDD()
+    {
+    return new DerivedPhysicalDevice;
+    }</codeblock> <p>This factory object is created on the kernel heap. Its
+purpose is to create the physical channel, if needed. </p> <p> <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita"><apiname>DPhysicalDevice</apiname></xref> is
+derived from <xref href="GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497.dita"><apiname>DObject</apiname></xref>, and is, therefore a reference-counting
+object. It also means that <codeph>DPhysicalDevice</codeph> objects are given
+a name, as these objects are always subsequently found by name. Names are
+also used to identify those PDDs that can be used with a given LDD; they have
+a name of the form <codeph>x.y</codeph> where <codeph>x</codeph> is the name
+used by the LDD and <codeph>y</codeph> is PDD-specific. </p> <p>An LDD indicates
+that it requires an accompanying PDD by setting the LDD factory object member <xref href="GUID-7616AA05-83E6-3989-AB9D-11AE01245BEB.dita#GUID-7616AA05-83E6-3989-AB9D-11AE01245BEB/GUID-EB891156-94D9-323A-AB23-7B5994CD95E3"><apiname>DLogicalDevice::iParseMask</apiname></xref> with
+the <codeph>KDeviceAllowPhysicalDevice</codeph> flag. There are two ways that
+a suitable PDD can be found: </p> <ol id="GUID-FA526F7D-1DD7-5228-AA5C-CEBC74191B0B">
+<li id="GUID-2D096381-32BD-57EB-9387-2B10B0020686"><p>A user can specify the
+name of a PDD through the <codeph>RBusLogicalChannel::DoCreate()</codeph> protected
+function: </p><codeblock id="GUID-21CE3362-AD93-5FCE-BBC7-212C919ED83C" xml:space="preserve">TInt DoCreate(const TDesC&amp; aDevice, const TVersion&amp; aVer, TInt aUnit, const TDesC* aDriver, const TDesC8* anInfo, TOwnerType aType=EOwnerProcess, TBool aProtected=EFalse);</codeblock> <p>The user side passes a pointer to a descriptor containing the name of
+the required PDD as the fourth argument. A PDD with that name must already
+have been loaded, and its factory object created. The device driver framework
+searches for a PDD factory object with that name, and if found, calls <codeph>Validate()</codeph> on
+that object; if this function returns <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref>, then the
+PDD is accepted as the required PDD. </p> </li>
+<li id="GUID-ECF90DCF-71B6-5F1D-A3B5-0FF245A58306"><p>If no explicit PDD name
+is passed from the user side, then the device driver framework searches for
+all PDD factory objects, i.e. <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita"><apiname>DPhysicalDevice</apiname></xref> objects,
+that have a name in the form <codeph>x.y</codeph>, where <codeph>x</codeph> is
+the name of the LDD factory object. The device driver framework calls <codeph>Validate()</codeph> on
+each matching PDD factory object, passing the unit number and the optional
+extra information block; the first one to return <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref> is
+accepted as the required PDD. </p> </li>
+</ol> <p>The file extension of a PDD DLL can be any permitted Symbian Platform
+name but, by convention, the PDD DLL has the extension <filepath>.PDD</filepath>.
+Device driver DLLs are polymorphic interface DLLs. When building PDDs, specify
+a target type of <i>pdd</i> in the <filepath>.mmp</filepath> file. </p> <p>A
+PDD is loaded by calling <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-A0F4BF4A-9C58-3E5E-88E1-6D98597DDA18"><apiname>User::LoadPhysicalDevice()</apiname></xref>. This
+static function: </p><ul>
+<li id="GUID-EFB4CF23-26C3-5874-9709-5BE112F92C2A"><p>loads the DLL into RAM,
+if necessary </p> </li>
+<li id="GUID-4C131AE3-7048-5C91-9EF8-C7EBC04CC7B3"><p>calls the exported function
+at ordinal 1 to create the factory object, the <codeph>DPhysicalDevice</codeph> derived
+object </p> </li>
+<li id="GUID-FC279525-DC2E-5000-AE8F-B2E03F8A2FCF"><p>places the factory object
+into the appropriate object container. </p> </li>
+</ul> <note>This only needs to be done once, not every time the driver is
+used.</note><p>If a PDD needs to perform initialisation at boot time (before
+the driver is loaded by <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-A0F4BF4A-9C58-3E5E-88E1-6D98597DDA18"><apiname>User::LoadPhysicalDevice()</apiname></xref>), then
+specify the entry point macros <codeph>DECLARE_STANDARD_EXTENSION</codeph> and <codeph>DECLARE_EXTENSION_PDD</codeph>. </p><codeblock id="GUID-CF83DB15-2040-5C18-9728-E1B3A56E9D50" xml:space="preserve">DECLARE_STANDARD_EXTENSION()
+    {
+    // initialise code here
+    }
+
+DECLARE_EXTENSION_PDD()
+    {
+    return new DMyPhysicalFactory;
+    }</codeblock> <note><p>In order for the kernel to initialise the PDD extension
+at boot time then the <filepath>.oby</filepath> file must specify the <codeph>extension</codeph> keyword.
+Also note that initialisation of the extension will not load the PDD - this
+still has to be done through a call to <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-67DF6521-DE70-39E1-8EFB-246D419F7566"><apiname>User::LoadPhysicalDevice().</apiname></xref></p></note> 
+   </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-D2D41326-BA88-5A02-805B-5EAEC29ADB5D-master.png has changed
Binary file Adaptation/GUID-D2D41326-BA88-5A02-805B-5EAEC29ADB5D_d0e19383_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D34DB4A1-1B17-5FAF-A48B-E06D247B0A83.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,85 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D34DB4A1-1B17-5FAF-A48B-E06D247B0A83" xml:lang="en"><title>Keyboard Mapping DLL Tutorial</title><shortdesc/><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>A keyboard mapping DLL provides a set of lookup tables that the
+generic <filepath>ektran.dll</filepath> uses to convert scancodes
+to keycodes. A keyboard mapping DLL is implemented in a base port. </p>
+<p>The basic purpose of the tables is to provide a mapping from scancodes
+to keycodes, so that, given a scancode, the corresponding keycode
+can be found. The tables are organized so that there is, in effect,
+one set of lookup tables for each likely combination of modifier key
+states. <filepath>ektran.dll</filepath> compares the modifier keys
+that have been pressed with the stored modifier key state combinations
+to decide which set of lookup tables to use. </p>
+<p>An outline set of tables is provided in the template port.</p>
+<p>The following list outlines the structure of the tables. </p>
+<ol id="GUID-54817A2B-F65D-5BDF-BFCF-3E68A582C91A">
+<li id="GUID-0C32BD32-0EFD-5622-9C66-2610A3D7F660"><p>The tables are
+organized in a hierarchical structure. The start of this hierarchy
+is the root table, defined by a <xref href="GUID-F7DFE751-C534-36A8-9B57-9C8417B1BE06.dita"><apiname>SConvTable</apiname></xref> struct.
+This contains: </p> <ul>
+<li id="GUID-98675F02-D273-5C0D-8AF1-A9F93F8A5AC2"><p>an array of
+pointers to nodes, where each node is defined by the <xref href="GUID-3D2F56DB-DD36-3787-8653-C5AC114D69A1.dita"><apiname>SConvTableNode</apiname></xref> struct. Each node corresponds to a specific combination of modifier
+key states. </p> </li>
+<li id="GUID-8321989A-20FE-58C3-90D0-2D3BE29E11F6"><p>a field containing
+the total number of such nodes. </p> </li>
+</ul> <fig id="GUID-A8C68654-2D56-501F-8D45-C0F75E63B630">
+<title>Keyboard Mapping Table</title>
+<image href="GUID-FB69F45C-2256-5F2D-8D2C-98C93B865962_d0e14972_href.png" placement="inline"/>
+</fig> </li>
+<li id="GUID-C232C328-190D-59F1-A1CB-BC9D736367B0"><p>The combination
+of modifier key states that each node represents is encapsulated by
+a <xref href="GUID-7D0DE872-AC17-3045-9F97-E25A13B5CFB0.dita"><apiname>TMaskedModifiers</apiname></xref> object. One of these objects
+is embedded within each node. </p> <p>A <xref href="GUID-7D0DE872-AC17-3045-9F97-E25A13B5CFB0.dita"><apiname>TMaskedModifiers</apiname></xref> object consists of a mask, and a value for comparison. For example,
+if an instance is set to the following: </p> <codeblock id="GUID-E53A8286-C304-50BD-9DB5-81777B48A2E3" xml:space="preserve">iMask = EModifierShift | EModifierCtrl | EModifierFunc
+iValue = EModifierShift | EModifierFunc</codeblock> <p>then a match
+occurs only for the following combination of modifier key states: </p> <p> <codeph>ctrl</codeph> + <codeph>shift</codeph> + <i>not</i> <codeph>Fn</codeph>  </p> <p>i.e. a match occurs only if <codeph>ctrl</codeph>  <i>and</i> <codeph>shift</codeph> are pressed, and only if <codeph>Fn</codeph> is <i>not</i> pressed. Other modifier keys are ignored,
+i.e. it does not matter whether or not they are pressed. </p> <p>In
+C++ code, this is expressed as: </p> <codeblock id="GUID-E84542A2-932F-50C6-90B6-2AFC72CBE75F" xml:space="preserve">inline TBool MatchesMaskedValue(TInt aModifiers,const TMaskedModifiers &amp;aMaskedModifiers)
+    {
+    return (TBool)((aModifiers &amp; aMaskedModifiers.iMask) == aMaskedModifiers.iValue);
+    }</codeblock> <p>where <codeph>aModifiers</codeph> contains the
+modifier key combination to be tested. </p> </li>
+<li id="GUID-C147C929-63EE-593B-8CB7-689E5E6E60C2"><p>In principle,
+each node represents scancode-to-keycode mappings by associating one
+or more <i>pairs</i> (or range) of scancodes with corresponding blocks
+of keycodes. Each pair represents an inclusive and contiguous range
+of scancodes. </p> <p>Each pair (or range) of scancodes may be "discontiguous"
+from the next. </p> <p>The association is made through a table defined
+by the <xref href="GUID-35A21F70-F080-364D-8655-5E1781B378EB.dita"><apiname>SConvSubTable</apiname></xref> struct. This has: </p> <ul>
+<li id="GUID-9A023CDD-FADF-5641-8DD8-30C11F73E8BE"><p>a <xref href="GUID-DB86A3E5-D118-3A1D-8A76-BEC6111993E8.dita"><apiname>SScanCodeBlockList</apiname></xref> object that contains pointers to a number of <xref href="GUID-F18D6A71-122E-3202-927B-25DCEF1576A4.dita"><apiname>SScanCodeBlock</apiname></xref> objects, each of which contains the start and end values defining
+a range of scancodes. </p> </li>
+<li id="GUID-AC4820E0-F3D9-547A-9437-964D5A7FE540"><p>a pointer to
+a table containing the target keycodes. The target keycodes are arranged
+so that successive scancode pairs are associated with successive blocks
+of keycodes as the following diagram shows. </p> </li>
+</ul> <fig id="GUID-4B2FBB49-6CBD-5030-82D0-9B4DDF2D3DBF">
+<title>Target keycodes</title>
+<image href="GUID-DFADEB44-4D57-564F-ABDF-A3CCD38ACABC_d0e15086_href.png" placement="inline"/>
+</fig> <p>This means that successive scancodes, for example, from
+"A1" through to "B1" are represented by the successive keycodes "keycode
+for A1" through to "keycode for B1"; scancode "A2" is represented
+by "keycode for A2", which follows "keycode for B1" in the keycode
+table. </p> </li>
+<li id="GUID-68C8A342-A3D2-5975-82F1-F635E366F741"><p>To allow for
+possible reuse of keycode tables, a node can point to more than one <xref href="GUID-35A21F70-F080-364D-8655-5E1781B378EB.dita"><apiname>SConvSubTable</apiname></xref>. The following diagram shows an example of
+this: </p> <fig id="GUID-3F5514B5-86E6-52BE-A4C2-38882A1CEACA">
+<title>Reusing keycode tables</title>
+<image href="GUID-5FDAF564-6BE1-544A-B5C0-E0D6E25D82E7_d0e15107_href.png" placement="inline"/>
+</fig> </li>
+<li id="GUID-C6001149-460A-57D4-A9FE-BCB050B49791"><p>If no keycode
+can be found that matches the scancode, for a given modifier combination,
+then the algorithm returns the <xref href="GUID-76B2E62E-EC09-3CA9-8B2D-EBAC6BF1FFDB.dita"><apiname>EKeyNull</apiname></xref> keycode. </p> </li>
+</ol>
+<section id="GUID-A7823728-26DD-4C2F-A97F-91CC4D58B404"><title>See
+also</title> <p> <xref href="GUID-EB76FAF8-CD4B-5CB6-9F23-C852ED91866F.dita">Concepts</xref>  </p> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-D43AB2F5-32AE-540C-80D8-DE8B2072F1E6-master.png has changed
Binary file Adaptation/GUID-D43AB2F5-32AE-540C-80D8-DE8B2072F1E6_d0e10612_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D477EB1F-89CF-5836-BAA2-6D731D50D99F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D477EB1F-89CF-5836-BAA2-6D731D50D99F" xml:lang="en"><title>Reference</title><shortdesc>Summary of related documentation for the Sound Driver to which
+you can refer. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-BD24E6D9-6D8E-5EB5-BC3B-72D98D598B73"><title>API Reference</title> <p><b>Kernel
+Architecture </b> </p> <table id="GUID-212A4CA9-95B5-5824-8D8B-81BABF744A5E">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Item</b>  </p> </entry>
+<entry><p> <b>Header</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B0118EDD-2B08-353E-BE92-2DC75E5622B3.dita"><apiname>RSoundSc</apiname></xref>  </p> </entry>
+<entry><p> <filepath>d32soundsc.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita"><apiname>DSoundScPdd</apiname></xref>  </p> </entry>
+<entry><p> <filepath>soundsc.h</filepath>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-66111E83-BBEE-5623-B6E3-202E1DCBA201"><title>Engineering
+Specifications</title> <p>None published. </p> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-D5030CC5-1FC1-40F3-9D68-4A454B25C58B-master.png has changed
Binary file Adaptation/GUID-D5030CC5-1FC1-40F3-9D68-4A454B25C58B_d0e103563_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D520CBC3-FCAC-5A53-AE1A-E5254ABBC6A2.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D520CBC3-FCAC-5A53-AE1A-E5254ABBC6A2" xml:lang="en"><title>Symbian
+platform Memory Map</title><shortdesc>Reference for users of the debug monitor tool to the Symbian platform
+memory map for the moving memory model.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-A5845A0C-2C88-52BB-B7DE-210C2DE481B9"><title>Moving model</title> <fig id="GUID-5235CD78-B320-54DE-A349-D8564B2CCE32">
+<image href="GUID-8F78705E-CD82-5039-A7CB-7C963F7FBA83_d0e69457_href.png" placement="inline"/>
+</fig> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D5ED62EB-744D-42EB-B8CF-D5623BDA5B38.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,107 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D5ED62EB-744D-42EB-B8CF-D5623BDA5B38" xml:lang="en"><title>DMA Client Interface Guide</title><shortdesc>Explains how to use the interface between the DMA platform
+service and the Symbian platform.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The DMA client interface specifies the connection between the Symbian
+platform and the DMA platform service. This document describes how
+to open and close a DMA channel along with how to use the DMA client
+interface to perform a DMA transfer.</p>
+<section id="GUID-C917EAE6-BB3F-436A-BBF4-612FCCB837DB"><title>Interface
+classes</title><p>The classes that process a DMA transfer are:</p><table id="GUID-32AF43CB-8D2F-427A-984F-B577280905F0">
+<tgroup cols="2"><colspec colname="col1" colwidth="0.43*"/><colspec colname="col2" colwidth="1.57*"/>
+<thead>
+<row>
+<entry align="center" valign="top"><p><b>Name</b></p></entry>
+<entry align="center" valign="top"><p><b>Description</b></p></entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p><xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita"><apiname>DDmaRequest</apiname></xref></p></entry>
+<entry><p>This class is used to handle transfer requests. It carries
+out the configuration and initialization of the DMA transfer, along
+with tracking the state of the transfer to the client. Communication
+with the rest of the Symbian platform is carried out with the aid
+of a callback function.</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref></p></entry>
+<entry><p>This class is used to open and close DMA channels.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p>The steps involved in performing a DMA transfer are described
+below.</p></section>
+<section id="GUID-96B6E82F-85C1-4AB0-96EF-F2E7AA705973"><title>Using
+the DMA client interface</title><p>The sequence diagram of a DMA transfer
+is:</p><fig id="GUID-6A4644F2-62A7-4821-9C13-DFF13793CAE0">
+<title>The sequence diagram of a DMA transfer</title>
+<image href="GUID-DDD883A2-6784-4851-8E36-227EC564452A_d0e90311_href.png" placement="inline"/>
+</fig><p><b>Initialization</b></p><p>Before any DMA operations can
+be carried out, the data structure that holds the configuration of
+the DMA channel must be initialized. An example of this is shown below:</p><codeblock xml:space="preserve"> TDmaChannel::SCreateInfo info;
+ 
+ info.iCookie = iDMAChannelNumber;
+ info.iDesCount = 3;
+ info.iDfcPriority = 3;
+ info.iDfcQ = iDfcQue;</codeblock><p>The <codeph>iCookie</codeph> parameter
+is used to provide a unique ID for the channel. Its value is application
+specific.</p><p>The <codeph>iDesCount</codeph> element is used to
+specify how many descriptors this channel can use.</p><p>The <codeph>iDfcPriority</codeph> element is used to specify the priority of
+the DMA callback relative to all the other callbacks on its DFC queue.</p><p>The <codeph>iDfcQ</codeph> element is used to specify which DFC
+queue is to be used by this DMA channel.</p><p><b>Open a DMA channel</b></p><p>Next the DMA channel is opened and configured. An example
+of this is show below: </p><codeblock xml:space="preserve">r = TDmaChannel::Open(info, iDMAChannel);
+
+if (r)
+{
+      // [...] handle the error
+      return r;
+}</codeblock><p>The first parameter for the open method holds the
+channel configuration details. The second parameter is the DMA channel
+handle. In this example, if an error occurs during the open operation,
+then the error code is returned to the rest of the system and the
+transfer is aborted.</p><p>The first parameter contains the DMA channel
+configuration information. The second parameter points to the instance
+of the DMA channel class that is to be used. This class must be declared
+before this method call can be made.</p><p><b>Create a request object</b></p><p>The next task is to create a request object, specifying the
+channel it will be queued on and the callback when it completes. An
+example of this is shown below:</p><codeblock xml:space="preserve">new (iDMARequest) DDmaRequest(*iDMAChannel, DmaCallback, this);</codeblock><p>The above line creates a new instance of the DDmaRequest class
+which will be queued on the DMA channel specified in the first parameter.
+The callback function (<codeph>DmaCallback</codeph>) that will process
+the result of an operation is specified in the second parameter and
+is optional. The third parameter specifies the argument passed to
+the callback function.</p><p><b>Transfer</b></p><p>Once the DMA channel
+has been setup, the DMA transfer can be carried out. Executing a DMA
+transfer consists of two parts:</p><ol>
+<li id="GUID-FEBFEA0C-A6A3-4920-B62B-5F011F1FA571"><p>Specifying the
+details of the DMA transfer.</p></li>
+<li id="GUID-AD469BD7-94F4-4F79-91E0-2CB6CD988F97"><p>Placing the
+transfer onto the DMA transfer queue.</p></li>
+</ol><p>Once a successful transfer has been completed, the specified
+DMA callback function is executed.</p><p>An example of the use of
+the fragment method call is:</p><codeblock xml:space="preserve"> retval = iDMARequest-&gt;Fragment(EDmaSDMMC, aDest, aCount, KDmaMemDest | KDmaIncDest, 0);
+ 
+ if (retval) 
+{
+     // [...] handle the error
+     return retval;
+}</codeblock><p>In this code snippet, the details of the DMA transfer
+are specified. If an error is returned by the fragment method, then
+the error code is passed on to the rest of the system and the transfer does
+not take place. The first parameter specifies the data source. The
+second specified the destination of the data. The third specifies
+the number of bytes that are to be sent. The fourth parameter consists
+of flags. The final parameter specifies any DMA PSL specific settings
+(there are none in the example).</p><p>A code snippet that shows the
+DMA transfer request being placed onto the DMA queue is:</p><codeblock xml:space="preserve"> iDMARequest-&gt;Queue();</codeblock><p><b>Close a DMA channel</b></p><p>Finally, once the DMA functionality is no longer required, the
+DMA channel is closed. A code snippet that shows this is:</p><codeblock xml:space="preserve">iDMAChannel-&gt;Close();</codeblock><p>Where <codeph>iDMAChannel</codeph> is the instance of the DMA channel that was being used.</p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D5EE0A17-2246-4CB3-9CE5-538F1E01F8D4.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,55 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D5EE0A17-2246-4CB3-9CE5-538F1E01F8D4" xml:lang="en"><title>What is Adaptation?</title><shortdesc>Provides a brief overview of hardware adaptation .</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-66019FCA-913D-4BC1-B823-038A3CCB8602"><title>Adaptation</title><p>Adaptation is the process of adding a hardware or a platform service
+to the device, it includes:</p><ul>
+<li><p>the required hardware</p></li>
+<li><p>a list of device drivers to be written</p></li>
+<li><p>the list of required Platform services</p></li>
+<li><p>the process of porting the operating system to the hardware</p></li>
+<li><p>integration of peripherals possibly created by third parties</p></li>
+</ul><p>Base porting and device drivers involve platform specific
+implementation on hardware.</p></section>
+<section id="GUID-F6B4ED47-12F9-450D-AE96-930939382C7A"><title>The
+Adaptation Layer and Platform services</title><p>The adaptation layer
+interfaces between the operating system and hardware: it is a hardware
+abstraction layer extended with modular functionality. It is partitioned
+into platform services and client interfaces. The hardware manufacturers
+implement the platform services in platform-specific instructions.
+The device driver writers use the client interface in their code to
+control various hardware. </p><fig id="GUID-3C3C24BE-B6B9-4738-83A4-DF05C3CDC19C">
+<title>Adaptation Layer, Platform services and hardware</title>
+<image href="GUID-2C312536-2410-42D7-B976-F7CF99492DEA_d0e344_href.png" placement="inline"/>
+</fig><p>The purpose of Platform services:</p><ul>
+<li><p> to make porting easier,</p></li>
+<li><p> to enable hardware  vendors to supply standard solutions,
+and</p></li>
+<li><p> to create a common interface for use by chipset vendors, phone
+vendors and peripheral vendors.</p></li>
+</ul><p>The simplest Platform services are sets of APIs running in
+kernel space and corresponding to discrete items of hardware. Other
+Platform services form part of frameworks which may extend into user
+space and higher levels of the operating system. Some Platform services
+interact with other Platform services within the adaptation layer,
+forming a logical stack which may cross the boundary between adaptation
+layer and operating system at several points. A Platform service is
+not necessarily implemented on hardware: some are implemented wholly
+or partly as device specific software.</p><p>Implementers are provided
+with:</p><ul>
+<li><p>the APIs to be  implemented, with an explanation of the intended
+functionality</p></li>
+<li><p>information about the associated framework and stack if appropriate</p></li>
+<li><p>a statement of any associated standards and protocols</p></li>
+<li><p>information about the tools required</p></li>
+<li><p> tests to prove the implementation once it has been written</p></li>
+</ul>They are sometimes also given a reference implementation.</section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D683DBD8-15AA-5F2F-826C-B56CCE1DC06E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,51 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D683DBD8-15AA-5F2F-826C-B56CCE1DC06E" xml:lang="en"><title>Reference</title><shortdesc>Summary of related documentation for the Digitizer Driver to which
+you can refer</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-1D2B061C-CCD5-57BE-AB31-068FD3F4115E"><title>API Reference</title> <p><b>Kernel
+Architecture </b> </p> <table id="GUID-4E07BEF7-8FE5-5D72-A004-8F2B8C8ED3AD">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Item</b>  </p> </entry>
+<entry><p> <b>Header</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita"><apiname>DDigitiser</apiname></xref>  </p> </entry>
+<entry><p> <filepath>xyin.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-5FFA3299-D300-308C-B1AB-5716E9F895A2.dita"><apiname>TDigitizerCalibration</apiname></xref>  </p> </entry>
+<entry><p> <filepath>e32hal.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-86A737D5-0602-3DB3-9CFF-764C80A8D468.dita"><apiname>TDigitiserHalFunction</apiname></xref>  </p> </entry>
+<entry><p> <filepath>e32hal.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-992CAF48-98CE-392E-BE24-852E2ED6B9D6.dita"><apiname>TDigitiserInfoV01</apiname></xref>  </p> </entry>
+<entry><p> <filepath>e32hal.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-BF61C44A-EC94-3741-8611-696CD4C0BF78.dita"><apiname>TDigitiserInfoV02</apiname></xref>  </p> </entry>
+<entry><p> <filepath>e32hal.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-8B3280A2-318F-380C-B2A4-894C3C675868.dita"><apiname>UserHal</apiname></xref>  </p> </entry>
+<entry><p> <filepath>e32hal.h</filepath>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-8AA8A384-2822-596D-90CA-228B42283896"><title>Engineering
+Specifications</title> <p>None published. </p> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-D6861A7A-1845-52AF-BB09-4B97E6B8AA13-master.png has changed
Binary file Adaptation/GUID-D6861A7A-1845-52AF-BB09-4B97E6B8AA13_d0e10260_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D729BD58-D4FE-5D46-ACD4-F78B37BA833A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D729BD58-D4FE-5D46-ACD4-F78B37BA833A" xml:lang="en"><title>GNU
+Assembler Source Format</title><shortdesc>Describes the rules that you must follow if you use GNU assembler
+syntax.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The platform-specific source code can be written in GNU assembler
+syntax or ARM assembler syntax.</p>
+<p>The generic source and header files are all written using the ARM assembler
+syntax, as are the source files for the template and example ports. However
+the bootstrap can be built using the GNU assembler; in this case, source files
+are translated from ARM to GNU assembler syntax automatically. </p>
+<p>The rules that you must follow to use GNU assembler syntax in the platform-specific
+source are: </p>
+<ul>
+<li id="GUID-4D2E66B7-D3DE-5877-817B-316E16612AAC"><p>The first non-blank
+line of any GNU-syntax source or header file should start with an @ (the GNU
+comment delimiter); this acts as a directive to the translation tool that
+no translation is required. </p> </li>
+<li id="GUID-BDEE2BA7-5FD4-5BC0-B945-8E598388019C"><p>Files included from
+GNU source should be included with a <filepath>.ginc</filepath> extension
+instead of the normal <filepath>.inc</filepath> extension. However the file
+itself should have a <filepath>.inc</filepath> extension. </p> </li>
+</ul>
+<p>To enable the generic makefile to work correctly, assembler source files
+should always be given the extension <filepath>.s</filepath> and assembler
+include files <filepath>.inc</filepath>; this is independent of whether these
+are ARM or GNU syntax. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-D7D7615F-B67D-44D0-82DF-24853159A114.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,168 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-D7D7615F-B67D-44D0-82DF-24853159A114" xml:lang="en"><title>Baseport Template Client Interface Guide</title><shortdesc>Provides a basic framework consisting of base parts of
+the Symbian platform.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Baseport Template platform service provide an interface to
+the kernel-side client for hardware-specific functions (for example,
+GPIO, DMA, IIC, USB Client Controller) that are used by the kernel. </p>
+<section id="GUID-CEE49D22-800F-4906-9634-ED90D6326CD4">         
+   <title>Interface class</title>             <p>The client interface
+for the Baseport Template platform service is:<table id="GUID-04372BCC-FF57-454B-808A-6CE36F305FD1">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita"><apiname>TemplateAssp</apiname></xref></p></entry>
+<entry><p>Provides common peripheral control functions such as power,
+bootstrap, keymap, keyboard and sound that other extensions and device
+drivers can use</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></p><p>The Baseport Template interface provides the following
+functions.</p><table id="GUID-F62F1769-B473-4CD7-AFB8-B87EDED9473F">
+<tgroup cols="3"><colspec colname="col1"/><colspec colname="COLSPEC0" colwidth="1.00*"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">Function</entry>
+<entry valign="top">Return Type</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-D6F36994-1F14-38FA-8030-F958BEFA31B5"><apiname>TemplateAssp::Init1()</apiname></xref></p></entry>
+<entry><codeph>void</codeph></entry>
+<entry><p>Initialize the ASSP interrupt controller</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-3B629F63-8F31-32E9-9953-3D01F8A979BB"><apiname>TemplateAssp::Init3()</apiname></xref></p></entry>
+<entry><codeph>void</codeph></entry>
+<entry><p>Called in the context of the supervisor thread</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-D3897D91-4127-3A9C-B996-84AE19CE1227"><apiname>TemplateAssp::StartupReason()</apiname></xref></p></entry>
+<entry><codeph>TMachineStartupType</codeph></entry>
+<entry><p>Return the Startup reason of the Super Page (set up by Bootstrap)</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-69BD314C-DB6D-326C-9B6B-7ACA5D2D6109"><apiname>TemplateAssp::MsTickPeriod()</apiname></xref></p></entry>
+<entry><codeph>TInt</codeph></entry>
+<entry><p>Obtain the period of System Tick timer in microseconds</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-371B9277-7E59-3B52-B8FA-C83D02192F34"><apiname>TemplateAssp::SystemTimeInSecondsFrom2000(TInt&amp;
+aTime);</apiname></xref></p></entry>
+<entry><codeph>TInt</codeph></entry>
+<entry><p>Obtain System Time from the RTC</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-47B670EB-CD22-3CBE-A20C-5E5752207ED0"><apiname>TemplateAssp::SetSystemTimeInSecondsFrom2000(TInt
+aTime)</apiname></xref></p></entry>
+<entry><codeph>TInt</codeph></entry>
+<entry><p>Obtain Adjust the RTC with new System Time</p></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-10356DD9-911A-3213-964E-90ED73DEDBE0"><apiname>TemplateAssp::NanoWaitCalibration()</apiname></xref></p></entry>
+<entry><codeph>TUint32</codeph></entry>
+<entry><p>Obtain the time it takes to execute two processor instructions</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table>         </section>
+<section id="GUID-353FB844-F423-48C8-A992-4B0B509B6717"><title>Pure
+Virtual Functions for derivation by variant</title><p> These are the
+functions whose implementation are not provided in the class, but
+the behavior can be overridden within an inheriting class by a function
+with the same return type.</p><p><b>External interrupt handling functions</b> are used by second-level interrupt controllers at variant level.</p><table id="GUID-16FE0DE3-1096-47A0-A7FE-9989F73ABF6C">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">Functions</entry>
+<entry valign="top">Return Type</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-40F10C5C-912E-3433-B01E-9F4FC8448AF1"><apiname>TemplateAssp::InterruptBind(TInt anId, TIsr anIsr,
+TAny* aPtr)</apiname></xref></p></entry>
+<entry><codeph>TInt</codeph></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-27DBAA7C-CF52-3167-84ED-BB1BDA2160F9"><apiname>TemplateAssp::InterruptUnbind(TInt anId)</apiname></xref></p></entry>
+<entry><codeph>TInt</codeph></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-EA574990-A3F5-3127-9052-477AF80746B5"><apiname>TemplateAssp::InterruptEnable(TInt anId)</apiname></xref></p></entry>
+<entry><codeph>TInt</codeph></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-C9ED2A0E-6725-3230-AF82-83E3CE67931B"><apiname>TemplateAssp::InterruptDisable(TInt anId)</apiname></xref></p></entry>
+<entry><codeph>TInt</codeph></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-E180DE9E-7F38-3552-83C1-E0E99CC61C16"><apiname>TemplateAssp::InterruptClear(TInt anId)</apiname></xref></p></entry>
+<entry><codeph>TInt</codeph></entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><b>USB client controller functions</b> are the called by
+the USB PSL, and to be implemented by the variant .</p><table id="GUID-C68B5AA4-DCBA-4380-A317-0DF7DB24A2C7">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">Functions</entry>
+<entry valign="top">Return Type</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-C139AF42-D777-3E24-8C51-EE9713382984"><apiname>TemplateAssp::UsbClientConnectorDetectable()</apiname></xref></p></entry>
+<entry><codeph>TBool</codeph></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-4579D639-36EF-3F9B-B61F-0617737AEF6B"><apiname>TemplateAssp::UsbClientConnectorInserted()</apiname></xref></p></entry>
+<entry><codeph>TBool</codeph></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-7F3C5DE4-1271-3D01-8851-F98B2C65D902"><apiname>TemplateAssp::RegisterUsbClientConnectorCallback(TInt
+(*aCallback)(TAny*), TAny* aPtr)</apiname></xref></p></entry>
+<entry><codeph>TInt</codeph></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-F790857E-0ADD-3867-BC31-2465682F759F"><apiname>TemplateAssp::UnregisterUsbClientConnectorCallback()</apiname></xref></p></entry>
+<entry><codeph>void</codeph></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-D1145A00-6288-353B-B12B-FF975A34543C"><apiname>TemplateAssp::UsbSoftwareConnectable()</apiname></xref></p></entry>
+<entry><codeph>TBool</codeph></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-34F11331-62B8-3F1E-9C53-55A4727926AE"><apiname>TemplateAssp::UsbConnect()</apiname></xref></p></entry>
+<entry><codeph>TInt</codeph></entry>
+</row>
+<row>
+<entry><p><xref href="GUID-E893165C-0E62-3AC6-98BA-227E104B672E.dita#GUID-E893165C-0E62-3AC6-98BA-227E104B672E/GUID-5C7895A2-323D-34C5-BFAB-3FF470CB3503"><apiname>TemplateAssp::UsbDisconnect()</apiname></xref></p></entry>
+<entry><codeph>TInt</codeph></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+</conbody><related-links>
+<link href="GUID-57989FF8-5E8F-4C8A-9D38-169AFCA4C078.dita"><linktext>Baseport
+Template Implementation Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-D8911BE6-100D-588A-8E5C-A429A72AFCDA-master.png has changed
Binary file Adaptation/GUID-D8911BE6-100D-588A-8E5C-A429A72AFCDA_d0e19356_href.png has changed
Binary file Adaptation/GUID-D8A3C18B-A107-5557-B882-CD6CDD0F0F1D-master.png has changed
Binary file Adaptation/GUID-D8A3C18B-A107-5557-B882-CD6CDD0F0F1D_d0e76208_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-DA382265-232F-40F4-92ED-C90E6DE3D709.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,74 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-DA382265-232F-40F4-92ED-C90E6DE3D709" xml:lang="en"><title>Version</title><shortdesc>This document describes how to set the interface version used by
+an LDD or a PDD and how to check version compatibility.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>An LDD and a PDD each have a version number which helps to identify the
+interface. In order to communicate, an LDD and a PDD must have the same version
+number.</p>
+<section id="GUID-A0AC274C-E530-44C4-A955-582E294C3986">       <title>Version
+definition</title>       <p>Each LDD and PDD has their own version number.
+LDDs and PDDs must set their version numbers in their respective factory objects,
+using a <xref href="GUID-D82DEC7A-71C2-3004-BFC2-C82C009A2715.dita"><apiname>TVersion</apiname></xref> object. <codeph>TVersion</codeph> specifies
+a major number, a minor number and a build number. </p> <p>A version number
+defines the interface version supported by the LDD or PDD. It is used to check
+that an LDD and PDD are compatible. It is also checked against the version
+requested by a client when it opens a channel. </p> <p>The following shows
+how the example device drivers set their version numbers: </p> <codeblock id="GUID-0346530F-4560-5132-BD78-625C55F69840" xml:space="preserve">inline TVersion RExDriverChannel::VersionRequired()
+    {    
+    return (TVersion(EUartMajorVersionNumber,
+            EUartMinorVersionNumber,
+            EUartBuildVersionNumber));
+    }</codeblock> <codeblock id="GUID-C89697A9-B8D3-5BAC-8020-429483C5D492" xml:space="preserve">// LDD Factory object Constructor
+DExDriverLogicalDevice::DExDriverLogicalDevice ()
+    {
+    iVersion = RExDriverChannel::VersionRequired();
+    }</codeblock> <codeblock id="GUID-728B933E-6F42-599A-8C63-9C572EB6C54E" xml:space="preserve">// PDD Factory object Constructor
+DExH4PhysicalDevice::DExH4PhysicalDevice ()
+    {        
+    iVersion= RExDriverChannel::VersionRequired();
+    }</codeblock>     </section>
+<section id="GUID-7778CFE6-EFFC-45FD-A1CD-92EE21A35C14"><title>Version compatibility</title> <p>The
+Kernel provides the <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-A28757CC-B89B-3F63-AD39-9955FBE7533B"><apiname>Kern::QueryVersionSupported()</apiname></xref> API to
+enforce a consistent set of rules for checking version compatibility. It returns
+true if one of the following conditions is true: </p> <ul>
+<li id="GUID-5DE6B5DA-2823-546D-BB2D-0556D3AEEC52"><p>the major version of
+the client is less than the major version of the driver. </p> </li>
+<li id="GUID-54E77028-897E-53BE-BEAB-72ECD796EF63"><p>the major version of
+the client is equal to the major version of the driver, and the minor version
+of the client is less than or equal to the minor version of the driver. </p> </li>
+</ul> <p> <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita#GUID-A3CC1D95-4681-3349-A67C-F113A614041D/GUID-3DE558DF-16A3-39F9-87E3-F5600899A4D4"><apiname>DLogicalChannel::DoCreate()</apiname></xref> typically checks
+the client version against the driver using this API. </p> <codeblock id="GUID-2E1A3DC4-5A28-5CB7-A983-BDE461E4A861" xml:space="preserve">// Logical Channel Second stage constructor
+TInt DExDriverLogicalChannel::DoCreate(TInt /*aUnit*/, const TDesC8* 
+/*anInfo*/, const TVersion&amp; aVer)
+    {
+    ...
+    // Version check
+    if(!Kern::QueryVersionSupported(RExDriver::VersionRequired(),
+aVer))
+    return KErrNotSupported;
+    ...
+    }</codeblock> <p>When the device framework searches for a corresponding
+PDD factory object for an LDD, it calls <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita#GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930/GUID-70B6293C-9000-31D9-AE9E-441C9760B92E"><apiname>DPhysicalDevice::Validate()</apiname></xref> on
+each matching PDD factory object, passing the unit number and the optional
+extra information block. The first PDD to return <codeph>KErrNone</codeph> is
+accepted as the required PDD. </p> <p>The example PDD's <codeph>Validate()</codeph> implementation
+checks the version of the LDD against the PDD, using the <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-A28757CC-B89B-3F63-AD39-9955FBE7533B"><apiname>Kern::QueryVersionSupported()</apiname></xref> API: </p> <codeblock id="GUID-56F482C2-B312-58B6-8454-262A774A1B53" xml:space="preserve">// PDD: Validate
+TInt DExH4PhysicalDevice::Validate(TInt aUnit, const TDesC8* 
+/*aInfo*/, const TVersion&amp; aVer)    
+    {
+    ...
+    // Version check
+    if (!Kern::QueryVersionSupported(iVersion,aVer))    
+        return KErrNotSupported;
+    ...
+    }</codeblock></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-DA62FD4F-2E74-5B2F-B703-4A40DF5F01CA.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,70 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-DA62FD4F-2E74-5B2F-B703-4A40DF5F01CA" xml:lang="en"><title>MAKSYM
+Tool</title><shortdesc>MAKSYM is a command line tool that processes the log file generated
+when building a ROM image, and creates a text file that lists the address
+of every global and exported function in the ROM</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> <xref href="GUID-CC04A14B-A839-5613-820D-F1E65EB2DF7F.dita">Reference: tools:
+MAKSYM</xref> outlines the syntax of the command. </p>
+<p>If you know the address of the instruction which caused an exception, you
+can compare this address with the MAKSYM log to see which function this is
+in. You can narrow this down to the exact code within the function by using <codeph>ABLD
+LISTING</codeph> to get the assembler output from the compiler. </p>
+<p>The following example MAKSYM log is taken from an EKA1 build; however,
+the principle is the same for EKA2. </p>
+<codeblock id="GUID-D59F2E58-C39A-516B-8185-F4C8DBB9BE45" xml:space="preserve">From    \Epoc32\Release\Misa\UREL\ekern.exe
+
+50003040    0094    _E32Startup
+500030d4    002c    ImpDma::Init1(void)
+50003100    0004    ImpDma::Init3(void)
+50003104    0008    ImpDma::MaxBlockSize(void)
+</codeblock>
+<p>If, for example, the code address of the exception is at <codeph>0x500030dc</codeph>,
+then you can see from the log that this is in the <codeph>ImpDma::Init1()</codeph> function,
+at offset 8 from the start of the function. This function is in the file <filepath>...\e32\ekern\epoc\arm\sa1100\ka_dma.cpp</filepath>,
+so use<codeph> ABLD LISTING</codeph> to obtain the assembler: </p>
+<p><userinput>cd \e32</userinput> </p>
+<p><userinput>abld listing misa urel ekern ka_dma </userinput> </p>
+<p>Notice that you must specify the component that the file is part of, in
+this case <codeph>EKERN</codeph>, and that you do not put the <filepath>.cpp</filepath> extension
+on the source file name. If you do not specify a source file ABLD will create
+an assembler listing for every file in component <codeph>EKERN</codeph>. </p>
+<p>The listing file will be placed in the same directory as <codeph>ka_dma.cpp</codeph>,
+and will be called <codeph>ka_dma.lis</codeph>. If you look at this file you
+will see something like this: </p>
+<codeblock id="GUID-285B04C6-E2C4-5A62-A47B-C31F71231F57" xml:space="preserve">7                  Init1__6ImpDma:
+   8                      @ args = 0, pretend = 0, frame = 0
+   9                      @ frame_needed = 0, current_function_anonymous_args = 0
+  10                      @ I don't think this function clobbers lr
+  11 0000 18209FE5         ldr    r2, .L793
+  12 0004 0630A0E3         mov    r3, #6
+  13 0008 003082E5         str    r3, [r2, #0]
+  14 000c 10309FE5         ldr    r3, .L793+4
+  15 0010 10009FE5         ldr    r0, .L793+8
+  16 0014 000083E5         str    r0, [r3, #0]
+  17 0018 1810A0E3         mov    r1, #24
+  18 001c FEFFFFEA         b    FillZ__3MemPvi
+</codeblock>
+<p>Offset 8 is the first STR instruction. Comparing this with the C++ source: </p>
+<codeblock id="GUID-695798DA-4A00-5963-A3B8-F30D5D908FDA" xml:space="preserve">void ImpDma::Init1()
+//
+// Phase 1 initialisation of the Dma channels
+//
+    {
+    PP::DmaMaxChannels=KNumberOfDmaChannels;
+    PP::DmaChannelTable=(TDma **)(&amp;DmaChannels[0]);
+    Mem::FillZ(PP::DmaChannelTable,sizeof(TDma *)*KNumberOfDmaChannels);
+    }
+</codeblock>
+<p>The first store is to PP::DmaMaxChannels, so clearly there is a problem
+writing this memory. </p>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-DA7751A1-4EC5-5FBA-A42B-E254133A1D82-master.png has changed
Binary file Adaptation/GUID-DA7751A1-4EC5-5FBA-A42B-E254133A1D82_d0e76254_href.png has changed
Binary file Adaptation/GUID-DB0EDBC2-8204-59F3-9029-EBBCE04A9E3C-master.png has changed
Binary file Adaptation/GUID-DB0EDBC2-8204-59F3-9029-EBBCE04A9E3C_d0e9220_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-DB441DFF-0075-5122-A2EB-A6EF76375D71.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,842 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-DB441DFF-0075-5122-A2EB-A6EF76375D71" xml:lang="en"><title> APIs affected by the platsecprocessisolation keyword</title><shortdesc>Certain legacy APIs are insecure. Using the <codeph>platsecprocessisolation</codeph> keyword affects whether those APIs are allowed.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Each Symbian platform release may include APIs, which are insecure.
+These APIs are inherited from earlier versions of the OS, which are
+based on EKA1 kernel. You may choose to allow or not allow such APIs
+using the <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-B5EE7071-532B-591B-904B-93108A42D939">platsecprocessisolation</xref> Obey file keyword. The following is
+a list of APIs, which are affected by <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-B5EE7071-532B-591B-904B-93108A42D939">platsecprocessisolation</xref> keyword. </p>
+<p> <b>Note</b>: The list also states whether the API can be hidden
+at build time by defining the <codeph>__SECURE_API__</codeph> macro. </p>
+<table id="GUID-E864D522-8783-5858-BA8F-FBD36DCB85EC">
+<tgroup cols="3"><colspec colname="col0"/><colspec colname="col1"/>
+<colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p> <b>API</b>  </p> </entry>
+<entry><p> <b>Restriction</b>  </p> </entry>
+<entry><p> <b>Hidden by __SECURE_API__ macro ?</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::Kill(TInt aReason)</codeph>  </p> </entry>
+<entry><p>Not allowed on threads in a different process. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::Terminate(TInt aReason)</codeph>  </p> </entry>
+<entry><p>Not allowed on threads in a different proces. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::Panic(const TDesC&amp; aCategory,TInt
+            aReason)</codeph>  </p> </entry>
+<entry><p>Not allowed on threads in a different process. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::Suspend()</codeph>  </p> </entry>
+<entry><p>Not allowed on threads in a different process. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::Resume()</codeph>  </p> </entry>
+<entry><p>Not allowed on threads in a different process. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::SetPriority(TThreadPriority aPriority)</codeph>  </p> </entry>
+<entry><p>Not allowed on threads in a different process. (Unless the
+process has enabled PriorityControl then it's priority can be changed
+between Foreground and Background.) </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::RequestComplete(TRequestStatus*&amp; aStatus,
+TInt             aReason)</codeph>  </p> </entry>
+<entry><p>Not allowed on threads in a different process. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::Heap()</codeph>  </p> </entry>
+<entry><p>Removed. Not allowed on threads in a different process. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::SetProcessPriority(TProcessPriority  
+          aPriority)</codeph>  </p> </entry>
+<entry><p>Deprecated. Not allowed on threads in a different process. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::Protected()</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::SetProtected(TBool aState)</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-94182E2E-2CDD-3204-B2C1-18D722A14400"><apiname>User::SetCritical()</apiname></xref> instead. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::System()</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-518F09CB-9E69-301D-B181-6BDEAF7D3F77"><apiname>User::Critical()</apiname></xref> instead. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::SetSystem(TBool aState)</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-94182E2E-2CDD-3204-B2C1-18D722A14400"><apiname>User::SetCritical()</apiname></xref> instead.
+Not allowed on threads in a different process. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::GetDesLength(const TAny *aPtr)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::GetDesMaxLength(const TAny *aPtr)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::ReadL(const TAny* aPtr, TDes8&amp; aBuf,
+TInt             anOffset)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::ReadL(const TAny* aPtr, TDes16&amp; aBuf,
+TInt             anOffset)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::WriteL(const TAny* aPtr, const TDesC8&amp;
+aBuf,             TInt anOffset)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::WriteL(const TAny* aPtr, const TDesC16&amp;
+aBuf,             TInt anOffset)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::Rename(const TDesC&amp; aName)</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-7B587954-D211-328B-8868-5196C0ADE5D6"><apiname>User::RenameThread()</apiname></xref> instead.
+Not allowed on threads in a different process </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::ExceptionHandler()</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-E11E87FD-AFA4-353F-887B-EF36154E4B4E"><apiname>User::ExceptionHandler()</apiname></xref> instead. Can only be called to get the handler for the current thread. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::SetExceptionHandler(TExceptionHandler
+            aHandler,TUint32 aMask)</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-FDB3FF0D-705D-3EFE-9666-F26F7E390D54"><apiname>User::SetExceptionHandler()</apiname></xref> instead. Can only be called to set the handler for the current thread. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::ModifyExceptionMask(TUint32 aClearMask,
+TUint32             aSetMask)</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-77B2CCE3-B8FB-331A-9E61-15B2040CEC70"><apiname>User::ModifyExceptionMask()</apiname></xref> instead. Can only be called to modify the exception mask for the
+current thread. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::RaiseException(TExcType aType) </codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-6AB971F1-EE72-38E9-AA4A-9E0D8FACD4FE"><apiname>User::RaiseException()</apiname></xref> instead.
+Can only be called to raise an exception on the current thread. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::IsExceptionHandled(TExcType aType) </codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-3016380F-1101-395E-AEC8-1A1BA8DF3914"><apiname>User::IsExceptionHandled()</apiname></xref> instead. Can only be called to query the current thread. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::Create(const TDesC&amp; aName,TThreadFunction
+            aFunction,TInt aStackSize,TAny* aPtr,RLibrary* aLibrary,RHeap*
+aHeap, TInt             aHeapMinSize,TInt aHeapMaxSize,TOwnerType
+aType)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::Kill(TInt aReason)</codeph>  </p> </entry>
+<entry><p>Unless PowerMgmt capabilility is held this can only allowed
+to be called by the process itself, or by the process which created
+it (if it has not yet been resumed). </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::Terminate(TInt aReason)</codeph>  </p> </entry>
+<entry><p>Unless PowerMgmt capabilility is held this can only allowed
+to be called by the process itself or by the process which created
+it (if it has not yet been resumed). </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::Panic(const TDesC&amp; aCategory,TInt
+            aReason)</codeph>  </p> </entry>
+<entry><p>Unless PowerMgmt capabilility is held this can only allowed
+to be called by the process itself or by the process which created
+it (if it has not yet been resumed). </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::SetType(const TUidType&amp; aType) </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::Resume() </codeph>  </p> </entry>
+<entry><p>Can only be called by the process which created the process
+to be resumed. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::CommandLineLength()</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-6791564A-717D-3FD7-873D-BAD51DD98E4F"><apiname>User::CommandLineLength()</apiname></xref> instead. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::CommandLine(TDes&amp; aCommand)S</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-26212880-9DD8-3D5A-BEA9-AD79D72F6224"><apiname>User::CommandLine()</apiname></xref> instead. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::SetPriority(TProcessPriority aPriority)</codeph>  </p> </entry>
+<entry><p>Can only be called by a process to change it's own priority,
+or by the process which created the process having it's priority changed
+if it hasn't yet been resumed. Iff a process has enabled PriorityControl
+then it's priority can be changed between Foreground and Background. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::Protected()</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-59C2CE5A-75F9-3D36-B801-2EB6AB08C77F"><apiname>User::ProcessCritical()</apiname></xref> instead. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::SetProtected(TBool aState)</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-E2FD7D21-83EE-3EB5-8516-5ABCE7976853"><apiname>User::ProcessSetCritical()</apiname></xref> instead. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::System()</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-59C2CE5A-75F9-3D36-B801-2EB6AB08C77F"><apiname>User::ProcessCritical()</apiname></xref> instead. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::SetSystem(TBool aState)</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-E2FD7D21-83EE-3EB5-8516-5ABCE7976853"><apiname>User::ProcessSetCritical()</apiname></xref> instead. Can only be used on the current process. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::SetJustInTime(TBool aState)</codeph>  </p> </entry>
+<entry><p>Can only be called by a process to change it's own JustInTime
+state or by the process which created the process having it's JustInTime
+state changed if it hasn't yet been resumed. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::Owner(RProcess&amp; aOwner)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::SetOwner(const RProcess&amp; aProcess) </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::Rename(const TDesC&amp; aName)</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-F2781607-FD9A-3CCA-BB0B-3ADA6C993E33"><apiname>User::RenameProcess()</apiname></xref> instead.
+Only allowed for a process renaming itself. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMessagePtr2::Read(TInt aParam,TDes8&amp; aDes,TInt
+            aOffset)O</codeph>  </p> </entry>
+<entry><p>The client descriptor refered to by <codeph>aParam</codeph> must be a <xref href="GUID-FB97E0A3-352A-316F-97C6-69E4741A8120.dita"><apiname>TDesC8</apiname></xref> (not a <codeph>TDesC16</codeph>). Failure is indicated by a return code of <codeph>KErrBadDescriptor</codeph>. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMessagePtr2::Read(TInt aParam,TDes16&amp; aDes,TInt
+            aOffset)</codeph>  </p> </entry>
+<entry><p>The client descriptor refered to by <codeph>aParam</codeph> must be a <codeph>TDesC16</codeph> (not a <xref href="GUID-FB97E0A3-352A-316F-97C6-69E4741A8120.dita"><apiname>TDesC8</apiname></xref>). Failure is indicated by a return code of <codeph>KErrBadDescriptor</codeph>. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMessagePtr2::Write(TInt aParam,const TDesC8&amp;
+aDes,TInt             aOffset)</codeph>  </p> </entry>
+<entry><p>The client descriptor refered to by <codeph>aParam</codeph> must be a <xref href="GUID-445B19E5-E2EE-32E2-8D6C-C7D6A9B3C507.dita"><apiname>TDes8</apiname></xref> (not a <codeph>TDes16</codeph>). Failure is indicated by a return code of <codeph>KErrBadDescriptor</codeph>. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMessagePtr2::Write(TInt aParam,const TDesC16&amp;
+aDes,TInt             aOffset)</codeph>  </p> </entry>
+<entry><p>The client descriptor refered to by <codeph>aParam</codeph> must be a <codeph>TDes16</codeph> (not a <xref href="GUID-445B19E5-E2EE-32E2-8D6C-C7D6A9B3C507.dita"><apiname>TDes8</apiname></xref>). Failure is indicated by a return code of <codeph>KErrBadDescriptor</codeph>. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMessagePtr2::SetProcessPriority(TProcessPriority
+            aPriority)</codeph>  </p> </entry>
+<entry><p>Client must have enabled priority control with <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-4A8EA8E2-9493-3CCC-BFAA-7EA10D2216DB"><apiname>User::SetPriorityControl()</apiname></xref>. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMessage::ReadL(const TAny* aPtr,TDes8&amp; aDes) </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMessage::ReadL(const TAny* aPtr,TDes8&amp; aDes,TInt
+            anOffset)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMessage::ReadL(const TAny* aPtr,TDes16&amp; aDes)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMessage::ReadL(const TAny* aPtr,TDes16&amp; aDes,TInt
+            anOffset)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMessage::WriteL(const TAny* aPtr,const TDesC8&amp;
+            aDes)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMessage::WriteL(const TAny* aPtr,const TDesC8&amp;
+aDes,TInt             anOffset)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMessage::WriteL(const TAny* aPtr,const TDesC16&amp;
+            aDes)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMessage::WriteL(const TAny* aPtr,const TDesC16&amp;
+            aDes,TInt anOffset)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMessage::RMessage(const RMessagePtr2&amp; aPtr) </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMessage (all other methods)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>TFindChunk::Next(TFullName&amp; aResult)</codeph>  </p> </entry>
+<entry><p>Can't find objects without a name. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>TFindLogicalDevice::Next(TFullName&amp; aResult) </codeph>  </p> </entry>
+<entry><p>Can't find objects without a name. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>TFindPhysicalDevice::Next(TFullName&amp; aResult) </codeph>  </p> </entry>
+<entry><p>Can't find objects without a name. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>TFindLibrary::Next(TFullName&amp; aResult)</codeph>  </p> </entry>
+<entry><p>Can't find objects without a name </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>TFindServer::Next(TFullName&amp; aResult)</codeph>  </p> </entry>
+<entry><p>Can't find objects without a name. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>TFindMutex::Next(TFullName&amp; aResult)</codeph>  </p> </entry>
+<entry><p>Can't find objects without a name. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>TFindProcess::Next(TFullName&amp; aResult)</codeph>  </p> </entry>
+<entry><p>Can't find objects without a name. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>TFindSemaphore::Next(TFullName&amp; aResult) </codeph>  </p> </entry>
+<entry><p>Can't find objects without a name. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>TFindThread::Next(TFullName&amp; aResult)</codeph>  </p> </entry>
+<entry><p>Can't find objects without a name. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RChunk::OpenGlobal(const TDesC&amp; aName,TBool
+            isReadOnly,TOwnerType aType)</codeph>  </p> </entry>
+<entry><p>Can't open objects without a name or objects that are not
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RDevice::Open(const TDesC&amp; aName,TOwnerType
+aType)</codeph> </p> </entry>
+<entry><p>Can't open objects without a name or objects that are not
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMutex::OpenGlobal(const TDesC&amp; aName,TOwnerType
+            aType)</codeph>  </p> </entry>
+<entry><p>Can't open objects without a name or objects that are not
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RCondVar::OpenGlobal(const TDesC&amp; aName, TOwnerType
+            aType)</codeph>  </p> </entry>
+<entry><p>Can't open objects without a name or objects that are not
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RSemaphore::OpenGlobal(const TDesC&amp; aName,TOwnerType
+            aType)</codeph>  </p> </entry>
+<entry><p>Can't open objects without a name or objects that are not
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::Open(const TDesC&amp; aName,TOwnerType
+            aType)</codeph>  </p> </entry>
+<entry><p>Can't open objects without a name or objects that are not
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::Open(const TDesC&amp; aName,TOwnerType
+aType)             </codeph>  </p> </entry>
+<entry><p>Can't open objects without a name or objects that are not
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMsgQueueBase::OpenGlobal(const TDesC&amp; aName,
+TOwnerType             aType)</codeph>  </p> </entry>
+<entry><p>Can't open objects without a name or objects that are not
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RChunk::Duplicate(const RThread&amp; aSrc,TOwnerType
+            aType=EOwnerProcess)</codeph>  </p> </entry>
+<entry><p>If the handle being duplicated belongs to a different process
+then it can't be duplicated if the object doesn't have a name or isn't
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RDevice::Duplicate(const RThread&amp; aSrc,TOwnerType
+            aType=EOwnerProcess)</codeph>  </p> </entry>
+<entry><p>If the handle being duplicated belongs to a different process
+then it can't be duplicated if the object doesn't have a name or isn't
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMutex::Duplicate(const RThread&amp; aSrc,TOwnerType
+            aType=EOwnerProcess)</codeph>  </p> </entry>
+<entry><p>If the handle being duplicated belongs to a different process
+then it can't be duplicated if the object doesn't have a name or isn't
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RCondVar::Duplicate(const RThread&amp; aSrc,TOwnerType
+            aType=EOwnerProcess)</codeph>  </p> </entry>
+<entry><p>If the handle being duplicated belongs to a different process
+then it can't be duplicated if the object doesn't have a name or isn't
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RSemaphore::Duplicate(const RThread&amp; aSrc,TOwnerType
+            aType=EOwnerProcess)</codeph>  </p> </entry>
+<entry><p>If the handle being duplicated belongs to a different process
+then it can't be duplicated if the object doesn't have a name or isn't
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::Duplicate(const RThread&amp; aSrc,TOwnerType
+            aType=EOwnerProcess)</codeph>  </p> </entry>
+<entry><p>If the handle being duplicated belongs to a different process
+then it can't be duplicated if the object doesn't have a name or isn't
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::Duplicate(const RThread&amp; aSrc,TOwnerType
+            aType=EOwnerProcess)</codeph>  </p> </entry>
+<entry><p>If the handle being duplicated belongs to a different process
+then it can't be duplicated if the object doesn't have a name or isn't
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMsgQueueBase::Duplicate(const RThread&amp; aSrc,TOwnerType
+            aType=EOwnerProcess)</codeph>  </p> </entry>
+<entry><p>If the handle being duplicated belongs to a different process
+then it can't be duplicated if the object doesn't have a name or isn't
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::Open(TThreadId aID, TOwnerType       
+     aType=EOwnerProcess)</codeph>  </p> </entry>
+<entry><p>Can't open objects without a name. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RHandleBase::Open(const TFindHandleBase&amp;  
+          aFindHandle,TOwnerType aType)</codeph>  </p> </entry>
+<entry><p>Can't open objects without a name or those which aren't
+global. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>UserSvr::CaptureEventHook()</codeph>  </p> </entry>
+<entry><p>Can only be called by the Window Server process. </p> </entry>
+<entry><p>No </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>class CSharableSession</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>class CSession</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>class CServer </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>class RServer</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RSessionBase::Share(TAttachMode             aAttachMode=EExplicitAttach)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RSessionBase::Attach()</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RSessionBase::Send(TInt aFunction,TAny* aPtr) </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RSessionBase::SendReceive(TInt aFunction,TAny*
+            aPtr,TRequestStatus&amp; aStatus)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RSessionBase::SendReceive(TInt aFunction,TAny*
+aPtr)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RSubSessionBase::CreateSubSession(RSessionBase&amp;
+            aSession,TInt aFunction,const TAny* aPtr)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RSubSessionBase::Send(TInt aFunction,const TAny*
+aPtr)</codeph> </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RSubSessionBase::SendReceive(TInt aFunction,const
+TAny*             aPtr,TRequestStatus&amp; aStatus)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RSubSessionBase::SendReceive(TInt aFunction,const
+TAny*             aPtr)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>UserSvr::DllGlobalAlloc(TInt aHandle,TInt aSize) </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>UserSvr::DllGlobalAllocated(TInt aHandle) </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>UserSvr::DllGlobalRead(TInt aHandle,TInt aPos,TInt
+            aLength,TDes8&amp; aDes)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>UserSvr::DllGlobalWrite(TInt aHandle,TInt aPos,const
+            TDesC8&amp; aDes)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>Dll::GlobalAlloc(TInt aSize)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>Dll::GlobalAllocated()</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>Dll::GlobalRead(TInt aPos, TInt aLength, TDes8&amp;
+            aDes)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>Dll::GlobalWrite(TInt aPos,const TDesC8&amp; aDes) </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>TBusLocalDrive::Lock(TMediaPassword&amp; aOldPassword,
+            TMediaPassword&amp; aNewPassword, TBool aStorePassword)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>class CSecurityEncryptBase</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>class CSecurityDecryptBase</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>class CSecurityBase </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>class CBoundedSecurityBase</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>class Security</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RBusLogicalChannel::DoCreate(const TDesC&amp; aDevice,const
+            TVersion&amp; aVer,const TDesC* aChan,TInt aUnit,const
+TDesC* aDriver,const             TDesC8* anInfo,TOwnerType aType=EOwnerProcess)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RHeap::Adjust(TAny* aCell,TInt anOffset,TInt aDelta)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RHeap::AdjustL(TAny* aCell,TInt anOffset,TInt aDelta)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RHeap::FreeAll()</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>class THeapWalk</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>enum TDllReason </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>class RDebug </codeph>  </p> </entry>
+<entry><p>) Removed. (Apart from Printf functions </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>class TFindLogicalChannel</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>Rdevice::IsAvailable(TInt aUnit, const TDesC* 
+           aPhysicalDevice, const TDesC16* anInfo)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RLibrary::EntryPoint()</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RLibrary::DllRefTable()</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RThread::GetRamSizes(TInt&amp; aHeapSize,TInt&amp;
+            aStackSize)</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-B0E661BC-4058-3256-B9C3-5A4FD52F6DE5.dita#GUID-B0E661BC-4058-3256-B9C3-5A4FD52F6DE5/GUID-699F8282-62EF-3F13-85DC-5C0F7910A43D"><apiname>RThread::StackInfo()</apiname></xref> instead. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RProcess::GetRamSizes(TInt&amp; aCodeSize, TInt&amp;
+            aConstDataSize, TInt&amp; anInitialisedDataSize, TInt&amp;
+            anUninitialisedDataSize)</codeph>  </p> </entry>
+<entry><p>Removed. Use <xref href="GUID-B0E661BC-4058-3256-B9C3-5A4FD52F6DE5.dita#GUID-B0E661BC-4058-3256-B9C3-5A4FD52F6DE5/GUID-7E02F11A-8E57-36BB-802B-2CF31BC707B2"><apiname>RThread::GetMemoryInfo()</apiname></xref> instead. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>class TNotifyInfo</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>class Password</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>User::Adjust(TAny* aCell,TInt aOffset,TInt aDelta)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>User::AdjustL(TAny* aCell,TInt aOffset,TInt aDelta)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>User::__DbgMarkStart(RHeap::TDbgHeapType aHeapType)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>User::__DbgMarkCheck(RHeap::TDbgHeapType aHeapType,TBool
+            aCountAll,TInt aCount,const TDesC8&amp; aFileName,TInt
+aLineNum)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>User::__DbgMarkEnd(RHeap::TDbgHeapType aHeapType,TInt
+            aCount)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>User::__DbgSetAllocFail(RHeap::TDbgHeapType   
+         aHeapType,RHeap::TAllocFail aType,TInt aRate)</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>UserSvr::InitRegisterCallback(TCallBack, TInt) </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>UserSvr::ChangeLocale(RLibrary aLibrary) </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>UserSvr::DllInitialiseData(TInt aHandle) </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>UserSvr::DllFreeData(TInt aHandle) </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>UserSvr::WsRegisterThread(TThreadFunction) </codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>UserSvr::ServerStarted()</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RMutex::Count()</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>RSemaphore::Count()</codeph>  </p> </entry>
+<entry><p>Removed. </p> </entry>
+<entry><p>Yes </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table></conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-DB55C1A0-2901-4661-B6B1-3B61BF6FF4FA.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,129 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-DB55C1A0-2901-4661-B6B1-3B61BF6FF4FA" xml:lang="en"><title>Register Access Client Interface Guide</title><shortdesc>Explains how to use the Register Access client interface
+functions. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Register Access client interface is intended for use in writing
+device drivers. Writing device drivers involves frequent access to
+hardware registers by reading, writing and modifying them. </p>
+<section id="GUID-7107B7C2-04E3-4876-892B-20C3F9F12F85"><title>Interface
+class</title>             <p>The client interface for the Register
+Access platform services is:</p><table id="GUID-A29A52B7-14C5-40F3-A73B-284B0D730965">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry>Class</entry>
+<entry>Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita"><apiname>AsspRegister</apiname></xref></entry>
+<entry>Provides read, write and modify functions to access hardware
+registers of different widths.</entry>
+</row>
+</tbody>
+</tgroup>
+</table>         </section>
+<section id="GUID-E1D195A0-715F-5961-A67C-A2536D68DAE3"><title>Interface
+functions</title> <p>The Register Access client interface provides
+the following functions:</p><table id="GUID-12019299-2FEB-4F6B-8217-D4AD085B12BB">
+<tgroup cols="3"><colspec colname="col1"/><colspec colname="col2"/>
+<colspec colname="col3"/>
+<thead>
+<row>
+<entry>Function</entry>
+<entry>Return Type</entry>
+<entry>Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-A47E7A93-8180-38BA-8FAD-27ADA0E86EF7"><apiname>AsspRegister::Read8(TLinAddr aAddr)</apiname></xref></entry>
+<entry>TUint8</entry>
+<entry>Return the contents of an 8-bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-41AA4058-4528-3AB7-9084-AA6053AF0656"><apiname>AsspRegister::Read16(TLinAddr aAddr)</apiname></xref></entry>
+<entry>TUint16</entry>
+<entry>Return the contents of a 16-bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-E637527E-537A-367D-91C2-A3BB3AA0A587"><apiname>AsspRegister::Read32(TLinAddr aAddr)</apiname></xref></entry>
+<entry>TUint32</entry>
+<entry>Return the contents of a 32-bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-05FADA8D-5B77-39C6-A939-5EB1B209DD53"><apiname>AsspRegister::Read64(TLinAddr aAddr)</apiname></xref></entry>
+<entry>TUint64</entry>
+<entry>Return the contents of a 64-bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-CB85C4D4-3652-311E-808A-048A43F49F3E"><apiname>AsspRegister::Write8(TLinAddr aAddr, TUint8 aValue)</apiname></xref></entry>
+<entry>void</entry>
+<entry>Store a new value in an 8-bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-C20B9119-AAC8-354B-902A-B4349AEFC00E"><apiname>AsspRegister::Write16(TLinAddr aAddr, TUint16 aValue)</apiname></xref></entry>
+<entry>void</entry>
+<entry>Store a new value in a 16-bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-E18C1674-47EA-3B70-9BEE-55302D58F83B"><apiname>AsspRegister::Write32(TLinAddr aAddr, TUint32 aValue)</apiname></xref></entry>
+<entry>void</entry>
+<entry>Store a new value in a 32-bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-99D3233D-8F1C-3A65-BC1F-F10998728EB8"><apiname>AsspRegister::Write64(TLinAddr aAddr, TUint64 aValue)</apiname></xref></entry>
+<entry>void</entry>
+<entry>Store a new value in a 64-bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-3E66E373-E7DB-3F59-B6B1-3577AAD9FBF0"><apiname>AsspRegister::Modify8(TLinAddr aAddr, TUint8 aClearMask,
+TUint8 aSetMask)</apiname></xref></entry>
+<entry>void</entry>
+<entry>Modify the contents of an 8-bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-9A6FF0D8-1136-3188-8D85-43EF8919FA7C"><apiname>AsspRegister::Modify16(TLinAddr aAddr, TUint16 aClearMask,
+TUint16 aSetMask)</apiname></xref></entry>
+<entry>void</entry>
+<entry>Modify the contents of a 16-bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-035D2133-037A-36C5-B47C-A6FD00FEE3BA"><apiname>AsspRegister::Modify32(TLinAddr aAddr, TUint32 aClearMask,
+TUint32 aSetMask)</apiname></xref></entry>
+<entry>void</entry>
+<entry>Modify the contents of a 32-bit register.</entry>
+</row>
+<row>
+<entry><xref href="GUID-66BB033A-3386-3913-9A25-EF3867D42C2C.dita#GUID-66BB033A-3386-3913-9A25-EF3867D42C2C/GUID-7127519C-305D-3727-898F-860023CE586A"><apiname>AsspRegister::Modify64(TLinAddr aAddr, TUint64 aClearMask,
+TUint64 aSetMask)</apiname></xref></entry>
+<entry>void</entry>
+<entry>Modify the contents of a 64-bit register.</entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>All these functions can be called in any context. </p> <p>The address of a particular register on a particular platform
+is typically expressed as a base address and an offset: this is what
+you pass to the <codeph>aAddr</codeph> argument of these functions
+as a <codeph>TLinAddr</codeph>. </p> <p>The write functions take an
+unsigned integer (<codeph>TUint8</codeph>, <codeph>TUint16</codeph>, <codeph>TUint32</codeph> or <codeph>TUint64</codeph>) as the value
+of the parameter <codeph>aValue</codeph>.</p> <p>The modify functions
+take two unsigned integers (<codeph>TUint8</codeph>, <codeph>TUint16</codeph>, <codeph>TUint32</codeph> or <codeph>TUint64</codeph>) as arguments.
+Both the parameters, <codeph>aClearMask</codeph> and <codeph>aSetMask</codeph>, are bitmasks. The <codeph>aClearMask</codeph> argument clears the
+bits specified and the <codeph>aSetMask</codeph> sets the bits specified. </p> <b>Addressing a register</b><p>The following code reads the current
+value of a hardware register identified by a base address <codeph>iBaseAddr</codeph> plus an offset <codeph>KHoPciStatus</codeph>. </p><codeblock id="GUID-6308D594-B74D-50EE-A3EB-D8739371E46B" xml:space="preserve">TUint status=AsspRegister::Read16(iBaseAddr+KHoPciStatus);</codeblock><b>Modifying a register</b><p>The following code clears the bits
+specified by the bitmask <codeph>KHtPciStatus_ParityError</codeph> and sets the bits specified by the bitmask <codeph>NULL</codeph> (that is so say, none in this case). </p><codeblock id="GUID-F000597B-1B52-5C3F-B61E-6B5B88D859C7" xml:space="preserve">AsspRegister::Modify16(baseAddr+KHoPciStatus,KHtPciStatus_ParityError,NULL);</codeblock></section>
+</conbody><related-links>
+<link href="GUID-3722B946-07CF-4AEA-B228-E50642D6B5BE.dita"><linktext>Register
+Access Implementation Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-DBEAD516-5DD4-5E33-B6DA-657C1AE60C4B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,166 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-DBEAD516-5DD4-5E33-B6DA-657C1AE60C4B" xml:lang="en"><title>Dynamic
+Behaviour</title><shortdesc>Describes the dynamic behaviour of the Digitizer Driver. The description
+shows the use of the template port. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The design assumes that interrupts are generated by pen-down events; however,
+there is no difficulty in adjusting your implementation to deal with interrupts
+generated by pen-up events. </p>
+<p>The heart of the design is a DFC that reads digitizer data samples when
+the pen goes down, and then samples the digitizer at regular intervals until
+the pen goes up. These samples are accumulated in a buffer in the platform
+independent layer. When enough samples have been gathered, the platform independent
+layer averages them, processes them, and issues pen movement events. </p>
+<table id="GUID-324D657A-DBA8-5862-BC0D-04F02CE2A9D4">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>In the template port, the behaviour of the platform specific layer
+is based on three states: </p> </entry>
+<entry><p>The template port represents these three states using the enum values
+of the enum <codeph>TSate,</codeph> defined within the scope of the <codeph>DTemplateDigitiser</codeph> class
+(derived from <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita"><apiname>DDigitiser</apiname></xref>). The enum values are: </p> </entry>
+</row>
+<row>
+<entry><p>"power up" </p> </entry>
+<entry><p> <codeph> E_HW_PowerUp</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p>"collect sample" </p> </entry>
+<entry><p> <codeph>E_HW_CollectSample</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p>"pen up debounce" </p> </entry>
+<entry><p> <codeph>E_HW_PenUpDebounce</codeph>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table>
+<section id="GUID-7860EA0B-CE04-4D32-B813-9D23274999AD"><title>State diagram</title> <p>The flow of control through the digitizer
+is described by this state diagram. The notes following relate to this state
+diagram on the left-hand side. </p> <p>The diagram on the right-hand side
+shows, in a simplified form, the flow of control. The numbers correspond to
+the state diagram numbers. Calls into the platform independent layer are shown
+in green boxes; important functions are shown in purple boxes. </p> <table id="GUID-23381681-744E-54DA-AAA2-5F30AD486783">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><fig id="GUID-C7D88A4C-B5A0-5A1B-8710-188DC398B6CB">
+<image href="GUID-F127644A-6072-52CA-9B17-E9DDEA784BE0_d0e8997_href.png" placement="inline"/>
+</fig> </entry>
+<entry><fig id="GUID-F244E871-48C7-548E-AF69-43D4265F9C48">
+<image href="GUID-9173EEBA-CC84-51D9-9C8D-A75F7F494D62_d0e9004_href.png" placement="inline"/>
+</fig> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <ol id="GUID-B0BF0EE6-5059-5C43-BEE7-C500751CEC36">
+<li id="GUID-5E21DADA-B4C0-5F90-B7C7-DF44C4FAA0CC"><p>If the pen is down at
+power on, i.e. when in the <i>power up</i> state, the device keeps sampling
+the digitiser at regular intervals until the pen is up. In the template port,
+the interval is defined by the constant <xref href="GUID-3574BE12-9DA9-573D-8545-3B073005A139.dita#GUID-3574BE12-9DA9-573D-8545-3B073005A139/GUID-EDA72AF2-460E-52F0-9EC7-634B7AC14D46">KPenUpPollTime</xref> </p> </li>
+<li id="GUID-DC234930-4914-54BB-B7D1-AF13832EB65F"><p>If the pen is up at
+power on, i.e. when in the <i>power up</i> state, or when the pen is first
+lifted, the sampling is initialised; see <xref href="GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07.dita#GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07/GUID-4B0737BA-74E2-5FF2-BCE3-4BC822C14470">Step
+6 - initialise sampling</xref>  </p> </li>
+<li id="GUID-788762CA-2B94-5E8E-944E-8BC79F5E8E7B"><p>If the pen is down in
+the <i>collect sample</i> state, then the digitiser coordinates are sampled
+at regular intervals, and stored in a buffer allocated by the platform independent
+layer. When a group of samples has been taken, the platform specific layer
+calls <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita#GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9/GUID-35568A81-14C1-39A2-A8AC-A1D1ED1C0E93"><apiname>DDigitiser::RawSampleValid()</apiname></xref> in the platform independent
+layer to start the processing of the samples. </p> <p>In the template port,
+the interval is defined by the constant <xref href="GUID-3574BE12-9DA9-573D-8545-3B073005A139.dita#GUID-3574BE12-9DA9-573D-8545-3B073005A139/GUID-C8EC7A1D-7597-57BB-ADE4-0EDFFEB323D0">KInterSampleTime</xref>; see <xref href="GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07.dita#GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07/GUID-4E84D583-7745-531B-AB62-65D012B4BCB2">Step
+7 - take sample readings</xref>. </p> </li>
+<li id="GUID-161E6630-D116-5559-BD19-10BA9A30FDEA"><p>If the pen is lifted
+while in the <i>collect sample</i> state, then the state changes to the <i>pen
+up debounce</i> state. This state describes the situation where a pen is lifted
+from the device and there is uncertainty as to whether this represents a positive
+move by the user, or whether the pen pressure has just been reduced momentarily.
+A delay is scheduled to decide to see which is case is true. At the end of
+the interval the state of the pen is checked again. If the pen is found to
+be down at the end of this interval, then the state changes back to the <i>collect
+sample</i> state, and the sample buffer is reset. </p> <p>In the template
+port, the delay interval is defined by the constant <xref href="GUID-3574BE12-9DA9-573D-8545-3B073005A139.dita#GUID-3574BE12-9DA9-573D-8545-3B073005A139/GUID-9BFC5FDA-FC84-5B54-93AA-BED4035F2A59">KPenUpDebounceTime</xref>. </p> </li>
+<li id="GUID-FE0F5F20-683E-5860-81E8-940F9FD98794"><p>If the pen is found
+to be down at the end of this interval, then the state changes back to the <i>collect
+sample</i> state, and the sample buffer is reset. </p> </li>
+<li id="GUID-84C0E701-1076-517B-B212-A4A48F2F622B"><p>If the pen is found
+to be still up at the end of this interval, then the pen is assumed to be
+intentionally up. The sample buffer is reset in preparation for future readings,
+and the platform independent layer is notified that the pen is now up by calling <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita#GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9/GUID-58094BAE-A932-366A-A2B0-977E3539540C"><apiname>DDigitiser::PenUp()</apiname></xref>. </p> </li>
+</ol> </section>
+<section id="GUID-CD820F5C-01F7-427F-8FFC-675CDE48F1BD"><title>Interaction between the two layers</title> <p>This section
+shows the main interactions between the two layers: </p> <p><b>1</b> </p> <fig id="GUID-BC82D3E5-C190-57F4-AAC4-38532E2225E9">
+<image href="GUID-4FDD1F7B-1A4E-5389-A0A4-22727CD42B5B_d0e9110_href.png" placement="inline"/>
+</fig> <p>When the device is started, the platform independent layer calls
+the function <codeph>DoCreate()</codeph>. This is where the power handler
+should be registered, interrupts bound and any other initialisation should
+take place. </p> <p>The platform independent layer then calls the function <codeph>WaitForPenDown()</codeph>.
+This is declared as pure virtual in the <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita"><apiname>DDigitiser</apiname></xref> class
+and is implemented in the platform specific layer. This function is also called
+from the <codeph>ProcessPenUp()</codeph> function that runs in a DFC thread
+scheduled to run when the pen is lifted. This DFC is scheduled in the platform
+specific layer. </p> <p>See also <xref href="GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07.dita#GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07/GUID-1A1194A0-DF74-59E7-B3AD-FD87D501F00F">Step
+4 - implement DDigitiser::WaitForPenDown()</xref>. </p> <p><b>2</b> </p> <fig id="GUID-3C50B57F-46A9-5CF0-94BB-50E63837D2CB">
+<image href="GUID-AE53C15E-0C0F-5726-BBA4-E7DCDA7F48B4_d0e9145_href.png" placement="inline"/>
+</fig> <p>The platform specific layer calls <codeph>RawSampleValid()</codeph> when
+it has a group of digitizer coordinates ready to be processed by the platform
+independent layer. This is called in the context of a DFC thread, the DFC
+being queued when the digitizer interrupt is fired. </p> <p><b>3</b> </p> <fig id="GUID-AAEC4068-6743-5E50-906D-AE05622A0627">
+<image href="GUID-DE7BD5C8-9966-5D5E-B81F-D57EA9FBA451_d0e9161_href.png" placement="inline"/>
+</fig> <p>The platform independent layer calls <codeph>WaitForPenUp()</codeph> to
+request another sample from the hardware. This is declared as pure virtual
+in the <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita"><apiname>DDigitiser</apiname></xref> class and is implemented in the platform
+specific layer. The function is called after the platform independent layer
+has processed a group of raw samples while the pen is down, and also tells
+the platform specific layer that the buffers in the platform independent layer
+can be re-used. </p> <p><b>4</b> </p> <fig id="GUID-5C3344EC-B07F-5D02-A107-7F4BB381EB55">
+<image href="GUID-C8450E58-A603-5CF8-993E-053C990DDA19_d0e9181_href.png" placement="inline"/>
+</fig> <p>The platform independent layer calls <codeph>WaitForPenUpDebounce()</codeph> if
+a group of collected samples is not good enough. This is declared as pure
+virtual in the <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita"><apiname>DDigitiser</apiname></xref> class and is implemented in the
+platform specific layer. The function is called after the platform independent
+layer has processed a group of raw samples while the pen is down and also
+tells the platform specific layer that the buffers in the platform independent
+layer can be re-used. </p> <p><b>5</b> </p> <fig id="GUID-CAF3646F-0078-5F25-94A8-B03A42B132BC">
+<image href="GUID-465D1450-B1EF-568B-B518-34ACE8C1697C_d0e9201_href.png" placement="inline"/>
+</fig> <p>When the pen is lifted, the platform specific layer calls <codeph>PenUp()</codeph> in
+the platform independent layer, which then changes its internal state, issues
+a pen up event to the device, and then calls <codeph>WaitForPenDown()</codeph> in
+the platform specific layer. </p> <p><b>6</b> </p> <fig id="GUID-77BBAF4E-D737-54CF-B67C-292D5ABD5CB3">
+<image href="GUID-DB0EDBC2-8204-59F3-9029-EBBCE04A9E3C_d0e9220_href.png" placement="inline"/>
+</fig> <p>The platform independent layer calls <codeph>DigitiserOn()</codeph> when
+the device is turned on, or it may be called from the HAL. The function, implemented
+in the platform specific layer, and turns the hardware on if it is not already
+on. See also <xref href="GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07.dita#GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07/GUID-A4B43E01-9638-5967-8EFA-0AABA33189EA">Step
+3 - implement power on behaviour</xref>. </p> <p><b>7</b> </p> <fig id="GUID-481F038C-2C5D-5D95-88A3-62F54EEDA713">
+<image href="GUID-2622DE31-AA12-5FAD-86FB-B13259EFC6D9_d0e9239_href.png" placement="inline"/>
+</fig> <p> <codeph>DigitiserOff()</codeph> turns the digitizer off, and may
+be called as a result of a power transition, or it may be called from the
+HAL. If it is called from the Power Manager, the digitizer may already be
+off if the platform is in silent running mode. See also <xref href="GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07.dita#GUID-AF71FDC2-A8CC-5035-91FE-36212844BC07/GUID-6DC8A3DB-452F-5738-9D60-7E34BF8A3596">Step 10 - implement DDigitiser::DigitiserOff()</xref>. </p> <p><b>8</b> </p> <p>There are two functions: <codeph>DigitiserToScreen()</codeph> and <codeph>ScreenToDigitiser()</codeph> that
+convert digitizer coordinates to and from screen coordinates. Both are declared
+as pure virtual in the <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita"><apiname>DDigitiser</apiname></xref> class and need to be
+implemented in the platform specific layer. </p> <p><b>9</b> </p> <fig id="GUID-500D1D6B-85AE-5C1C-8F34-95036A6B9D82">
+<image href="GUID-3F0053A7-6EE2-5B59-81C2-27EC3CC7820A_d0e9276_href.png" placement="inline"/>
+</fig> <p>The platform independent layer provides the <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-1B59A40C-D023-5555-8E5E-DF18D653D321">HAL handler</xref> for the <xref href="GUID-E22F7F41-C578-36B4-A7AB-AE0AEF520A69.dita"><apiname>EHalGroupDigitiser</apiname></xref>  <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita#GUID-9AE254D4-AA60-579E-8D9D-F2797106A413/GUID-366CC4B8-C6BD-5DCC-B55D-6D87CD5C8E64">HAL groups and function-ids</xref>. This is <codeph>DDigitiser::HalFunction()</codeph>.
+It delegates the handling of 5 of the individual behaviours, as represented
+by the <xref href="GUID-86A737D5-0602-3DB3-9CFF-764C80A8D468.dita"><apiname>TDigitiserHalFunction</apiname></xref> function-ids, to the following
+functions, declared as pure virtual in the <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita"><apiname>DDigitiser</apiname></xref> class,
+and implemented by the platform specific layer: </p> <ul>
+<li id="GUID-A1F40F14-B2AB-5784-B5E9-35411C722CD0"><p> <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita#GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9/GUID-1B0F51F0-C3F4-333A-AC7E-CE332248355E"><apiname>DDigitiser::SetXYInputCalibration()</apiname></xref>  </p> </li>
+<li id="GUID-2EC061EB-FBC4-5462-98E2-AA79B6BFD981"><p> <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita#GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9/GUID-856B4F1A-ACE4-338B-B618-3DB3830CE0B9"><apiname>DDigitiser::CalibrationPoints()</apiname></xref>  </p> </li>
+<li id="GUID-4DBA15F8-34D3-5586-BF0C-89B648005EEE"><p> <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita#GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9/GUID-90861298-19B7-3D1F-80CD-E49D4C500D49"><apiname>DDigitiser::SaveXYInputCalibration()</apiname></xref>  </p> </li>
+<li id="GUID-B6CCEBBA-93CD-5C2A-9343-9F22E7E1DD2D"><p> <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita#GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9/GUID-4184805F-CF27-30AA-A551-684B595E4228"><apiname>DDigitiser::RestoreXYInputCalibration()</apiname></xref>  </p> </li>
+<li id="GUID-4626F772-B9E9-5313-80F3-AF7859F58ADD"><p> <xref href="GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9.dita#GUID-2EDAF642-2399-3594-986A-5E8A5EEA01B9/GUID-B2B3E681-018C-34A9-9686-580B60FE0D40"><apiname>DDigitiser::DigitiserInfo()</apiname></xref>  </p> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-DC2CF276-95E2-5810-9B8D-EB8B72E04FEC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-DC2CF276-95E2-5810-9B8D-EB8B72E04FEC" xml:lang="en"><title> Memory
+Dump Commands</title><shortdesc>Describes how to use the <codeph>m</codeph> command to get a dump
+of memory. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p/>
+<p>This command has two formats: </p>
+<codeblock id="GUID-FD4DF47B-6200-552F-987F-23F41C250476" xml:space="preserve">m start end</codeblock>
+<codeblock id="GUID-ACF95A5E-1EC9-50BE-93BE-EBE8E1EAF562" xml:space="preserve">m start+length</codeblock>
+<p>Using the first format you provide the start and end addresses that you
+want to inspect; for example: </p>
+<codeblock id="GUID-A9C1C18D-0B7C-5B8F-99AE-9C2773BA2342" xml:space="preserve">m 81240000 8124003F</codeblock>
+<p>Using the second form you provide the start address and the number of bytes
+to dump (in hex); for example: </p>
+<codeblock id="GUID-A1900018-03F8-5887-B7E2-73F31605512D" xml:space="preserve">m 81240000 +40</codeblock>
+<p>Both of the above examples dump 64 bytes from address 0x81240000. The output
+is a standard hex-dump: </p>
+<codeblock id="GUID-178A2669-9B71-503E-AA0C-B9F1E4DED957" xml:space="preserve">.m 81240000 +40
+81240000: 00 00 FF EB 08 01 BF D7 00 04 7D B6 02 00 BF EF ..........}.....
+81240010: 00 01 DF EE 0A 40 7F F7 00 80 BF FF 20 10 FF EA .....@...... ...
+81240020: 00 82 FF 77 04 24 FD FF 40 01 FF 7F 00 01 FF FF ...w.$..@.......
+81240030: 08 10 FF BF 08 00 BF DE 08 00 EF FB 00 00 FF DF ................
+</codeblock>
+<section id="GUID-8955F5AD-8E15-4698-A0DD-81949984D6C1"><title>Dumping the contents of classes</title> <p>You can use the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-2A0D5950-F1A5-5EE1-87A3-840B1EAD6AAD">m</xref> command
+to inspect the contents of structures and class instances, but you need to
+be aware of a few things about the memory layout: </p> <ul>
+<li id="GUID-A06A2095-01D6-5AB9-B2CB-E5A9AA4A0BC0"><p>Symbian platform is
+little-endian, which means that all values are stored so that the least significant
+bytes are stored at the lower addresses in memory (or “backwards” as commonly
+perceived). </p> <p>For example, the value 0x1234ABCD would be shown in the
+memory dump as: </p> <codeblock id="GUID-6E679A58-26E5-594E-BCEE-D01EAD5C16D2" xml:space="preserve">CD AB 34 12</codeblock> </li>
+<li id="GUID-B6A8FFF7-7F7A-555E-AD5F-A75BCD87DA36"><p>The compiler may add
+padding between variables either to speed up access or to avoid alignment
+restrictions; for example, words cannot be on odd addresses. </p> <p>As an
+example, the following struct: </p> <codeblock id="GUID-01348886-FDDB-5B7A-8AB9-D0C2C18333FE" xml:space="preserve">struct SExample
+    {
+    TUint8    iByte;
+    TInt    iInteger;
+    };
+</codeblock> <p>would be laid out in memory as: </p> <codeblock id="GUID-5D747268-124C-58BF-ACEF-BB2537863F9D" xml:space="preserve">+0(1)    iByte
++1(3)    padding
++4(4)    iInteger
+</codeblock> <p>The padding and alignment is compiler-dependent. Generally,
+fields must be aligned on a boundary equal to their size; for example, a <xref href="GUID-F58A1C0D-1B36-37EA-8012-1C74B2D12CAD.dita"><apiname>TUint32</apiname></xref> is
+4 bytes wide so it must lie on a 4-byte boundary, i.e. the least significant
+two bits of the address must be zero. </p> <p>When using GCC, classes which
+derive from <xref href="GUID-8F6FE089-E2A8-30F4-B67E-10F286347681.dita"><apiname>CBase</apiname></xref> will have a virtual table pointer as
+the first word in the class data and classes which derive from <xref href="GUID-4FCB6127-84F3-38F6-8AD2-FC3B94D67DA3.dita"><apiname>DBase</apiname></xref> will
+have a virtual table pointer as the second word in the class data. </p> <p>When
+using an EABI-compliant compiler, the virtual table pointer is always the
+first word of the class. </p> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-DC8D3736-EDCF-54CB-A614-2AAC4664F1CA.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-DC8D3736-EDCF-54CB-A614-2AAC4664F1CA" xml:lang="en"><title>Kernel-Side Services</title><shortdesc>This section describes how device drivers can use the services
+that the Kernel provides. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The section begins with a discussion of the APIs for fundamental types
+such as buffers and arrays. Kernel side programs cannot use all of the same
+APIs as user-side programs, so you need to be aware of these restrictions,
+and the alternative APIs provided by the Kernel. </p>
+<p>The guide then discusses a number of idioms for communicating between different
+threads and processes, including Publish and Subscribe, Kernel-side messages,
+shared chunks, and environment slots. </p>
+<p>Some more advanced programming issues are then discussed, including how
+to design a device driver to behave correctly in a demand paged OS environment,
+in which client programs may not be continuously in memory, and how to integrate
+a device driver with system wide power resource management. </p>
+<p>The section ends with a discussion of how Kernel APIs encourage safe programming
+with the use of precondition checks. </p>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-DCBBDFA7-1E6C-5B00-A13E-A25794668E12-master.png has changed
Binary file Adaptation/GUID-DCBBDFA7-1E6C-5B00-A13E-A25794668E12_d0e13252_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-DCDD68C7-8EBE-4E91-A983-076460B2C2F3.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-DCDD68C7-8EBE-4E91-A983-076460B2C2F3" xml:lang="en"><title>IIC Quick Start</title><shortdesc>Identifies the documents needed to understand, use and
+implement the Inter-Integrated Circuit (IIC) serial bus interface.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The IIC is a technology-independent interface for serial bus technologies.
+The IIC supports multi-master and multi-slave serial interfaces, used
+by devices attached to the bus to exchange control information. </p>
+<section id="GUID-8B55B11F-6E48-434A-A238-7BA6E57CFE58"><title>Getting
+started with IIC</title><p>There are two categories of users who need
+to understand IIC:<ul>
+<li><p>Device driver creators - need to know how to use IIC</p></li>
+<li><p>Hardware adaptation developers - need to understand how to
+write software to allow IIC to communicate with their hardware.</p></li>
+</ul></p><p>Both categories of user need to understand the basic concepts
+of IIC such as channels, nodes, transactions, transfers, the IIC controller.
+You should read the <xref href="GUID-B2F86F54-EF50-56DB-ADF7-15325AC9324D.dita">IIC Concepts</xref> guide to understand these concepts.</p></section>
+<section id="GUID-3B41F52F-35A6-4718-8589-0A65787BF8F3"><title>Device
+driver creators</title><p>After reading and understanding the <xref href="GUID-B2F86F54-EF50-56DB-ADF7-15325AC9324D.dita">IIC Concepts</xref> guide, the next step is to read the <xref href="GUID-A3A3405C-C89C-5079-85CE-8CB069C8E0C0.dita">IIC Client Interface
+Quickstart</xref> to understand how to use the APIs for your device
+driver.</p></section>
+<section id="GUID-6A4AD586-0A83-406C-B007-A585CD5D9622"><title>Hardware
+adaptation developers</title><p>After reading and understanding the <xref href="GUID-B2F86F54-EF50-56DB-ADF7-15325AC9324D.dita">IIC Concepts</xref> guide, you should start with the <xref href="GUID-C6647E84-7237-44FC-BD5D-2476EC161D02.dita">IIC Implementation</xref>.</p></section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-DD0DA06D-4180-54F1-8807-A7BF31D6A1F1-master.png has changed
Binary file Adaptation/GUID-DD0DA06D-4180-54F1-8807-A7BF31D6A1F1_d0e70450_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-DD568637-CD37-5E4C-AD78-4AA5AFE1E9D8.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-DD568637-CD37-5E4C-AD78-4AA5AFE1E9D8" xml:lang="en"><title>Entry
+Point Implementation</title><shortdesc>Media driver must implement an entry point function that creates
+a PDD factory object that is derived from <codeph>DPhysicalDevice</codeph>.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Because media drivers are implemented as kernel extensions, use the <xref href="GUID-F10BBEC9-FC49-3B85-9B7F-9A6DB66A7B30.dita"><apiname>DECLARE_EXTENSION_PDD()</apiname></xref> macro
+as a wrapper around the code that creates your factory object; the following
+code fragment is typical: </p>
+<codeblock id="GUID-BE6811EF-1FA7-58D2-89AC-12887B49DA5B" xml:space="preserve">DECLARE_EXTENSION_PDD()
+    {
+    return new DMyPhysicalDevice;
+    } </codeblock>
+<p>where <codeph>DMyPhysicalDevice</codeph> is an implementation of <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita"><apiname>DPhysicalDevice</apiname></xref>. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-DD9DBB55-330E-4F43-A156-621979B675BC.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-DD9DBB55-330E-4F43-A156-621979B675BC" xml:lang="en"><title>Personality Layer</title><shortdesc>Describes what a personality layer is and how to design
+one.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
Binary file Adaptation/GUID-DDD883A2-6784-4851-8E36-227EC564452A-master.png has changed
Binary file Adaptation/GUID-DDD883A2-6784-4851-8E36-227EC564452A_d0e90311_href.png has changed
Binary file Adaptation/GUID-DE7BD5C8-9966-5D5E-B81F-D57EA9FBA451-master.png has changed
Binary file Adaptation/GUID-DE7BD5C8-9966-5D5E-B81F-D57EA9FBA451_d0e9161_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-DF2F0439-AE1A-599C-91B9-6EF2177C3C7E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-DF2F0439-AE1A-599C-91B9-6EF2177C3C7E" xml:lang="en"><title>DMA Framework</title><shortdesc>The DMA Framework is a kernel extension that manages DMA (Direct
+Memory Access) hardware.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> Device drivers use DMA to copy data quickly between memory locations,
+and between memory and peripherals. This section describes how to create a
+port of it for your phone hardware. The Device Driver Guide documentation
+describes how to use the DMA Framework from a device driver. </p>
+<p>The DMA Framework provides a Platform Independent Layer. You must provide
+a Platform Specific Layer to implement the interface to the DMA Controller
+hardware on your phone. </p>
+</conbody><related-links>
+<link href="GUID-18EFC99D-68B6-51E1-8520-272DC278E82A.dita#GUID-18EFC99D-68B6-51E1-8520-272DC278E82A/GUID-11A6DFA7-4274-5545-823E-45D104295065">
+<linktext>DMA Framework in   the Device Driver Tutorial</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-DF3045C7-4BDA-53AF-85E4-A8AAD99F40F7-master.png has changed
Binary file Adaptation/GUID-DF3045C7-4BDA-53AF-85E4-A8AAD99F40F7_d0e18806_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,507 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74" xml:lang="en"><title>ROMBUILD Obey File Structure</title><shortdesc>A <codeph>ROMBUILD</codeph> obey file consists of a number
+of section, each defining a ROM image.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The sections are: </p>
+<ul>
+<li id="GUID-68682324-5270-5D3C-8943-CD6B3E3D4D27"><p>a <codeph>KernelRomSection</codeph> that defines a bootable ROM image, and includes the Kernel </p> </li>
+<li id="GUID-868955E2-C45C-5012-8C53-4EEE816B455A"><p>one or more <codeph>ExtensionRomSection</codeph> s that define ROM images that extend
+the <codeph>KernelRomSection</codeph>. </p> </li>
+</ul>
+<p>Every section contains a list of obey statements that specify ROM
+configuration information or specifies the files to be included in
+the ROM image. </p>
+<p>Extension ROM sections are marked by the <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-0BDDFFBC-C045-5A1A-8DEC-7FBF6AEFFC64">extensionrom</xref> keyword, and can only contain those ROM information
+statements that are not related to the Kernel configuration. </p>
+<p>The structure is defined as: </p>
+<codeblock id="GUID-2E1260F7-0A98-511D-9548-825A616AA0E1" xml:space="preserve">ObeyFile : KernelRomSection  [ ExtensionRomList ]</codeblock>
+<codeblock id="GUID-95EEC427-6FC2-5546-9D0F-517E32B1B92F" xml:space="preserve">KernelRomSection : ObeyStatementList</codeblock>
+<codeblock id="GUID-9741EBC0-A39B-5417-9901-13CCEDA8B465" xml:space="preserve">ExtensionRomList : ExtensionRomSection | ExtensionRomSection ExtensionRomList
+ExtensionRomSection : extensionrom = &lt;RomFileName&gt; ObeyStatementList</codeblock>
+<codeblock id="GUID-3D4DC238-4B21-5C13-93C8-96B4BBD7F7DF" xml:space="preserve">ObeyStatementList : ObeyStatement | ObeyStatement ObeyStatementList
+ObeyStatement : RomStatement | FileStatement</codeblock>
+<ul>
+<li id="GUID-D61FCED1-3241-544A-822A-07D0311711ED"><p>See <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-E6AF9AF7-2C9B-57B8-8904-271068FDF4E3">RomStatement</xref>  </p> </li>
+<li id="GUID-BF6899C1-8FC8-5AB3-BDC6-F704E95744F8"><p>See <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-E7C84930-915D-5590-837C-889B5BE37898">FileStatement</xref>  </p> </li>
+<li id="GUID-F15DF94B-8FC8-581B-8FDF-2F52D8FE4854"><p>See <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-0BDDFFBC-C045-5A1A-8DEC-7FBF6AEFFC64">extensionrom</xref> keyword </p> </li>
+</ul>
+<section id="GUID-E6AF9AF7-2C9B-57B8-8904-271068FDF4E3"><title>RomStatement</title> <p>A <codeph>RomStatement</codeph> is one of the following. </p> <table id="GUID-1339306C-7DEA-5B40-918C-A54B99F8745C">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-29BEF45C-2361-5245-9184-0261B99B6FB1">romname</xref> = </p> </entry>
+<entry><p> <codeph>&lt;rom-file-name&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-A24CE761-5675-575A-A85C-74D16A7A17FC">bootbinary</xref> = </p> </entry>
+<entry><p> <codeph>&lt;boot-file-name&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-9F070479-77D7-57E0-B142-64B3A23BBB1F">codepagingpolicy</xref></entry>
+<entry><p><codeph>[NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED | DEFAULTPAGED]</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-7DAC5804-0A03-5098-836A-2DB2CDB6F5D4">datapagingpolicy</xref></entry>
+<entry><p><codeph>[NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED | DEFAULTPAGED]</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-20A2663B-FE05-5E0A-ACF9-669EDDC8317C">codepagingoverride</xref></entry>
+<entry><p><codeph>[NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED | DEFAULTPAGED]</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-DF3AEED2-A9D0-5176-B4E5-63F73262BE07">datapagingoverride</xref></entry>
+<entry><p><codeph>[NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED | DEFAULTPAGED]</codeph></p></entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-F6F5BB84-ED0A-578F-88E5-26017E303C8E">demandpagingconfig</xref> = </p> </entry>
+<entry><p> <codeph>&lt;MinLivePages&gt; &lt;MaxLivePages&gt;           
+       &lt;YoungOldPageRatio&gt; &lt;NANDPageReadDelay&gt;             
+     &lt;NANDPageReadCPUOverhead&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-046089DD-D441-5960-9C3C-97639C6CD0AD">kerneldataaddress</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-address&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-00885DED-DF1A-5489-91A7-FA07D915EA2F">kernelheapmin</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-size&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-8F83C7C7-9DEC-5EA2-85AF-C5E1CEA68462">kernelheapmax</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-number&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-92BCC365-0353-4B29-9D71-356016ABBFCC">maxunpagedsize</xref> </p> </entry>
+<entry><p> <codeph>&lt;hex-number&gt;</codeph></p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-85ECD9AF-EDA0-42BB-9989-306F0A0F21B5">kernelconfig</xref> =</p></entry>
+<entry><p> <codeph>&lt;hex-number&gt;</codeph></p></entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-B97ECBBE-B28F-5241-9D78-DBA20108BB14">multikernel</xref> = </p> </entry>
+<entry><p> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-1443CA1F-7234-5480-8306-9C28BF16AF82">kerneltrace</xref> = </p> </entry>
+<entry><p> <codeph>&lt;32 bit hex-number | decimal number&gt; [&lt;32
+bit                   hex-number | decimal number&gt;]{0,7}</codeph>  </p> <p>The maximum number of bit mask is 8. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-560AF806-B405-529A-9222-C43220355D81">kernelromname</xref> = </p> </entry>
+<entry><p> <codeph>&lt;rom-file-name&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-FB2E9BFF-B5B3-50D8-AFAD-F120D2007173">romnameodd</xref> = </p> </entry>
+<entry><p> <codeph>&lt;rom-file-name-odd&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-2F1CEC9A-CC82-5029-9EC2-A03A491FEC09">romnameeven</xref> = </p> </entry>
+<entry><p> <codeph>&lt;rom-file-name-even&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-B784EA89-934C-55CB-9819-A28B98E4F5FA">srecordfilename</xref> = </p> </entry>
+<entry><p> <codeph>&lt;srec-file-name&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-1D2BBB97-2406-55D2-AEAB-4A584EEB3808">srecordbase</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-address&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-6CD93289-02BF-57B9-8BD4-CFC0FF1EB3E0"> version</xref> = </p> </entry>
+<entry><p> <codeph>[ &lt;major&gt; ] [ .&lt;minor&gt; ] [ (&lt;build&gt;) 
+                 ]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-4F40AAAE-A6CE-5492-99E3-95B0D74F3229">romsize</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-size&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-6D4D4AF5-92E2-5E87-97D0-B5233E700287">romlinearbase</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-address&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-C956A0A9-F8F0-5144-896C-1DBF32E76915">romalign</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-alignment&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-2F0E6FDC-4822-5FFF-9D7A-E2E25E088945">dataaddress</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-address&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-D9A6B254-D76E-51C2-A943-FA360CDB3F0E">romchecksum</xref> = </p> </entry>
+<entry><p> <codeph>&lt;base-checksum&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-39410510-6C93-5203-8577-5C4D1520517F">time</xref> = </p> </entry>
+<entry><p> <codeph>dd/mm/yyyy hh:mm:ss</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-31DD609C-5C70-5626-B892-5FD7BA63B640">trace</xref> = </p> </entry>
+<entry><p> <codeph>&lt;32bit-hex-number&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-28C6642D-FBA6-5FD4-A8A5-BE761F71FBB6">debugport</xref> = </p> </entry>
+<entry><p> <codeph>&lt;32bit-number&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-C4BD2116-A9A2-5EB6-8795-AD7AB3230640">collapse</xref> = </p> </entry>
+<entry><p> <codeph>&lt;cpu&gt; &lt;compiler&gt; &lt;mode&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-A97C37B0-8909-58FA-9BC2-2BD68F25A8B0">ascii</xref> = </p> </entry>
+<entry><p> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-AF6440C5-839B-5CC7-A645-405F34BC643F">unicode</xref> = </p> </entry>
+<entry><p> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-14316103-95C6-50A2-A15C-4980979EBCF2">epocwrapper</xref> = </p> </entry>
+<entry><p> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-A71135A8-C6A6-50DB-8081-8CCD5B6AC0CB">externaltool</xref> = </p> </entry>
+<entry><p> <codeph>&lt;toolname&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-70AAC0A2-5865-5378-998B-199B5FA60C50">coffwrapper</xref> = </p> </entry>
+<entry><p> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-B4C3E29E-9E4A-565E-B9EC-B078894521B6">filecompressnone</xref> = </p> </entry>
+<entry><p> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-5B670D2C-9295-556A-BF56-B1018EB79CCE">filecompressinflate</xref> = </p> </entry>
+<entry><p> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-6003A5F3-0537-53DF-BEC4-13D310FD944D">filecompressbytepair</xref> = </p> </entry>
+<entry><p> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-B4C3E29E-9E4A-565E-B9EC-B078894521B6">filecompressnone</xref> = </p> </entry>
+<entry><p> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-5B670D2C-9295-556A-BF56-B1018EB79CCE">filecompressinflate</xref> = </p> </entry>
+<entry><p> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-6003A5F3-0537-53DF-BEC4-13D310FD944D">filecompressbytepair</xref> = </p> </entry>
+<entry><p> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-0F63B6BF-5F9B-54A6-9109-D8661D365E5D">defaultstackreserve</xref> = </p> </entry>
+<entry><p> <codeph>default stack reserve</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-F6F5BB84-ED0A-578F-88E5-26017E303C8E">demandpagingconfig</xref> = </p> </entry>
+<entry><p> <codeph>&lt;MinLivePages&gt; &lt;MaxLivePages&gt;           
+       &lt;YoungOldPageRatio&gt; &lt;NANDPageReadDelay&gt;             
+     &lt;NANDPageReadCPUOverhead&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-8F9F15ED-B972-517E-91E3-F58657324A31">dlldatatop</xref> = </p> </entry>
+<entry><p> <codeph> address of data region</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-F57DE321-5C08-5D3B-BFE8-B4BD0BA1EBE4">memmodel</xref> = </p> </entry>
+<entry><p> <codeph> moving | direct | multiple &lt;chunk size&gt; &lt;page
+                  size&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-0432CA22-868F-5C9E-B778-378662954DD8">nowrapper</xref> = </p> </entry>
+<entry><p> <codeph/>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-ADB633E8-8DD1-514C-9560-A6A2429DA199">pagingoverride</xref> = </p> </entry>
+<entry><p> <codeph>[NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED |     
+             DEFAULTPAGED]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-29A1FB89-E364-5C90-99D3-92247B514810">pagingpolicy</xref> = </p> </entry>
+<entry><p> <codeph>[NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED |     
+             DEFAULTPAGED]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-1950C3F1-BB6A-5560-955B-41D8A62FF041">platsecdiagnostics</xref> = </p> </entry>
+<entry><p> <codeph>[on | off]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-2644E195-4339-5809-ACA0-6B15244AA4AD">platsecdisabledcaps</xref> = </p> </entry>
+<entry><p> <codeph>[on | off]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-275FDBE0-D0AA-5976-9886-B0D56C075C7F">platsecenforcement</xref> = </p> </entry>
+<entry><p> <codeph>[on | off]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-83F419EE-9ECD-5B19-9B9E-11F2066E5C8D">platsecenforcesysbin</xref> = </p> </entry>
+<entry><p> <codeph>[on | off]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-B5EE7071-532B-591B-904B-93108A42D939">platsecprocessisolation</xref> = </p> </entry>
+<entry><p> <codeph>[on | off]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-ADB633E8-8DD1-514C-9560-A6A2429DA199">pagingoverride</xref> = </p> </entry>
+<entry><p> <codeph>[NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED |     
+             DEFAULTPAGED]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-29A1FB89-E364-5C90-99D3-92247B514810">pagingpolicy</xref> = </p> </entry>
+<entry><p> <codeph>[NOPAGING | ALWAYSPAGE | DEFAULTUNPAGED |     
+             DEFAULTPAGED]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-705897FD-9EC4-5F54-9198-A93C5080B80E">patchdata</xref> = </p> </entry>
+<entry><p> <codeph>&lt;binary_name&gt; ordinal &lt;ordinal_no.&gt;     
+             &lt;size_bytes&gt; &lt;new_value&gt;</codeph>  </p> <p>OR </p> <p> <codeph>&lt;binary_name&gt; addr &lt;symbol_address&gt;          
+        &lt;size_bytes&gt; &lt;new_value&gt;</codeph>  </p> <p>Where, &lt;<varname>binary_name</varname> &gt; is the name of the binary along with its
+complete path, &lt;<varname>ordinal_no.</varname> &gt; is the ordinal
+number of the symbol to be patched, &lt;<varname>symbol_address</varname> &gt; is the address of the data symbol to be patched, &lt;<varname>size_bytes</varname> &gt; is the size of the symbol in bytes, and &lt;<varname>new_value</varname> &gt; is the new value for the symbol. </p> <p> <b>Note:</b> If you want to use the second version of <codeph>patchdata</codeph>, you must know the address of the data symbol to be patched. </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-8964BB60-D323-56F3-9093-DA623CA56500">BTrace</xref> = </p> </entry>
+<entry><p> <codeph>N1 [N2 [N3 [N4 [N5 [N6 [N7 [N8]]]]]]]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-95B716E3-EC86-5B3A-9784-2930AC6B1E8B">BTraceBuffer</xref> = </p> </entry>
+<entry><p> <codeph>N</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-3D917AF7-F4FF-54F4-8CDB-5647B440137D">BTraceMode</xref> = </p> </entry>
+<entry><p> <codeph>N</codeph>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-E7C84930-915D-5590-837C-889B5BE37898"><title>FileStatement</title> <codeblock id="GUID-2149E903-F44F-560D-A53B-D3896AE80900" xml:space="preserve">FileStatement : ControlStatement | FileSpecificationStatement | RomDirectoryStatement</codeblock> <p>A <codeph>ControlStatement</codeph> is one of the following: </p> <table id="GUID-3B3F33F2-A998-5876-9ABE-83E0B1D50DE9">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-9724A786-4431-595F-8945-C29914D63A40">rem</xref> = </p> </entry>
+<entry><p> <codeph>&lt;comments&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-D31658A3-6346-5BBE-B79C-D274113C6120">section</xref> = </p> </entry>
+<entry><p> <codeph>&lt;section-offset&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-0BDDFFBC-C045-5A1A-8DEC-7FBF6AEFFC64">extensionrom</xref> = </p> </entry>
+<entry><p> <codeph>&lt;rom-filename</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-F5A15F4D-2CD5-530D-8031-51546EE28E1C">align</xref> = </p> </entry>
+<entry><p> <codeph>alignment</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-0FA9D55F-4081-5A46-ABD7-C95406827730">area</xref> = </p> </entry>
+<entry><p> <codeph>&lt;name&gt; &lt;run-address&gt; &lt;maxlength&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-0D56F068-91DE-50C8-94FF-9744B5E5B3E6">stop</xref> = </p> </entry>
+<entry><p> </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>A <codeph>FileSpecificationStatement</codeph> is one of
+the following: </p> <table id="GUID-A3CA10B0-5AF4-5160-A031-A64B85B0A6EA">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-23851F44-7FAC-5B99-8D15-44099A61A4E4">data[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;source-file&gt; &lt;destination-image-file&gt;  
+                [</codeph> <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-723EAEB3-3D76-513D-B010-49C40E3113BC">FileAttributeList</xref> <codeph>]</codeph> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-ECDEA52A-1357-5173-AA80-4E34A83A4511">file[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;Source-file&gt; &lt;destination-file&gt; [</codeph> <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-723EAEB3-3D76-513D-B010-49C40E3113BC">FileAttributeList</xref>] [<xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-D77A83B7-71A9-5473-8E11-63D5B5470C2E">OverrideAttributeList</xref> <codeph>]                   [paged |
+unpaged]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-D14ECB32-00DD-574B-9301-2EF11AE55BA5">primary[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;source-file&gt; &lt;destination-image-file&gt;  
+                [</codeph> <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-723EAEB3-3D76-513D-B010-49C40E3113BC">FileAttributeList</xref> <codeph>]</codeph> [<xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-D77A83B7-71A9-5473-8E11-63D5B5470C2E">OverrideAttributeList</xref> <codeph>]</codeph> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-41316071-4988-5E48-896C-61F7E6E766DD">secondary</xref> = </p> </entry>
+<entry><p> <codeph>&lt;source-file&gt; &lt;destination-image-file&gt;  
+                [</codeph> <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-723EAEB3-3D76-513D-B010-49C40E3113BC">FileAttributeList</xref> <codeph>]</codeph> [<xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-D77A83B7-71A9-5473-8E11-63D5B5470C2E">OverrideAttributeList</xref> <codeph>]</codeph> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-434D1F4F-5CA5-5793-9119-8C89A8C0B251">variant[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;source-file&gt; &lt;destination-image-file&gt;  
+                [</codeph> <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-723EAEB3-3D76-513D-B010-49C40E3113BC">FileAttributeList</xref> <codeph>]</codeph> [<xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-D77A83B7-71A9-5473-8E11-63D5B5470C2E">OverrideAttributeList</xref> <codeph>]</codeph> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-5A5348CB-1562-5C05-857D-C3F3EEDB51D7">device[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;source-file&gt; &lt;destination-image-file&gt;  
+                [</codeph> <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-723EAEB3-3D76-513D-B010-49C40E3113BC">FileAttributeList</xref> <codeph>]</codeph> [<xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-D77A83B7-71A9-5473-8E11-63D5B5470C2E">OverrideAttributeList</xref> <codeph>]</codeph> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-1D8AC4CF-8EDA-538B-8A74-5A55CCDEE2AB">extension[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;source-file&gt; &lt;destination-image-file&gt;  
+                [</codeph> <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-723EAEB3-3D76-513D-B010-49C40E3113BC">FileAttributeList</xref> <codeph>]</codeph> [<xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-D77A83B7-71A9-5473-8E11-63D5B5470C2E">OverrideAttributeList</xref> <codeph>]</codeph> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-35E198AB-4B68-55C1-B6FB-471E743412DD">dll[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;source-file&gt; &lt;destination-image-file&gt;  
+                [</codeph> <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-723EAEB3-3D76-513D-B010-49C40E3113BC">FileAttributeList</xref> <codeph>]</codeph> [<xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-D77A83B7-71A9-5473-8E11-63D5B5470C2E">OverrideAttributeList</xref> <codeph>]</codeph> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-B9B523ED-4D61-5EBF-9EFC-C47F8FA78C80">filecompress[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;source-file&gt; &lt;destination-image-file&gt;  
+                [</codeph> <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-723EAEB3-3D76-513D-B010-49C40E3113BC">FileAttributeList</xref> <codeph>]</codeph> [<xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-D77A83B7-71A9-5473-8E11-63D5B5470C2E">OverrideAttributeList</xref> <codeph>]</codeph> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-9CAD6F80-7817-56E6-BB06-DB70B0A1EBF1">fileuncompress[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;source-file&gt; &lt;destination-image-file&gt;  
+                [</codeph> <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-723EAEB3-3D76-513D-B010-49C40E3113BC">FileAttributeList</xref> <codeph>]</codeph> [<xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-D77A83B7-71A9-5473-8E11-63D5B5470C2E">OverrideAttributeList</xref> <codeph>]</codeph> </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>A <codeph>RomDirectoryStatement</codeph> is one of the
+following: </p> <table id="GUID-3DACC408-30F7-5F10-BDEC-6A3ACF881EBF">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-0A8E6B07-1C40-55DD-A2D8-122E62A285F1">hide[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;existing-file&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-7CE887E7-C2C3-5F87-AB40-AFA571A68A23">alias[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;existing-file&gt; &lt;destination-file&gt;      
+            [</codeph> <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-723EAEB3-3D76-513D-B010-49C40E3113BC">FileAttributeList</xref> <codeph>]</codeph> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-4584DD65-6861-5B2A-A4FB-B7F366DCE13A">rename[[HWVD]]</xref> = </p> </entry>
+<entry><p> <codeph>&lt;existing-file&gt; &lt;destination-file&gt; [</codeph> <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-723EAEB3-3D76-513D-B010-49C40E3113BC">FileAttributeList</xref> <codeph>]                   [</codeph> <xref href="GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74.dita#GUID-DF8CBC8C-9823-5FA9-962F-22215A6C0B74/GUID-D77A83B7-71A9-5473-8E11-63D5B5470C2E">OverrideAttributeList</xref> <codeph>]</codeph> </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-723EAEB3-3D76-513D-B010-49C40E3113BC"><title>FileAttributeList</title> <codeblock id="GUID-C5A031EE-B730-5F60-97EE-2AA303D1DB00" xml:space="preserve">FileAttributeList : FileAttribute | FileAttribute  FileAttributeList</codeblock> <p>A <codeph>FileAttribute</codeph> is one of the following: </p> <table id="GUID-FC7537B4-AC54-5C96-BF3E-44CE8AE482EB">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-19D49CB3-C180-5F32-9488-63C71A3D5991">attrib</xref> = </p> </entry>
+<entry><p> <codeph>[ s | S ][ h | H ][ r | R | w | W ] | hide</codeph>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-D77A83B7-71A9-5473-8E11-63D5B5470C2E"><title>OverrideAttributeList</title> <codeblock id="GUID-3C945FCA-9163-5018-9AD2-0D1D8B401FA9" xml:space="preserve">OverrideAttributeList : OverrideAttribute | OverrideAttribute  OverrideAttributeList</codeblock> <p>An <codeph>overrideAttribute</codeph> is one of the following: </p> <table id="GUID-CE4D5A2E-D2B9-54DF-A365-958FA62FA13B-GENID-1-2-1-8-1-1-6-1-1-11-1-4-1-3-14-4">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-D3FA449B-0A87-4739-991C-6C59C6DEEC71">data-align</xref> </entry>
+<entry><p><codeph>&lt;hex-number&gt;</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-03F5D906-B29F-4375-9EA4-BDEEFE53645F">capability</xref> =</entry>
+<entry><p><codeph>&lt;capability&gt;</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-39CDB129-CE41-4ACD-952E-72D9DDA61556">process</xref> =</entry>
+<entry><p><codeph>&lt;filepath&gt;</codeph></p></entry>
+</row>
+<row>
+<entry><xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-F773E3A5-50D0-4370-9D73-902FEAE8C3B4">preferred</xref></entry>
+<entry/>
+</row>
+<row>
+<entry><xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-C95FF58E-B556-4B31-AC67-9B8FCB283D0F">paged</xref></entry>
+<entry/>
+</row>
+<row>
+<entry><xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-AE7F4574-69AD-4817-A15D-A4560BA210D6">unpaged</xref></entry>
+<entry/>
+</row>
+<row>
+<entry><xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-1314D06A-FA06-4D08-87FA-4B4927081127">pagedcode</xref></entry>
+<entry/>
+</row>
+<row>
+<entry><xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-6423A7D6-1129-49A1-882E-64C5182A197F">unpagedcode</xref></entry>
+<entry/>
+</row>
+<row>
+<entry><xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-23A28BEA-1AF4-42B6-887F-60C7B0EE2DEC">pageddata</xref></entry>
+<entry/>
+</row>
+<row>
+<entry><xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-F6B182CA-4042-4E03-8718-893423913EB8">unpageddata</xref></entry>
+<entry/>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-2F8E864B-0754-566B-9F88-3FC44E4ECF91">stackreserve</xref> = </p></entry>
+<entry><p><codeph>&lt;hex-size&gt;</codeph></p></entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-205BE385-1937-5034-9DBE-51D1A276326A">stack</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-size&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-E816D875-0CE6-5C0A-BB1A-93F9A3E2DE90">reloc</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-address&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-250AC57D-0430-5DBD-B04E-99A874E42256">heapmin</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-size&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-DDB9FC14-73FF-5D99-963E-C289D3091FD1">heapmax</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-size&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-255FE5A6-B1F7-59E3-AB5A-65F990F96103">code-align</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-number&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-37403D0E-65E7-5998-A568-CC5839B7ACDC">fixed</xref>  </p> </entry>
+<entry><p> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-02DE8552-5FE0-52D4-8A82-A0B679E934AA">priority</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-number&gt; | &lt;keyword&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-19D81B5A-A13E-5468-B886-2EF65139C950">patched</xref>  </p> </entry>
+<entry><p> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-A53DC5BA-7531-53F4-9117-4F26D372F212">uid1</xref> = </p> </entry>
+<entry><p> <codeph>&lt;uid value&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-342B6CA5-8508-5673-900F-9CF331F5AC79">uid2</xref> = </p> </entry>
+<entry><p> <codeph>&lt;uid value&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-6F5B7223-A8E2-51EC-B950-79426DB0AAB4">uid3</xref> = </p> </entry>
+<entry><p> <codeph>&lt;uid value&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-2F8E864B-0754-566B-9F88-3FC44E4ECF91">stackreserve</xref> = </p> </entry>
+<entry><p> <codeph>&lt;hex-size&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-50B4683F-C796-577A-8444-D75465BC9563">area</xref> = </p> </entry>
+<entry><p> <codeph>&lt;name&gt;</codeph>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-DFADEB44-4D57-564F-ABDF-A3CCD38ACABC-master.png has changed
Binary file Adaptation/GUID-DFADEB44-4D57-564F-ABDF-A3CCD38ACABC_d0e15086_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-DFDB6864-0F63-41EC-B549-791B750F3EB3.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-DFDB6864-0F63-41EC-B549-791B750F3EB3" xml:lang="en"><title>DMA Client Interface</title><shortdesc>Describes the DMA platform service to the higher layers
+of the platform.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The DMA client interface is the interface between DMA and the higher
+layers of the platform</p>
+</conbody><related-links>
+<link href="GUID-D5ED62EB-744D-42EB-B8CF-D5623BDA5B38.dita"><linktext>DMA
+Client Interface Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E081474F-6B17-5D2E-833B-E8177778577A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E081474F-6B17-5D2E-833B-E8177778577A" xml:lang="en"><title>Digitizer Driver</title><shortdesc>The Digitizer Driver is a kernel extension that manages digitizers
+(touch screens).</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> Graphic User Interface (GUI) that accept input from a pen or a stylus
+must implement the driver. This section describes how to create a port of
+it for your phone hardware. </p>
+<p>Symbian platform provides a generic Platform Independent Layer for the
+driver. You must provide a Platform Specific Layer to implement the interface
+to the digitizer hardware on your phone. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E0A0C542-2922-407D-88E9-2DC5D159E1F6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E0A0C542-2922-407D-88E9-2DC5D159E1F6" xml:lang="en"><title>Interrupt Tools Guide</title><shortdesc>Tools required for the Interrupt platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There are no specific tools required to use or implement the Interrupt
+platform service.</p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E0DCBDCF-C056-53E5-A375-778327F848E4.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,408 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E0DCBDCF-C056-53E5-A375-778327F848E4" xml:lang="en"><title>Asic Class Tutorial</title><shortdesc>Provides a work through tutorial that allows you to port
+an Asic implementation to the template variant. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p id="GUID-39010DA3-632A-5C27-92BF-9AA8B5966EAB">  This tutorial
+describes how to implement the Asic class. This is a pure virtual
+interface that is defined and called by the Kernel, but which must
+be implemented by the ASSP/Variant. The tutorial assumes that the
+ASSP/Variant is split into an ASSP layer and a Variant layer. </p>
+<p>For a minimal port, it isn't necessary to provide implementations
+for the entire <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita"><apiname>Asic</apiname></xref> class to be able to test that
+the kernel boots, provided that those functions that are not fully
+implemented have a dummy function so that the code will build. </p>
+<p>The <codeph>Asic</codeph> class is defined in<filepath>..\e32\include\kernel\arm\assp.h</filepath>. For reference, the definition is: </p>
+<codeblock id="GUID-B33CCD29-C6D2-5DC9-9302-A265E248E8DF" xml:space="preserve">class Asic
+    {
+public:
+       // initialisation
+    virtual TMachineStartupType StartupReason()=0;
+    virtual void Init1()=0;
+    virtual void Init3()=0;
+
+    // debug
+    virtual void DebugOutput(TUint aChar)=0;
+
+    // power management
+    virtual void Idle()=0;
+
+    // timing
+    virtual TInt MsTickPeriod()=0;
+    virtual TInt SystemTimeInSecondsFrom2000(TInt&amp; aTime)=0;
+    virtual TInt SetSystemTimeInSecondsFrom2000(TInt aTime)=0;
+    virtual TUint32 NanoWaitCalibration()=0;
+
+    // HAL
+    virtual TInt VariantHal(TInt aFunction, TAny* a1, TAny* a2)=0;
+
+    // Machine configuration
+    virtual TPtr8 MachineConfiguration()=0;
+    };</codeblock>
+<p>Taking the template port as a concrete example, the ASSP layer
+implementation of the <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita"><apiname>Asic</apiname></xref> class is defined and
+implemented by the <codeph>TemplateAssp</codeph> class, and the Variant
+implemention is defined and implemented by the <codeph>Template</codeph> class. </p>
+<section id="GUID-7F5D4AD6-0881-5942-9A86-A95C02125A28"><title>Asic::Init1()
+implementation</title> <p><b>Entry conditions</b> </p> <ul>
+<li id="GUID-6B761E80-7B63-5F96-9852-65F7321D365B"><p>called in the
+context of the initial (null) thread </p> </li>
+<li id="GUID-B8211B76-1308-5372-8034-4B1B9CFE58F3"><p>interrupts are
+disabled </p> </li>
+<li id="GUID-482B5E00-A25F-5966-90FB-B622F9C1AF99"><p>there is no
+kernel heap </p> </li>
+<li id="GUID-6D985E4B-1A69-58B6-975D-7F696BB062C3"><p>memory management
+functions are not available. </p> </li>
+</ul> <p><b>What the function should do</b> </p> <p>This is called during
+stage 1 of kernel initialisation. </p> <p>In this function, you need
+to: </p> <ul>
+<li id="GUID-D156866C-0BA0-58AE-9438-C4D1D2628D67"><p>initialise the
+real time clock </p> </li>
+<li id="GUID-7FB60E9E-938C-515E-803D-27DA1315040C"><p>initialise the
+interrupt dispatcher before CPU interrupts are enabled. </p> </li>
+<li id="GUID-D55DD2D9-3E45-5256-B1F4-E583706AED66"><p>set the threshold
+values for cache maintenance. You can set separate values for: </p> <ul>
+<li id="GUID-B3CEB2A4-4849-517F-A0E9-76A6018537B8"><p>purging (invalidating)
+a cache </p> </li>
+<li id="GUID-9DE85DFB-D789-565C-A944-EFBF987D457C"><p>cleaning a cache </p> </li>
+<li id="GUID-0C638F72-1D6B-512D-88EB-7369240C776A"><p>flushing (i.e.
+cleaning and invalidating) a cache. </p> </li>
+</ul> <p>You use the <xref href="GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F.dita#GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F/GUID-81AA7412-9754-3020-9D77-14DEDD3196CA"><apiname>Cache::SetThresholds()</apiname></xref> interface
+to set these values. </p> <p>As an example of what the threshold values
+mean, if you purge a memory region from cache, and the size of that
+region is greater than the threshold value, then the entire cache
+is purged. If the size of that region is less than or equal to to
+the threshold value, then only the region is purged. </p> <p>The threshold
+values are platform specific, and you need to choose your values based
+on your own performance measurements. Symbian cannot make recommendations.
+If you choose not to set your own values, Symbian platform supplies
+a set of default values, which are set by <codeph>Cache::Init1()</codeph>. </p> <p>Note that there is also a <xref href="GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F.dita#GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F/GUID-2DBD79A7-2061-3B89-89FA-B0DFC7AFFCF9"><apiname>Cache::GetThresholds()</apiname></xref> interface that you may find useful. </p> </li>
+<li id="GUID-DA94E963-6AA5-5084-8C19-77B7AD484A44"><p>set up the RAM
+zones. For details, see the <xref href="GUID-C376486D-B9BF-5D00-8B1A-1527FC1F83AD.dita">RAM Zone Tutorial</xref>. </p> </li>
+</ul> <p>Typically, you would also initialise any memory devices not
+initialised by the bootstrap. Any other initialisation that must happen
+early on should also be done here. </p> <p>The kernel calls the Variant's <codeph>Init1()</codeph> function. On the template port, this is the Variant
+layer's <codeph>Init1()</codeph>, i.e. the functions <codeph>Template::Init1()</codeph>. The source for this is in <filepath>...\template_variant\specific\variant.cpp</filepath>. </p> <codeblock id="GUID-E1247A9A-B7F7-5C0F-BD3B-A0E471FA4654" xml:space="preserve">void Template::Init1()
+    {
+     __KTRACE_OPT(KBOOT,Kern::Printf("Template::Init1()"));
+
+     //
+     // TO DO: (mandatory)
+     //
+     // Configure Memory controller and Memrory Bus parameters (in addition to what was done in the Bootstrap)
+     //
+     __KTRACE_OPT(KBOOT,Kern::Printf("Memory Configuration done"));
+
+     //
+     // TO DO: (optional)
+     //
+     // Inform the kernel of the RAM zone configuration via Epoc::SetRamZoneConfig().
+     // For devices that wish to reduce power consumption of the RAM IC(s) the callback functions
+     // RamZoneCallback() and DoRamZoneCallback() will need to be implemented and passed 
+     // to Epoc::SetRamZoneConfig() as the parameter aCallback.
+     // The kernel will assume that all RAM ICs are fully intialised and ready for use from boot.
+     //
+
+     //
+     // TO DO: (optional)
+     //
+     // Initialise other critical hardware functions such as I/O interfaces, etc, not done by Bootstrap
+     //
+     // if CPU is Sleep-capable, and requires some preparation to be put in that state (code provided in Bootstrap),
+     // the address of the idle code is writen at this location by the Bootstrap
+     // e.g.
+     // iIdleFunction=*(TLinAddr*)((TUint8*)&amp;Kern::SuperPage()+0x1000);
+     //
+     TemplateAssp::Init1();
+     }</codeblock> <p>The last line is a call into the ASSP layer,
+which is implemented as shown below. On the template port, it is the
+ASSP layer that initialises the interrupt dispatcher and the real
+time clock. The source for this is in <filepath>...\template_assp\assp.cpp</filepath>: </p> <codeblock id="GUID-1E90071E-6CB0-5B01-984C-AFCFD095CA64" xml:space="preserve">EXPORT_C void TemplateAssp::Init1()
+    {
+     __KTRACE_OPT(KBOOT,Kern::Printf("TemplateAssp::Init1()"));
+     //
+     // TO DO: (optional)
+     //
+     TemplateInterrupt::Init1();            // initialise the ASSP interrupt controller
+
+     //
+     // TO DO: (optional)
+     //
+     // Initialises any hardware blocks which require early initialisation, e.g. enable and power the LCD, set up
+     // RTC clocks, disable DMA controllers. etc.
+     //
+    }
+
+   </codeblock> <p> <codeph>TemplateInterrupt::Init1();</codeph> is
+static function that initialises the interrupt dispatcher. See <xref href="GUID-423537D5-2C8A-5C26-8D7B-60446E95F681.dita">Interrupt Layer Initialisation</xref>. </p> </section>
+<section id="GUID-F5275882-BBD0-561F-B617-683AA2004BB9"><title>Asic::Init3()
+implementation</title> <p><b>Entry conditions</b> </p> <ul>
+<li id="GUID-9450694C-ADF3-52DE-AA58-4AFF53A1EEC6"><p>called in the
+context of the supervisor thread </p> </li>
+<li id="GUID-335F8A2E-0223-598E-AA23-F72E3BE84D76"><p>the kernel is
+ready to handle interrupts </p> </li>
+<li id="GUID-B198D669-9E88-5279-81A8-6A11F8EE3BFD"><p>the kernel heap
+and memory management system is fully functional. </p> </li>
+</ul> <p><b>What the function should do</b> </p> <p>This is called during
+stage 3 of kernel initialisation. </p> <p>In this function, you need
+to: </p> <ul>
+<li id="GUID-38C35732-E79A-595C-9852-12D1FE30A081"><p>enable interrupt
+sources </p> </li>
+<li id="GUID-D4F750D9-96B1-5AD1-AA66-2485D37B6323"><p>start the millisecond
+tick timer. </p> </li>
+<li id="GUID-390278B7-EF0F-59ED-A57D-54490655C97B"><p>Optionally,
+replace the implementation used by <codeph>Kern::NanoWait()</codeph>. </p> </li>
+</ul> <p>Any other general initialisation can also be done here. </p> <p>As an example, on the template port, the function is implemented
+in the Variant layer, by <codeph>Template::Init3()</codeph>. </p> <p><b>Millisecond tick timer</b> </p> <p>The kernel expects that the
+kernel's tick handler routine will be called at a fixed microsecond
+period, the value of which is returned by the implementation of <xref href="GUID-E0DCBDCF-C056-53E5-A375-778327F848E4.dita#GUID-E0DCBDCF-C056-53E5-A375-778327F848E4/GUID-917B420D-5F10-5190-97D2-9D2DAFD4FB76">Asic::MsTickPeriod()</xref> function. The <codeph>Init3()</codeph> function must be implemented to start this. See <xref href="GUID-F84E18B8-5883-5A3A-A9DB-EC25BB86149F.dita">Kernel Timers</xref> for background information. </p> <p>The template implementation
+is as follows: </p> <codeblock id="GUID-AF60AC52-5188-5911-9A03-A090D048ADA3" xml:space="preserve">EXPORT_C void TemplateAssp::Init3()
+    {
+    __KTRACE_OPT(KBOOT,Kern::Printf("TemplateAssp::Init3()"));
+
+    TTemplate::Init3();
+
+    NTimerQ&amp; m=*(NTimerQ*)NTimerQ::TimerAddress();
+    iTimerQ=&amp;m;
+    //
+    // TO DO: (mandatory)
+    //
+    // If Hardware Timer used for System Ticks cannot give exactly the period required store the initial rounding value
+    // here which is updated every time a match occurs. Note this leads to "wobbly" timers whose exact period change
+    // but averages exactly the required value
+    // e.g.
+    // m.iRounding=-5;
+    //
+    
+    TInt r=Interrupt::Bind(KIntIdOstMatchMsTimer,MsTimerTick,&amp;m);    // bind the System Tick interrupt
+    if (r!=KErrNone)
+        Kern::Fault("BindMsTick",r);
+
+    // 
+    // TO DO: (mandatory)
+    //
+    // Clear any pending OST interrupts and enable any OST match registers.
+    // If possible may reset the OST here (to start counting from a full period). Set the harwdare to produce an 
+    // interrupt on full count
+    //
+
+    r=Interrupt::Enable(KIntIdOstMatchMsTimer);    // enable the System Tick interrupt
+    if (r!=KErrNone)
+        Kern::Fault("EnbMsTick",r);
+
+    // 
+    // TO DO: (optional)
+    //
+    // Allocate physical RAM for video buffer, as per example below. However with some hardware, the Video Buffer
+    // may not reside in main System memory, it may be dedicated memory.
+    //
+    // EXAMPLE ONLY
+    TInt vSize=VideoRamSize();
+    r=Epoc::AllocPhysicalRam(2*vSize,TemplateAssp::VideoRamPhys);
+    if (r!=KErrNone)
+        Kern::Fault("AllocVRam",r);
+    }</codeblock> <p><b>Servicing the timer interrupt</b> </p> <p>The timer interrupt
+service routine is required only to call the <xref href="GUID-DFEAC0DA-E384-3249-BF6A-529A76C3AC34.dita#GUID-DFEAC0DA-E384-3249-BF6A-529A76C3AC34/GUID-DA340CB0-C334-3C17-B903-14B135ABDCF1"><apiname>Ntimer::TickQ()</apiname></xref> function and perform any housekeeping necessary to ensure that the
+handler itself is called again after the time reported by the <xref href="GUID-BCFC62D6-B87A-3319-8DA7-4BA64A9D0311.dita"><apiname>MsTickPeriod()</apiname></xref> routine. Since the handler is called frequently,
+it is written in assembler for the fastest execution. </p> <codeblock id="GUID-0770E505-10F8-582C-BCAA-BC99074FD906" xml:space="preserve">__NAKED__ void MsTimerTick(TAny* aPtr)
+    {
+    // Service 1ms tick interrupt
+    asm("ldr ip, [r0, #%a0]" : : "i" _FOFF(NTimerQ,iRounding));
+    asm("ldr r2, __KHwBaseOst ");
+    asm("adds ip, ip, #2 ");
+    asm("ldr r3, __KOst1000HzTickMatchIncrement ");
+    asm("subcs ip, ip, #5 ");
+    asm("str ip, [r0, #%a0]" : : "i" _FOFF(NTimerQ,iRounding));
+    asm("addcs r3, r3, #1 ");
+    asm("mov r1, #%a0" : : "i" ((TInt)(1&lt;&lt;KHwOstMatchMsTimer)));
+    asm("str r1, [r2, #0x14] ");            // clear interrupt
+    asm("ldr r1, [r2, #%a0]" : : "i" ((TInt)KHwOstMatchMsTimer*4));    // r1=old match value
+    asm("add r1, r1, r3 ");            // step match value on
+    asm("ldr ip, [r2, #0x10] ");            // r3=system timer value
+    asm("str r1, [r2, #%a0]" : : "i" ((TInt)KHwOstMatchMsTimer*4));
+    asm("cmp ip, r1 ");            // compare to next match value
+
+#ifdef _DEBUG
+    asm("addpl r1, ip, #10 ");    // in DEBUG if timer&gt;match value, set match value to timer + a bit
+    asm("strpl r1, [r2, #%a0]" : : "i" ((TInt)KHwOstMatchMsTimer*4));
+    asm("b Tick__7NTimerQ ");    // call interrupt handler anyway
+#else
+    asm("bmi Tick__7NTimerQ ");    // if timer&lt;match value, OK - call interrupt handler
+#endif
+
+    // otherwise we are late for the next tick so force a data abort exception...
+    asm("mvn r2, #0x10000002 ");    // r2=0xeffffffd
+    asm("str r2, [r2] ");            // die
+
+    // Constant data embedded in code. 
+    asm("__KOst1000HzTickMatchIncrement: ");
+    asm(".word %a0" : : "i" ((TInt)KOst1000HzTickMatchIncrement));
+    asm("__KHwBaseOst: ");
+    asm(".word %a0" : : "i" ((TInt)KHwBaseOst));
+    }</codeblock> <p>Note that it is a requirement that the timer
+period should be an integral number of microseconds, even if the exact
+period is not 1000us. It is always possible to add code to the interrupt
+handler to achieve this average so that over a large number of ticks,
+the deviation from this average will tend to 0, by adjusting the exact
+number of ticks from tick to tick. See also <xref href="GUID-F84E18B8-5883-5A3A-A9DB-EC25BB86149F.dita">Timers</xref></p> <p><b>NanoWait() implementation</b> </p> <p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-0EEAFE45-5C0D-32A9-AD64-CE3AB0AEE6B3"><apiname>Kern::NanoWait()</apiname></xref> is a function that can be called if you want to wait for very short
+periods of time within the kernel. You call this function and specify
+the number of nanoseconds. The function is, in effect, a shell that
+uses default implementation code provided by the generic platform.
+You can provide your own implementation in your port, and register
+this with the platform. This allows the wait functionality to be implemented
+in the best possible way for your platform, possibly by using a hardware
+timer whose frequency is independent of the CPU frequency. </p> <p>To replace the default implementation, you need to: </p> <ul>
+<li id="GUID-733329E1-99C5-56A4-B80F-FFCFD74F1320"><p>code your own
+function. This has the same signature as <codeph>Kern::NanoWait()</codeph>: </p> <codeblock id="GUID-0AC0DC75-38C7-58A8-8A4F-4C5AA8F23A80" xml:space="preserve">void AsicImpl::DoNanoWait(TUint32 aInterval)
+    {
+    // Wait for aInterval nanoseconds
+    }</codeblock> <p>where <codeph>AsicImpl</codeph> is the class that is ultimately derived from <codeph>Asic</codeph>. </p> </li>
+<li id="GUID-BDE8C5D6-6E6C-5B2E-9219-A8D5DC114EA2"><p>register this
+implementation by adding the following call into your <codeph>Asic::Init3()</codeph> function: </p> <codeblock id="GUID-1A99C7D2-A550-5B39-9AE7-559AE7B13C3E" xml:space="preserve">Kern::SetNanoWaitHandler(AsicImpl::DoNanoWait);</codeblock> </li>
+</ul> <p>You can see where this goes by looking at the template port
+at: <filepath>...\base\cedar\template\template_assp\template_assp.cpp</filepath>  </p> </section>
+<section id="GUID-1028F2D0-BA8B-4880-9565-50C89EBD1685"><title>Asic::DebugOutput()
+implementation</title> <p>It is worth implementing this early so that
+it is possible to get trace output to see what the kernel is doing.
+This function is passed one character at a time. Normally this is
+sent to a UART, though it can be output through any convenient communications
+channel. </p> <p>On the template port, this is implemented in the
+Variant layer, by <codeph>Template::DebugOutput()</codeph> in <filepath>...\template_variant\specific\variant.cpp</filepath>. </p> </section>
+<section id="GUID-EEC48040-B7D7-406B-8138-4A1F646ED990"><title>Asic::Idle()
+implementation</title> <p>If no power management has been implemented,
+then this function is called when the system is to idle to allow power
+saving. This function can just return, until power management is implemented.
+Once power management has been implemented, then idling behaviour
+will be handled by the power controller, i.e. the Variant's implementation
+of the <xref href="GUID-B3D1C422-6A82-3C6E-9123-1E4F598F0366.dita"><apiname>DPowerController</apiname></xref> class </p> </section>
+<section id="GUID-917B420D-5F10-5190-97D2-9D2DAFD4FB76"><title>Asic::MsTickPeriod()
+implementation</title> <p>This function is used to return the number
+of microseconds per tick. To avoid timing drift, a tick frequency
+should be chosen that gives a round number of microseconds per tick.
+The function can return zero until the tick timer has been implemented. </p> <p>On the template port, this function is implemented in the ASSP
+layer, and can be found in the source file <filepath>...\template_assp\assp.cpp</filepath>. It is a simple function that just returns the value. </p> <codeblock id="GUID-C0D88A32-974C-5824-8D9D-A9B6D7C45802" xml:space="preserve">EXPORT_C TInt TemplateAssp::MsTickPeriod()
+    {
+     // 
+     // TO DO: (mandatory)
+     //
+     // Return the OST tick period (System Tick) in microseconds ( 10E-06 s ).
+     //
+     return 1000;   // EXAMPLE ONLY
+    }
+</codeblock> <p>See also <xref href="GUID-F84E18B8-5883-5A3A-A9DB-EC25BB86149F.dita">Timers</xref>. </p> </section>
+<section id="GUID-1C8A7F79-8CD5-442E-A9A5-925C94E80773"><title>Asic::SystemTimeInSecondsFrom2000()
+          implementation</title> <p>This is a function that the kernel
+uses to get the system time. Its signature is </p> <codeblock id="GUID-A1FF9777-D627-5409-B6CD-02F20F7A1889" xml:space="preserve">Tint SystemTimeInSecondsFrom2000(Tint&amp; aTime);</codeblock> <p>An implementation must set the <codeph>aTime</codeph> reference
+to the number of seconds that have elapsed since the start of the
+year 2000. This is a positive number; a negative number is interpreted
+as time before 2000. </p> <p>For the template reference board, the
+implementation is as follows: </p> <codeblock id="GUID-C4812A82-C069-564B-972A-0922EAC00AAB" xml:space="preserve">EXPORT_C TInt TemplateAssp::SystemTimeInSecondsFrom2000(TInt&amp; aTime)
+     {
+      aTime=(TInt)TTemplate::RtcData();
+      __KTRACE_OPT(KHARDWARE,Kern::Printf("RTC READ: %d",aTime));
+      return KErrNone;
+     }
+</codeblock> <p>Until a real time clock is implemented, this function
+can just return <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref>. </p> <p>This function
+calls the register access functions in the <codeph>TTemplate</codeph> class. See <filepath>...\template_assp\template_assp.cpp</filepath> for implementation details. </p> <p>Note that tracing output is
+provided when the KHARDWARE bit in the kerneltrace flags is set for
+the debug build. </p> </section>
+<section id="GUID-F0AC3E98-345F-4491-9957-51B127437181"><title>Asic::SetSystemTimeInSecondsFrom2000()
+implementation</title> <p>This is a function that the kernel uses
+to set the system time. Its signature is </p> <codeblock id="GUID-B965C38C-A65E-5E54-BE09-C81300B59EDC" xml:space="preserve">Tint SetSystemTimeInSecondsFrom2000(Tint aTime);</codeblock> <p>This sets the real time clock to the number of seconds that have
+elapsed since the start of the year 2000. This is a positive number;
+a negative number is interpreted as time before 2000. </p> <p>For
+the template reference board, the implementation is as follows: </p> <codeblock id="GUID-89BFC844-B053-51B7-9ACA-81B19E63414B" xml:space="preserve">EXPORT_C TInt TemplateAssp::SetSystemTimeInSecondsFrom2000(TInt aTime)
+    {
+     //
+     // TO DO: (optional)
+     //
+     // Check if the RTC is running and is stable
+     //
+     __KTRACE_OPT(KHARDWARE,Kern::Printf("Set RTC: %d",aTime));
+     TTemplate::SetRtcData(aTime);
+     __KTRACE_OPT(KHARDWARE,Kern::Printf("RTC: %d",TTemplate::RtcData()));
+     return KErrNone;
+    }
+</codeblock> <p>Note that tracing output is provided when the KHARDWARE
+bit in the kerneltrace flags is set for the debug build. In this function,
+the trace output shows the value passed in from the kernel and then
+shows the value read back from the real time clock for verification. </p> </section>
+<section id="GUID-50BB6924-899F-4385-879E-19A2FC68657C"><title>Asic::NanoWaitCalibration()
+ implementation</title> <p>The function <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-0EEAFE45-5C0D-32A9-AD64-CE3AB0AEE6B3"><apiname>Kern::NanoWait()</apiname></xref> can be called if you want to wait for very short periods of time
+within the kernel. You call this function and specify the number of
+nanoseconds. You can either use the default implementation of this
+function, or you can provide your own. </p> <p>The default implementation
+provided by Symbian platform that <codeph>Kern::NanoWait()</codeph> uses is a busy loop that is calibrated by calling <codeph>Asic::NanoWaitCalibration()</codeph>. <codeph>NanoWaitCalibration()</codeph> should return the number
+of nanoseconds taken to execute 2 machine cycles. This is obviously
+dependent on the CPU clock speed, so if variants are likely to run
+at different speeds, then this should be implemented in the Variant
+layer. </p> <p>This approach cannot always take into account factors
+such as processor frequency scaling. An alternative approach is for
+the Variant to supply its own implementation to be used by <codeph>Kern::NanoWait()</codeph>. Note that you do not replace <codeph>Kern::NanoWait()</codeph> itself as this is a shell function that results in a call to the
+the implementation. See <xref href="GUID-E0DCBDCF-C056-53E5-A375-778327F848E4.dita#GUID-E0DCBDCF-C056-53E5-A375-778327F848E4/GUID-F5275882-BBD0-561F-B617-683AA2004BB9">Asic::Init3()</xref> for detail on how to replace the implementation. </p> <p>On the template port, <codeph>Asic::NanoWaitCalibration()</codeph> is implemented in the ASSP layer, and not in the Variant layer,
+and can be found in the source file <filepath>...\template_assp\assp.cpp</filepath>. It is a simple function that just returns the value. </p> <codeblock id="GUID-68298BF1-EAE7-507D-9B5B-DDACE6C19799" xml:space="preserve">EXPORT_C TUint32 TemplateAssp::NanoWaitCalibration()
+    {
+     // 
+     // TO DO: (mandatory)
+     //
+     // Return the minimum time in nano-seconds that it takes to execute the following code:
+     //     nanowait_loop:
+     //               subs r0, r0, r1
+  //               bhi nanowait_loop
+     //
+     // If accurate timings are required by the Base Port, then it should provide it's own implementation 
+     // of NanoWait which uses a hardware counter. (See Kern::SetNanoWaitHandler)
+     //
+    
+     return 0;   // EXAMPLE ONLY
+    }
+</codeblock> </section>
+<section id="GUID-15F344C5-A1CC-45FC-AC94-27022A1DF448"><title>Asic::VariantHal()
+implementation</title> <p>You might find it useful to review <xref href="GUID-9AE254D4-AA60-579E-8D9D-F2797106A413.dita">User-Side Hardware
+Abstraction Technology</xref> first. </p> <p>This is the HAL handler
+for the HAL group <xref href="GUID-66A851A0-2A0C-3624-AEC1-22F6629FABF7.dita#GUID-66A851A0-2A0C-3624-AEC1-22F6629FABF7/GUID-3FA061DE-68F8-3948-96B3-5AFC989DBDE1"><apiname>THalFunctionGroup::EHalGroupVariant</apiname></xref>. </p> </section>
+<section id="GUID-2EEA143D-612C-47C5-B16C-22DAD1BC179E"><title>Asic::MachineConfiguration()
+          implementation</title> <p>This returns a <xref href="GUID-C0D29B11-1535-3D11-B318-B18D30A6120B.dita"><apiname>TPtr8</apiname></xref> descriptor representing an area containing machine configuration
+information. </p> <p>The address of this object is obtained by calling <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-4DAE5199-1EB0-31D1-BA06-8F47E96EEADE"><apiname>Kern::MachineConfig()</apiname></xref>. However, the Variant (either the
+ASSP layer or the Variant layer or both) is responsible for the content. </p> <p>In the template port, the function is implemented in the Variant
+layer: </p> <codeblock id="GUID-B75F631E-03DB-5C98-911F-1161842AA17F" xml:space="preserve">TPtr8 Template::MachineConfiguration()
+    {
+     return TPtr8((TUint8*)&amp;Kern::MachineConfig(),sizeof(TActualMachineConfig),sizeof(TActualMachineConfig));
+    }
+</codeblock> <p>Here, the machine configuration information is represented
+by an object of type <codeph>TTemplateMachineConfig</codeph>, which
+derives from <codeph>TMachineConfig</codeph>. In effect, <codeph>TMachineConfig</codeph> represents information that is common to all, while the Variant
+can extend this to contain whatever information is appropriate. </p> <p>Note that <codeph>TActualMachineConfig</codeph> is a typedef
+for <codeph>TTemplateMachineConfig</codeph>. </p> </section>
+<section id="GUID-B1E39D8C-1562-4464-A316-144ED89935C9"><title>Asic::StartupReason()
+implementation</title> <p>If a startup reason is available from hardware
+or a preserved RAM location, it should be returned by the function.
+The default is to return <codeph>EStartupColdReset</codeph>. </p> <p>On the template port, this is implemented in the ASSP layer: </p> <codeblock id="GUID-FC4FFA46-804D-5A7F-B7CA-DDDC72C60041" xml:space="preserve">EXPORT_C TMachineStartupType TemplateAssp::StartupReason()
+    {
+     __KTRACE_OPT(KBOOT,Kern::Printf("TemplateAssp::StartupReason"));
+  #ifdef _DEBUG                                                            // REMOVE THIS
+     TUint s = Kern::SuperPage().iHwStartupReason;
+     __KTRACE_OPT(KBOOT,Kern::Printf("CPU page value %08x", s));
+  #endif                                                                    // REMOVE THIS
+     //
+     // TO DO: (mandatory)
+     //
+     // Map the startup reason read from the Super Page to one of TMachineStartupType enumerated values
+     // and return this
+     //
+     return EStartupCold;   // EXAMPLE ONLY
+    }
+</codeblock> </section>
+</conbody><related-links>
+<link href="GUID-984C2A0D-36BE-5A99-9D65-3F8791C669FF.dita#GUID-984C2A0D-36BE-5A99-9D65-3F8791C669FF/GUID-95C34114-F986-5428-9D40-5CF64429CDBD">
+<linktext>ASSP/Variant Architecture</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E1277A18-7201-4856-8712-067022F92123.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,84 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E1277A18-7201-4856-8712-067022F92123" xml:lang="en"><title>DSDIOStack
+Class Tutorial</title><shortdesc>Describes the DSDIOStack API class.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-4BDF2833-2D45-4AAF-BB79-FC1215209C3B"><title>Description</title><p>The <xref href="GUID-908B4DA8-8E1C-3B38-90FF-14EC52277B91.dita"><apiname>DSDIOStack</apiname></xref> class
+provides the SDIO specific implementation of the initialization state machine
+and the support for asynchronous IO read and write operations.</p><table id="GUID-6247B2E9-C6A2-4EDD-9694-71514DEB44FD">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<tbody>
+<row>
+<entry><p>Header file</p></entry>
+<entry><p><filepath>sdio.h</filepath></p></entry>
+</row>
+<row>
+<entry><p>Source code file</p></entry>
+<entry><p><filepath>sdiostack.cpp</filepath></p></entry>
+</row>
+<row>
+<entry><p>Required libraries</p></entry>
+<entry><p>EPBUSSDIO</p></entry>
+</row>
+<row>
+<entry><p>Class declaration</p></entry>
+<entry><p><codeph>class DSDIOStack : public DStackBase</codeph></p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-764AE495-9C67-4181-ACCF-F4705FC0CBCA"><title>AcquireStackSM()</title><p>The
+function declaration for the <xref href="GUID-A5562C23-91EC-38A4-A13E-1BF70C4920C5.dita"><apiname>AcquireStackSM()</apiname></xref>method is:</p><codeblock xml:space="preserve">IMPORT_C virtual TMMCErr AcquireStackSM();</codeblock><p><b>Description</b></p><p>This adds a new SDIO card to the SDIO card stack.
+This is an extension of the <codeph>DSDStack::AcquireStackSM</codeph> state
+machine function. It handles the SDIO initialization procedure as described
+in version 1.10f of the SDIO card specification.</p><p><b>Parameters</b></p><p>None</p><p><b>Return
+value</b></p><table id="GUID-9D79FCCD-516A-4A78-9F74-8E28B0E57E92">
+<tgroup cols="2"><colspec colname="col1" colwidth="0.48*"/><colspec colname="col2" colwidth="1.52*"/>
+<tbody>
+<row>
+<entry><p><codeph>TMMCErr</codeph></p></entry>
+<entry><p>Return code of the operation. The return value is <codeph>KErrNone</codeph> if
+the operation was successful, otherwise an error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-017EE801-8BBA-4D8D-9EAC-68534D510A3F"><title>CIMIoReadWriteDirectSM()</title><p>The
+function declaration for the <xref href="GUID-2F44539D-406E-3EFF-8F4A-035F1F040BC0.dita"><apiname>CIMIoReadWriteDirectSM()</apiname></xref> method
+is:</p><codeblock xml:space="preserve">IMPORT_C TMMCErr CIMIoReadWriteDirectSM();</codeblock><p><b>Description</b></p><p>Implements
+the state machine for the IO_RW_DIRECT command (CMD52).</p><p><b>Parameters</b></p><p>None</p><p><b>Return
+value</b></p><table id="GUID-695217EC-13A0-4AFF-A0CA-8BBB3AFEBB1A">
+<tgroup cols="2"><colspec colname="col1" colwidth="0.48*"/><colspec colname="col2" colwidth="1.52*"/>
+<tbody>
+<row>
+<entry><p><codeph>TMMCErr</codeph></p></entry>
+<entry><p>Return code of the operation. The return value is <codeph>KErrNone</codeph> if
+the operation was successful, otherwise an error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+<section id="GUID-9D061070-2B38-4A03-89F3-221F6F3BC28B"><title>CIMIoReadWriteExtendedSM()</title><p>The
+function declaration for the <xref href="GUID-2513922B-5796-3F96-A09E-FA2014C25A25.dita"><apiname>CIMIoReadWriteExtendedSM()</apiname></xref> method
+is:</p><codeblock xml:space="preserve">IMPORT_C TMMCErr CIMIoReadWriteExtendedSM();</codeblock><p><b>Description</b></p><p>Used
+to write an CMD53 command to the card.</p><p><b>Parameters</b></p><p>None</p><p><b>Return
+value</b></p><table id="GUID-A2C65FB6-DDAE-4EB1-A6D9-588D09735B9B">
+<tgroup cols="2"><colspec colname="col1" colwidth="0.48*"/><colspec colname="col2" colwidth="1.52*"/>
+<tbody>
+<row>
+<entry><p><codeph>TMMCErr</codeph></p></entry>
+<entry><p>Return code of the operation. The return value is <codeph>KErrNone</codeph> if
+the operation was successful, otherwise an error code.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E1FEEDCE-0CD5-559C-9AE0-8090A613C166.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E1FEEDCE-0CD5-559C-9AE0-8090A613C166" xml:lang="en"><title>Obey File Syntax Conventions</title><shortdesc><filepath>obey</filepath> file contents must follow certain
+conventions.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The following conventions apply to <i>all</i> obey file statements: </p>
+<ul>
+<li id="GUID-1EC64EC3-8F32-5064-BFE8-C29EFD1A0525"><p>A line that
+is a comment can be identified using the <codeph>rem</codeph> keyword. </p> </li>
+<li id="GUID-0BEFAFB6-B0DD-58EF-BC69-1A0F250BF20C"><p>Blank lines
+are ignored. </p> </li>
+<li id="GUID-25E92BFD-D62A-536F-A320-C1DAEE1EA769"><p>The <codeph>=</codeph> symbol, where used, is optional; a blank character can
+be used instead. </p> </li>
+<li id="GUID-AFFD11AA-625C-5546-9BA3-914ADAF435AD"><p>A file name
+can, <i>optionally</i>, be enclosed within quotes; a file name that
+contains spaces <i>must</i> be enclosed within quotes. </p> </li>
+<li id="GUID-1FD6BDEB-66E8-594C-97A5-CE311A9C865A"><p>The <codeph>stop</codeph> statement causes the rest of the obey file to be ignored. </p> </li>
+</ul>
+<p/>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E21C4AF8-852A-5BBD-A92A-5473D1DFFBB1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E21C4AF8-852A-5BBD-A92A-5473D1DFFBB1" xml:lang="en"><title>Media Driver Tutorial</title><shortdesc>Describes the steps to implement a new Media Driver. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E21E7992-607A-5A49-B022-189ECA9E76D1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,61 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E21E7992-607A-5A49-B022-189ECA9E76D1" xml:lang="en"><title>Code
+Paging Overview</title><shortdesc>Overview of demand paging when applied to code paging. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-254768D6-B78B-5193-8583-2F8CF57614AC"><title>Purpose</title> <p>Demand
+paging is a technique where memory appears to application programs to be present
+in RAM, but may in fact be stored on some external media and transparently
+loaded into RAM when needed. Demand paging trades off increased available
+RAM against decreased performance, increased media wear and increased power
+usage. More RAM is made available by loading pages only on demand, but a cost
+is incurred every time a page is loaded. </p> <p>Demand paging is used to
+reduce the amount of RAM that needs to be shipped with a device and so reduce
+its cost. </p> <p>For the code paging type of demand paging, the executable
+is stored in a ROM. Since the memory locations that will be pointed to cannot
+be determined ahead of time, the pointers in the executable have to be modified
+after the page-in process. This process is known as 'relocation' and 'fix-up'.
+It is usually done by loader. </p> </section>
+<section id="GUID-217936E7-4F09-5291-B6C5-FF00BCE1B4BD"><title>Description</title> <p>The
+executable is in a ROM and so has to be loaded into RAM before it can be executed.
+When the required part of the executable is not present in RAM, then a paging
+fault is generated which starts the paging in process of specifying which
+part of the ROM is to be paged-in along with which RAM page is to be used. </p> <p>The
+above process (in very simple terms) describes how ROM paging works. With
+code paging, there is the added complication that the executable is not execute
+in place (it is probably stored via the use of an operating system e.g. ROFS)
+and so when it is paged in any pointers in the page will not point to any
+valid location. Hence a new step has to be carried out that modifies the pointers
+in the new page so that will point to meaningful locations once they are RAM.
+This process is known as 'relocation' and 'fix-up'. It is usually done by
+loader. </p> <p> </p> </section>
+<section id="GUID-85164F03-A6B5-5227-A380-5B199C805670"><title>Components</title> <p>These
+are the main components of code demand paging: </p> <ul>
+<li id="GUID-FB01C6A6-A688-5A2C-85ED-9AA81550031B"><p>Rom image - The executable
+is stored in a ROM. </p> </li>
+<li id="GUID-1A2D6E09-4A95-5000-B526-A005AD07A2A5"><p>RAM - Where the executable
+will be executed. </p> </li>
+<li id="GUID-ED582DCB-2018-5E02-8B97-84D41D79F06C"><p>Paging Fault Handler
+- To detect that a page-in process is required and to carry it out. </p> </li>
+<li id="GUID-ECF22038-E5E2-56BC-9DDF-4EB50ADAFBBC"><p>Loader - This usually
+does the 'relocation' and 'fix-up' process after the 'page-in' process. </p> </li>
+</ul> </section>
+<section id="GUID-A0780848-8A13-41F8-9BCD-C93B6CC7E0B8"><title>Using ROM Paging</title> <p>Which
+type of paging is used and for which area of memory is first specified the <codeph>oby</codeph> and <codeph>mmp</codeph> files
+and finally build by using specific parameters in the buildrom utility. </p> </section>
+</conbody><related-links>
+<link href="GUID-BDB847A2-557A-5902-AA6D-C1AE10D8E493.dita"><linktext>Code Paging
+Guide</linktext></link>
+<link href="GUID-795B8649-B6C3-5540-B52A-9B460F35A5B5.dita"><linktext>ROM Paging</linktext>
+</link>
+<link href="GUID-B35A70D2-1BC8-51DE-95BF-F315DB394582.dita"><linktext>Demand Paging
+Overview</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,76 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E2641957-8163-5EF4-B282-FC3FD9CA75A6" xml:lang="en"><title>Sound
+Driver Technology</title><shortdesc>Describes the technology concepts that are used in the Sound Driver. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-CBC17614-34B3-52A1-9C74-F7093A175398"><title>Audio hardware
+device</title> <p>An audio hardware device is an individual hardware codec
+device together with any associated controller hardware that allows the CPU
+to communicate with it. </p> <p>A basic audio hardware device typically provides
+two communication paths: an input path for the audio recording and an output
+path for audio playback. </p> <p>Most basic audio hardware devices support
+full duplex data transfer although some are only half-duplex or maybe just
+simplex. Each input or output path may be used to transfer mono data or stereo
+data. In the case of stereo this consists of two audio channels, the left
+and the right; mono data consists of just a single audio channel. </p> <p>A
+more complex audio hardware device could be an AC 97 codec or similar, plus
+its associated controller, which can support multiple input and output paths.
+Each input or output path may be used to transfer mono data, stereo data or
+'multichannel data'. For example, left, right, centre, left and right surround
+and Low-Frequency Effects (LFE). </p> </section>
+<section id="GUID-7C8FF32F-2E84-57B1-8962-9EDB4D51FEE6"><title>Unit</title> <p>Units
+are used to provide access to the various audio hardware devices. Each unit
+supports just one communication path this is either input or output. </p> <p>Clients
+of the audio hardware system can open a separate connection to each unit.
+The mapping between the units on a given phone and the audio hardware devices
+themselves is platform specific; this is determined by the implementer of
+the Sound Driver PDD for that platform. </p> <p>A basic full-duplex audio
+hardware device is presented as two units, one input/record unit and one output/playback
+unit. A more complex audio hardware device such as an AC 97 codec may be represented
+to the rest of the OS as a number of audio input and output units. </p> </section>
+<section id="GUID-74B14664-8D9D-57D2-B090-709136FEB5E3"><title>Audio channel</title> <p>An
+audio channel is a data stream between a client and an audio unit. There are
+one or more audio channels per driver channel. </p> </section>
+<section id="GUID-4D6A01FE-47E7-5A6F-9DFE-F612B880165B"><title>Driver channel</title> <p>A
+driver channel is a session between a client and an audio unit. A client may
+have driver channels open on more than one unit. </p> <p><note> The difference
+between a driver channel and an audio channel. A driver channel is a session
+between the client and an audio device which can consist of one or more audio
+channels. An audio channel refers to the audio stream, for example, left or
+right output.</note> </p> <fig id="GUID-C3B51755-EDB0-5518-83D1-886E9148D65A">
+<title>              The relationship between audio channels and device channels.
+           </title>
+<image href="GUID-2D98DB88-BA48-5EF8-A5F9-0CB8688B0B63_d0e32099_href.png" placement="inline"/>
+</fig> </section>
+<section id="GUID-5C66667B-55C0-521D-86E3-67593DB381C9"><title>Mono to stereo
+conversion</title> <p>Many codecs that support stereo playback can only accept
+audio data that is delivered with the samples for each of the channels interleaved,
+for example, LRLRLR. For these audio hardware devices, in order to operate
+the channel in mono mode and to play audio data which contains only samples
+for a single channel it is necessary to perform mono-to-stereo conversion
+on the audio data before delivering it to the codec. So, for a section of
+mono audio data that contains three samples, lets call them S1, S2 and S3,
+each sample is duplicated, so we have S1,S1,S2,S2,S3,S3, with identical samples
+being delivered to each channel. </p> <p>Unfortunately, the only way for the
+PDD to implement this conversion is for it to allocate a conversion buffer
+and to copy each sample twice into this buffer. The PDD has to allocate a
+separate conversion buffer for each simultaneous transfer operation it supports,
+for example, for the template playback driver, a conversion buffer count equal
+to <xref href="GUID-EE69DF4F-3341-355A-837A-5DA1C8A20A67.dita"><apiname>KTemplateMaxTxDmaRequests</apiname></xref>. </p> <p>When performing conversion
+in this manner, the maximum transfer size that the PDD can accept from the
+LDD becomes half the size of each conversion buffer, and when configured in
+this mode, the value returned to the LDD in response to <xref href="GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424.dita#GUID-61CC68CB-A01D-3CA0-93D9-F3717ABD6424/GUID-A47005E5-36B4-3795-A4C0-CB67B43802B5"><apiname>DSoundScPdd::MaxTransferLen</apiname></xref> must
+equal this value. </p> <p>Likewise, the record data may be delivered by the
+audio hardware device only in stereo format with the data samples for each
+channel interleaved. If the driver channel is configured in mono record mode,
+stereo to mono conversion has to be performed in the PDD to discard each alternate
+sample. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E3C70135-EC0C-504C-B428-53A5750B520B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,144 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E3C70135-EC0C-504C-B428-53A5750B520B" xml:lang="en"><title>BUILDROM Specific Statements</title><shortdesc>There are certain statements that <codeph>BUILDROM</codeph> can process.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> <codeph>BUILDROM</codeph> understands the following statements: </p>
+<table id="GUID-66DA2B29-B79E-53B0-BD7B-6E02CC60ED96">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-51EA4180-A0FC-5DCE-8CEA-C43EA24330E4">##</xref>  </p> </entry>
+<entry><p>Performs textual substitution. All subsequent instances
+of the two characters ## are replaced with an empty string.</p></entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-56A2AC12-CA1A-531C-94DB-E493735D70C8">ABI_DOWNGRADE</xref> = </p> </entry>
+<entry><p> <codeph>from-&gt;to</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-34A37221-7BCF-5C6C-AC15-BD9C2E9B0465">AUTO-BITMAP</xref> = </p> </entry>
+<entry><p> <codeph>&lt;source&gt; &lt;dest&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-9CF1F2B0-A9F2-5463-8308-787A91F74742">BITMAP</xref> = </p> </entry>
+<entry><p> <codeph>&lt;source&gt; &lt;dest&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-3ECB9A8C-7F90-5556-936A-ACFB5A3630C5">BINARY_SELECTION_ORDER</xref> = </p> </entry>
+<entry><p> <codeph>&lt;source-build1&gt;,&lt;source-build2&gt;,...</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-FDED610B-0483-54F8-9129-123047536445">compress</xref>  </p> </entry>
+<entry/>
+</row>
+<row>
+<entry><p> <xref href="GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A.dita#GUID-B9698943-0D4E-5B18-B7E4-448A0E21876A/GUID-F68BF5AB-9C25-5736-9EF6-496548D08C74">COMPRESSED-BITMAP</xref> = </p> </entry>
+<entry><p> <codeph>&lt;source&gt; &lt;dest&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-DD194603-EF11-5119-944B-399844BE8FF6">DATA_IMAGE </xref> </entry>
+<entry><codeph>&lt;id&gt; &lt;name&gt; [size=&lt;partition size&gt;] [FAT16
+| FAT32] [compress | no-compress]</codeph></entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-A3DA2415-FAF3-56D9-9598-6A3E615C2248">DEFAULT_LANGUAGE</xref> = </p> </entry>
+<entry><p> <codeph> NN</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-06D8C5BB-5FFD-5A49-98FC-C5F133C0C126">DEFINE</xref> = </p> </entry>
+<entry><p> <codeph> &lt;name&gt; &lt;replacement&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-E7D77979-190A-5BB4-90A3-00E3C022A6E5">ECHO</xref> = </p> </entry>
+<entry><p> <codeph> &lt;anything at all&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-92EAD7F7-6524-57BF-9417-B455AF469C7A">__ECOM_PLUGIN</xref> = </p> </entry>
+<entry><p> <codeph>(&lt;local build directory&gt;, &lt;rom binary directory&gt;,
+                &lt;local epoc32\data\Z directory&gt;, &lt;rom resources
+directory&gt;, &lt;DLL                 filename&gt;, &lt;resource filename&gt;)</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-7FB63AF4-EEAF-538E-8E55-95CC6CA9091B">EPOCROOT</xref> = </p> </entry>
+<entry/>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-1756F49A-2609-52C1-AC31-6CC0B2306069">ERROR</xref> = </p> </entry>
+<entry><p> <codeph>&lt;anything at all&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-B46B421D-4237-5053-BF27-66EA64EFAD92">EXCLUDE_FEATURE</xref> = </p> </entry>
+<entry><p> <codeph>&lt;feature&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-A71135A8-C6A6-50DB-8081-8CCD5B6AC0CB">externaltool</xref> = </p> </entry>
+<entry><p>&lt;toolname&gt; </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-AA809069-1D03-5578-8409-314DD3D27FD5">FEATURE</xref> = </p> </entry>
+<entry><p> <codeph>&lt;feature&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-50550839-5F46-5096-98A4-857B62E19C34">_HIDE__ECOM_PLUGIN</xref> = </p> </entry>
+<entry><p> <codeph>(&lt;local build directory&gt;, &lt;rom binary directory&gt;,
+                &lt;local epoc32\data\Z directory&gt;, &lt;rom resources
+directory&gt;, &lt;DLL                 filename&gt;, &lt;resource filename&gt;)</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-8BC22156-1E47-542F-88CC-37274B879E8A">LANGUAGE_CODE</xref> = </p> </entry>
+<entry><p> <codeph> NN</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-705897FD-9EC4-5F54-9198-A93C5080B80E">patchdata</xref> = </p> </entry>
+<entry><p> <codeph>&lt;binary_name&gt; @ &lt;symbolname&gt;            
+    &lt;newvalue&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-04CE5B92-FF2B-53BB-BC21-C66731B94CC1">RIGHT_NOW</xref> = </p> </entry>
+<entry/>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-9841CB4D-D71F-53E8-AF0E-22B393ADF2CD">ROMBUILD_OPTION</xref> = </p> </entry>
+<entry><p> <codeph> &lt;command line option&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-C88976BA-6381-5DEB-830F-5ED63CB929FA">ROM_IMAGE</xref> = </p> </entry>
+<entry><p> <codeph>&lt;id&gt; &lt;name&gt; [size=&lt;rom max size&gt;] [xip
+|                 non-xip] [compress | no-compress] [extension]</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-FBB17172-11E6-53AC-A833-7DEF02EFA57E">SECTION2</xref> = </p> </entry>
+<entry><p> <codeph>&lt;anything&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-04F39AC1-3947-5C80-90BB-55CDF4D34571">spidata</xref> = </p> </entry>
+<entry><p> <codeph>&lt;source-file&gt; &lt;original-destination-file&gt;
+                &lt;spi-id&gt; &lt;target-spi-dir&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-E54F3C5D-ED40-5196-8D9C-6B7B71826F79">spidatahide</xref> = </p> </entry>
+<entry><p> <codeph>&lt;source-file&gt; &lt;spi-id&gt;                 &lt;target-spi-dir&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-B375C7B6-DFA5-593C-8BEC-763789B89CE0">TODAY</xref> = </p> </entry>
+<entry/>
+</row>
+<row>
+<entry><p> <xref href="GUID-6843109A-1567-5287-9AFF-3AE5E80334AF.dita#GUID-6843109A-1567-5287-9AFF-3AE5E80334AF/GUID-821B5D5B-D800-5CB1-BFF1-7AD0D1402CC6">WARNING</xref> = </p> </entry>
+<entry><p> <codeph> &lt;anything at all&gt;</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-616C3426-A8C4-5653-912D-7150944E5836.dita#GUID-616C3426-A8C4-5653-912D-7150944E5836/GUID-977C6041-365A-5D23-A370-A9939689FFD7">&lt;xxx&gt;=MULTI_LINGUIFY</xref> = </p> </entry>
+<entry><p>(<codeph>&lt;ext&gt; &lt;sourcename&gt; &lt;destname&gt;</codeph>) </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table></conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E3C7CB78-8A68-4FFA-BD00-04D27E67C1F3.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,43 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E3C7CB78-8A68-4FFA-BD00-04D27E67C1F3" xml:lang="en"><title>Interrupt Quick Start</title><shortdesc>Describes how to get started with the Interrupt
+platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-EAB1F5D0-D340-4578-8ECB-E325440261EC-GENID-1-2-1-10-1-5-1-7-1-1-5-1-3-1"><title>Getting
+started</title><ul>
+<li><p>The <xref href="GUID-654A788A-526A-4C3F-838C-05B09F0D5445.dita">Interrupt Technology Guide</xref> describes the key concepts of the
+Interrupt platform service.</p></li>
+<li><p>The <xref href="GUID-862CA4C4-C6E8-4D60-8DD0-F3590C92E15D.dita">Interrupt Client Interface</xref> section describes the Interrupt
+platform service API and its use by device drivers. </p></li>
+<li><p>The <xref href="GUID-5FB6BEFD-579B-4139-B54D-9CDCF2198A14.dita">Interrupt Implementation</xref> section describes the implementation
+of the Interrupt PSL.</p></li>
+<li><p>The <xref href="GUID-9B66387C-B6CF-41D9-BEFC-F79E30C70F52.dita">Interrupt Build Guide</xref> describes how to include the Interrupt
+platform service in a ROM image.</p></li>
+<li><p>The <xref href="GUID-E0A0C542-2922-407D-88E9-2DC5D159E1F6.dita">Interrupt Tools Guide</xref> describes the tools that are specific
+to the Interrupt platform service.</p></li>
+<li><p>The <xref href="GUID-2490DA46-A57B-4DFD-AA9C-2004D58486E3.dita">Interrupt Testing Guide</xref> explains how to test the functionality
+of the Interrupt platform service.</p></li>
+</ul>                     </section>
+<section id="GUID-16DBBAC5-8F94-45AC-B66D-C40FA24FA3DB"><title>Architecture</title><p>The following diagram shows the architecture of the Interrupt
+platform service:</p><fig id="GUID-BEC5FF9A-ECCE-481C-A697-2464F64F8A78">
+<title>Interrupt platform service architecture</title>
+<image href="GUID-40880992-B177-4584-84B4-6F6CF096E423_d0e96877_href.png" placement="inline"/>
+</fig><p>The Interrupt platform service provides an interface between
+the interrupt controller in the hardware and device drivers in the
+kernel-side. The Interrupt platform service is implemented in the
+ASSP/Variant module.</p></section>
+<section id="GUID-771CF32A-9FC4-435F-8B08-51221A5E5CDB"><title>Key
+users</title><ul>
+<li><p>Device driver developers – to bind and unbind interrupts.</p></li>
+<li><p>Hardware implementers and base port developers - to implement
+an interrupt dispatcher to manage interrupts. </p></li>
+</ul></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,365 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E4447BEF-33D2-5099-BCC1-C72FBB3B0463" xml:lang="en"><title>BUILDROM</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>BUILDROM is the Symbian platform ROM configuration tool. It is
+a unified ROM building front end to prepare the configurations. It
+then invokes the ROMBUILD to generate the ROM image or ROFSBUILD to
+generate the ROFS image. </p>
+<section id="GUID-3E50F8DA-36D3-5E3D-B229-F841EF4AC47D"><title>BUILDROM
+command syntax</title><p>If the OBY files are encoded in UTF-8 with
+non-ASCII character support, use the following the BUILDROM command
+syntax:</p><codeblock id="GUID-379818BF-A17B-5CAF-A311-3EE4142EE51D-GENID-1-2-1-8-1-1-6-1-1-4-1-2-2-3" xml:space="preserve">BUILDROM [options] &lt;–oby-charset=utf-8 obyfile &gt; [&lt;obeyfile2&gt; [obeyfile3 [...</codeblock><p>If the OBY files are encoded in local character set
+with non-ASCII character support, use the following the BUILDROM command
+syntax:</p><codeblock id="GUID-379818BF-A17B-5CAF-A311-3EE4142EE51D-GENID-1-2-1-8-1-1-6-1-1-4-1-2-2-5" xml:space="preserve">BUILDROM [options] &lt;obeyfile1&gt; [&lt;obeyfile2&gt; [obeyfile3 [...</codeblock><p> <codeph>options</codeph> can be one or more of the following: </p> <table id="GUID-F50B15E9-AA5A-5946-9FD5-024287F2FD6C">
+<tgroup cols="2"><colspec colname="col0" colwidth="1.00*"/><colspec colname="col1" colwidth="1.00*"/>
+<tbody>
+<row>
+<entry><p> <codeph>–argfile=&lt;parameter file&gt;</codeph>  </p> </entry>
+<entry><p>Accepts a parameter file, which contains a list of command-line
+parameters specific to the ROM tools, as input. </p></entry>
+</row>
+<row>
+<entry><p> <codeph> -Dxxx </codeph>  </p> </entry>
+<entry><p>C++ preprocessor arguments. A common, but not exhaustive
+set is: </p><p><table id="GUID-0FD13125-051C-515A-B595-525B6C03CEA7">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>-D_DEBUG</codeph>  </p></entry>
+<entry><p>Selects debug versions of some files. </p></entry>
+</row>
+<row>
+<entry><p> <codeph> -D_FULL_DEBUG</codeph>  </p></entry>
+<entry><p>Selects debug versions of all files. </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-D_ARM4T</codeph>  </p></entry>
+<entry><p>Specifies the target platform. </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-D_KABI=xxxx</codeph>  </p> </entry>
+<entry><p>Specifies the target platform for the kernel (for example,
+ARMv5). </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-D_EABI=xxxx</codeph>  </p> </entry>
+<entry><p>Specifies the target for all files (for example, ARMv5). </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-DFEATUREVARIANT=xxxx</codeph>  </p> </entry>
+<entry><p>Specifies the name of feature-based variant (for example,
+myvar). </p> <p>BUILDROM automatically looks for the binary names
+and properties of the selected variant, using the data generated by
+build system. </p></entry>
+</row>
+<row>
+<entry><p>-D_NAND2 </p> </entry>
+<entry><p>Specifies to generate the image for NAND flash. </p></entry>
+</row>
+<row>
+<entry><p>-D_ONENAND </p> </entry>
+<entry><p>Specifies to generate the image for ONENAND flash. </p></entry>
+</row>
+</tbody>
+</tgroup>
+</table> </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-lowmem</codeph>  </p></entry>
+<entry><p>Reduces the physical memory consumption during image generation. </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-loglevel&lt;level&gt;</codeph>  </p> </entry>
+<entry><p>Level of information to log file. The following valid log
+levels are available: </p> <p><table id="GUID-8275A5E1-141E-56B3-8202-51377AD7CAA4">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>0</codeph>  </p> </entry>
+<entry><p>Default level of information to log file. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>1</codeph>  </p> </entry>
+<entry><p>Logs the host or the ROM filenames, the file size, and the
+hidden attribute in addition to the <codeph>loglevel 0</codeph> information. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>2</codeph>  </p> </entry>
+<entry><p>Logs the E32 file header attributes such as UIDs, data size,
+heap size, stack size, VID, SID, and priority in addition to the <codeph>loglevel 1</codeph> information. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-nospi </codeph>  </p> </entry>
+<entry><p>Instructs <codeph>BUILDROM</codeph> not to produce any static
+plug-in information (<codeph>.spi</codeph>) files. See the <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-92EAD7F7-6524-57BF-9417-B455AF469C7A">__ECOM_PLUGIN</xref> keyword for details of these files. The default
+is to produce <codeph>.spi</codeph> files. </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-noimage</codeph>  </p> </entry>
+<entry><p>Instructs <codeph>BUILDROM</codeph> to suppress only the
+generation of any ROM or ROFS images, while allowing generation of
+all other relevant files. </p></entry>
+</row>
+<row>
+<entry><p> <codeph> -o&lt;image name&gt; </codeph>  </p> </entry>
+<entry><p>The name of the ROM image. This overrides any name specified
+using the <xref href="GUID-43852F38-4841-5E6F-927B-A38ED4424F0C.dita#GUID-43852F38-4841-5E6F-927B-A38ED4424F0C/GUID-29BEF45C-2361-5245-9184-0261B99B6FB1">romname</xref> keyword in an Obey file. </p></entry>
+</row>
+<row>
+<entry><p> <codeph> -s </codeph>  </p> </entry>
+<entry><p>The strict option. Specifying this means that any missing
+files will stop <codeph>BUILDROM</codeph> without generating a ROM
+image. </p> <p>If this option is not specified, then it is possible
+to generate a ROM image with missing files. </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-p</codeph>  </p> </entry>
+<entry><p>Preserves the intermediate files and folders (data drive
+and <codeph>Z</codeph> drive) generated by BUILDROM. </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-e</codeph>  </p> </entry>
+<entry><p>Specifies the external tools that need to be invoked. These
+are the names of the Perl modules (without the .pm extension). Multiple
+modules names must be separated by commas. This is an optional parameter. </p> <p>Alternatively, external tools can be invoked by using IBY file
+keyword <xref href="GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA.dita#GUID-A27BD4D8-8B0E-57C8-9C15-736109297DEA/GUID-A71135A8-C6A6-50DB-8081-8CCD5B6AC0CB">externaltool</xref>. </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-fm</codeph> =&lt;<varname>feature_manager_database_file</varname> &gt;<filepath>.xml</filepath> </p> </entry>
+<entry><p>Parses the specified feature manager database XML files
+and generates the features data file(s) (<filepath>features.dat</filepath>) in the present working directory. The number of <filepath>features.dat</filepath> files generated depends on the total number of ROM image partitions
+specified in the OBEY file that is used to create the ROM image. </p> <p> <b>Notes</b>  </p> <ul>
+<li id="GUID-F229ED73-75AF-519F-9121-62E2D340D945"><p>You can provide
+multiple feature manager database XML files delimited by commas. </p> </li>
+<li id="GUID-885CB92B-7F41-5C55-B251-5955AC1B8D5C"><p>If a feature
+manager option (<codeph>-fm</codeph> or <codeph>-nofm</codeph>) is
+not passed to <codeph>BUILDROM</codeph> explicitly, the <codeph>-fm</codeph> option is used internally to generate a feature data file using
+the default <filepath>featuredatabase.xml</filepath> file in <filepath>\epoc32\rom\include</filepath>. For more information, refer to <xref href="GUID-66708290-1472-5A2C-B6D2-191454ECFE66.dita">Enabling feature
+data file generation</xref>. </p> </li>
+</ul></entry>
+</row>
+<row>
+<entry><p> <codeph>-nofm</codeph> =&lt;<varname>Existing_features_data_file_name</varname> &gt;<filepath>.dat</filepath> </p> </entry>
+<entry><p>Includes the specified features data file in the ROM image. </p> <p> <b>Note:</b> This option is ignored by <codeph>BUILDROM</codeph> if used with the <codeph>-fm</codeph> option. </p></entry>
+</row>
+<row>
+<entry><p> <codeph> -z=xxx or -zdrivepath=xxx </codeph>  </p> </entry>
+<entry><p>Specifies the location to create the Z drive directory. </p> <p>By default, a Z drive directory is created in the location from
+where BUILDROM was invoked. </p></entry>
+</row>
+<row>
+<entry><p> <codeph> -d=xxx or -datadrivepath=xxx </codeph>  </p> </entry>
+<entry><p>Specifies the location to create data drive directory. </p> <p>By default, the data drive directory is created in the location
+from where BUILDROM was invoked. </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-k or -keepgoing </codeph>  </p> </entry>
+<entry><p>Enables BUILDROM to continue to create the data drive image
+even if the SIS file(s), non-SIS file(s), or the Z drive image file(s)
+are missing or corrupted. </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-zdriveimage="&lt;image_1.img&gt;,[...,&lt;image_n.img&gt;]"
+                  </codeph>  </p></entry>
+<entry><p>Specifies the Z drive image (ROM, ROFS, and CORE image). </p></entry>
+</row>
+<row>
+<entry><p> <codeph> –r or -retainfolder </codeph>  </p></entry>
+<entry><p>Instructs BUILDROM not to delete any pre-existing data drive
+folder. </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-pfile=xxx</codeph>  </p></entry>
+<entry><p>Specifies a parameter file for INTERPRETSIS to take additional
+parameters. </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-l=&lt;logfile.txt&gt; or                   -logimageentry=&lt;logfile.txt&gt;</codeph>  </p></entry>
+<entry><p>Logs all stub-sis and SWI certificate file(s) that are part
+of the Z drive image onto a log file. </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-argforinterpretsis </codeph>  </p> </entry>
+<entry><p>Specifies the command-line argument for the InterpretSIS
+tool. These command-line arguments take precedence over the arguments
+in the parameter file. </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-i=&lt;optional path&gt;</codeph>  </p> </entry>
+<entry><p>Specifies an optional path in which the IBY files are stored.
+This option is case-sensitive. </p> <p> <b>Notes:</b>  </p> <ul>
+<li id="GUID-549E1869-8D18-5828-A167-F2757AA476FA"><p>If the IBY files
+are found both in the default path (<filepath>\epoc32\rom\include</filepath>), and the &lt;optional path&gt;, <codeph>BUILDROM</codeph> uses the
+IBY files in the &lt;optional path&gt;. </p> </li>
+<li id="GUID-35ABE65C-91A1-54D9-A221-8AE8DE1B8D5E"><p>If the IBY files
+are not found in the default path, <codeph>BUILDROM</codeph> uses
+the IBY files in the &lt;optional path&gt;. </p> </li>
+</ul></entry>
+</row>
+<row>
+<entry><p> <codeph>-j&lt;NUM_OF_WORKING_THREADS&gt;</codeph>  </p> </entry>
+<entry><p>Specifies the number of working threads that can run concurrently
+to create a ROM image. The <codeph>&lt;NUM_OF_WORKING_THREADS&gt;</codeph> must be an integer in the range 1-128. </p><p>If the <codeph>-j</codeph> option is not specified or an invalid value is specified, BUILDROM
+automatically takes the number of working threads in the following
+ways: </p><ul>
+<li id="GUID-918C5655-3D9C-5D55-A0A2-D817ABD8049D"><p>If the <codeph>NUMBER_OF_PROCESSORS</codeph> environment variable is set properly,
+BUILDROM uses the number of processors as the number of working threads. </p> </li>
+<li id="GUID-A892D1A3-2054-5DE8-98E8-D023C41F5D18"><p>If the <codeph>NUMBER_OF_PROCESSORS</codeph> environment variable is not set or
+is invalid, the default value <codeph>8</codeph> is used as the number
+of working threads. </p> </li>
+</ul></entry>
+</row>
+<row>
+<entry><p> <codeph>-compress</codeph>  </p> </entry>
+<entry><p>Compresses the ROM image. It supports three types of compression:</p><ul>
+<li><p><codeph>-compress</codeph>: Compresses the entire ROM image.</p></li>
+<li><p><codeph>-compress=paged</codeph>: Compresses the paged section
+in the ROM image.</p></li>
+<li><p><codeph>-compress=unpaged</codeph>: Compresses the unpaged
+section in the ROM image.</p></li>
+</ul></entry>
+</row>
+<row>
+<entry><p><codeph>—w</codeph></p></entry>
+<entry><p>Warns if an incorrect input file is selected. For example,
+a warning is displayed, if an incorrect binary file is selected when
+binary variant is enabled.</p></entry>
+</row>
+<row>
+<entry><p><codeph>-nosymbols</codeph></p></entry>
+<entry><p>Suppresses the generation of any ROM or ROFS symbol file.
+This option generates all the relevant files except symbol files.</p></entry>
+</row>
+<row>
+<entry><p><codeph>-geninc</codeph></p></entry>
+<entry><p>Generates an INC file of ROM image. The INC file contains
+size information of the paged and the unpaged section within the ROM
+image. The name of the output file is the same as that of the output
+ROM image, with <codeph>.inc</codeph> as extension. </p></entry>
+</row>
+<row>
+<entry><p><codeph>-spi</codeph></p></entry>
+<entry><p>Creates an SPI file.</p></entry>
+</row>
+<row>
+<entry><p><codeph>-spiplacement</codeph></p></entry>
+<entry><p>Enables positioning of the SPI file.</p></entry>
+</row>
+<row>
+<entry><p> <codeph>-compressionmethod [none | inflate | bytepair]</codeph>  </p> </entry>
+<entry><p>Specifies the compression algorithm to use. The following
+options are available with the  <codeph>-compressionmethod</codeph> keyword:</p> <p><table id="GUID-34E5FD4C-7B82-5342-85C3-C84A706C8C17-GENID-1-2-1-8-1-1-6-1-1-4-1-2-2-7-1-3-29-2-2-1">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <codeph>none </codeph>  </p> </entry>
+<entry><p>No compression is used. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>inflate </codeph>  </p> </entry>
+<entry><p>Compresses executable files using the default (Deflate,
+Huffman+LZ77) algorithm. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>bytepair </codeph>  </p> </entry>
+<entry><p>Compresses executable files using the bytepair algorithm.
+Bytepair compression allows faster decompression than the default
+Deflate, Huffman+LZ77 algorithm. It also supports demand paging by
+performing compression and decompression of code in independent 4
+KB pages. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-cache</codeph>  </p> </entry>
+<entry><p>Enables cache mechanism. It ensures that BUILDROM uses cached
+executable files while creating a ROFS image. This allows BUILDROM
+to reuse or generate cached files. </p> <p> <b>Notes</b>: </p><ul>
+<li id="GUID-9B7056D4-EF5B-533B-9E9F-50AD9A7BF498-GENID-1-2-1-8-1-1-6-1-1-4-1-2-2-7-1-3-30-2-3-1"><p>The cache mechanism
+is disabled by default.  </p> </li>
+<li id="GUID-AF355401-C732-5FB5-A472-D7EEB294E4E0-GENID-1-2-1-8-1-1-6-1-1-4-1-2-2-7-1-3-30-2-3-2"><p>The cached files
+are stored on the hard disk. </p> </li>
+<li id="GUID-7EEA01CD-E155-535B-915B-DE22C42FEDD0-GENID-1-2-1-8-1-1-6-1-1-4-1-2-2-7-1-3-30-2-3-3"><p>The cache command
+line options (<codeph>-cache</codeph>, <codeph>-nocache</codeph>,
+and <codeph>-cleancache</codeph>) are mutually exclusive. This means
+that you can use only one cache option at a time. </p> </li>
+</ul></entry>
+</row>
+<row>
+<entry><p> <codeph>-nocache</codeph>  </p></entry>
+<entry><p>Disallows BUILDROM from using cached files while creating
+a ROFS image. </p></entry>
+</row>
+<row>
+<entry><p> <codeph>-cleancache</codeph>  </p></entry>
+<entry><p>Deletes all cached files from the hard disk. </p></entry>
+</row>
+<row>
+<entry><p><codeph>-gendep</codeph></p></entry>
+<entry><p>Generates dependencies file describing a internal dependencies
+among executables or dlls in a ROM image.</p><p><b>Note</b>: You can
+only generate dependence information in the paged section of a ROM
+image.</p></entry>
+</row>
+<row>
+<entry><p><codeph>-checkcase</codeph></p></entry>
+<entry><p>Checks the character case of the path or name in OBY or
+IBY files. By default, this option is disabled.</p><p><b>Note</b>:
+ This option is only valid on Windows.</p></entry>
+</row>
+<row>
+
+<entry><p><codeph>-workdir &lt;output-location&gt;</codeph></p></entry>
+<entry><p>Generates the output files at the specified location.</p></entry>
+</row>
+<row>
+
+<entry><p><codeph>-prependepocroot</codeph></p></entry>
+<entry><p>Prepends EPOCROOT to the file location, if the specified
+location starts from <codeph>\epoc32</codeph> without <codeph>EPOCROOT</codeph>.</p></entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p><b>Note</b>: <codeph>&lt;obeyfile1&gt;</codeph> and <codeph>&lt;obeyfile2&gt;</codeph> and are standard text files containing statements
+that are used to control the building of ROM images. </p> <p>See the <xref href="GUID-9CF985F1-C100-5999-9410-58B7865A1E18.dita">OBEY files</xref> reference for the full syntax. </p> </section>
+<section id="GUID-4436DEEC-DB8A-4FDE-A869-63544C856ED8"><title>Passing
+parameters using a file</title> <p>BUILDROM allows to pass parameters
+in a file using the <codeph>-argfile</codeph> option. It provides
+a solution to the limited command line length. It also reduces the
+risk of error and saves time in typing from a command prompt. </p> <p><userinput>BUILDROM –argfile=arg.txt -s</userinput> </p> <p>In
+the BUILDROM command above, <filepath>arg.txt</filepath> is the text
+file with the parameters. An example of this file is as follows: </p> <codeblock id="GUID-C7412FD1-31CC-5860-9A6F-5A386AF5C658" xml:space="preserve">; sample parameter-file
+-fm=\epoc32\rom\include\featuredatabase.xml ;generate features data file.
+-noimage -nosymbols -s ;do not generate ROM image and symbol file
+                       ;and invoke buildrom in strict mode.
+-D_PLAT=ARMV5
+; EOF</codeblock> <p>Rules of this argument file are as follows: </p> <ul>
+<li id="GUID-BBCBEA65-8DD6-5440-8F9F-E780FE2839AA"><p>Single line
+comments begin with a semicolon (<b>;</b>). </p> </li>
+<li id="GUID-4322E7DB-E539-5E79-85B8-1CD4C1088BA0"><p>Comments can
+also be specified after the parameters. </p> </li>
+<li id="GUID-C509C35B-6643-581F-9A78-ECC4E49DD943"><p>Parameters can
+be specified either in a single line separated a by space, or in multiple
+lines. </p> <p> </p> </li>
+<li id="GUID-69B173D5-2501-5D60-8CD3-CC144422CBB7"><p>Parameters provided
+in a parameter file override those specified in the command line. </p> </li>
+<li id="GUID-48482902-77FE-552B-9D4D-FFC062F41E1B"><p>Environment
+variables must be specified in the command line and not in the parameter
+file. </p> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,538 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815" xml:lang="en"><title>HAL Attributes
+and Function IDs</title><shortdesc>List of HAL attributes, their related function IDs and links to
+the related reference documentation. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This topic The list is ordered by group. </p>
+<p>Symbian defines capabilities for each function ID. To find out a function
+ID's capabilities, follow the link to its reference information. If no capabilities
+are listed in the reference documentation for a function ID, it means that
+no capabilities are required. </p>
+<p> <b>Note</b>: </p>
+<ul>
+<li id="GUID-29CD38AD-8F05-5BAE-8C53-931A894B791D"><p>An attribute can map
+to more than one function ID. This reflects the fact that any given attribute
+can be passed to both <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-573C49D6-7763-37AE-B2B2-4C8FB1327E21"><apiname>HAL::Get()</apiname></xref> and <xref href="GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8.dita#GUID-BD00E7FC-C234-3111-87A5-10F79EB0F2B8/GUID-9454F1B2-D525-3D6D-A872-C6457CACD4FC"><apiname>HAL::Set()</apiname></xref>,
+but the set behavior and get behavior map to two different function IDs. </p> </li>
+<li id="GUID-94AFCF72-281F-5B8A-8BC2-15530433A2D2"><p>There are group/function
+ID pairs for which there is no attribute. This reflects the fact that the
+hardware specific information represented by that group/function ID cannot
+be accessed from the user side using the generic interface. </p> </li>
+</ul>
+<p>Attributes are defined as values of the <xref href="GUID-72B0351E-E8D1-3990-9673-A6713F923BC9.dita"><apiname>TAttribute</apiname></xref> enum
+within the scope of the <xref href="GUID-8BE90160-2C60-3582-82C8-4A108C7C0317.dita"><apiname>HALData</apiname></xref> class in <filepath>...\os\kernelhwsrv\halservices\hal\inc\hal_data.h</filepath>,
+which is exported to <filepath>...\epoc32\include</filepath>. </p>
+<p>HAL groups are defined as values of the <xref href="GUID-66A851A0-2A0C-3624-AEC1-22F6629FABF7.dita"><apiname>THalFunctionGroup</apiname></xref> enum
+in <filepath>...\os\kernelhwsrv\kernel\eka\include\u32hal.h</filepath>, which
+is exported to <filepath>...\epoc32\include</filepath>. </p>
+<p>Function IDs are defined as values of various enums in <filepath>...\os\kernelhwsrv\kernel\eka\include\u32hal.h</filepath>. </p>
+<ul>
+<li id="GUID-AA8AC897-38D8-505B-99AB-F0E92BA38A46"><p><xref href="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita#GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815/GUID-7D502FF8-AE94-529D-A4E5-72C8CE7C211A">Group EHalGroupVariant</xref>  </p> </li>
+<li id="GUID-79BB470B-DFBE-50D0-A31A-C321F9426342"><p><xref href="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita#GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815/GUID-D3629B44-AAA7-5396-82A3-15FEF12E722D">Group EHalGroupPower</xref>  </p> </li>
+<li id="GUID-7C43081C-E67E-5337-A902-1BD9C2008B65"><p><xref href="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita#GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815/GUID-703AC577-D3C8-52B9-A586-2FFFDB9856B3">Group EHalGroupDisplay</xref>  </p> </li>
+<li id="GUID-05998CEA-D718-5A02-97B7-253BB1E91C91"><p><xref href="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita#GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815/GUID-A910FD8A-CF4B-559A-B43F-634D91E5DB1B">Group EHalGroupDigitiser</xref>  </p> </li>
+<li id="GUID-42BEC6A7-CB06-59C6-BF35-66AD4DE93C1F"><p><xref href="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita#GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815/GUID-C1F73889-85EC-573F-B2DB-5E61B3B633AC">Group EHalGroupKeyboard</xref>  </p> </li>
+<li id="GUID-7C262D60-E72D-5C11-8D19-BC2D05E9B04D"><p><xref href="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita#GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815/GUID-C6EDF013-7F3D-5FE4-A67F-F75B5946E4E7"> Group EHalGroupKernel</xref>  </p> </li>
+<li id="GUID-F2E3ECDE-9557-5ADB-B6A1-E67C599C1BA3"><p><xref href="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita#GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815/GUID-C757F468-2257-5D6A-BE81-BAA73038E4BD">Group EHalGroupMedia</xref>  </p> </li>
+<li id="GUID-93368B58-473E-52C9-9FBD-108E1D90579D"><p><xref href="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita#GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815/GUID-C63D903F-17FC-5D70-A8C5-B657D07BC792">Group EHalGroupEmulator</xref>  </p> </li>
+<li id="GUID-C702DE86-DFBF-5454-9705-CE9FF9DD26B2"><p><xref href="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita#GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815/GUID-E261AF53-3B72-53A9-90C0-CA915F58CDC8">Group EHalGroupSound</xref>  </p> </li>
+<li id="GUID-9E686382-7D63-54EC-8B75-EB42CA5AAB90"><p><xref href="GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815.dita#GUID-E49A8036-EACF-5181-91DA-AE89D3B6E815/GUID-B586EA0D-5DAF-506D-9495-EF30ED2E8456">Group EHalGroupMouse</xref>  </p> </li>
+</ul>
+<section id="GUID-7D502FF8-AE94-529D-A4E5-72C8CE7C211A"><title>Group EHalGroupVariant</title> <table id="GUID-21B9B1C9-E233-5C7F-9E9E-3B51E42578FB">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Attribute</b>  </p> </entry>
+<entry><p> <b>Function ID</b> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C008B391-2DCC-3EED-9B3F-4690A1CD5B35.dita"><apiname>ECPUSpeed</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-89F7F9F7-C096-3979-A255-A903DC9ED382.dita"><apiname>EVariantHalVariantInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-F700FA31-C4A0-30CD-B923-E345D5358FCC.dita"><apiname>ELEDs</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-89F7F9F7-C096-3979-A255-A903DC9ED382.dita"><apiname>EVariantHalVariantInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-5F3656D0-1B01-3BEE-9A1A-F6CEFFD84162.dita"><apiname>ELEDmask</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-900E5A8F-CF7B-3E15-B3C9-E1931E3F9A3D.dita"><apiname>EVariantHalLedMaskSet</apiname></xref>  </p> <p> <xref href="GUID-F9F43170-DE8B-3EB7-804B-4FF4EC4BBFF4.dita"><apiname>EVariantHalLedMaskGet</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-661716C0-15C0-391B-884C-B30D81B9BD9B.dita"><apiname>ESwitches</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-24210FCB-1F17-32E1-A506-D64A026BFBA6.dita"><apiname>EVariantHalSwitches</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-FB10392D-ECC3-35C3-83DB-3D5A218333F7.dita"><apiname>EDebugPort</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-CFB48CE0-5F92-3F8B-9109-74022C3CECB2.dita"><apiname>EVariantHalDebugPortSet</apiname></xref>  </p> <p> <xref href="GUID-33A87F89-BA1E-3037-B9E1-A79788D8664D.dita"><apiname>EVariantHalDebugPortGet</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-077497C9-C001-3837-A0CC-5848DBA5F80B.dita"><apiname>ECustomRestart</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-DF323606-1E73-3357-9B66-2CF994971EF9.dita"><apiname>EVariantHalCustomRestart</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-97505653-A2AC-376D-998E-99D0053175B5.dita"><apiname>ECustomRestartReason</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-7D96F298-79A9-3D17-8E5C-4E7EC774E57F.dita"><apiname>EVariantHalCustomRestartReason</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p><xref href="GUID-2545BD12-D36A-326E-8453-75DEBBA4BCC5.dita"><apiname>ECpuProfilingDefaultInterruptBase</apiname></xref></p></entry>
+<entry><p><xref href="GUID-47F724F6-F74D-33FF-9078-8C3894002DFD.dita"><apiname>EVariantHalProfilingDefaultInterruptBase</apiname></xref></p></entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-D3629B44-AAA7-5396-82A3-15FEF12E722D"><title>Group EHalGroupPower</title> <table id="GUID-60BD267B-DDD0-5C69-B4F5-54F2B868B4BB">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Attribute</b>  </p> </entry>
+<entry><p> <b>Function ID</b> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-2B7F6316-4A0E-3608-89F9-51D312791849.dita"><apiname>EPowerGood</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-B38AC3EC-0B82-3DDA-881E-A80871BFC188.dita"><apiname>EPowerHalSupplyInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-7CA6FBC0-D49C-3C98-AFC6-CF0E36FB0A45.dita"><apiname>EPowerBatteryStatus</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-B38AC3EC-0B82-3DDA-881E-A80871BFC188.dita"><apiname>EPowerHalSupplyInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A50F2224-A8ED-341A-AC7B-BA61C010F546.dita"><apiname>EAccessoryPower</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-36A9D4A1-06C8-3138-9476-6310BD15599D.dita"><apiname>EPowerHalAcessoryPowerPresent</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-3EF9A25D-0CAE-355C-B6D6-0A6E63673C06.dita"><apiname>EPowerBackup</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-C5CA3D6C-3838-3CB9-AD9F-5596FF5E458E.dita"><apiname>EPowerHalBackupPresent</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-39E73240-54CB-3FC4-A2A7-8E711F85DD8D.dita"><apiname>EPowerBackupStatus</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-B38AC3EC-0B82-3DDA-881E-A80871BFC188.dita"><apiname>EPowerHalSupplyInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A8605C00-42C4-35C0-81BC-1B8A1664D24A.dita"><apiname>EPowerExternal</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-B38AC3EC-0B82-3DDA-881E-A80871BFC188.dita"><apiname>EPowerHalSupplyInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-4B18C01A-1764-38C4-B0B5-C95B8C1AFEF4.dita"><apiname>EPenDisplayOn</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-E0507A29-439B-3E26-82AE-0EEF7542F41E.dita"><apiname>EPowerHalSetPointerSwitchesOn</apiname></xref>  </p> <p> <xref href="GUID-03757103-EDB5-3C2E-ADA9-D4C3BB08049D.dita"><apiname>EPowerHalPointerSwitchesOn</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-29AF7D90-9DB4-37DF-A43C-23453967A75A.dita"><apiname>ECaseSwitchDisplayOn</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-3E0A43D4-326F-3365-97CD-7788947BC074.dita"><apiname>EPowerHalSetCaseOpenSwitchesOn</apiname></xref>  </p> <p> <xref href="GUID-25603B1D-DE3F-32B2-9AC6-8BA510B73A2E.dita"><apiname>EPowerHalCaseOpenSwitchesOn</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-42C677ED-A31C-3A67-BD1B-883D813A8229.dita"><apiname>ECaseSwitchDisplayOff</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-CE43E78F-7692-3388-8D8D-80EC880FF702.dita"><apiname>EPowerHalSetCaseCloseSwitchesOff</apiname></xref>  </p> <p> <xref href="GUID-64CA74AA-C0F6-3B8F-B829-07128A4A69DB.dita"><apiname>EPowerHalCaseCloseSwitchesOff</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-BDDA830C-A738-3C7E-9D87-7AFBA275AD5B.dita"><apiname>EPowerHalOnOffInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-374F41E9-1F4F-3E6F-B587-E78D007E4121.dita"><apiname>EPowerHalSetAutoSwitchOffBehavior</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-5AF8F0F8-4189-33B8-87BC-78B90A4CCB7E.dita"><apiname> EPowerHalAutoSwitchOffBehavior</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-2F6F3944-6FAA-377C-932B-AE4FF09914D6.dita"><apiname>EPowerHalSetAutoSwitchOffTime</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-D4F68E15-71A7-314F-B6CE-DB0E2121FB8D.dita"><apiname>EPowerHalAutoSwitchOffTime</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-229907C3-0326-31B1-9B6A-B22F2BB28857.dita"><apiname>EPowerHalResetAutoSwitchOffTimer</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-58BEC503-6EC8-3E29-897A-EA4CB2AB82F1.dita"><apiname>EPowerHalSwitchOff</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-DA6AAC17-9183-3D85-8035-26CDE3F9DC27.dita"><apiname>EPowerHalSetBatteryType</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-BC6E579D-A614-39FA-8F6E-E871194D3D43.dita"><apiname>EPowerHalBatteryType</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-4CF6286A-F58D-312C-B422-3A5358F7F940.dita"><apiname> EPowerHalSetBatteryCapacity</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-9009B01E-D247-33A2-8891-661B74EF78F6.dita"><apiname>EPowerHalBatteryCapacity</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-3D25759B-102F-3F83-A15B-293EBEC63E52.dita"><apiname>EPowerHalAutoSwitchOffType</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-454FF1A2-0868-37E2-8EB0-F183C4C0070A.dita"><apiname>EPowerHalTestBootSequence</apiname></xref>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-703AC577-D3C8-52B9-A586-2FFFDB9856B3"><title>Group EHalGroupDisplay</title> <table id="GUID-1B2D86F7-95CE-5B91-8331-3648919E8A90">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Attribute</b>  </p> </entry>
+<entry><p> <b>Function ID</b> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-498E2E94-2232-3C97-9957-57192D43D1E3.dita"><apiname>EDisplayContrast</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-C5B5A001-04B9-3039-AF50-20F67AB9635D.dita"><apiname>EDisplayHalSetDisplayContrast</apiname></xref>  </p> <p> <xref href="GUID-DCC748C3-B9C3-389D-9905-FC63C4D81D66.dita"><apiname>EDisplayHalDisplayContrast</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-DEEDAD63-57EB-3FFC-9D1C-5AD32C424879.dita"><apiname>EDisplayBrightness</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-41EE4201-0EA7-3640-A728-74D7E560146C.dita"><apiname>EDisplayHalSetDisplayBrightness</apiname></xref>  </p> <p> <xref href="GUID-58D24B40-57D0-3657-A75F-E51E2138D474.dita"><apiname>EDisplayHalDisplayBrightness</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-AB833EAE-451C-36D3-BE29-97AA8559EC19.dita"><apiname>EDisplayPaletteEntry</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-3297DCF2-AD10-3CC6-B88F-2ABB01DE0643.dita"><apiname>EDisplayHalSetPaletteEntry</apiname></xref>  </p> <p> <xref href="GUID-B3D920E2-499D-3BF4-B466-65F83777A602.dita"><apiname>EDisplayHalPaletteEntry</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-8518DC83-22B7-3337-BF09-C82B344F63E5.dita"><apiname>EDisplayNumModes</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-354A771C-34E3-3B66-9EA1-28794E57A141.dita"><apiname>EDisplayHalModeCount</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-CD7F9648-57DA-33C1-AFAC-B00316F70078.dita"><apiname>EDisplayState</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-D4076CFE-7464-37F2-A8D3-2BD6CC3B854D.dita"><apiname>EDisplayHalSetState</apiname></xref>  </p> <p> <xref href="GUID-00EB15A7-8CD1-325D-AC50-6FD95679E97B.dita"><apiname>EDisplayHalState</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-E5187C28-8FC3-3E54-86A6-8435959537DA.dita"><apiname>EDisplayColors</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-23B804E2-E5D7-3847-A195-6C387B926CBC.dita"><apiname>EDisplayHalColors</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-815A521C-9765-33A5-805E-B7DD7B2F627D.dita"><apiname>EDisplayBrightnessMax</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-FC88C751-B431-3092-AAFD-ACCE217C5C69.dita"><apiname>EDisplayHalMaxDisplayBrightness</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-D5B88D37-AC78-3F7F-889A-4E5024B24330.dita"><apiname>EDisplayContrastMax</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-28E0DF1E-8951-30E7-8BC5-BB45F55D780D.dita"><apiname>EDisplayHalMaxDisplayContrast</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-D8D50F6D-DECC-3909-820B-6CD76638EE17.dita"><apiname>EDisplayXPixels</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-BFD11038-20E9-356A-9F52-B3B8416F7CCC.dita"><apiname>EDisplayHalCurrentModeInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-0B16DD4F-4316-358C-914A-F595B71B69E5.dita"><apiname>EDisplayYPixels</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-BFD11038-20E9-356A-9F52-B3B8416F7CCC.dita"><apiname>EDisplayHalCurrentModeInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-78DA31E4-B480-3E08-9683-8E15F3481BB2.dita"><apiname>EDisplayXTwips</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-BFD11038-20E9-356A-9F52-B3B8416F7CCC.dita"><apiname>EDisplayHalCurrentModeInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-D11C8614-F30A-37A1-8A0B-A238229EF1A6.dita"><apiname>EDisplayYTwips</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-BFD11038-20E9-356A-9F52-B3B8416F7CCC.dita"><apiname>EDisplayHalCurrentModeInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-CD04674B-AB14-38AD-AC53-58F018F23A42.dita"><apiname>EDisplayMemoryAddress</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-BFD11038-20E9-356A-9F52-B3B8416F7CCC.dita"><apiname>EDisplayHalCurrentModeInfo</apiname></xref>  </p> <p> <xref href="GUID-80C31E7F-9DA0-37D8-8354-C964AFA7A4F7.dita"><apiname>EDisplayHalGetDisplayMemoryAddress</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-9FC1D3F3-A1EC-3792-A4E3-52DDB365C382.dita"><apiname>EDisplayIsPixelOrderRGB</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-BFD11038-20E9-356A-9F52-B3B8416F7CCC.dita"><apiname>EDisplayHalCurrentModeInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-9C548FD0-ECA5-37C3-8D7E-70C9CCE9A777.dita"><apiname>EDisplayIsPixelOrderLandscape</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-BFD11038-20E9-356A-9F52-B3B8416F7CCC.dita"><apiname>EDisplayHalCurrentModeInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C0C91CB7-D344-3463-B991-BE52B8747414.dita"><apiname>EDisplayMemoryHandle</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-F4E52933-C4A9-30C4-BD87-A169F8668516.dita"><apiname>EDisplayHalGetDisplayMemoryHandle</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-D832D912-F2AF-378B-A253-4C887064869E.dita"><apiname>EBacklight</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-FBEDF845-B0A4-3989-9B39-03068001FEA6.dita"><apiname>EDisplayHalBacklightOn</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-0C4BA719-B9BE-30EE-8A09-A841586AB591.dita"><apiname>EBacklightState</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-7F46D65A-2530-3DC0-9F0E-E919FE65B1FF.dita"><apiname>EDisplayHalSetBacklightOn</apiname></xref>  </p> <p> <xref href="GUID-FBEDF845-B0A4-3989-9B39-03068001FEA6.dita"><apiname>EDisplayHalBacklightOn</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-7B48EE15-528B-3315-A35A-08F8C2A1D76C.dita"><apiname>EDisplayHalScreenInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-4CDA60AF-FDCA-3D53-8203-7471DE542CF4.dita"><apiname>EDisplayHalWsRegisterSwitchOnScreenHandling</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-142025D1-5606-3D30-8C2A-F162C35BAB50.dita"><apiname> EDisplayHalWsSwitchOnScreen</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-C6867675-EDA6-3000-A153-3FB4EF3C6A0E.dita"><apiname> EDisplayHalSetBacklightBehavior</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-90DB0BBB-1314-3D30-B824-8F2989457941.dita"><apiname> EDisplayHalBacklightBehavior</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-A139BD32-B00F-3382-B331-128955028767.dita"><apiname>EDisplayHalSetBacklightOnTime</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-7AB811A6-5F36-389A-AEA6-15FDCD22D768.dita"><apiname>EDisplayHalBacklightOnTime</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-C4C17524-CC23-3CBC-9E86-730EC20ADEB1.dita"><apiname>EDisplayHalBlockFill</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-1F42DC15-07B9-383F-9EC1-BEBFBE422ED8.dita"><apiname>EDisplayHalBlockCopy</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-C5F8B493-BAB5-3ADE-B76A-F4EDF9C4D6E7.dita"><apiname> EDisplayHalSecure</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-CD174A82-FEA7-35B8-9DD1-9BD9FE8A83E1.dita"><apiname>EDisplayHalSetSecure</apiname></xref>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-A910FD8A-CF4B-559A-B43F-634D91E5DB1B"><title>Group EHalGroupDigitiser</title> <table id="GUID-90C55B5A-CDFA-515D-8D3C-06CDD9409A7B">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Attribute</b>  </p> </entry>
+<entry><p> <b>Function ID</b>) </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-496368DD-3299-348C-BF9A-4F468894265F.dita"><apiname>EPen</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-954DF648-874F-3C2B-89A1-10673EE1AC78.dita"><apiname>EDigitiserHalXYInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-696EDBEB-76B2-3F02-AD33-BA4977551F32.dita"><apiname>EPenX</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-954DF648-874F-3C2B-89A1-10673EE1AC78.dita"><apiname>EDigitiserHalXYInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-3E3B49CC-53F6-3341-A969-1DDC0A837B0B.dita"><apiname>EPenY</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-954DF648-874F-3C2B-89A1-10673EE1AC78.dita"><apiname>EDigitiserHalXYInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-16B3C7A7-99B0-3F58-BDC0-95F5D3B76966.dita"><apiname>EPenState</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-72B40361-398E-3E03-9157-B6871836B4EE.dita"><apiname>EDigitiserHalSetXYState</apiname></xref>  </p> <p> <xref href="GUID-35E06851-F4AF-3D08-8E71-67F103EC2AED.dita"><apiname>EDigitiserHalXYState</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-985048BC-704E-3F2B-9292-23AAD8C9B8C2.dita"><apiname>EDigitiserHalSetXYInputCalibration</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-A6C2115F-7BEC-3B0E-A158-0EC321E5DBD6.dita"><apiname>EDigitiserHalCalibrationPoints </apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-2ABBC383-980A-3BD0-8207-120F97A14F9F.dita"><apiname>EDigitiserHalSaveXYInputCalibration</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attributes</i>  </p> </entry>
+<entry><p> <xref href="GUID-AE6CC468-F55B-32EB-916C-46C74B7B12A8.dita"><apiname>EDigitiserHalRestoreXYInputCalibration</apiname></xref>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-C1F73889-85EC-573F-B2DB-5E61B3B633AC"><title>Group EHalGroupKeyboard</title> <table id="GUID-6445B8E8-EE24-51B6-86AB-B9D1C6B4C231">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Attribute</b>  </p> </entry>
+<entry><p> <b>Function ID</b> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-E900BEFD-B75C-30B5-A0AB-42B98258F210.dita"><apiname>EKeyboardState</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-C70E5726-4213-339A-A4C2-75B5B19EFA01.dita"><apiname>EKeyboardHalSetKeyboardState</apiname></xref>  </p> <p> <xref href="GUID-536765A0-21F5-3A84-ACAE-D205CD2322BA.dita"><apiname>EKeyboardHalKeyboardState</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-325AF41F-5760-3B7C-B658-60D3EA01ED13.dita"><apiname>EKeyboard</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-B6223CCA-848D-3CED-9D81-7B78FB5C500C.dita"><apiname>EKeyboardHalKeyboardInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-C97FB1E9-5A09-32FE-B6CB-C825A158515F.dita"><apiname>EKeyboardDeviceKeys</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-B6223CCA-848D-3CED-9D81-7B78FB5C500C.dita"><apiname>EKeyboardHalKeyboardInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-999CA66F-F297-3FA8-86C5-00A56E067600.dita"><apiname>EKeyboardAppKeys</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-B6223CCA-848D-3CED-9D81-7B78FB5C500C.dita"><apiname>EKeyboardHalKeyboardInfo</apiname></xref>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-C6EDF013-7F3D-5FE4-A67F-F75B5946E4E7"><title>Group EHalGroupKernel</title> <p>This
+group is defined as internal and is listed here for information purposes only.
+However, the attributes are public. </p> <table id="GUID-DB43ED73-C184-51F5-B736-FF94C77CD014">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Attribute</b>  </p> </entry>
+<entry><p> <b>Function ID</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-E6063C77-07FB-32B7-A34B-50BC9DC06FF9.dita"><apiname>ESystemStartupReason</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-713D46B5-F7DA-302F-AFBF-31FF18CB0F56.dita"><apiname>EKernelHalStartupReason</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-33538F27-1F8D-38A9-8779-CAF775F85D14.dita"><apiname>ESystemException</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-30114D91-8520-3E72-8388-844C7AD323C3.dita"><apiname>EKernelHalExceptionId</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-77C904C0-972A-3251-89B4-27400E55396D.dita"><apiname>EMemoryRAM</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-5CF4B892-AB87-3EE4-8124-C31AA3CF7D4B.dita"><apiname>EKernelHalMemoryInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B0803465-795B-3A46-8783-9F52A2ABE404.dita"><apiname>EMemoryRAMFree</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-5CF4B892-AB87-3EE4-8124-C31AA3CF7D4B.dita"><apiname>EKernelHalMemoryInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6BC3412E-CB18-36E2-AE80-3C79D97F2428.dita"><apiname>EMemoryROM</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-5CF4B892-AB87-3EE4-8124-C31AA3CF7D4B.dita"><apiname>EKernelHalMemoryInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-9FBD7229-A2B3-35E7-89D3-4FE87B464D36.dita"><apiname>EFastCounterFrequency</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-D51A3BF1-4530-38F7-9512-7C24FC9E38EA.dita"><apiname>EKernelHalFastCounterFrequency</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-E61E19CA-27B7-3BE6-B659-7B955C8D4592.dita"><apiname>ENanoTickPeriod</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-15FA2541-7B5D-3E39-8552-8A68D13596DB.dita"><apiname>EKernelHalNTickPeriod</apiname></xref>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-C757F468-2257-5D6A-BE81-BAA73038E4BD"><title>Group EHalGroupMedia</title> <table id="GUID-6DF32932-BF19-5FBC-A82C-8FF65BEFFC8D">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Attribute</b>  </p> </entry>
+<entry><p> <b>Function ID</b> </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attribute</i> - the group and function ID pair is used internally. </p> </entry>
+<entry><p> <xref href="GUID-778B97C0-1519-3C22-8E34-2246982B7A9E.dita"><apiname>EMediaHalDriveInfo</apiname></xref>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-C63D903F-17FC-5D70-A8C5-B657D07BC792"><title>Group EHalGroupEmulator</title> <p>This
+group is defined as internal and is listed here for information purposes only.
+However, the attributes are public. </p> <table id="GUID-B1A281C1-2EF6-54BD-8AD8-A2A4D9A7B585">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Attribute</b>  </p> </entry>
+<entry><p> <b>Function ID</b> </p> </entry>
+</row>
+<row>
+<entry><p> <i>No attribute</i> - the group and function ID pair is used internally. </p> </entry>
+<entry><p> <xref href="GUID-6AADB8A0-D498-35C4-92F2-7AA10D9317B8.dita"><apiname>EEmulatorHalStringProperty</apiname></xref>  </p> <p> <xref href="GUID-FBC291BE-B12E-3D4F-91CF-7DB4AC0A6F27.dita"><apiname>EEmulatorHalIntProperty</apiname></xref>  </p> <p> <xref href="GUID-53A12DF2-451E-3185-B73E-6E050722F0F6.dita"><apiname>EEmulatorHalBoolProperty</apiname></xref>  </p> <p> <xref href="GUID-86B20C51-14D1-3BBE-8D3F-5503CE955555.dita"><apiname>EEmulatorHalMapFilename</apiname></xref>  </p> <p> <xref href="GUID-CBC9E587-23C9-3FDD-A14A-D745938A13CC.dita"><apiname>EEmulatorHalColorDepth</apiname></xref>  </p> <p> <xref href="GUID-D3267AFE-05E1-3396-A337-66A3552E2D84.dita"><apiname>EEmulatorHalSetFlip</apiname></xref>  </p> <p> <xref href="GUID-4289AFC4-BFFB-3D6F-BF04-CED9797E4228.dita"><apiname>EEmulatorHalCPUSpeed</apiname></xref>  </p> <p> <xref href="GUID-9D7F12CF-697C-3EAA-A6C1-DD3D101544B8.dita"><apiname>EEmulatorHalNumberOfScreens</apiname></xref>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-E261AF53-3B72-53A9-90C0-CA915F58CDC8"><title>Group EHalGroupSound</title> <table id="GUID-58C84F00-F381-5109-A12C-18BDEC36C0BC">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Attribute</b>  </p> </entry>
+<entry><p> <b>Function ID</b> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-9A4088C1-5B67-3795-8AC1-486DC527CB5A.dita"><apiname>EKeyboardClick</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-93450BD1-79E1-3923-8ED2-02CA23CCF337.dita"><apiname>ESoundHalKeyClickEnabled</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-113C7F8A-3FFC-3AE4-9BD7-35D8C3D0230A.dita"><apiname>EKeyboardClickVolumeMax</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-C311824E-3FB9-3B56-98E8-88B42617C715.dita"><apiname>ESoundHalKeyClickVolumeMax</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-6604666B-D049-3C78-A7B7-915602445F66.dita"><apiname>EKeyboardClickState</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-D77E06E6-9574-3779-A4F6-2366A65B51DD.dita"><apiname>ESoundHalSetKeyClickEnabled</apiname></xref>  </p> <p> <xref href="GUID-93450BD1-79E1-3923-8ED2-02CA23CCF337.dita"><apiname>ESoundHalKeyClickEnabled</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-FDF8DCC7-2EEF-322B-9DFC-20187A65F263.dita"><apiname>EKeyboardClickVolume</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-C311824E-3FB9-3B56-98E8-88B42617C715.dita"><apiname>ESoundHalKeyClickVolumeMax</apiname></xref>  </p> <p> <xref href="GUID-65500DD7-EC42-38EE-8C37-6115628F3F31.dita"><apiname>ESoundHalSetKeyClickLoud</apiname></xref>  </p> <p> <xref href="GUID-4CCFD899-2E19-3399-919F-98D636279608.dita"><apiname>ESoundHalKeyClickLoud</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-9570B788-B927-33E8-A46A-0E6C7076663D.dita"><apiname>EPenClick</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-07AE3350-9601-35E3-A322-652D4BBA94D8.dita"><apiname>ESoundHalPointerClickEnabled</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-F8C39587-718E-33B2-B994-AD482AD3A55E.dita"><apiname>EPenClickVolumeMax</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-DCF12E0D-FF8F-3FBF-85C6-C12351D8A360.dita"><apiname>ESoundHalPointerClickVolumeMax</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-868B1549-AC92-3C60-8C01-25494E84C2B0.dita"><apiname>EPenClickState</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-FBE2FD0A-B109-3DDB-A5B4-95A437309DB8.dita"><apiname>ESoundHalSetPointerClickEnabled</apiname></xref>  </p> <p> <xref href="GUID-07AE3350-9601-35E3-A322-652D4BBA94D8.dita"><apiname>ESoundHalPointerClickEnabled</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-D4D5BE09-025C-3DF7-B3D7-4C9FB43C1F96.dita"><apiname>EPenClickVolume</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-DCF12E0D-FF8F-3FBF-85C6-C12351D8A360.dita"><apiname>ESoundHalPointerClickVolumeMax</apiname></xref>  </p> <p> <xref href="GUID-65B7029A-0DC3-349A-B539-D9F6CA1881A2.dita"><apiname>ESoundHalSetPointerClickLoud</apiname></xref>  </p> <p> <xref href="GUID-C04564C0-D67C-3E99-985F-8D68767D7002.dita"><apiname>ESoundHalPointerClickLoud</apiname></xref>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-B586EA0D-5DAF-506D-9495-EF30ED2E8456"><title>Group EHalGroupMouse</title> <table id="GUID-612E6AE0-810D-5F82-90C8-60787FE9EE71">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Attribute</b>  </p> </entry>
+<entry><p> <b>Function ID</b> </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-20DF5BD6-FC41-3FA1-A2E1-7BA4E87E19EA.dita"><apiname>EMouse</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-A87E298C-3BAE-3BBF-966D-62220B9D5DFA.dita"><apiname>EMouseHalMouseInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B237D2A9-4FB6-3E31-B2DC-A7F192A3CC58.dita"><apiname>EMouseX</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-A87E298C-3BAE-3BBF-966D-62220B9D5DFA.dita"><apiname>EMouseHalMouseInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-BFCAB446-6437-30B3-A694-507581D02220.dita"><apiname>EMouseY</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-A87E298C-3BAE-3BBF-966D-62220B9D5DFA.dita"><apiname>EMouseHalMouseInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-3BF11727-B366-338B-928B-109231CE0AC4.dita"><apiname>EMouseButtons</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-A87E298C-3BAE-3BBF-966D-62220B9D5DFA.dita"><apiname>EMouseHalMouseInfo</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-5A811DD8-586D-3390-9745-F0241E1DEF01.dita"><apiname>EMouseState</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-81BB4F41-14FB-3461-AC7A-736463565211.dita"><apiname>EMouseHalSetMouseState</apiname></xref>  </p> <p> <xref href="GUID-4289A281-333A-3818-9E06-E84BB3BC55F3.dita"><apiname>EMouseHalMouseState</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-D6FADD67-9D8C-3303-8BA7-7F2E707C9FC5.dita"><apiname>EMouseSpeed</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-221C9954-1498-3CF4-B76F-CC084A0B19D7.dita"><apiname>EMouseHalSetMouseSpeed</apiname></xref>  </p> <p> <xref href="GUID-B1C023A2-D1FB-3B16-895C-21FC049F79C5.dita"><apiname>EMouseHalMouseSpeed</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-E19D841B-01AE-3AC1-B4B3-9FC8B15B9478.dita"><apiname>EMouseAcceleration</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-BB759BAF-7785-3AEC-B350-83016D7B897F.dita"><apiname>EMouseHalSetMouseAcceleration</apiname></xref>  </p> <p> <xref href="GUID-D25387E0-97A2-3C07-A637-6FAEE5FA3584.dita"><apiname>EMouseHalMouseAcceleration</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-084393CE-012A-36DD-87FB-8820C56880A8.dita"><apiname>EMouseButtonState</apiname></xref>  </p> </entry>
+<entry><p> <i>Not supported</i>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E539FF7D-C221-4961-8227-9E94FBAA624C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E539FF7D-C221-4961-8227-9E94FBAA624C" xml:lang="en"><title>Time Implementation</title><shortdesc>Describes how to implement the Time platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E5459A54-14BC-55C1-B911-63415E4C61A6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E5459A54-14BC-55C1-B911-63415E4C61A6" xml:lang="en"><title>Concepts</title><shortdesc>This section describes the technology, architecture, and source
+code organization of the Base Starter.</shortdesc><prolog><metadata><keywords/></metadata></prolog><related-links>
+<link href="GUID-BFE1422D-3B4A-5B25-A757-B5B68D6390F8.dita"><linktext>Port   Implementation
+Tutorial</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,1012 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B" xml:lang="en"><title>Platform
+Specific Layer Implementation</title><shortdesc>Describes how to implement the Platform Specific Layer of the MMC
+Controller. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-4C6CA873-A798-5C79-8838-0CC3C9E914FB"><title>DMMCStack derived
+class</title> <p>This class controls access to the MultiMediaCard stack. This
+class has a number of pure virtual functions that need to be implemented in
+your Variant DLL. The diagram at <xref href="GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF.dita#GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF/GUID-92F5EBE4-C9AD-5D9A-A80E-9AFD1A09B6B3">MultiMediaCard
+controller basic structure</xref> shows the class in context. </p> <p>There
+is one virtual function with a default implementation that needs to be overridden. </p> <ul>
+<li id="GUID-01ABEA80-002F-5490-B90F-3AE83927220B"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-0B55A650-E9ED-56CB-B06F-B1113ACDF282">Init()</xref>  </p> </li>
+<li id="GUID-04245FCC-D55A-5840-98CC-2113E7B6D9E4"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-CEF0EDF7-4B33-5452-8635-51C5319F78AE">MachineInfo()</xref> </p> </li>
+<li id="GUID-C5C86175-9100-5687-96EB-F4AEAF0CE161"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-F41EA0A6-1CBF-5AE2-9C66-DD6E3B7312E0">ProgramPeriodInMilliSeconds()</xref>  </p> </li>
+<li id="GUID-12B3B751-9EFE-5273-844B-A18D99E2A7FF"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-A7EC6536-3822-58C8-9A65-B71FDDBA10F3">AdjustPartialRead()</xref> </p> </li>
+<li id="GUID-AF40CF60-918D-5D9D-96C3-D96FDAD94B85"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-8A3E9782-C8D4-562D-9470-5CCE0ED1C303">GetBufferInfo()</xref> </p> </li>
+<li id="GUID-60AC1F94-4936-5AB1-B31E-CEDBDE59E08E"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-BC742EB6-7063-5D00-B422-96B3772605D5">SetBusConfigDefaults()</xref> </p> </li>
+<li id="GUID-592CDEF6-F450-572A-878E-077ED633C621"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-49DF2E60-AE31-502E-B7CB-694AFAF69F1B">InitClockOff()</xref>  </p> </li>
+<li id="GUID-82080A27-BCB7-5EC3-8F3E-2C1CDEDCA601"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-0DF60D11-AAD6-59E2-AE81-16E0DF96291B">ASSPDisengage()</xref> </p> </li>
+<li id="GUID-5E0E9EC9-742A-5265-9429-C52B60D83863"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-99AC4F3B-E273-515E-8690-983E98E17256">ASSPReset()</xref> </p> </li>
+<li id="GUID-DA38EA59-0A91-5498-9B3A-1F17D4511EFC"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-6EEE7EF6-4272-5116-BCEF-A852BB7B8FBD">CardDetect()</xref> </p> </li>
+<li id="GUID-9F025A5A-F303-55C8-85C4-BAC0BF0C27E4"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-3F34865D-5B16-5F53-AF9E-9F52DB5D0FB5">WriteProtected()</xref> </p> </li>
+<li id="GUID-D1B3A73F-E3AC-55C6-84E4-11A2AA9C3A7F"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-65547330-E112-55F2-AD4A-9B9CA5617E33">DoPowerDown()</xref> </p> </li>
+<li id="GUID-4117DD14-59D4-5257-AAAD-79498391979E"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-C8C15101-4614-5DEC-A620-6EAE8EC463ED">DoPowerUpSM()</xref> </p> </li>
+<li id="GUID-D93B8DEC-CFA0-5FC9-AF46-81A3B21F3545"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-C976320E-80FF-50F8-A882-F89C74F76ED3">InitClockOnSM()</xref> </p> </li>
+<li id="GUID-F6BB7D3C-8A9A-5228-88ED-2F28980373D8"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-FABAED76-FC63-577B-9436-DC7C8978E2AE">IssueMMCCommandSM()</xref>  </p> </li>
+</ul> <p id="GUID-0B55A650-E9ED-56CB-B06F-B1113ACDF282"><b>Init()</b> </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-43A06EF7-FA7B-3653-97B4-B04336E3EB54"><apiname>DMMCStack::Init()</apiname></xref>  </p> <p>The
+function is intended to initialize the stack, and is called during initialization
+of the MultiMediaCard controller Variant DLL from <xref href="GUID-45B97680-1756-3559-8A2D-2F2E851AD6A7.dita#GUID-45B97680-1756-3559-8A2D-2F2E851AD6A7/GUID-18825E56-F155-38D0-A4DF-A7C57D73C1EF"><apiname>DMMCSocket::Init()</apiname></xref>: </p> <p>You
+will almost certainly need to provide your own implementation to perform any
+platform-specific MultiMediaCard stack initialization. Whatever your implementation
+provides, <i>it is important that you call the base class function from within
+your derived version</i>. </p> <p>Return <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref> if initialization
+is successful, otherwise return one of the system-wide error codes to indicate
+initialization failure. Note that returning a value other than <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref> will
+cause the kernel to panic and to fail to boot. </p> <p>You will allocate a
+data transfer buffer here. The MultiMediaCard media driver needs a memory
+buffer to perform data transfer operations. Where supported, DMA is generally
+used to do this, and requires physically contiguous memory. However, the media
+driver is created each time a card is inserted into a machine and destroyed
+when the card is removed, and giving the media driver the responsibility for
+allocating the memory buffer means that it might not always be possible to
+allocate physically contiguous pages for it as memory becomes fragmented over
+time. </p> <p>The MultiMediaCard media driver uses the <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-8A3E9782-C8D4-562D-9470-5CCE0ED1C303">GetBufferInfo()</xref> function each time it is created to get a pointer
+to the buffer, and to get its length. </p> <p>Although the MultiMediaCard
+media driver only expects a single buffer, it actually uses this as two separate
+buffers: </p> <ul>
+<li id="GUID-21E69407-DEB2-5DBE-9614-ADFF7DBF06B6"><p>a minor buffer which
+must have at least enough space for the MBR (512 bytes) </p> </li>
+<li id="GUID-1FF25456-0CE3-582C-9FEC-B5913C1E437A"><p>a cache buffer to cache
+data blocks from the card. </p> </li>
+</ul> <p>The ideal size of the cache buffer depends on the characteristics
+of the card present at the time, and it is possible to customize the MultiMediaCard
+controller at the platform specific layer for a particular card. </p> <p>The
+following example code allocates a physically contiguous buffer - a minor
+buffer size of one block is allocated together with a cache buffer size of
+eight blocks. The whole buffer is then rounded up to a whole number of memory
+pages. </p> <codeblock id="GUID-B01B50BE-6574-5A81-BA25-8FDFEB2C5620" xml:space="preserve">// The constant calculations could be explicitly folded, but this illustrates
+// how the values are derived.
+const TUint blkSzLog2 = 9;                    
+const TUint blkSz = 1 &lt;&lt; blkSzLog2;
+const TInt minorBufLen = Max(KDiskSectorSize, blkSz);
+
+const TInt KMinBlocksInBuffer = 8;
+const TInt cchBufLen = KMinBlocksInBuffer &lt;&lt; blkSzLog2;
+
+TInt totalBufLen = minorBufLen + cchBufLen;
+
+// Allocate contiguous physical memory
+totalBufLen = Kern::RoundToPageSize(totalBufLen);
+
+TPhysAddr physAddr = 0;
+r = Epoc::AllocPhysicalRam(totalBufLen, physAddr);
+__KTRACE_OPT(KHARDWARE, Kern::Printf("mmc:ini:physical = %08x", physAddr));
+if (r != KErrNone)
+    {
+    return r;
+    }
+
+DPlatChunkHw* bufChunk = NULL;
+r = DPlatChunkHw::New(bufChunk, physAddr, totalBufLen, EMapAttrCachedWBRA|EMapAttrSupRw);
+
+if(r != KErrNone)
+    {
+    if (physAddr)
+        {
+        Epoc::FreePhysicalRam(physAddr, totalBufLen);
+        }
+    return r;
+    }
+          
+iMDBuf = reinterpret_cast&lt;TUint8*&gt;(bufChunk-&gt;LinearAddress());
+iMDBufLen = totalBufLen;
+</codeblock> <p id="GUID-CEF0EDF7-4B33-5452-8635-51C5319F78AE"><b>MachineInfo()</b> </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-3E5532A5-4645-3F77-A7A9-7AFF334FA5A4"><apiname>DMMCStack::MachineInfo()</apiname></xref>  </p> <p>The
+function returns configuration information for the MultiMediaCard stack. </p> <p>The
+function takes a reference to a <xref href="GUID-3F9D89E8-44F0-35B3-9404-6CCAC79763E8.dita"><apiname>TMMCMachineInfo</apiname></xref> object,
+and your implementation must fill the public data members of the object. </p> <p id="GUID-F41EA0A6-1CBF-5AE2-9C66-DD6E3B7312E0"><b>ProgramPeriodInMilliSeconds()</b> </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-C0998F1F-EE3B-32C1-9898-288EA1D71AC0"><apiname>DMMCStack::ProgramPeriodInMilliSeconds()</apiname></xref>  </p> <p>When a data block is written to a card, the data is read into an
+internal buffer on the card and is then programmed into the payload memory.
+While the card is in <i>programming mode</i>, it cannot be read from, or written
+to, but it is possible to query its status using CMD13. </p> <p>Immediately
+after a block of data is written by <codeph>CIMReadWriteBlocksSM()</codeph>,
+the MultiMediaCard controller requests the card's state using CMD13. If the
+card is still in the programming state, then the state machine <codeph>ProgramTimerSM()</codeph> launches
+a timer with the period returned by <codeph>ProgramPeriodInMilliSeconds()</codeph>.
+The state of the card is periodically checked until it is no longer in programming
+mode. </p> <p>For platforms that do not provide an interrupt to indicate when
+programming mode is finished, <codeph>ProgramPeriodInMilliSeconds()</codeph> should
+return the interval, in milliseconds, to be used by the poll timer. </p> <p id="GUID-A7EC6536-3822-58C8-9A65-B71FDDBA10F3"><b>AdjustPartialRead()</b> </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-7FEC1574-5448-3DF5-8BD2-AABDBD0211C3"><apiname>DMMCStack::AdjustPartialRead()</apiname></xref>  </p> <p>Some
+cards support a partial read feature, which is indicated by the <codeph>READ_BL_PARTIAL</codeph> bit
+in the <codeph>CSD</codeph> register. When this is the case, it is possible
+to read a section within a single physical block, without having to read the
+entire block. </p> <p>The MultiMediaCard media driver uses this feature to
+read small amounts of data more quickly. However, many hardware implementations
+impose restrictions on the granularity of the data that can be read from the
+card. For example, they may use a 32-bit FIFO. </p> <p>This function allows
+you to enforce the limits imposed by the hardware. </p> <p>The <codeph>aStart</codeph> and <codeph>aEnd</codeph> arguments
+of <codeph>AdjustPartialRead()</codeph> define the range on the card from
+which the media driver would like to read. Your implementation should return
+in <codeph>*aPhysStart</codeph> and <codeph>*aPhysEnd</codeph> the range that
+the hardware will allow to be read. </p> <p>For example, to word align data,
+the function would be implemented using the following code: </p> <codeblock id="GUID-30DE526C-70C2-5118-BFBB-72759EFC8C93" xml:space="preserve">void AdjustPartialRead(const TMMCard* aCard, TUint32 aStart, TUint32 aEnd, TUint32* aPhysStart, TUint32* aPhysEnd);
+    {
+    ...
+    const TUint32 KWordMask = 3;
+    *aPhysStart = aStart &amp; ~KWordMask;
+    *aPhysEnd = (aEnd + KWordMask) &amp; ~KWordMask;
+    ...
+    }
+</codeblock> <p id="GUID-8A3E9782-C8D4-562D-9470-5CCE0ED1C303"><b>GetBufferInfo()</b> </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-EC9B740A-3A07-35AB-BACE-2EC1F96EEF0F"><apiname>DMMCStack::GetBufferInfo()</apiname></xref>  </p> <p>The
+MultiMediaCard media driver needs a memory buffer to perform data transfer
+operations, and this is, typically, allocated once only by the <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-0B55A650-E9ED-56CB-B06F-B1113ACDF282">Init()</xref> function when this stack object is initialized. </p> <p>The
+MultiMediaCard media driver is created each time a card is inserted into a
+machine and destroyed when the card is removed, and it uses this function,
+each time it is created to get a pointer to the memory buffer, and to get
+its length. The MultiMediaCard media driver then uses this buffer, over its
+lifetime, for data transfer operations. </p> <p id="GUID-BC742EB6-7063-5D00-B422-96B3772605D5"><b>SetBusConfigDefaults()</b> </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-C7297E13-5F78-396D-842B-FB16D3424374"><apiname>DMMCStack::SetBusConfigDefaults()</apiname></xref>  </p> <p>The function returns information about the MultiMediaCard bus configuration
+for this platform. </p> <p>The function takes a <xref href="GUID-F9432D7B-41C9-3048-AC50-B5BCF8BE11D0.dita"><apiname>TUint</apiname></xref> value
+containing the bus speed that the controller intends to use, and a reference
+to a <xref href="GUID-C0E2780A-47B3-31A2-827C-AF89C1B65F2E.dita"><apiname>TMMCBusConfig</apiname></xref> object. The implementation of this function
+must fill the public data members of this object. See the class reference
+documentation for the data members. </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita"><apiname>DMMCStack</apiname></xref> has
+two private data members of type <xref href="GUID-75FF770B-07D1-3C07-9577-5A37841E53E7.dita"><apiname>TMMCStackConfig</apiname></xref>: </p> <ul>
+<li id="GUID-A56BF364-F02F-54EA-80F8-E4AB5E7A10C9"><p> <codeph>iMasterConfig</codeph>  </p> </li>
+<li id="GUID-C94FFA4E-51C7-5CBA-BFBB-F692438412FE"><p> <codeph>iConfig</codeph>  </p> </li>
+</ul> <p>The information returned by the call to <codeph>SetBusConfigDefaults()</codeph> is
+stored in <codeph>iMasterConfig</codeph>'s <codeph>iBusConfig</codeph> private
+data member. </p> <p> <codeph>iMasterConfig</codeph> contains the master bus
+configuration settings for the platform. Each time a new session is made current,
+the master bus configuration settings are merged with the specific bus configuration
+settings for that session, (as set up in the public data member <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita#GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A/GUID-73BC8CE4-593E-3BAC-909A-FB8F419895C8"><apiname>DMMCSession::iConfig</apiname></xref>),
+and the result is stored in <codeph>iConfig</codeph>. It is these merged bus
+configuration settings that are used to configure the hardware interface.
+The platform specific layer can access these settings with a call to Master<xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-E0275614-109E-3803-A0AE-3313E1E0038B"><apiname>DMMCStack::BusConfig()</apiname></xref>. </p> <p> <codeph> SetBusConfigDefaults()</codeph> is called at two stages in the execution of the macro CIM_UPDATE_ACQ to
+update the <codeph>iMasterConfig</codeph> object. </p> <ul>
+<li id="GUID-5C98DB8C-60AF-5333-A250-5D6509D754E5"><p>First, it is called
+at the start of the card initialization stage with the bus speed argument, <codeph>aClock</codeph>,
+set to the fOD rate (400kHz). </p> </li>
+<li id="GUID-0CD15184-15F8-5104-908F-612CCBCA953A"><p>Second, it is called
+after the CSD registers for each card have been read with the bus speed argument, <codeph>aClock</codeph>,
+set to the slowest maximum transfer rate (TRAN_SPEED) reported by any of the
+CSD registers. </p> </li>
+</ul> <p id="GUID-49DF2E60-AE31-502E-B7CB-694AFAF69F1B"><b> InitClockOff()</b> </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-BF94B298-7F72-33F7-A2F0-F19807BF2CDC"><apiname>DMMCStack::InitClockOff()</apiname></xref>  </p> <p>Switches
+from identification mode of operation to data transfer mode operation. </p> <p>When
+this function is called, the clock information in the <codeph>iBusConfig</codeph> member
+(see <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-BC742EB6-7063-5D00-B422-96B3772605D5">SetBusConfigDefaults()</xref>)
+will not have been updated to the new data transfer rate. </p> <p>This function
+should, in general, just switch from open drain to push-pull bus mode, with
+the clock rate being changed at the start of <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-A48C1C16-B465-3DDA-9C83-00DEB8D27B68"><apiname>DMMCStack::IssueMMCCommandSM()</apiname></xref>,
+when <codeph>iBusConfig</codeph> will be valid. </p> <p id="GUID-0DF60D11-AAD6-59E2-AE81-16E0DF96291B"><b> ASSPDisengage()</b> </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-36C720F9-DEAF-3896-A12A-2AE2581AA347"><apiname>DMMCStack::ASSPDisengage()</apiname></xref>  </p> <p>This
+function is called by the platform independent layer each time a session has
+completed or has been aborted. </p> <p>The function gives the platform specific
+layer the chance to free resources or disable any activities that were required
+to perform the session. </p> <p>The implementation should not turn off the
+clock to the hardware interface as this will be turned off by the inactivity
+timer. Typically, the implementation disables DMA and interface interrupts,
+and forces the hardware interface into idle. </p> <p>At the end of your implementation,
+you must add a call <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-3DFCBE96-E9F3-3FF3-97BC-A3A3024089BD"><apiname>DMMCStack::ReportASSPDisengaged()</apiname></xref> to
+report to the platform independent layer that platform specific layer resources
+have been disengaged. </p> <p id="GUID-99AC4F3B-E273-515E-8690-983E98E17256"><b>ASSPReset()</b> </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-36D3F4D9-A2FC-3355-ABE0-31C9F7397E2D"><apiname>DMMCStack::ASSPReset()</apiname></xref>  </p> <p>This
+function is called by the platform independent layer when the current session
+is being aborted, and platform specific asynchronous activity is to be cancelled.
+The function may also be called by the platform specific layer as part of
+the <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-65547330-E112-55F2-AD4A-9B9CA5617E33">DoPowerDown()</xref> implementation. </p> <p>The function gives the platform specific layer the chance to stop all activities
+on the host stack. It will, in general, perform the same operations as <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-0DF60D11-AAD6-59E2-AE81-16E0DF96291B">ASSPDisengage()</xref> but,
+in addition, will turn off the clock to the hardware interface and release
+any requested power requirements made on the power model, i.e. release any
+power requirements made by <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-C976320E-80FF-50F8-A882-F89C74F76ED3">InitClockOnSM()</xref>. </p> <p>At the end of your implementation, you must add a call <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-3DFCBE96-E9F3-3FF3-97BC-A3A3024089BD"><apiname>DMMCStack::ReportASSPDisengaged()</apiname></xref> to
+report to the platform independent layer that platform specific layer resources
+have been disengaged. </p> <p id="GUID-6EEE7EF6-4272-5116-BCEF-A852BB7B8FBD"><b>CardDetect()</b> </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-02C4D1A0-6149-389D-9F31-3E7EBF1DCA66"><apiname>DMMCStack::CardDetect()</apiname></xref>  </p> <p>Implement
+this function to report whether a card is present in a specified card socket. </p> <p>This
+function takes a <xref href="GUID-F9432D7B-41C9-3048-AC50-B5BCF8BE11D0.dita"><apiname>TUint</apiname></xref> value containing the card socket
+that is to be queried. </p> <p id="GUID-3F34865D-5B16-5F53-AF9E-9F52DB5D0FB5"><b>WriteProtected()</b> </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-E7E97501-10E7-38E6-9F8C-2A62F260BA46"><apiname>DMMCStack::WriteProtected()</apiname></xref>  </p> <p>Implement
+this function to report whether a card in a specified card socket is mechanically
+write protected. </p> <p>This function takes a <xref href="GUID-F9432D7B-41C9-3048-AC50-B5BCF8BE11D0.dita"><apiname>TUint</apiname></xref> value
+containing the card socket that is to be queried. </p> <p id="GUID-65547330-E112-55F2-AD4A-9B9CA5617E33"><b>DoPowerDown()</b> </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-3E90AF73-F4D3-34C5-B6D3-6BF69C6137C8"><apiname>DMMCStack::DoPowerDown()</apiname></xref>  </p> <p>This
+function is called as part of the bus power down sequence: </p> <ul>
+<li id="GUID-E9E072D3-A2F7-5DD2-B7D9-A89840BBA914"><p>by the power model,
+in power standby and power emergency standby situations </p> </li>
+<li id="GUID-1EFB0616-45B9-5EC2-9456-54F7D10D2894"><p>when a door-open event
+occurs </p> </li>
+<li id="GUID-83F42DEB-C6EE-5558-8907-CFD141461456"><p>when the bus inactivity
+timer has timed out </p> </li>
+<li id="GUID-0EA77E57-E2D0-599D-8E90-ECE1D21BC329"><p>if a power supply unit
+(PSU) voltage check fails. </p> </li>
+</ul> <p>The function should stop all activities on the host stack, turn off
+the clock to the hardware interface and release any requested power requirements
+made on the power model. The function is very often implemented as a call
+of <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-99AC4F3B-E273-515E-8690-983E98E17256">ASSPReset()</xref>. </p> <p>The
+function should not turn off the MultiMediaCard power supply unit as this
+will be performed immediately afterwards by a call to the <xref href="GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B.dita#GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B/GUID-4DF0741F-B143-3B46-82BE-9CD0261C27E5"><apiname>DMMCPsu::DoSetState()</apiname></xref> derived
+class function from the platform independent layer. </p> <p id="GUID-C8C15101-4614-5DEC-A620-6EAE8EC463ED"><b> DoPowerUpSM()</b> </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-791BCA03-61F3-3C1C-BA2D-D633A94AF299"><apiname>DMMCStack::DoPowerUpSM()</apiname></xref>  </p> <p>This
+is a state machine function, called as a child function at the start of the <codeph>CIM_UPDATE_ACQ</codeph> macro
+state machine. </p> <p>The function should perform the necessary platform
+specific actions associated with powering up the bus. This includes turning
+on the MultiMediaCard PSU. However, the hardware interface clock should <i>not</i> be
+turned on as part of this function. </p> <p>If the controller has to request
+power resources from the power model, e.g. where a fast system clock is required
+all the time the bus is powered, then this state machine function can be used
+to wait asynchronously for this resource to become available. </p> <p>If the
+activity performed by this function completes successfully: </p> <ul>
+<li id="GUID-7C64DB32-139B-5F45-9F2C-6693F9E16F83"><p>it must call <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-40973A35-3A73-3DBD-9EB7-99CE55E6D694"><apiname>DMMCStack::ReportPowerUp()</apiname></xref>. </p> </li>
+<li id="GUID-42E872B5-EA6A-5901-AD93-5F9B99C81D69"><p>it returns <xref href="GUID-E7D46003-E502-39D1-AF52-83B87AE6930B.dita"><apiname>KMMCErrNone</apiname></xref>. </p> </li>
+</ul> <p>The function should return <xref href="GUID-E7D46003-E502-39D1-AF52-83B87AE6930B.dita"><apiname>KMMCErrNone</apiname></xref> if it completes
+successfully or one of the other <xref href="GUID-FF4AB1CF-7A2C-3FC6-B123-D6819E1BCDCA.dita"><apiname>TMMCErr</apiname></xref> error codes. </p> <p>See
+the general background information on <xref href="GUID-80E0DB93-A96A-54A8-A201-E11935418BE7.dita">the
+state machine</xref>. </p> <p id="GUID-C976320E-80FF-50F8-A882-F89C74F76ED3"><b>InitClockOnSM()</b> </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-7B91EF52-26E5-333C-A037-B142B492BCC4"><apiname>DMMCStack::InitClockOnSM()</apiname></xref>  </p> <p>This
+is a state machine function, called as part of the <codeph>CIM_UPDATE_ACQ</codeph> macro
+state machine. </p> <p>The function should turn on the clock to the hardware
+interface. The function is so named because this clock is always first turned
+on at the identification mode frequency. </p> <p>The function is implemented
+as a state machine function because it may be necessary to include a short
+delay after the clock has been turned on to allow it to stabilize. </p> <p>If
+it is necessary for the MultiMediaCard controller to request any power resources
+from the power model on this platform, for example, requesting a necessary
+system clock, then it should be performed as part of this function. In some
+cases, it may be necessary to wait for this power resource to become available. </p> <p>At
+the <i>beginning</i> of your implementation, you must add a call <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-D797747A-0AF6-36B1-BD92-3D6950A3B7B4"><apiname>DMMCStack::ReportASSPEngaged()</apiname></xref> to
+report to the platform independent layer that platform specific layer resources
+have been engaged. </p> <p>The function should return <xref href="GUID-E7D46003-E502-39D1-AF52-83B87AE6930B.dita"><apiname>KMMCErrNone</apiname></xref> if
+it completes successfully or one of the other <xref href="GUID-FF4AB1CF-7A2C-3FC6-B123-D6819E1BCDCA.dita"><apiname>TMMCErr</apiname></xref> error
+codes. </p> <p>Note: </p> <ul>
+<li id="GUID-2474710D-C595-5331-9182-A2EF97A1EB27"><p>the function is only
+called once for each invocation of the CIM_UPDATE_ACQ macro and the important
+thing to stress is that the interface clock is being turned on after a period
+when it has been off, and therefore often requires time to stabilize. </p> </li>
+<li id="GUID-FE92334D-757D-5C08-AF98-9E0912BA2820"><p>In the course of executing
+a session, the MultiMediaCard controller may switch the clock more than once
+between the identification mode frequency and the data transfer mode frequency,
+but this function only ever gets called once. </p> </li>
+</ul> <p>See the general background information on <xref href="GUID-80E0DB93-A96A-54A8-A201-E11935418BE7.dita">the
+state machine</xref>. </p> <p id="GUID-FABAED76-FC63-577B-9436-DC7C8978E2AE"><b> IssueMMCCommandSM()</b> </p> <p> <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-A48C1C16-B465-3DDA-9C83-00DEB8D27B68"><apiname>DMMCStack::IssueMMCCommandSM()</apiname></xref>  </p> <p>This
+is a <xref href="GUID-80E0DB93-A96A-54A8-A201-E11935418BE7.dita">state machine</xref> function
+that executes a single command over the bus. The implementation of this function
+is an important part in the process of porting the MultiMediaCard controller. </p> <p>The
+input parameters for the command are passed via the current command descriptor,
+an instance of the <xref href="GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A.dita"><apiname>TMMCCommandDesc</apiname></xref> class, on the session’s
+command stack. The parameters contain information such as: the type of command,
+the response type, the command arguments, the data source/destination for
+data transfer commands etc. Use <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita#GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A/GUID-931547BD-665D-326A-92B5-909B2D57F8C6"><apiname>DMMCSession::Command()</apiname></xref> to
+get the current command descriptor. </p> <p>Information about the command
+response, the number of bytes transferred etc., is passed back using the same
+command descriptor. Specifically, the platform independent layer relies on
+responses to the following commands being returned in the <xref href="GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A.dita#GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A/GUID-86553172-AE4E-3707-A0D2-8C2BB8880253"><apiname>TMMCCommandDesc::iResponse</apiname></xref> member,
+in big-endian format: </p> <ul>
+<li id="GUID-45605105-B91A-506B-A0F9-A317CA84D5EF"><p>Returns the OCR register
+value in response to a SEND_OP_COND command (CMD1). Note that there is <i>no
+CRC</i> with this response. Your code should ignore any CRC failure indication
+from the MultiMediaCard controller hardware, and just copy the response into <xref href="GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A.dita#GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A/GUID-86553172-AE4E-3707-A0D2-8C2BB8880253"><apiname>TMMCCommandDesc::iResponse</apiname></xref>. </p> </li>
+<li id="GUID-3E8B7D20-71F1-5609-8A16-24C6E2A7186A"><p>Returns the CID register
+value in response to an ALL_SEND_CID command (CMD2) and a SEND_CID command
+(CMD10). </p> </li>
+<li id="GUID-8D051F10-65BB-57AF-8B75-247829DC239A"><p>Returns the CSD register
+value in response to a SEND_CSD command (CMD9). </p> </li>
+<li id="GUID-C899645F-8478-57BF-8E1E-58AC50EB9FE3"><p>Returns the card status
+in response to all R1 and R1b commands. </p> </li>
+</ul> <p>Note that you can use the functions <xref href="GUID-32036692-8BA3-3AAF-9FD8-D135DFADAE77.dita#GUID-32036692-8BA3-3AAF-9FD8-D135DFADAE77/GUID-D2EFC17B-FC2E-3FDC-AE7A-E2AA109D4B40"><apiname>TMMC::BigEndian4Bytes()</apiname></xref> and
+TMC::to help with conversion to big-endian format. </p> <p>The function should
+return <xref href="GUID-E7D46003-E502-39D1-AF52-83B87AE6930B.dita"><apiname>KMMCErrNone</apiname></xref> if it completes successfully or one
+of the other <xref href="GUID-FF4AB1CF-7A2C-3FC6-B123-D6819E1BCDCA.dita"><apiname>TMMCErr</apiname></xref> error codes. </p> <p>See also background
+information: </p> <ul>
+<li id="GUID-0667980A-4A9E-5BD0-952E-97AD4C83B939"><p> <xref href="GUID-C059F39F-BC53-5C92-B05E-863B8CF22859.dita">Issuing
+commands</xref>  </p> </li>
+<li id="GUID-DF2B96DD-DD85-52C2-9EC8-30379E03D1DA"><p> <xref href="GUID-80E0DB93-A96A-54A8-A201-E11935418BE7.dita">The
+state machine</xref>. </p> </li>
+</ul> </section>
+<section id="GUID-3A1E907E-A74D-59CB-A1D6-FEF4849EF2D5"><title>DMMCPsu derived
+class</title> <p>This class controls the MultiMediaCard socket's power supply.
+A class needs to be derived from this in the platform specific layer to handle
+the Variant specific functionality of the power supply. </p> <p>This class
+has a number of pure virtual functions that need to be implemented in your
+Variant DLL. The diagram at <xref href="GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF.dita#GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF/GUID-92F5EBE4-C9AD-5D9A-A80E-9AFD1A09B6B3">MultiMediaCard
+controller basic structure</xref> shows the class in context. </p> <p>There
+is one virtual function with an empty default implementation that needs to
+be overridden. </p> <ul>
+<li id="GUID-025272EF-9DE8-5975-8993-006EE4D56E80"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-6EB8EF1C-BCCB-54A1-8CBA-4E8A2A20CABE">DoCreate()</xref>  </p> </li>
+<li id="GUID-6BAFE3AA-6CCA-581B-A96C-D1FD89D1D8CD"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-99529E84-17E1-5F23-9A1B-EBE3976D9B14">PsuInfo()</xref>  </p> </li>
+<li id="GUID-7419D681-D0CC-5CA7-8EE7-0D5A20779921"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-5809318D-E3E1-5261-AABA-604EBE72523F">DoSetState()</xref>  </p> </li>
+<li id="GUID-E570E830-B57E-5A39-9EF1-CF68F3853AFF"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-B5030D2E-A466-596C-A2C3-73F38CF9C1A7">DoCheckVoltage()</xref>  </p> </li>
+</ul> <p id="GUID-6EB8EF1C-BCCB-54A1-8CBA-4E8A2A20CABE"><b>DoCreate()</b> </p> <p> <xref href="GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B.dita#GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B/GUID-32771B9D-D2B8-33F5-AFC5-4476165C0A76"><apiname>DMMCPsu::DoCreate()</apiname></xref>  </p> <p>The
+function is intended to perform hardware initialization on the MultiMediaCard
+power supply, for example, setting port direction registers. </p> <p>The function
+is called after creation of the <xref href="GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B.dita"><apiname>DMMCPsu</apiname></xref> derived class instance,
+which is done during kernel initialization when the MultiMediaCard controller
+Variant DLL extension is loaded. </p> <p>The function has a default implementation
+that just returns <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref>. </p> <p>Your implementation
+should <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref> if the hardware initialization is successful,
+otherwise it should return one of the system-wide error codes to indicate
+initialization failure. Note that returning a value other than <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref> will
+cause the kernel to panic and to fail to boot. </p> <p id="GUID-99529E84-17E1-5F23-9A1B-EBE3976D9B14"><b>PsuInfo()</b> </p> <p> <xref href="GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B.dita#GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B/GUID-C7600EDA-B564-31E2-835C-9C580A29FC1D"><apiname>DMMCPsu::PsuInfo()</apiname></xref>  </p> <p>The
+function returns information about the MultiMediaCard power supply. </p> <p>The
+function takes a reference to a <xref href="GUID-E3BB783F-423F-352A-9B6E-FD23EC80AA8D.dita"><apiname>TPBusPsuInfo</apiname></xref> object, and
+your implementation must fill the public data members of the object. </p> <p>Note: </p> <ul>
+<li id="GUID-B8527FE4-61BB-574A-A200-5EA083A76A6D"><p>You can use the constant <xref href="GUID-3B63FFD6-AE21-366A-B435-AE6213AA2EE0.dita"><apiname>KMMCAdjustableOpVoltage</apiname></xref> to
+set bit 31 in <xref href="GUID-E3BB783F-423F-352A-9B6E-FD23EC80AA8D.dita#GUID-E3BB783F-423F-352A-9B6E-FD23EC80AA8D/GUID-6B1E1CDD-A0E7-3AA5-989E-8D7A199ADE2A"><apiname>TPBusPsuInfo::iVoltageSupported</apiname></xref>. </p> </li>
+<li id="GUID-694DB272-C66E-5392-8C7E-DC1B875E9DD3"><p>Set <xref href="GUID-E3BB783F-423F-352A-9B6E-FD23EC80AA8D.dita#GUID-E3BB783F-423F-352A-9B6E-FD23EC80AA8D/GUID-8C9792BC-8FAA-3DE5-8032-7546887FA8FB"><apiname>TPBusPsuInfo::iNotLockedTimeOut</apiname></xref> to
+0. </p> </li>
+</ul> <p id="GUID-5809318D-E3E1-5261-AABA-604EBE72523F"><b> DoSetState()</b> </p> <p> <xref href="GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B.dita#GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B/GUID-4DF0741F-B143-3B46-82BE-9CD0261C27E5"><apiname>DMMCPsu::DoSetState()</apiname></xref>  </p> <p>The
+function is called to turn the PSU on or off. </p> <p>The requested state
+of the PSU depends on the <xref href="GUID-CD00D507-CC86-33BE-91A7-FAF7EAFD4840.dita"><apiname>TPBusPsuState</apiname></xref> value passed to
+it. </p> <p>If the PSU supports voltage adjustment, rather than a single fixed
+value, then the required voltage setting is contained in the protected data
+member <xref href="GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B.dita#GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B/GUID-7A625108-D5AE-301F-9CAB-2625DAD0C0B0"><apiname>DMMCPsu::iVoltageSetting</apiname></xref>. </p> <p>Note that the
+stack may call this function to request the power to be turned on when it
+is already on. You should check for this and do nothing if the power is already
+in the requested state. </p> <p id="GUID-B5030D2E-A466-596C-A2C3-73F38CF9C1A7"><b>DoCheckVoltage()</b> </p> <p> <xref href="GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B.dita#GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B/GUID-17AC2A1C-5430-38B1-BD3F-966CE4936940"><apiname>DMMCPsu::DoCheckVoltage()</apiname></xref>  </p> <p>The
+function is called to check that the voltage level of the PSU is as expected. </p> <p>Checking
+the voltage level may be a long running operation (e.g. using an ADC), and
+it may not always be appropriate to perform and complete the check directly
+within this function. </p> <p>When voltage checking is complete, either synchronously
+in this function, or asynchronously at some later stage, the result should
+be returned by calling the base class function <xref href="GUID-A8B5FB5A-4709-3F29-B2CB-81FC5B0E7D63.dita#GUID-A8B5FB5A-4709-3F29-B2CB-81FC5B0E7D63/GUID-5643935F-9E97-35B0-9D92-88CA613F0016"><apiname>DPBusPsuBase::ReceiveVoltageCheckResult()</apiname></xref>.
+Pass <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref> to indicate a successful check; pass <xref href="GUID-A94AC24A-EADF-3913-8345-708ED637968E.dita"><apiname>KErrGeneral</apiname></xref> to
+indicate a failed check. </p> <p>Note that this function is not called as
+part of <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-791BCA03-61F3-3C1C-BA2D-D633A94AF299"><apiname>DMMCStack::DoPowerUpSM()</apiname></xref> processing, which means
+that it is not possible to use this function to introduce a delay until power
+is stable when the PSU is turned on. If such a delay is required while the
+power lines stabilize, then it will be necessary to make this function part
+of the DoPowerUpSM state machine. </p> </section>
+<section id="GUID-C80E57B1-933B-55D7-949B-E68DB9B96B94"><title>DMMCMediaChange
+derived class</title> <p>This class provides support for dealing with media
+change events, i.e. the insertion and removal of removable media. </p> <p>A
+class needs to be derived from this in the platform specific layer to handle
+the Variant specific functionality. </p> <p>This class has a number of pure
+virtual functions that need to be implemented in your Variant DLL. The diagram
+at <xref href="GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF.dita#GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF/GUID-92F5EBE4-C9AD-5D9A-A80E-9AFD1A09B6B3">MultiMediaCard
+controller basic structure</xref> shows the class in context. </p> <p>There
+is one virtual function with an empty default implementation that needs to
+be overridden. </p> <ul>
+<li id="GUID-1BAEFE73-3B73-5BA7-872D-89C3B3F8BF75"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-BFC23CC1-102F-5740-A608-CF91C2BC3897">Create()</xref> </p> </li>
+<li id="GUID-C1235A87-68BB-5AF4-80F6-DFB7DBA8432C"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-726A2A5F-18D3-55BD-9B92-0676266794C6">MediaState()</xref>  </p> </li>
+<li id="GUID-BBAEC56C-DBA7-586C-A9CC-1E4E70A81096"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-1ADD0F5A-B561-54AE-BB2F-81AC3E8D81A4">DoDoorOpen()</xref>  </p> </li>
+<li id="GUID-22D6992C-868B-5E18-9AA0-624EA51DB529"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-58829228-43A9-546B-8CFD-31DF8FBB0078">DoDoorClosed()</xref>  </p> </li>
+<li id="GUID-04B7E650-7DA8-5F61-9D8E-89FC2B93AE20"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-F91B9434-5B90-5221-B5E6-D57F50391D81">ForceMediaChange()</xref>  </p> </li>
+</ul> <p id="GUID-BFC23CC1-102F-5740-A608-CF91C2BC3897"><b>Create()</b> </p> <p> <xref href="GUID-2F974AD8-551B-35F0-B72C-99122913714D.dita#GUID-2F974AD8-551B-35F0-B72C-99122913714D/GUID-F96EF34B-7B38-37DC-9B34-E0D4D1963622"><apiname>DMMCMediaChange::Create()</apiname></xref>  </p> <p>The
+function is intended to perform hardware initialization on the MultiMediaCard
+media change hardware, for example, setting port direction registers, binding
+to the door open interrupt etc. </p> <p>The function is called after creation
+of the <xref href="GUID-2F974AD8-551B-35F0-B72C-99122913714D.dita"><apiname>DMMCMediaChange</apiname></xref> derived class instance, which is
+done during kernel initialization when the MultiMediaCard controller Variant
+DLL extension is loaded. </p> <p>The function has a default implementation
+that just returns <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref>. </p> <p>Your implementation
+should return <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref> if the hardware initialization is
+successful, otherwise it should return one of the system-wide error codes
+to indicate initialization failure. Note that returning a value other than <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref> will
+cause the kernel to panic and to fail to boot. </p> <p id="GUID-726A2A5F-18D3-55BD-9B92-0676266794C6"><b> MediaState()</b> </p> <p> <xref href="GUID-2F974AD8-551B-35F0-B72C-99122913714D.dita#GUID-2F974AD8-551B-35F0-B72C-99122913714D/GUID-A951EF31-83F1-3E07-A5BD-5342B6125ACF"><apiname>DMMCMediaChange::MediaState()</apiname></xref>  </p> <p>The
+function should return the current state of the media, i.e. whether the media
+door is open or closed. To indicate the state, it should return one of the <xref href="GUID-49F96729-2DDB-37E0-AE39-9BEF2B7FF7F9.dita"><apiname>TMediaState</apiname></xref> enum
+values. </p> <p id="GUID-1ADD0F5A-B561-54AE-BB2F-81AC3E8D81A4"><b>DoDoorOpen()</b> </p> <p> <xref href="GUID-2F974AD8-551B-35F0-B72C-99122913714D.dita#GUID-2F974AD8-551B-35F0-B72C-99122913714D/GUID-6F734353-3458-3A8B-93E7-317674A1CAA4"><apiname>DMMCMediaChange::DoDoorOpen()</apiname></xref>  </p> <p>This
+function should handle a media door open event. What needs to be done depends
+on how door open and door closed events are detected. </p> <p>The most common
+pattern is where the platform hardware is capable of generating an interrupt
+when a door open event occurs, but cannot generate an interrupt when a door
+closed event occurs. In this situation, the hardware provides a readable door
+status that can be checked for the door closed state on a periodic basis (i.e.
+polling). </p> <p>Assuming this, <codeph>DoDoorOpen()</codeph> would need
+to enable a tick timer to poll for the door closing. The timer callback function
+would check the state of the door, and if this showed a closed door, the timer
+would be disabled and the function <xref href="GUID-C122D579-BB08-3084-A30E-DC857D6E7282.dita#GUID-C122D579-BB08-3084-A30E-DC857D6E7282/GUID-4F53C9F7-89C5-3CB6-A3D5-7DF40DAFF37F"><apiname>DMediaChangeBase::DoorClosedService()</apiname></xref> called.
+This results in a call to <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-58829228-43A9-546B-8CFD-31DF8FBB0078">DoDoorClosed()</xref>. </p> <p>Note that the door open interrupt is cleared before this function is
+called. The interrupt results in a call to <xref href="GUID-C122D579-BB08-3084-A30E-DC857D6E7282.dita#GUID-C122D579-BB08-3084-A30E-DC857D6E7282/GUID-6197984B-3884-367B-AE91-8E7E25203C95"><apiname>DMediaChangeBase::DoorOpenService()</apiname></xref>,
+which in turn results in a call to this function <codeph>DoDoorOpen()</codeph>. </p> <p>Your
+implementation would necessarily be different if an open door event could
+not be signalled by an interrupt and a tick timer were to be used to poll
+for an open door status. </p> <p id="GUID-58829228-43A9-546B-8CFD-31DF8FBB0078"><b>DoDoorClosed()</b> </p> <p> <xref href="GUID-2F974AD8-551B-35F0-B72C-99122913714D.dita#GUID-2F974AD8-551B-35F0-B72C-99122913714D/GUID-F26714BC-6648-349D-812D-6FD911602754"><apiname>DMMCMediaChange::DoDoorClosed()</apiname></xref>  </p> <p>This
+function should handle a media door closed event. What needs to be done depends
+on how door open and door closed events are detected. </p> <p>The most common
+pattern is where the platform hardware is capable of generating an interrupt
+when a door open event occurs, but cannot generate an interrupt when a door
+closed event occurs. In this situation, the hardware provides a readable door
+status that can be checked for the door closed state on a periodic basis (i.e.
+polling). </p> <p>Assuming this, <codeph>DoDoorClosed()</codeph> would be
+called by the timer callback function established by <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-1ADD0F5A-B561-54AE-BB2F-81AC3E8D81A4">DoDoorOpen()</xref> when the door status indicates a closed door; the function
+would need to re-enable the door open interrupt. </p> <p>Your implementation
+would necessarily be different if a closed door event were to be signalled
+by an interrupt. </p> <p id="GUID-F91B9434-5B90-5221-B5E6-D57F50391D81"><b> ForceMediaChange()</b> </p> <p> <xref href="GUID-2F974AD8-551B-35F0-B72C-99122913714D.dita#GUID-2F974AD8-551B-35F0-B72C-99122913714D/GUID-2DB81D37-C930-3B3C-A64E-B734039A2C95"><apiname>DMMCMediaChange::ForceMediaChange()</apiname></xref>  </p> <p>This function is called by the local media device driver to force a remount
+of the media device. For example to reopen a media driver in secure mode. </p> <p>It
+should result in the same sequence of operations as would occur if a door
+open event had taken place; for example, disabling the door open interrupt
+and calling <xref href="GUID-C122D579-BB08-3084-A30E-DC857D6E7282.dita#GUID-C122D579-BB08-3084-A30E-DC857D6E7282/GUID-6197984B-3884-367B-AE91-8E7E25203C95"><apiname>DMediaChangeBase::DoorOpenService()</apiname></xref>. </p> </section>
+<section id="GUID-7E709B21-8D38-5041-846F-CB7983B66834"><title>TMMCardControllerInterface
+derived class (The factory class)</title> <p>This is a class, also known as <xref href="GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF.dita#GUID-BE6AFD38-5952-537F-848C-C76C8F5FA9BF/GUID-26CFDD03-A4C4-5C96-88D4-5E750FDF69A3">the
+controller factory</xref> that is responsible for deciding which peripheral
+bus sockets are sockets that have been designated as a MultiMediaCard sockets
+on this platform. It is also responsible for creating the platform-specific
+layer objects associated with those MultiMediaCard sockets, i.e. the DMMCSocket,
+DMMCStack, DMMCMediaChange, and DMMCPsu objects. </p> <p>This class defines
+a number of pure virtual functions that need to be implemented in your Variant
+DLL to provide the functionality that is specific to your platform. </p> <p>An
+instance of your <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita"><apiname>TMMCardControllerInterface</apiname></xref> derived class
+is created in the <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-732EDE1D-452A-5A48-B5DB-1196C5F8BEBD">Variant
+DLL entry point code</xref>. </p> <ul>
+<li id="GUID-61BF196A-EFD3-57E1-98C2-A5B6350AC82E"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-2477BA25-2ADD-55CB-93F2-84F114221EBA">IsMMCSocket()</xref> </p> </li>
+<li id="GUID-0FED2860-6710-517D-BB60-7FCBD043CEFB"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-829E686F-58F9-56A9-9EC4-CD59B14E127B">NewSocket()</xref> </p> </li>
+<li id="GUID-3213A9CF-3155-513D-9F29-AB573018F23B"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-E0F612EB-85BC-533D-A71C-3FC93D9CC708">NewStack()</xref>  </p> </li>
+<li id="GUID-9C8219D2-67EF-55B0-B01E-ACB2B0AC63CB"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-33A9C3DE-80EF-5895-BC7D-EA2ED6EB083B">MediaChangeID()</xref>  </p> </li>
+<li id="GUID-B8309E5D-7F8A-5B62-81B3-6679AFBC9319"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-6B1FE81F-1497-5447-9286-B0BE54AE6831">NewMediaChange()</xref> </p> </li>
+<li id="GUID-62725219-BAD2-528E-BC6A-84ACBA0A5C87"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-E969F613-01A3-54A7-8CC6-67F4A8E9558F">VccID()</xref>  </p> </li>
+<li id="GUID-67AE2495-BCF2-51B6-9F52-78FA36A65F2A"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-083F38DB-AC65-5257-B169-2099194D3082">NewVcc()</xref>  </p> </li>
+<li id="GUID-428FA30E-1E9A-50EA-BE3F-02E9B279E868"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-81A8BF8E-FB8B-596D-8C9A-690CD6449C12">Init()</xref>  </p> </li>
+</ul> <p id="GUID-2477BA25-2ADD-55CB-93F2-84F114221EBA"><b>IsMMCSocket()</b> </p> <p> <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-5EC9F2EE-5D14-37F9-9EFE-95BD1062C681"><apiname>TMMCardControllerInterface::IsMMCSocket()</apiname></xref>  </p> <p>Implement this function to indicate whether the peripheral bus socket, as
+identified by the specified peripheral bus socket number, is designated as
+a MultiMediaCard socket on this platform. It should return <xref href="GUID-781E8158-805B-3784-8FED-D7A191822FC3.dita"><apiname>ETrue</apiname></xref> if
+the socket has been so designated, and return <xref href="GUID-A759CA2D-8327-348F-9337-4886E619D920.dita"><apiname>EFalse</apiname></xref> if
+not. </p> <p>The function is called from <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-2C6EA849-1B62-3158-A328-DB2A7149346C"><apiname>TMMCardControllerInterface::Create()</apiname></xref>,
+which passes a socket number that can fall into the range 0 to <xref href="GUID-2C5A5F8F-381C-3B99-AADE-44474E629CC4.dita"><apiname>KMaxPBusSockets</apiname></xref>. </p> <p>Internally,
+Symbian platform reserves space for an array of pointers to <xref href="GUID-C988CAE6-9073-3851-A0B0-5479D1A34CFB.dita"><apiname>DPBusSocket</apiname></xref> objects,
+and this function allows the platform specific layer to identify which slot
+is to be used for the <xref href="GUID-45B97680-1756-3559-8A2D-2F2E851AD6A7.dita"><apiname>DMMCSocket</apiname></xref> object. </p> <codeblock id="GUID-F1E0478A-8CE8-5E2F-87F8-AAFCCCE8A042" xml:space="preserve">GLDEF_D DPBusSocket* TheSockets[KMaxPBusSockets];</codeblock> <p>(This
+array is internal to Symbian platform.) </p> <p>If, on this platform, a socket
+has been designated as a MultiMediaCard stack, then the function not only
+returns <xref href="GUID-781E8158-805B-3784-8FED-D7A191822FC3.dita"><apiname>ETrue</apiname></xref>, but also provides the media information
+for that socket, by filling in the members of the <xref href="GUID-FC0F974E-9ABB-348B-9AE9-778B3A1F413A.dita"><apiname>SMediaDeviceInfo</apiname></xref> object
+passed in. </p> <p id="GUID-829E686F-58F9-56A9-9EC4-CD59B14E127B"><b>NewSocket()</b> </p> <p> <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-90615A9A-BFC2-3E1B-B2AC-7D1CF322FC65"><apiname>TMMCardControllerInterface::NewSocket()</apiname></xref>  </p> <p>Implement
+this function to create, and return a pointer to, an instance of the <xref href="GUID-45B97680-1756-3559-8A2D-2F2E851AD6A7.dita"><apiname>DMMCSocket</apiname></xref> class.
+This can be a class derived from <codeph>DMMCSocket</codeph>, but this should
+rarely be necessary. </p> <p>The function is called from <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-2C6EA849-1B62-3158-A328-DB2A7149346C"><apiname>TMMCardControllerInterface::Create()</apiname></xref>. </p> <p>If
+you create a <xref href="GUID-45B97680-1756-3559-8A2D-2F2E851AD6A7.dita"><apiname>DMMCSocket</apiname></xref> object, simply forward the peripheral
+bus socket number and pointer to the password store; there is no need to do
+anything with them. </p> <p>If you create an instance of a <xref href="GUID-45B97680-1756-3559-8A2D-2F2E851AD6A7.dita"><apiname>DMMCSocket</apiname></xref> derived
+class, then just pass the socket number and pointer to the <codeph>DMMCSocket</codeph> constructor
+in your constructor's ctor list. </p> <p>Note: </p> <ul>
+<li id="GUID-FA8D57D9-0827-5090-A12B-A47C936B6F70"><p>The socket number can
+fall into the range 0 to <xref href="GUID-2C5A5F8F-381C-3B99-AADE-44474E629CC4.dita"><apiname>KMaxPBusSockets</apiname></xref>, and is a value
+for which <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-2477BA25-2ADD-55CB-93F2-84F114221EBA">IsMMCSocket()</xref> returned <xref href="GUID-781E8158-805B-3784-8FED-D7A191822FC3.dita"><apiname>ETrue</apiname></xref>. </p> </li>
+<li id="GUID-3C4FCA1F-558D-5964-91F5-98588694DA70"><p>This function is only
+called for sockets that are associated with MultiMediaCard devices as reported
+by the function <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-2477BA25-2ADD-55CB-93F2-84F114221EBA">IsMMCSocket()</xref>. </p> </li>
+</ul> <p id="GUID-E0F612EB-85BC-533D-A71C-3FC93D9CC708"><b>NewStack()</b> </p> <p> <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-E2F99378-DD63-3BE0-8550-66EBF2C5D087"><apiname>TMMCardControllerInterface::NewStack()</apiname></xref>  </p> <p>Implement
+this function to create, and return a pointer to, an instance of a <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-4C6CA873-A798-5C79-8838-0CC3C9E914FB">DMMCStack derived class</xref>. </p> <p>The function is called from <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-2C6EA849-1B62-3158-A328-DB2A7149346C"><apiname>TMMCardControllerInterface::Create()</apiname></xref>. </p> <p>The
+peripheral bus socket number and pointer to the socket object should be forwarded
+to the <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita"><apiname>DMMCStack</apiname></xref> constructor in your class constructor's
+ctor list. </p> <p>Note: </p> <ul>
+<li id="GUID-CE363D03-6FEA-5AFE-A085-98D0FBAA9D52"><p>The socket number can
+fall into the range 0 to <xref href="GUID-2C5A5F8F-381C-3B99-AADE-44474E629CC4.dita"><apiname>KMaxPBusSockets</apiname></xref>, and is a value
+for which <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-2477BA25-2ADD-55CB-93F2-84F114221EBA">IsMMCSocket()</xref> returned <xref href="GUID-781E8158-805B-3784-8FED-D7A191822FC3.dita"><apiname>ETrue</apiname></xref>. </p> </li>
+<li id="GUID-7F8F2267-E8C3-5AC5-92AB-7D3179BA6D10"><p>The socket is the object
+created by <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-829E686F-58F9-56A9-9EC4-CD59B14E127B">NewSocket()</xref>. </p> </li>
+<li id="GUID-DF7C2369-D225-54E4-B6F1-D444343E7084"><p>This function is only
+called for sockets that are associated with MultiMediaCard devices as reported
+by the function <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-2477BA25-2ADD-55CB-93F2-84F114221EBA">IsMMCSocket()</xref>. </p> </li>
+</ul> <p id="GUID-33A9C3DE-80EF-5895-BC7D-EA2ED6EB083B"><b>MediaChangeID()</b> </p> <p> <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-10B49F15-8ED5-3CA9-873A-788B87078367"><apiname>TMMCardControllerInterface::MediaChangeID()</apiname></xref>  </p> <p>Implement this function to report which media change object is to be
+associated with the specified peripheral bus socket number. </p> <p>The function
+is called from <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-2C6EA849-1B62-3158-A328-DB2A7149346C"><apiname>TMMCardControllerInterface::Create()</apiname></xref>. </p> <p>The
+media change object is represented by a number, which is simply an index value
+that ranges from 0 to <xref href="GUID-92555AA1-73A5-3F88-8227-8D20C977F046.dita"><apiname>KMaxMediaChanges</apiname></xref>. Internally, Symbian
+platform reserves space for an array of pointers to <xref href="GUID-C122D579-BB08-3084-A30E-DC857D6E7282.dita"><apiname>DMediaChangeBase</apiname></xref> objects,
+and this function allows the platform specific layer to identify which slot
+is to be used for the <xref href="GUID-2F974AD8-551B-35F0-B72C-99122913714D.dita"><apiname>DMMCMediaChange</apiname></xref> object that will
+correspond to the specified socket number. </p> <codeblock id="GUID-08AE1956-86E0-544A-A95C-0D16DE6694D3" xml:space="preserve">GLDEF_D DMediaChangeBase* TheMediaChanges[KMaxMediaChanges];</codeblock> <p>(This array is internal to Symbian platform.) </p> <p>Note: </p> <ul>
+<li id="GUID-1A4ED330-90E5-5215-8149-093987DD5D9B"><p>The socket number can
+fall into the range 0 to <xref href="GUID-2C5A5F8F-381C-3B99-AADE-44474E629CC4.dita"><apiname>KMaxPBusSockets</apiname></xref>, and is a value
+for which <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-2477BA25-2ADD-55CB-93F2-84F114221EBA">IsMMCSocket()</xref> returned <xref href="GUID-781E8158-805B-3784-8FED-D7A191822FC3.dita"><apiname>ETrue</apiname></xref>. </p> </li>
+<li id="GUID-5EA3662D-82B2-529B-8DF4-2EAA9429990A"><p>This function is only
+called for sockets that are associated with MultiMediaCard devices as reported
+by the function <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-2477BA25-2ADD-55CB-93F2-84F114221EBA">IsMMCSocket()</xref>. </p> </li>
+</ul> <p id="GUID-6B1FE81F-1497-5447-9286-B0BE54AE6831"><b>NewMediaChange()</b> </p> <p> <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-2961273F-0D5A-3B9E-94D8-1FE216A57985"><apiname>TMMCardControllerInterface::NewMediaChange()</apiname></xref>  </p> <p>Implement this function to create, and return a pointer to, an instance
+of a <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-C80E57B1-933B-55D7-949B-E68DB9B96B94">DMMCMediaChange
+derived class</xref>. </p> <p>The function is called from <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-2C6EA849-1B62-3158-A328-DB2A7149346C"><apiname>TMMCardControllerInterface::Create()</apiname></xref>. </p> <p>The
+media change number should be forwarded to the <xref href="GUID-2F974AD8-551B-35F0-B72C-99122913714D.dita"><apiname>DMMCMediaChange</apiname></xref> constructor
+in your class constructor's ctor list. </p> <p>Note: </p> <ul>
+<li id="GUID-69B6384E-1B3C-567B-89AD-E0BE42E1F043"><p>The media change number
+can fall into the range 0 to <xref href="GUID-92555AA1-73A5-3F88-8227-8D20C977F046.dita"><apiname>KMaxMediaChanges</apiname></xref>, and is the
+value returned by <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-33A9C3DE-80EF-5895-BC7D-EA2ED6EB083B">MediaChangeID()</xref>. </p> </li>
+<li id="GUID-FD2DA86D-5D0E-5661-AC09-55F10087D7A2"><p>This function is only
+called for sockets that are associated with MultiMediaCard devices as reported
+by the function <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-2477BA25-2ADD-55CB-93F2-84F114221EBA">IsMMCSocket()</xref>. </p> </li>
+</ul> <p id="GUID-E969F613-01A3-54A7-8CC6-67F4A8E9558F"><b>VccID()</b> </p> <p> <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-1553B339-4171-396B-89E6-6C47C539D21F"><apiname>TMMCardControllerInterface::VccID()</apiname></xref>  </p> <p>Implement
+this function to report which power supply unit (PSU) object is to be associated
+with the specified peripheral bus socket number. </p> <p>The function is called
+from <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-2C6EA849-1B62-3158-A328-DB2A7149346C"><apiname>TMMCardControllerInterface::Create()</apiname></xref>. </p> <p>The
+PSU object is represented by a number, which is simply an index value that
+ranges from 0 to <xref href="GUID-E5DEB888-EC0E-3160-BA7D-76954B282D43.dita"><apiname>KMaxPBusVccs</apiname></xref>. Internally, Symbian platform
+reserves space for an array of pointers to <xref href="GUID-A8B5FB5A-4709-3F29-B2CB-81FC5B0E7D63.dita"><apiname>DPBusPsuBase</apiname></xref> objects,
+and this function allows the platform specific layer to identify which slot
+is to be used for the <xref href="GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B.dita"><apiname>DMMCPsu</apiname></xref> object that will correspond
+to the specified socket number. </p> <codeblock id="GUID-99CD9798-2CFB-533D-82E0-352B84FA5AC9" xml:space="preserve">GLDEF_D DPBusPsuBase* TheVccs[KMaxPBusVccs];
+</codeblock> <p>(This array is internal to Symbian platform.) </p> <p>Note: </p> <ul>
+<li id="GUID-2C77F138-1444-5815-AB12-16D3ED6D908E"><p>The socket number can
+fall into the range 0 to <xref href="GUID-2C5A5F8F-381C-3B99-AADE-44474E629CC4.dita"><apiname>KMaxPBusSockets</apiname></xref>, and is a value
+for which <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-2477BA25-2ADD-55CB-93F2-84F114221EBA">IsMMCSocket()</xref> returned <xref href="GUID-781E8158-805B-3784-8FED-D7A191822FC3.dita"><apiname>ETrue</apiname></xref>. </p> </li>
+<li id="GUID-F8F4E84D-C46D-5547-AD19-61FB30E2CC3F"><p>This function is only
+called for sockets that are associated with MultiMediaCard devices as reported
+by the function <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-2477BA25-2ADD-55CB-93F2-84F114221EBA">IsMMCSocket()</xref>. </p> </li>
+</ul> <p id="GUID-083F38DB-AC65-5257-B169-2099194D3082"><b>NewVcc()</b> </p> <p> <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-600A5477-E99A-39BC-9982-D54C07A528BE"><apiname>TMMCardControllerInterface::NewVcc()</apiname></xref>  </p> <p>The
+function should create, and return a pointer to, an instance of a <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-3A1E907E-A74D-59CB-A1D6-FEF4849EF2D5">DMMCPsu derived class</xref>. </p> <p>The function is called from <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-2C6EA849-1B62-3158-A328-DB2A7149346C"><apiname>TMMCardControllerInterface::Create()</apiname></xref>. </p> <p>The
+Power Supply Unit (PSU) number and the media change number should be forwarded
+to the <xref href="GUID-FBCEFDB6-28FF-3201-8E13-F12E3759E36B.dita"><apiname>DMMCPsu</apiname></xref> constructor in your class constructor's
+ctor list. </p> <p>Note: </p> <ul>
+<li id="GUID-833A0119-6A98-5F5F-BAEE-5070C7C23A55"><p>The PSU number can fall
+into the range 0 to <xref href="GUID-E5DEB888-EC0E-3160-BA7D-76954B282D43.dita"><apiname>KMaxPBusVccs</apiname></xref>, and is the value returned
+by <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-E969F613-01A3-54A7-8CC6-67F4A8E9558F">VccID()</xref>. </p> </li>
+<li id="GUID-25D7430A-2C12-50CF-BF84-FD2309732FC8"><p>The media change number
+can fall into the range 0 to <xref href="GUID-92555AA1-73A5-3F88-8227-8D20C977F046.dita"><apiname>KMaxMediaChanges</apiname></xref>, and is the
+value returned by <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-33A9C3DE-80EF-5895-BC7D-EA2ED6EB083B">MediaChangeID()</xref>. </p> </li>
+<li id="GUID-A8908747-E292-5D01-91E2-045DE2F341B2"><p>This function is only
+called for sockets that are associated with MultiMediaCard devices as reported
+by the function <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-2477BA25-2ADD-55CB-93F2-84F114221EBA">IsMMCSocket()</xref>. </p> </li>
+</ul> <p id="GUID-81A8BF8E-FB8B-596D-8C9A-690CD6449C12"><b>Init()</b> </p> <p> <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita#GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A/GUID-1F0C99EC-D8A9-304A-A738-BACAB5C766A6"><apiname>TMMCardControllerInterface::Init()</apiname></xref>  </p> <p>Implement
+this function to perform any initialization that the platform specific layer
+needs to do. </p> <p>It should return <xref href="GUID-6CA4F1ED-7947-3087-B618-D35858FAA3BC.dita"><apiname>KErrNone</apiname></xref> to indicate
+successful completion, or return one of the other system-wide error codes
+to indicate initialization failure. </p> <p>Note that you should <i>not</i> do
+any initialization that is specifically associated with: </p> <ul>
+<li id="GUID-9D706630-C477-5163-B0B2-5745D5D04559"><p>the stack - use <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-0B55A650-E9ED-56CB-B06F-B1113ACDF282">DMMCStack::Init()</xref> for
+this. </p> </li>
+<li id="GUID-99B883A6-FE47-5B7F-A9D1-01CCD7954DCD"><p>the power supply unit
+- use <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-6EB8EF1C-BCCB-54A1-8CBA-4E8A2A20CABE">DMMCPsu::DoCreate()</xref> for
+this. </p> </li>
+<li id="GUID-C7EAE4E6-DEE4-515A-83B1-E40EE8D37F32"><p>dealing with media change
+events - use <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-BFC23CC1-102F-5740-A608-CF91C2BC3897">DMMCMediaChange::Create()</xref> for
+this. </p> </li>
+</ul> </section>
+<section id="GUID-732EDE1D-452A-5A48-B5DB-1196C5F8BEBD"><title> Variant DLL
+entry point code</title> <p>The platform-specific layer as implemented in
+the Variant DLL is a standard kernel extension. The entry point for all standard
+kernel extensions is declared by a </p> <codeblock id="GUID-8835A131-2CDC-51AC-9C59-D72BAD651EA6" xml:space="preserve">DECLARE_STANDARD_EXTENSION()</codeblock> <p>statement,
+followed by the block of code that runs on entry to the DLL. </p> <p>Initialization
+of the MultiMediaCard DLL is done at this point, and follows the pattern shown
+below. It needs to create an instance of your <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita"><apiname>TMMCardControllerInterface</apiname></xref> derived
+class, followed by a call to <codeph>Create()</codeph> on this object. This
+starts a cascade of effects resulting in calls to your implementation of the <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita"><apiname>TMMCardControllerInterface</apiname></xref> functions,
+which in turn result in the creation of the platform-specific layer objects
+associated with the MultiMediaCard sockets, i.e. the DMMCSocket, DMMCStack,
+DMMCMediaChange, and DMMCPsu objects. </p> <codeblock id="GUID-16F754D1-6161-5E05-8BEA-2A89CC80CC41" xml:space="preserve">DECLARE_STANDARD_EXTENSION()
+//
+// Extension Entry Point
+//
+    {
+    __KTRACE_OPT(KPBUS1,Kern::Printf("Starting MMC interface"));
+
+    TInt r=KErrNoMemory;
+    TVARMMCardControllerInterface* pI=new TVARMMCardControllerInterface;
+    if (pI)
+        {
+        r=pI-&gt;Create();
+        }
+
+    __KTRACE_OPT(KPBUS1,Kern::Printf("MMC: Returns %d",r));
+    return r;
+    }
+</codeblock> <p>In this example, <codeph>TVARMMCardControllerInterface</codeph> is
+your class derived from <xref href="GUID-B1F2C60B-E098-395F-8ED0-FF33E3EC9E4A.dita"><apiname>TMMCardControllerInterface</apiname></xref>  </p> </section>
+<section id="GUID-00F918D3-761B-5500-805F-AB4DEE72144E"><title>Direct memory
+addressing</title> <p>To transfer data between a user side process and the
+media device, the Platform Specific Layer allocates a DMA-safe buffer at initialization.
+This buffer is allocated from physical memory. The memory in the user side
+process is virtual and you perform an inter-process copy of data between the
+user side process and the buffer allocated by the Platform Specific Layer. </p> <p>Data
+transfer is faster if the MultiMediaCard controller knows that an address
+passed in an I/O request is a physical address. The File caching and Demand
+Paging features in the file server and kernel can pass physical addresses.
+A physical address avoids the need for an inter-process copy operation. </p> <p>If
+you use a mechanism like <xref href="GUID-DF2F0439-AE1A-599C-91B9-6EF2177C3C7E.dita">DMA</xref> to
+transfer data, and your platform specific layer can deal with physical addresses,
+you need to make changes to the platform specific layer listed below. </p> <ul>
+<li id="GUID-04D498F3-F4BB-5A15-BE31-8DF6F11DB9BD"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-E50081BC-C923-5DAF-950C-9E1411916FED">Implement double buffers</xref>  </p> </li>
+<li id="GUID-39F10C4A-4291-579E-878B-E5BD2FB9C9D0"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-575211BC-BF66-5817-9825-EE402648D0CD">Register support for physical addresses</xref>  </p> </li>
+<li id="GUID-5638CD98-469C-587C-87B2-CA470D76F474"><p> <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-27FCEF7D-0AAB-599C-8405-4BD284308314">Modify the data transfer phase to handle physical memory</xref>  </p> </li>
+</ul> <p id="GUID-E50081BC-C923-5DAF-950C-9E1411916FED"><b>Implement double buffers</b> </p> <p>If
+you enable double buffer behavior, the MultiMediaCard subsystem can perform
+multiple data transfers in a single bus transaction. The double buffer implementation
+performs many data transfers in a single bus transaction. The MultiMediaCard
+subsystem logically splits the buffer allocated by the platform specific layer
+into two segments. Data transfer to the media device is in progress from one
+segment - this is the active segment. Concurrently, the media driver can prepare
+data in the other segment. </p> <p>To implement double buffers, you need to
+make changes to the platform specific layer. </p> <p><b>Use the command descriptor functions </b> </p> <ul>
+<li id="GUID-9471B51C-CB76-537F-B958-F61466A6B8F7"><p>Use the function <xref href="GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A.dita#GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A/GUID-7BDD7C93-65D3-312B-B99E-B4B07AA32B2C"><apiname>TMMCCommandDesc::BlockLength()</apiname></xref> to
+get the block length of the transaction. Find all direct references in the
+source code of the platform specific layer to <codeph>TMMCCommandDesc::iBlockLength</codeph>.
+Replace each reference with a call to <xref href="GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A.dita#GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A/GUID-7BDD7C93-65D3-312B-B99E-B4B07AA32B2C"><apiname>TMMCCommandDesc::BlockLength()</apiname></xref>  </p> </li>
+<li id="GUID-902FFE84-8F97-511D-B554-41283550DB16"><p>Use the function <xref href="GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A.dita#GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A/GUID-65B1C01B-1C8D-373A-83DB-0CEFF17667FC"><apiname>TMMCCommandDesc::BufferLength()</apiname></xref> to
+get the length of the next active segment. Find all references to <codeph>TMMCCommandDesc::iTotalLength</codeph>.
+There are two areas in the code where this data member can be referenced: </p> <ul>
+<li id="GUID-626ACF48-ADD0-5530-8CDB-373A3855FF81"><p>code where you test
+the progress of the data transfer operation and set up the MMC command. Do
+not change this code, because <codeph>TMMCCommandDesc::iTotalLength</codeph> still
+represents the total amount of data to be transferred. </p> </li>
+<li id="GUID-25A1A62A-9B80-5ACB-B9BB-6884B4331CD7"><p>code where you set up
+the DMA controller to transfer a number of blocks of data. Replace references
+to <codeph>TMMCCommandDesc::iTotalLength</codeph> with calls to <xref href="GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A.dita#GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A/GUID-65B1C01B-1C8D-373A-83DB-0CEFF17667FC"><apiname>TMMCCommandDesc::BufferLength()</apiname></xref>.
+This describes the size of the current segment. Note that if double buffers
+are not enabled, the value returned by this function is the same as <codeph>TMMCCommandDesc::iTotalLength</codeph>. </p> </li>
+</ul> </li>
+<li id="GUID-860835C7-D3FD-5727-9ADA-60E080EB1669"><p>You can use the function <xref href="GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A.dita#GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A/GUID-DFD121A5-0C03-31A3-AF20-6E693EDC8502"><apiname>TMMCCommandDesc::IsDoubleBuffered()</apiname></xref> to
+determine if the current transaction uses double buffers. </p> </li>
+</ul> <p><b>Separate the command and data phases </b> </p> <p>Without double buffer
+behavior, a single MMC command is always associated with a single buffer into
+which the hardware transfers data. With double buffer behavior, multiple buffers
+or segments are used to transfer data within a single command. You need to
+separate the command and data transfer phases. </p> <p>This code fragment
+is a simplified example of a platform specific layer that sets up the command
+and the data transfers in separate stages: </p> <codeblock id="GUID-D349BEBB-E983-59AA-AA7F-29928D5491F5" xml:space="preserve">   
+   TMMCErr DExampleMMCStack::IssueMMCCommandSM()
+    {
+    enum states
+        {
+        EStBegin=0,
+        EStSetUpCommand,
+        EStWaitComplete,
+        EStEnd
+        };
+    
+       TMMCCommandDesc&amp; cmd = Command();
+    
+    SMF_BEGIN
+
+       /** ...omitted for clarity */
+         
+    SMF_STATE(EStSetUpCommand)
+                 
+       /**
+        * Set up the controller to issue the command.  Depending on
+        * the command type, this will prepare DMA transfers and wait
+        * for a response to be received before unblocking the stack.
+        */
+       BlockCurrentSession(KMMCBlockOnASSPFunction);
+    
+       SetupCommand(cmd);
+        
+       If(iDataTransfer)
+          SetupDataTransfer(cmd);
+
+        /**
+        * Wait for all events to be received
+        *  - command sent, data transferred, response received
+        */
+       SMF_WAITS(EStWaitComplete);
+         
+    SMF_STATE(EStWaitComplete)
+
+       /**
+        * Command issued, data transferred and response received.
+        *  - check for and report any errors
+        *
+        *  - Note, functionality omitted for clarity – in practice this will
+        *    check the controller status and wait for more events as appropriate.
+        */
+       TMMCErr err = KMMCErrNone;
+
+       if(iResponseExpected)
+          err = ExtractResponse();
+
+       if(iDataTransfer &amp;&amp; err == KMMCErrNone)
+          err = CheckDataTransferErrors();
+
+       if(err)
+           SMF_RETURN(err);
+
+    SMF_END
+    }
+
+</codeblock> <p>If you depend on the MMC controller to signal the completion
+of data transfer after all blocks have been transmitted or received, change
+the DMA controller. Change the code to block the stack when DMA transfer starts,
+and unblock the stack when the current DMA transfer finishes. Do this operation
+while you wait for the final interrupt that signals the end of the data transfer. </p> <p>The
+following code fragment shows how to set the <xref href="GUID-8A9A2DD2-C630-3651-8374-17BCF2A09AC4.dita"><apiname>KMMCBlockOnASSPFunction</apiname></xref> blocking
+condition before the start of DMA transfer. After DMA transfer has finished,
+unblock the stack in the DMA complete service routine, <xref href="GUID-8B538AA6-9489-309F-8756-2474310CD5DA.dita"><apiname>DmaService()</apiname></xref>. </p> <codeblock id="GUID-FC9573C5-7A01-536B-8DA4-82F6DB493849" xml:space="preserve">
+   void DExampleMMCStack::SetupDataTransfer(const TMMCCommandDesc&amp; aCmd)
+      {
+      TUint8* bufPtr = reinterpret_cast&lt;TUint8*&gt;(aCmd.iDataMemoryP);
+      TUint32 bufLen = aCmd.BufferLength();
+
+      /** ...omitted for clarity */
+
+      BlockCurrentSession(KMMCBlockOnASSPFunction);
+      iDmaController::Start(aCmd.Direction(), bufPtr, bufLen);
+      }
+
+
+   void DExampleDmaController::DmaService()
+      {
+      /** ...omitted for clarity */
+
+      Session().iState |= KMMCSessStateDoDFC;
+      UnBlockCurrentSession(KMMCBlockOnASSPFunction, KErrNone);
+      }
+</codeblock> <p><b>Implement the double buffer state machine </b> </p> <p>Update the platform
+specific layer to implement the double buffer state machine. You use the function <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita#GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A/GUID-32596EBB-4315-3EF7-8175-8579DE69F78B"><apiname>DMMCSession::RequestMoreData()</apiname></xref>.
+The platform specific layer uses this function to tell the MMC subsystem to
+prepare the next segment for data transfer. You call this function when the
+hardware is busy performing a DMA transfer for the current segment. This allows
+the MMC Media Driver to copy data to/from the client process ready for the
+next transfer while the MMC card is transferring it’s current payload. </p> <p>This
+function sets the static <codeph>KMMCBlockOnMoreData</codeph> blocking condition.
+The platform specific layer must use <codeph>SMF_WAITS</codeph> (or equivalent)
+to suspend the platform specific layer state machine until the media driver
+has processed the current segment. When finished, the command descriptor is
+populated with the details of the next segment to be transferred. The <codeph>KMMCBlockOnMoreData</codeph> block
+condition set by this function can be set with the <codeph>KMMCBlockOnASSPFunction</codeph> condition.
+It allows the hardware to perform useful work, (for example, transfer the
+current buffer to or from the card) while the media driver is busy preparing
+the next buffer. In this case, the platform specific layer is unblocked when
+both the hardware and media driver have completed their tasks. </p> <p>The
+following code fragment shows how you do this: </p> <codeblock id="GUID-97151CF9-2C59-57D3-8856-8BCAB9BDC5B9" xml:space="preserve">TMMCErr DExampleMMCStack::IssueMMCCommandSM()
+    {
+    enum states
+       {
+       EStBegin=0,
+       EStSetUpCommand,
+   EStWaitDataTransfer
+       EStWaitComplete,
+       EStEnd
+       };
+    
+       TMMCCommandDesc&amp; cmd = Command();
+    
+    SMF_BEGIN
+
+       /** ...omitted for clarity */
+         
+    SMF_STATE(EStSetUpCommand)
+                 
+       /**
+        * Set up the controller to issue the command.  Depending on
+        * the command type, this will prepare DMA transfers and wait
+        * for a response to be received before unblocking the stack.
+        */
+       BlockCurrentSession(KMMCBlockOnASSPFunction);
+    
+       SetupCommand(cmd);
+        
+       If(iDataTransfer)
+      {
+          /**
+       * Kick off DMA transfer for the first buffer.
+           * …the stack will be blocked on KMMCBlockOnASSPFunction until DMA complete
+       */
+          SetupDataTransfer(cmd);
+      
+      /**
+       * DMA is now active. Now request the Media Driver to prepare the next 
+       * buffer in parallel. While active, the stack will be blocked with
+       * the KMMCBlockOnMoreData blocking condition and unblocked when complete.
+       */
+      Session().RequestMoreData();      
+      }
+
+        /**
+        * Wait for DMA and Media Driver completion.
+        */
+       SMF_WAITS(EStWaitDataTransfer);
+         
+    SMF_STATE(EStWaitDataTransfer)
+
+       /**
+        * DMA is complete and the Media Driver has prepared the next buffer.
+        *  - Start the next DMA transfer and request more data from the media driver.
+        */
+
+       if(cmd.BufferLength() &gt; 0)
+          {
+          /**
+           * There is more data to transfer.
+           * ..start DMA transfer, prepare the next buffer and wait for completion.
+           */
+          SetupDataTransfer(cmd);
+      Session().RequestMoreData();      
+          SMF_WAITS(EStWaitDataTransfer);
+          }
+
+       /**
+        * There is no more data to transfer.
+        * ..do whatever we need to do to wait for hardware completion
+        */
+
+       // …omitted for clarity
+
+   SMF_WAITS(EStWaitComplete);
+
+    SMF_STATE(EStWaitComplete)
+
+       /**
+        * Command issued, data transferred and response received.
+        *  - check for and report any errors
+        *
+        *  - Note, functionality omitted for clarity – in practice this will
+        *    check the controller status and wait for more events as appropriate.
+        */
+       TMMCErr err = KMMCErrNone;
+
+       if(iResponseExpected)
+          err = ExtractResponse();
+
+       if(iDataTransfer &amp;&amp; err == KMMCErrNone)
+          err = CheckDataTransferErrors();
+
+       if(err)
+          SMF_RETURN(err);
+
+    SMF_END
+    }
+</codeblock> <p><b>Register support for double buffers with the platform independent layer </b> </p> <p>You
+must tell the <xref href="GUID-40F2BC43-5022-5F4E-B445-56FEF43FEB8B.dita#GUID-40F2BC43-5022-5F4E-B445-56FEF43FEB8B/GUID-119E4B4A-03DB-5C79-AA97-14434E4BC2CA">platform
+independent layer</xref> that you support double buffers. Set <xref href="GUID-3F9D89E8-44F0-35B3-9404-6CCAC79763E8.dita#GUID-3F9D89E8-44F0-35B3-9404-6CCAC79763E8/GUID-B11D1DA9-89C2-37E3-A2CD-19EF5706ACB8"><apiname>TMMCMachineInfo::ESupportsDoubleBuffering</apiname></xref> into
+the <xref href="GUID-3F9D89E8-44F0-35B3-9404-6CCAC79763E8.dita"><apiname>TMMCMachineInfo</apiname></xref> object that you pass to <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-CEF0EDF7-4B33-5452-8635-51C5319F78AE">DMMCStack::MachineInfo()</xref>. </p> <p><b>Choose the size of the buffer </b> </p> <p>To choose the optimum size
+of buffer, you must perform benchmark tests on your system. A small buffer
+gives you a lower command setup latency, but DMA transfers and calls to the
+callback function <xref href="GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A.dita#GUID-0186BEDE-8E28-3F8C-8CAE-A8B92F41F47A/GUID-32596EBB-4315-3EF7-8175-8579DE69F78B"><apiname>DMMCSession::RequestMoreData()</apiname></xref> occur
+more frequently. The time taken to set up the DMA transfers can exceed the
+time taken to transfer the data into or out of the active segment. </p> <p><b>Testing </b> </p> <p>You need to do the standard E32 and F32 automated
+tests to check the operation of the MMC subsystem. You also need to perform
+the MMC specific manual test, T_MMCDRV. The test listed below performs data
+transfers in excess of the PSL buffer size to make sure that double buffer
+behavior is exercised. </p> <codeblock id="GUID-ED1D5B35-432C-5C54-9A13-92DD499316FD" xml:space="preserve">   
+   /**
+   @SYMTestCaseID PBASE-T_MMCDRV-0558
+   @SYMTestCaseDesc Test Long Read/Write Boundaries
+   @SYMTestPriority High
+
+   @SYMTestActions  
+
+   Perform and Write/Read/Verify for the given length (L) of data across the following boundaries.
+   Depending on the length, this will also perform a partial write/read at the end sector.
+
+             --------------
+            | Start    | End    |
+            |--------------|
+            | 0    | L    |
+            | 507    | L-507    |
+            | 10    | L    |
+            | 0    | L-3    |
+            | 27    | L-512    |
+            | 0    | L-509    |
+            | 3    | L-3    |
+             --------------
+
+   For each combination, the write/read/verify operations are performed in the following sequence:
+
+a: Write and Read in single 512-byte blocks.
+b: Write in a single operation (multiple blocks), Read in 512-Byte blocks.
+c: Write in 512-Byte blocks, Read in a single operation (multiple-blocks).
+d: Write and Read in a single operation (multiple-blocks).
+
+   In the cases where a partial read/write operation occurs (ie - the start and/or end position
+   don't lie within a sector boundary), the original contents of the start and/or end sectors are
+   read and stored at the start of the test, and compared with the contents of the sectors at the
+   end of the test to ensure that unwritten data within the sectors remain unaffected.
+  
+   @SYMTestExpectedResults All tests must pass
+
+   @SYMPREQ1389 REQ6951 Double Buffering and SD Switch
+   *
+   */
+
+</codeblock> <p>The test T_MMCDRV must be performed on versions of the platform
+specific layer that has: double buffers enabled, double buffers disabled,
+and with a number of different buffer sizes (for example, from 32k to 256k). </p> <p>The
+test cannot dynamically set the size of the buffer. You must do manual configuration
+of the buffer to test all configurations. </p> <p>To measure performance,
+use T_FSYSBM, with and without double buffers enable. </p> <p id="GUID-575211BC-BF66-5817-9825-EE402648D0CD"><b>Register support for physical
+addresses</b> </p> <p>There are three items to do: </p> <ul>
+<li id="GUID-0E169605-00B8-53F9-AF7A-5410EEE73A70"><p>you must tell the <xref href="GUID-40F2BC43-5022-5F4E-B445-56FEF43FEB8B.dita#GUID-40F2BC43-5022-5F4E-B445-56FEF43FEB8B/GUID-119E4B4A-03DB-5C79-AA97-14434E4BC2CA">platform
+independent layer</xref> that you support physical addresses in your implementation
+of <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-CEF0EDF7-4B33-5452-8635-51C5319F78AE">DMMCStack::MachineInfo()</xref>.
+The function takes a <xref href="GUID-3F9D89E8-44F0-35B3-9404-6CCAC79763E8.dita"><apiname>TMMCMachineInfo</apiname></xref> type. Set the <xref href="GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6.dita#GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6/GUID-CB8D99BA-8EC2-3A98-B3BF-BA5FEE3A6AE1"><apiname>THardwareConfig::ESupportsDMA</apiname></xref> flags
+into the <codeph>iFlags</codeph> member of <xref href="GUID-3F9D89E8-44F0-35B3-9404-6CCAC79763E8.dita"><apiname>TMMCMachineInfo</apiname></xref>. </p> <p>If
+you set the <xref href="GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6.dita#GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6/GUID-CB8D99BA-8EC2-3A98-B3BF-BA5FEE3A6AE1"><apiname>THardwareConfig::ESupportsDMA</apiname></xref> flag, you also
+set the <xref href="GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6.dita#GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6/GUID-3276FBA3-7028-30C2-A820-CEBD77DCF817"><apiname>THardwareConfig::ESupportsDoubleBuffering</apiname></xref> flag
+automatically. This flag enables double buffer support. You must also<xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-E50081BC-C923-5DAF-950C-9E1411916FED">implement
+double buffers</xref> if you use physical addresses. </p> </li>
+<li id="GUID-752318C6-301B-51B0-A064-64EAEBCF0E35"><p>You must tell the <xref href="GUID-40F2BC43-5022-5F4E-B445-56FEF43FEB8B.dita#GUID-40F2BC43-5022-5F4E-B445-56FEF43FEB8B/GUID-119E4B4A-03DB-5C79-AA97-14434E4BC2CA">platform
+independent layer</xref> the maximum transfer length that you support. This
+can be a limit imposed on you by the hardware. For example, if you use DMA,
+the DMA controller can impose a limit. You set one of the flags listed below
+into the <codeph>iFlags</codeph> member of <xref href="GUID-3F9D89E8-44F0-35B3-9404-6CCAC79763E8.dita"><apiname>TMMCMachineInfo</apiname></xref> in
+your implementation of <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-CEF0EDF7-4B33-5452-8635-51C5319F78AE">DMMCStack::MachineInfo()</xref>. </p> <p>Each flag represents a maximum transfer length. The MultiMediaCard
+subsystem splits a data transfer request that is bigger than the maximum into
+multiple data transfers. </p> <ul>
+<li id="GUID-1BD38D21-6B02-5610-8495-4C7C194657CF"><p> <xref href="GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6.dita#GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6/GUID-3375EE8E-49B8-3F24-BF40-D780AD8E1B0A"><apiname>THardwareConfig::EMaxTransferLength_256K</apiname></xref> </p> </li>
+<li id="GUID-D4AB6165-036A-5259-922A-E9E1CB5749C8"><p> <xref href="GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6.dita#GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6/GUID-F3BEFC8A-55F6-3B28-B383-6B33BAD2B5F7"><apiname>THardwareConfig::EMaxTransferLength_512K</apiname></xref> </p> </li>
+<li id="GUID-72380863-E20E-5478-98D8-FA342C14E80C"><p> <xref href="GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6.dita#GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6/GUID-20FB2892-190F-31C4-9F58-66AAB02DC4E1"><apiname>THardwareConfig::EMaxTransferLength_1M</apiname></xref>  </p> </li>
+<li id="GUID-68C4292C-5D9D-5E23-8608-DFBA2846A8FA"><p> <xref href="GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6.dita#GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6/GUID-45913568-5C4E-3A6F-A727-8734C303AC3D"><apiname>THardwareConfig::EMaxTransferLength_2M</apiname></xref>  </p> </li>
+<li id="GUID-D637F68D-4530-5BE5-9B99-A7437E7AF9BC"><p> <xref href="GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6.dita#GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6/GUID-66707CB4-A8E0-305E-9599-D22CBBC41E91"><apiname>THardwareConfig::EMaxTransferLength_4M</apiname></xref>  </p> </li>
+<li id="GUID-69AD58F1-06F6-564C-B130-BDBF8F1745BB"><p> <xref href="GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6.dita#GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6/GUID-DA25B30F-671C-3B54-B58D-9F58B17BC11F"><apiname>THardwareConfig::EMaxTransferLength_8M,</apiname></xref>  </p> </li>
+<li id="GUID-AAE1868C-8C51-58DE-8F29-34463E0F7104"><p> <xref href="GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6.dita#GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6/GUID-565830C3-14D4-3AA7-990E-78A199275DDF"><apiname>THardwareConfig::EMaxTransferLength_16M</apiname></xref>  </p> </li>
+<li id="GUID-BFC9B360-8023-5AC5-A2FC-F52A7D6BFD06"><p> <xref href="GUID-FA278485-D2CC-35D8-A779-8F0BDB691C3F.dita"><apiname>TMMCMachineInfoV4.iFlags</apiname></xref>  </p> </li>
+</ul> </li>
+<li id="GUID-54BCDD97-4E54-52D5-9526-BFAC5041F8F8"><p>You must tell the <xref href="GUID-40F2BC43-5022-5F4E-B445-56FEF43FEB8B.dita#GUID-40F2BC43-5022-5F4E-B445-56FEF43FEB8B/GUID-119E4B4A-03DB-5C79-AA97-14434E4BC2CA">platform
+independent layer</xref> the address scheme that the hardware uses. Mis-alignment
+of memory can corrupt data. You set <i>one</i> of the flags shown in the list
+below into the <codeph>iFlags</codeph> member of <xref href="GUID-3F9D89E8-44F0-35B3-9404-6CCAC79763E8.dita"><apiname>TMMCMachineInfo</apiname></xref> in
+your implementation of <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-CEF0EDF7-4B33-5452-8635-51C5319F78AE">DMMCStack::MachineInfo()</xref>. Each flags represents a different address scheme. You can set only one
+flag. If you set more than one of these flags, the creation of the media driver
+fails. </p> <ul>
+<li id="GUID-3055EE71-56B8-566A-A2B8-6F415F2D1675"><p> <xref href="GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6.dita#GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6/GUID-A36BA08C-2010-3002-8FB2-A8E917700604"><apiname>THardwareConfig::EDma8BitAddressing</apiname></xref>  </p> </li>
+<li id="GUID-C71091D1-7E53-530B-8AE6-37BD9125B8B2"><p> <xref href="GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6.dita#GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6/GUID-DA9AE183-855B-31A0-BDE3-54BFE894C1F8"><apiname>THardwareConfig::EDma16BitAddressing</apiname></xref>  </p> </li>
+<li id="GUID-6402A30F-4A49-528B-BF74-EB715521773B"><p> <xref href="GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6.dita#GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6/GUID-6D844C49-AD50-3C73-BEA8-473A44B9E9D4"><apiname>THardwareConfig::EDma32BitAddressing</apiname></xref>  </p> </li>
+<li id="GUID-F10F9E09-151D-5BB2-B1B6-B0B08B49B8F6"><p> <xref href="GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6.dita#GUID-9E833DE8-E795-3EC8-B27B-CFB6D7E1C4C6/GUID-6F43817F-611B-326C-8A1C-55703FFC6500"><apiname>THardwareConfig::EDma64BitAddressing</apiname></xref>  </p> </li>
+</ul> </li>
+</ul> <p>The following code is an example implementation of <xref href="GUID-B5193656-9819-3E00-A335-EEF1726115A5.dita#GUID-B5193656-9819-3E00-A335-EEF1726115A5/GUID-3E5532A5-4645-3F77-A7A9-7AFF334FA5A4"><apiname>DMMCStack::MachineInfo()</apiname></xref>. </p> <codeblock id="GUID-BF942E07-A7E8-5300-9015-3FC06CAB835E" xml:space="preserve">void DVariantMmcHwStack::MachineInfo(TMMCMachineInfoV4&amp; aMachineInfo)
+/**
+ * Gets the machine info for the hardware variant
+ *
+ * @param aMachineInfo    Info structure to populate
+ */
+    {
+    aMachineInfo.iTotalSockets=MMC_DRIVECOUNT;
+    aMachineInfo.iTotalMediaChanges=0;          // Not used at present
+    aMachineInfo.iTotalPrimarySupplies=0;        // Not used at present
+    
+    aMachineInfo.iBaseBusNumber=0;
+    aMachineInfo.iVersion = TMMCMachineInfoV4::EVersion4;
+    aMachineInfo.iMaxBusWidth = EBusWidth4;
+
+    // Report support for Physical Addressing
+    aMachineInfo.iFlags  = TMMCMachineInfo::ESupportsDMA;
+    aMachineInfo.iFlags |= TMMCMachineInfo::EMaxTransferLength_1M; 
+    aMachineInfo.iFlags |= TMMCMachineInfo::EDma16BitAddressing;
+
+    // High voltage (3.6V) power class. Set to maximum = 2000mA RMS
+    aMachineInfo.iHighVoltagePowerClass = TMMCMachineInfoV4::EHi200mA;
+
+    // Low voltage (1.95V) power class. Set to maximum = 200mA RMS
+    aMachineInfo.iLowVoltagePowerClass = TMMCMachineInfoV4::ELo200mA;
+    
+    // 52 Mhz clock supported
+    aMachineInfo.iMaxClockSpeedInMhz = TMMCMachineInfoV4::EClockSpeed52Mhz;    
+    }</codeblock> <p id="GUID-27FCEF7D-0AAB-599C-8405-4BD284308314"><b>Modify the data transfer
+phase to handle physical memory </b> </p> <p>The implementation of double
+buffers has separated the command setup and the data transfer phases. You
+need to change the data transfer phase to handle physical memory. </p> <ul>
+<li id="GUID-59E7DD5F-39B6-5CA5-9C8C-CC4847A885DC"><p>The data member <xref href="GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A.dita#GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A/GUID-596E150B-E5F1-3945-9C00-64B8EB24550C"><apiname>TMMCCommandDesc::iDataMemoryP</apiname></xref> contains
+the source or target memory address for the current data transfer command.
+Use the function <xref href="GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A.dita#GUID-6B3DDBFD-3A4A-3694-A058-7794700FEC7A/GUID-3A25BD15-A832-3C76-AB68-0B4470710C3A"><apiname>TMMCCommandDesc::IsPhysicalAddress()</apiname></xref> to
+determine if this address is a physical address or a virtual address. If you
+do not <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-575211BC-BF66-5817-9825-EE402648D0CD">register
+support for physical addresses</xref>, this function always returns <xref href="GUID-A759CA2D-8327-348F-9337-4886E619D920.dita"><apiname>EFalse</apiname></xref>. </p> </li>
+<li id="GUID-B9D101C4-FDD1-5233-9DCB-12DDA47073FC"><p>You do not need to perform
+virtual address to physical address translation on physical addresses. </p> </li>
+<li id="GUID-2382A7A0-B0EB-5E1F-9ADE-47389FABABBA"><p>you do not need to perform
+DMA synchronization for physical addresses, because the local media subsystem
+performs DMA synchronization for you. You need to perform DMA synchronization
+for virtual addresses. DMA synchronization is performed by calls to <xref href="GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F.dita#GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F/GUID-3FF3C567-C1BD-3D4E-97E1-B036456A374E"><apiname>Cache::SyncMemoryBeforeDmaRead()</apiname></xref> or <xref href="GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F.dita#GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F/GUID-5F08DEAA-1237-32DE-AE41-CE7B18230972"><apiname>Cache::SyncMemoryBeforeDmaWrite()</apiname></xref>. </p> </li>
+</ul> <p>The following code is an example of the changes needed for a read
+operation. </p> <codeblock id="GUID-B92D3E0B-09F3-54C9-83AE-34DA544C0055" xml:space="preserve">TInt DMMCDmaRx::Start(const TMMCCommandDesc&amp; aCmd)
+/**
+ *  Queues a DMA request after checking the buffer alignment constraints.
+ *
+ *  @param aCmd The command structure containing the details about the command.
+ */
+{
+   …
+   TUint flags = KDmaMemDest;
+
+   // Check if a physical address has been provided with this request
+   if(aCmd.IsPhysicalAddress())
+{
+       // …if so, set the appropriate flag for this DDmaRequest
+flags |= KDmaPhysAddrDest;
+}
+
+   TInt retval = iRequest-&gt;Fragment(    KMMC_Buf_Dt_Reg,
+                                        (TUint32)aCmd.iDataMemoryP,
+                aCmd.BufferLength(), 
+                                 flags,
+                                 0 /* no HW Flags*/);
+
+   if(retval != KErrNone)
+Kern::Fault("MMC DMA RX Start Fragment", retval);
+
+   …
+   return KErrNone;
+}
+</codeblock> <codeblock id="GUID-AB1E5042-8680-57C4-87F7-71F362232C37" xml:space="preserve">void DMMCRxDmaHelp::ChannelTransfer(const SDmaPseudoDes&amp; aDes)
+    {
+…
+    TPhysAddr dest;
+
+// Don’t perform Linear to Physical translation if we 
+    // have already been supplied with a Physical Address
+    if (aDes.iFlags &amp; KDmaPhysAddrDest)
+        dest = (TPhysAddr) aDes.iDest;
+    else
+        dest = Epoc::LinearToPhysical(aDes.iDest);
+
+    TPlatDma::SetDMARegister(KHoDMA_CDSA(iChno), dest);
+…
+    }
+</codeblock> </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-E55B594F-CC84-5984-9307-9819F6EBEB7F-master.png has changed
Binary file Adaptation/GUID-E55B594F-CC84-5984-9307-9819F6EBEB7F_d0e29647_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E6F9A60A-0112-4C9B-A880-7E2908A74DAA.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E6F9A60A-0112-4C9B-A880-7E2908A74DAA" xml:lang="en"><title>Interrupt</title><shortdesc>Describes the Interrupt platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E7C55048-5B7A-5BF2-B7F4-4D731659B88C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,206 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E7C55048-5B7A-5BF2-B7F4-4D731659B88C" xml:lang="en"><title>Device
+Driver Writing and Migration Technology Tutorial</title><shortdesc>Explains techniques for writing device drivers on data paged systems
+and migrating device drivers to data paged systems. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-8629C08B-C1C8-4435-962A-A57F11EB25CF"><title>Impact of data
+paging on kernel APIs</title> <p>The use of data paging impacts on the task
+of writing and migrating device drivers in two main ways: the preconditions
+for kernel API calls and the performance of the kernel APIs. </p> <p>Firstly,
+kernel APIs which access user memory may only be called subject to preconditions.
+The preconditions are that </p> <ul>
+<li id="GUID-81B56316-97C6-5EE8-BD88-D0741F9301F9"><p>no fast mutex may be
+held while calling them, and </p> </li>
+<li id="GUID-507412E1-1CA8-5590-B974-809B51C3D79D"><p>no kernel mutex may
+be held while calling them. </p> </li>
+</ul> <p>The APIs are these: </p> <ul>
+<li id="GUID-7A4E9152-8BFA-515E-A115-265436C843F4"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-C154A151-0DF7-345D-9A10-E9B1CF3400D9"><apiname>Kern::KUDesInfo</apiname></xref>  </p> </li>
+<li id="GUID-3C31D5D3-48E9-5D6D-8489-8259D98BF117"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-FAFAA120-AA28-32FD-9202-1534C3148026"><apiname>Kern::InfoCopy</apiname></xref>  </p> </li>
+<li id="GUID-FCE0C3D6-EE49-5AC9-856E-9833D22D541A"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-B79007D0-FF1F-30E7-986D-7CEBC5E45102"><apiname>Kern::KUDesGet</apiname></xref>  </p> </li>
+<li id="GUID-72D4E609-B189-570A-B4D6-D2F4F1289EC1"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-CDEA7B22-9520-3DB1-AA04-1289C2287936"><apiname>Kern::KUDesPut</apiname></xref>  </p> </li>
+<li id="GUID-EE2D8F45-5B12-5D69-A9FD-7ED47A0B5EAD"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-94F2DF65-87A5-32C6-9695-9557E5832ACF"><apiname>Kern::KUDesSetLength</apiname></xref>  </p> </li>
+<li id="GUID-46805316-D1D5-5477-8287-FBF43DD8D3C4"><p> <xref href="GUID-EE4CB2B4-EAFC-3721-BF0D-ECDF96C29FBF.dita"><apiname>umemget</apiname></xref>, <xref href="GUID-E569834D-8960-3D4E-8980-64902200D4F8.dita"><apiname>kumemget</apiname></xref>, <xref href="GUID-388FF557-3092-3EA0-BF4A-D73504521CD0.dita"><apiname>umemget32</apiname></xref>, <xref href="GUID-874BB607-F0CA-3123-AB2D-D04F4763B16A.dita"><apiname>kumemget32</apiname></xref>  </p> </li>
+<li id="GUID-DB8BF5C7-2444-5B8F-8F66-12383ECB6A81"><p> <xref href="GUID-71B53E34-1F41-3B53-8133-D76D8847D143.dita"><apiname>umemput</apiname></xref>, <xref href="GUID-7B0CC157-0EF6-3CF5-BAF2-D8227F7734A5.dita"><apiname>kumemput</apiname></xref>, <xref href="GUID-A6303814-456F-3583-86B0-A99EA5C3E5A4.dita"><apiname>umemput32</apiname></xref>, <xref href="GUID-B00A6392-9A90-357E-B6A2-D2762800C2C5.dita"><apiname>kumemput32</apiname></xref>  </p> </li>
+<li id="GUID-9E6B180A-B360-58A6-B60E-8605E22F2C2E"><p> <xref href="GUID-BBF5941C-3369-3B56-A560-6E80A7CFFE0F.dita"><apiname>umemset</apiname></xref>, <xref href="GUID-08C2BCA6-6842-3D10-AB56-835B618317F9.dita"><apiname>kumemset</apiname></xref>, <xref href="GUID-B48B5214-ACDD-3E9B-AE07-1B40F645D959.dita"><apiname>umemset32</apiname></xref>, <xref href="GUID-5C1EB135-F9A7-37A5-B256-299CB9598DA9.dita"><apiname>kumemset32</apiname></xref>  </p> </li>
+<li id="GUID-F307081B-7672-5C3F-869C-9B4B4F55CE62"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-D0FCFD5B-2814-3D81-A54A-9E2FA226019B"><apiname>Kern::RequestComplete</apiname></xref>  </p> </li>
+<li id="GUID-647B36DF-2124-5252-824E-E100695624C2"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-589188FC-48E8-3973-B88B-D9E47CFE4403"><apiname>Kern::ThreadRawRead</apiname></xref>  </p> </li>
+<li id="GUID-9776CFD1-B061-5FC1-B100-0A55D7E8BFA5"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-68BFCE22-E05E-3710-9014-6E72FDE7891F"><apiname>Kern::ThreadRawWrite</apiname></xref>  </p> </li>
+<li id="GUID-21F695FF-8933-5FF4-84DC-1F09056E36A6"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-451FD979-14A8-3301-A389-7B509C969FE9"><apiname>Kern::ThreadDesRead</apiname></xref>  </p> </li>
+<li id="GUID-B477D969-B73E-514B-8E40-565EE6C4490E"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-B4A7AF78-179A-378B-9184-CCC2E31830F5"><apiname>Kern::ThreadDesWrite</apiname></xref>  </p> </li>
+<li id="GUID-C8080F75-2F3B-5DBE-B0DE-D8518ED49516"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-6668EA8F-AA55-3CB4-ADEA-879579E94729"><apiname>Kern::ThreadGetDesLength</apiname></xref>  </p> </li>
+<li id="GUID-8D644BB0-9A01-5248-8DD2-95CDAE058B09"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-53813A59-7CED-39E2-818A-D9E0374D2BFD"><apiname>Kern::ThreadGetDesMaxLength</apiname></xref>  </p> </li>
+<li id="GUID-746E54A0-C6D0-5B90-89F3-D197DD04470C"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-60E5E01D-2965-3E33-BC05-052A575303F8"><apiname>Kern::ThreadGetDesInfo</apiname></xref>  </p> </li>
+</ul> </section>
+<section id="GUID-8C767668-D568-40E4-82F7-DD6FC6EA8132"><title>Impact of data
+paging on execution</title> <p>Device drivers use kernel side APIs to access
+user memory, and even when they are called in accordance with their preconditions
+they are no longer guaranteed to execute in a short and bounded time. This
+is because they may access paged memory and incur page faults which propagate
+from one thread to another. This document discusses how to mitigate the impact
+of data paging on device drivers. </p> </section>
+<section id="GUID-3903425C-EA48-44D6-B65E-253F583465BF"><title>Mitigating
+data paging: general principles</title> <p>Three general principles are involved
+in mitigating the impact of data paging on device drivers. </p> <ul>
+<li id="GUID-955ACDFA-CA71-5489-920F-B2F74039EA37"><p>Device drivers should
+not use shared DFC queues. </p> </li>
+<li id="GUID-3FD4823A-C1A0-53B2-8987-45313BC984C3"><p>Device drivers should,
+as far as possible, not access paged memory. </p> </li>
+<li id="GUID-3557B245-D479-5FA3-B039-092A8F1B7E06"><p>If a device driver needs
+to access paged memory, it should do so in the context of the client thread. </p> </li>
+</ul> </section>
+<section id="GUID-BE00235A-D227-4290-B3FA-93B20966073F"><title>Driver frameworks</title> <p>There
+are three main categories of device driver: </p> <ul>
+<li id="GUID-EAD164EF-A615-5AFE-A512-032C1C0CC0AC"><p><b>Boot-Loaded Non-Channel
+Drivers</b></p><p>Boot loaded drivers are built as kernel extensions. They
+are typically simple device drivers such as keyboard drivers with limited
+or no client side interface and are not much impacted by data paging. It is
+generally safe for them to pass data structures using the HAL in the context
+of a kernel thread and for them to execute in the context of a kernel thread:
+however, this assumption must always be verified for individual cases. </p></li>
+<li id="GUID-B82465B7-6306-5AAC-B6B4-FB5A4D07EBB2"><p><b>Media Drivers</b> </p><p>Media
+drivers are both channel based drivers and kernel extensions. When written
+according to the recommended model they either execute wholly in the context
+of their clients or use a unique DFC queue and associated kernel thread. If
+these recommendations are followed, no additional measures to mitigate the
+impact of data paging are required. </p> </li>
+<li id="GUID-86AB0CC9-B147-5019-837C-B2A6B32A9F6B"><p><b>Dynamically loaded
+channel based IO device drivers</b> </p><p>Channel based IO device drivers
+are based on various models: all are dynamically loaded. They are derived
+either from <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita"><apiname>DLogicalChannelBase</apiname></xref> or <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita"><apiname>DLogicalChannel</apiname></xref>.
+  </p><p>Channel based drivers derived from <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita"><apiname>DLogicalChannelBase</apiname></xref> usually
+execute in the context of their client, mitigating the impact of data paging.
+Where they are multi-threaded, they typically create separate and unique kernel
+threads and do not use shared DFC queues, mitigating the impact of data paging:
+if they use a shared DFC queue and associated kernel thread, they are impacted
+by data paging and must be written so as to mitigate the effects.  Channel
+based drivers derived from <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita"><apiname>DLogicalChannel</apiname></xref> may communicate
+with the hardware directly (LDD to hardware) or indirectly (LDD to PDD to
+hardware). If a PDD is involved, mitigation of data paging should take place
+at that level and not the LDD.   Channel based drivers may have single or
+multiple clients, channels and hardware. It is these drivers which require
+most work to mitigate the impact of data paging. </p> </li>
+</ul> </section>
+<section id="GUID-6CD39776-B448-4F7D-8EC2-727AF13B575B"><title>Mitigation
+techniques</title> <p>The impact of data paging on device drivers is mitigated
+by the use of various different techniques which are the subject of the rest
+of this document. </p> <p><b>Passing
+data by value</b> </p> <p>Clients should pass data by value not as pointers.
+Return values of calls should be return codes not data. </p> <p><b>Using dedicated DFC queues</b> </p> <p>All drivers which use DFCs should
+use a dedicated DFC queue to service them. You should not use the kernel queues <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-96588DB1-6884-300F-A85B-EA14A8A1BFAD"><apiname>Kern::DfcQue0</apiname></xref> and <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-7B1F53D8-7EC2-3A05-9F1B-240550A7283B"><apiname>Kern::DfcQue1</apiname></xref> for this purpose. How you create a dedicated DFC queue depends on the nature
+of the driver. </p> <p>To service boot loaded drivers and media drivers, you
+create a DFC queue by calling <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-F8D26F25-FBFB-3D89-9A80-95719D165C8E"><apiname>Kern::DfcQueueCreate()</apiname></xref>. </p> <p>To
+service dynamically loaded drivers derived from DLogicalChannelBase you call <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-ED1B8C3D-ABFB-37BD-A6E9-4080FCCE115C"><apiname>Kern::DynamicDfcQCreate()</apiname></xref> with
+a <xref href="GUID-D9111A26-FAA3-3D8E-AB41-5B1263FABB6A.dita"><apiname>TDynamicDfcQue</apiname></xref> as argument: </p> <codeblock id="GUID-73C0C08A-6BAC-5526-A987-57079ED762E7" xml:space="preserve">TInt Kern::DynamicDfcQCreate(TDynamicDfcQue*&amp; aDfcQ, TInt aPriority, const TDesC&amp; aBaseName);</codeblock> <p>To service a dynamically loaded driver derived from <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita"><apiname>DLogicalChannel</apiname></xref>,
+you use the DFC queue supplied with it (the member <xref href="GUID-954F5891-8BF3-33B2-9F40-9D80A6D2A17C.dita"><apiname>iDfc</apiname></xref>,
+accessed by pointer). To use the queue you call the <xref href="GUID-2FC8CE8F-102C-3025-86B6-C903D26CD002.dita"><apiname>SetDfcQ()</apiname></xref> function
+during the second phase construction of the LDD. </p> <p>You destroy queues
+by calling their function <xref href="GUID-38F49D2C-2798-37DB-82CC-A49EAB22B829.dita"><apiname>Destroy()</apiname></xref> which also terminates
+the associated thread. </p> <p><b>Setting
+realtime state</b> </p> <p>The realtime state of a thread determines whether
+it is enabled to access paged memory. If a thread is realtime (its realtime
+state is on) it is guaranteed not to access paged memory, so avoiding unpredictable
+delays. The realtime state of a thread may be set to <xref href="GUID-0AD1C6D1-591E-3ED2-A4AA-2486A37AE5CE.dita"><apiname>ERealtimeStateOn</apiname></xref>, <xref href="GUID-19425C4A-0B5F-3D89-B5C9-C5DB7E984D7F.dita"><apiname>ERealtimeStateOff</apiname></xref> and <xref href="GUID-2AB828E6-39A5-377C-87B1-FA0CB886E2D7.dita"><apiname>ERealtimeStateWarn</apiname></xref> as defined in the enumeration <xref href="GUID-C9606015-7E55-338D-BE81-42AF50980F59.dita"><apiname>TThreadRealtimeState</apiname></xref> and
+set by the kernel function <xref href="GUID-802BE082-128E-3F1E-A8D5-304DCDABFCC8.dita"><apiname>SetRealtimeState</apiname></xref>. </p> <p>If
+a driver uses DFC threads and is subject to performance guarantees, their
+realtime state should be set to on (this is the default when data paging is
+enabled). Otherwise the state should be set to off: the warning state is used
+for debugging. </p> <p><b>Validating
+arguments in client context</b> </p> <p>It is often necessary to validate
+the arguments of a request function. This should be done in the context of
+the client thread as far as possible. </p> <p>When a driver derived from the
+class <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita"><apiname>DLogicalChannelBase</apiname></xref> makes a request this happens
+automatically as a call to the <xref href="GUID-92AA62BB-14F1-325D-9A22-9C87AAE0535C.dita"><apiname>Request()</apiname></xref> function takes
+place in the client thread. When the driver is derived from the class <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita"><apiname>DLogicalChannel</apiname></xref> the
+request involves a call to the <xref href="GUID-E31B440A-A98E-30DA-B222-C8BA59A81A0E.dita"><apiname>SendMsg()</apiname></xref> function inherited
+from the base class and it is necessary to override the base implementation
+to force evaluation of the arguments within the client thread. </p> <p><b>Accessing user memory from client context</b> </p> <p>The DFC should access
+user memory as little as possible. Whenever there is a need to access user
+memory and it can be accessed in the context of the client thread, it should
+be. </p> <p>When the driver is derived from the class <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita"><apiname>DLogicalChannelBase</apiname></xref>,
+read and write operations on user memory can be performed with calls to the <xref href="GUID-92AA62BB-14F1-325D-9A22-9C87AAE0535C.dita"><apiname>Request()</apiname></xref> function
+and these take place in the context of the client thread. </p> <p>When the
+driver is derived from the class <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita"><apiname>DLogicalChannel</apiname></xref> it is
+possible to read from and write to user memory by overriding the <xref href="GUID-E31B440A-A98E-30DA-B222-C8BA59A81A0E.dita"><apiname>SendMsg()</apiname></xref> function
+before passing the message on to be processed by the DFC thread if necessary.
+If the message is passed on, data must be stored kernel side either on the
+client thread's kernel stack or in the channel object. </p> <p>Message data
+can only be stored on the client thread's kernel stack if the message is synchronous
+and the size of the data is less than 4Kb. Since the stack is local to the
+client it can be used by more than one thread. One way of doing this is to
+implement <xref href="GUID-E31B440A-A98E-30DA-B222-C8BA59A81A0E.dita"><apiname>SendMsg()</apiname></xref> with a call to <xref href="GUID-4DF8919A-CAA2-36D5-B91B-E26D2A32F5F5.dita"><apiname>SendControl()</apiname></xref> which
+is itself implemented to perform the copying in the client thread context
+and independently call the <xref href="GUID-E31B440A-A98E-30DA-B222-C8BA59A81A0E.dita"><apiname>SendMsg()</apiname></xref> function of the parent
+class. </p> <p>Where the message is asynchronous you can use a similar strategy
+for overriding the <xref href="GUID-E31B440A-A98E-30DA-B222-C8BA59A81A0E.dita"><apiname>SendMsg()</apiname></xref> function but this time perform
+the copying to a buffer owned by the channel independently of a call to the <xref href="GUID-E31B440A-A98E-30DA-B222-C8BA59A81A0E.dita"><apiname>SendMsg()</apiname></xref> function
+of the parent class. In this case the size of the data must be small (in the
+region of 4Kb), there must be only one client using the buffer, and data cannot
+be written back to the client. </p> <p><b>Using
+TClientDataRequest</b> </p> <p>An asynchronous request often needs to copy
+a structure of fixed size to its client to complete a request. The <xref href="GUID-918410AB-63D3-3672-82BE-73289F88C03E.dita"><apiname>TClientDataRequest</apiname></xref> object
+exists for this purpose: it writes a fixed size structure to user memory and
+completes the request in the following steps. </p> <ol id="GUID-100FA302-3292-565D-A0BC-A7314C2E2499">
+<li id="GUID-41BF301F-9FC7-55F8-9346-42262F49B5EE"><p>The driver creates a <xref href="GUID-918410AB-63D3-3672-82BE-73289F88C03E.dita"><apiname>TClientDataRequest</apiname></xref> object
+for each asynchronous client which may be outstanding concurrently: either
+one per client or one per request as appropriate. </p> </li>
+<li id="GUID-D4322A3D-C2F7-52D2-B600-35A65EF460CD"><p>When the client makes
+a request the <xref href="GUID-918410AB-63D3-3672-82BE-73289F88C03E.dita"><apiname>TClientDataRequest</apiname></xref> object is set to contain
+the address of the client's buffer or descriptor and the address of the client's <xref href="GUID-E0B34F3E-D4C4-3232-B8B1-7DB35B454646.dita"><apiname>TRequestStatus</apiname></xref>.
+This takes place in the client context. </p> </li>
+<li id="GUID-6FBED29F-E54D-5C5C-A6E5-8DBA41625338"><p>The data to be written
+is copied into the buffer of the <xref href="GUID-918410AB-63D3-3672-82BE-73289F88C03E.dita"><apiname>TClientDataRequest</apiname></xref> object. </p> </li>
+<li id="GUID-3316EB6E-804D-5CBC-8930-68D8E226C955"><p>A call to <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-DE0CF5BD-B166-3C5B-9E27-F95710322F21"><apiname>Kern::QueueRequestComplete()</apiname></xref> passes
+the address of the <xref href="GUID-918410AB-63D3-3672-82BE-73289F88C03E.dita"><apiname>TClientDataRequest</apiname></xref> object. </p> </li>
+<li id="GUID-39DE78F0-D6E0-582B-B3F1-3AEC6D0E12CE"><p>The client is signalled
+immediately. </p> </li>
+<li id="GUID-5FF0CD64-F05D-5DF2-BD96-6B5966119CA8"><p>When the client thread
+next runs, the buffer contents and completion value are written to the client. </p> </li>
+</ol> <p><b>Using
+TClientBufferRequest</b> </p> <p>When it is necessary to access user memory
+from a DFC thread context, that memory must be pinned for the duration of
+the request and unpinned when the request is completed. The pinning must be
+performed in the context of the client thread. The <xref href="GUID-5CD6D111-213B-31A2-AA46-C5598DDB7249.dita"><apiname>TClientBufferRequest</apiname></xref> object
+exists for this purpose.It is used in the following way. </p> <ol id="GUID-3FEB8983-0BF6-578D-856A-09433AD7182E">
+<li id="GUID-4C3FB914-624A-50FE-94E0-EFF85D6169F8"><p>The driver creates a <xref href="GUID-5CD6D111-213B-31A2-AA46-C5598DDB7249.dita"><apiname>TClientBufferRequest</apiname></xref> object
+for each client request which may be outstanding concurrently: either one
+per client or one per request as appropriate. </p> </li>
+<li id="GUID-CAD03D3A-19E6-5C3D-A203-1726917A50B2"><p>Whe a client makes a
+request, the <xref href="GUID-5CD6D111-213B-31A2-AA46-C5598DDB7249.dita"><apiname>TClientBufferRequest</apiname></xref> object is set to contain
+the address of any buffers used and the address of the client's <xref href="GUID-E0B34F3E-D4C4-3232-B8B1-7DB35B454646.dita"><apiname>TRequestStatus</apiname></xref>.
+Doing so pins the contents of the buffers: they can be specified as descriptors
+or by start address and length. This takes place in the client context. </p> </li>
+<li id="GUID-8493130F-9E96-580F-B509-5EB5B69852A0"><p>The driver calls <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-A33C039B-981C-3234-A414-95487D4103A9"><apiname>Kern::ThreadBufRead()</apiname></xref> and <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-0C62AA11-87B4-307A-B63E-08A6842C7283"><apiname>Kern::ThreadBufWrite()</apiname></xref> to access the client's buffers. This takes place in the context of the DFC. </p> </li>
+<li id="GUID-5C63E867-025B-5F67-90CE-CE960DC254BB"><p>When the request is
+complete, the driver calls <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-ECE11E29-0831-3271-AFAA-88DAE4131BE1"><apiname>Kern::QueueBufferRequestComplete()</apiname></xref> passing
+the <xref href="GUID-5CD6D111-213B-31A2-AA46-C5598DDB7249.dita"><apiname>TClientBufferRequest</apiname></xref> object. This signals the client
+immediately and unpins the buffers. </p> </li>
+<li id="GUID-474B2BBE-F24E-5DB3-B83F-CDA95DDE0C3E"><p>When the client thread
+next runs, the completion value is written back to the client along with the
+updated length of any descriptors. </p> </li>
+</ol> <p><b>Using
+Kern::RequestComplete()</b> </p> <p>The function <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-D720BB4C-5E31-3213-BB16-859AA325FE98"><apiname>Kern::RequestComplete()</apiname></xref> exists
+in two versions: </p> <codeblock id="GUID-11FEEAC7-3223-5B27-9FA2-0C71F5F55E8C" xml:space="preserve">static void Kern::RequestComplete(DThread* aThread, TRequestStatus*&amp; aStatus, TInt aReason);</codeblock> <p>which is now deprecated, and its overloaded replacement </p> <codeblock id="GUID-AAAAF661-3C0F-5048-8AD2-16C085A65387" xml:space="preserve">static void Kern::RequestComplete(TRequestStatus*&amp; aStatus, TInt aReason);</codeblock> <p>The
+overloaded version should always be used, as it does not take a thread pointer
+argument. </p> <p><b>Using
+shared chunks</b> </p> <p>Shared chunks are a mechanism by which kernel side
+code shares buffers with user side code. As an alternative to pinning memory
+they have the following advantages: </p> <ul>
+<li id="GUID-65C6ECA6-A89B-5303-B674-E90AA805841A"><p>Shared chunks cannot
+be paged and therefore paging faults never arise. </p> </li>
+<li id="GUID-D7B96CD0-725F-5FCB-A30A-6FFF55ADC439"><p>Shared chunks transfer
+data with a minimum number of copying operations and are useful where high
+speeds and large volumes are required. </p> </li>
+</ul> <p>Shared chunks present disadvantages when a driver is being migrated
+rather than written from scratch, as the client API must be rewritten as well
+as the driver code. </p> </section>
+<section id="GUID-143D7A45-D119-4AEF-8941-116C2567514F"><title>See Also</title> <p> <xref href="GUID-85C18DAF-DB76-51C6-B38D-A802E314F4D1.dita">Performance Guarantee Tutorial</xref>  </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E7E67A52-0725-446B-A49C-CF571C4A0C64.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,86 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E7E67A52-0725-446B-A49C-CF571C4A0C64" xml:lang="en"><title>DMA
+Buffer Operations</title><shortdesc>This document describes how a device driver allocates and deallocates
+DMA buffers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-74A2C413-DF2C-4DB6-917B-A4B6CD05612F"><title> Allocation</title> <p>DMA
+requires contiguous memory chunks to be allocated to do copy and read operations.
+A driver can do this by using the Symbian Kernel API. A contiguous block of
+memory can be allocated using <xref href="GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680.dita#GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680/GUID-B506D835-505D-3D89-A840-475F291908DC"><apiname>Epoc::AllocPhysicalRam()</apiname></xref>,
+which provides the physical address of the contiguous memory block allocated. </p> <p>After
+allocating the buffer, a global hardware chunk must be created, and its attributes
+set. The attributes define chunk properties such as whether it is non-cacheable,
+or whether it can be accessed only in supervisor mode, and so on. </p> <codeblock id="GUID-69AB812C-2497-5005-9BA4-F78BA6DB5A52" xml:space="preserve">TInt DExDriverUartTxDma::Init()
+    {
+    // Round up the transmit chunk size to the page size.     
+    // Kern::RoundToPageSize() rounds up the argument to the size of 
+    // a MMU page. The size of one MMU page can be found out by calling 
+    // Kern::RoundToPageSize(1).
+    //
+    iTxBufSize = Kern::RoundToPageSize (KRxTxDMABufferSize);
+
+    // Epoc::AllocPhysicalRam() allocate contiguous physical memory 
+    // for the transmit buffer of the specified size, and returns the physical address 
+    // of the buffer. We need contiguous block of memory and its 
+    // physical address for DMA.
+    //
+    TInt r = Epoc::AllocPhysicalRam (iTxBufSize, iTxPhysAddr);
+    if (r != KErrNone)
+        {
+        return r;
+        }
+
+    // Create a global hardware chunk for the buffer allocated using 
+    // Epoc::AllocPhysicalRam() and set attributes to make it 
+    // uncached and accessible only by kernel-side code. 
+    // Contiguous, uncached, unbuffereable RAM pages avoids 
+    // coherency and fragmentation issues while using DMA.
+    // However, in case of making buffers cacheable other APIs are     
+    // provided to synch, i.e. flush cache before doing a DMA 
+    // transfer 
+    // 
+    r = DPlatChunkHw::New(iTxChunk, iTxPhysAddr, iTxBufSize,
+    EMapAttrSupRw // Supervisor mode, user has no access
+    |EMapAttrFullyBlocking); // uncached, unbuffered    
+    if (r != KErrNone)
+        {
+        // Free the allocated RAM, that was earlier allocated by         
+        // Epoc::AllocPhysicalRam(). 
+        Epoc::FreePhysicalRam(iTxPhysAddr, iTxBufSize);
+        return r;
+        }
+    ...
+    }</codeblock> <p>Buffers can also be made cacheable, in which case, the
+driver has to ensure to synchronise by flushing the cache before writing and
+after reading. </p> <codeblock id="GUID-8C452D9B-6674-5B2F-931B-7C671F9E60DC" xml:space="preserve">// Synchronises cache(s) prior to a DMA write operation. i.e. 
+// before DMA is used write to a peripheral data which is read 
+// from RAM.
+void Cache::SyncMemoryBeforeDmaWrite(TLinAddr aBase, 
+                TUint aSize, TUint32 aMapAttr)
+
+// Synchronizes cache(s) prior to a DMA read operation.
+// i.e. before DMA is used read from a peripheral data which is 
+// written to RAM.
+void Cache::SyncMemoryBeforeDmaRead(TLinAddr aBase, 
+                TUint aSize, TUint32 aMapAttr)
+
+// Synchronises cache(s) after a DMA read operation.
+void Cache::SyncMemoryAfterDmaRead(TLinAddr aBase, TUint aSize)</codeblock> <p>However,
+unless required by design, DMA chunks are used in non-cacheable and non-buffered
+mode. </p></section>
+<section id="GUID-76E909F6-65D5-41BB-8B86-03801F42C8D6"><title>Deallocation</title> <p>DMA buffers have to be deallocated
+when they are no longer used. Buffers are deallocated in the physical channel
+destructor. </p> <p>Like allocation, deallocation is performed in two stages.
+When you allocate, the contiguous buffer is allocated and a hardware chunk
+is created; when you de-allocate, the contiguous buffer is deallocated and
+the chunk is closed. </p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E7F91A65-235D-589C-9A8C-0B207D19A24B.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E7F91A65-235D-589C-9A8C-0B207D19A24B" xml:lang="en"><title>Port client drivers to use the PRM</title><shortdesc>This document describes how to port client drivers to use
+the PRM.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-B2FA7A9A-8BA2-4C9C-AFB0-8F2E73A5653B"><title>Purpose</title> <p>Device drivers must register as clients to access services of
+the PRM. </p> <p><b>Introduction</b> </p> <p>Kernel side components
+can access PRM services through exported kernel side APIs by including <filepath>resourceman.h</filepath> and linking against the static library provided
+by the PRM. See <xref href="GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9.dita#GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9/GUID-0F328055-DBCE-5B2B-A1EB-77F73BA1FC82">setup and configuration requirements</xref>. </p> </section>
+<section id="GUID-E496B581-9C24-49BB-A7EA-7E1EE4AD7E39"><title>Porting
+client drivers </title> <p>Kernel side components register as clients
+with the PRM from their entry point during kernel boot and device
+drivers register as clients on channel opening. </p> <p>User side
+components can access PRM services through a user side proxy interface.
+See <xref href="GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE.dita#GUID-6E1DE1E4-1B09-541C-8708-9126E69B42CE/GUID-5C3F684C-D4F6-5343-AFFC-009B70210F9C">user-side</xref> for more information. </p> <p>To guarantee deterministic
+behaviour during resource state change and read operations (mainly
+on a long latency resource), clients should pre-allocate ‘client level’
+objects and request objects using <xref href="GUID-975D07BD-21A8-3797-916A-AD5D63ADE33B.dita"><apiname>AllocReserve()</apiname></xref>. This needs to be done immediately after registering as clients
+of the PRM. </p> <p>Before de-registering as clients from PRM, device
+drivers must: </p> <ul>
+<li id="GUID-6469D50E-BA4B-5BD2-898D-701547B1119F"><p>Cancel any pending
+asynchronous request with <xref href="GUID-98C67010-FAD0-3D09-BFBF-EE240ADB95E7.dita"><apiname>CancelAsyncRequestCallback()</apiname></xref>. If <codeph>CancelAsyncRequestCallback</codeph> returns <codeph>KErrInUse</codeph> the client must wait for the request to complete
+before proceeding with deregistration as the asynchronous request
+has started processing and will run to completion, </p> </li>
+<li id="GUID-A9377536-9850-534D-BEFA-95493B74B938"><p>Cancel all resource
+state change notification requests issued by this client using <xref href="GUID-51CAD2A1-C978-3EBD-984F-4C5C59D68885.dita"><apiname>CancelNotification()</apiname></xref>, </p> </li>
+<li id="GUID-24C83DC4-C6F2-5AFA-916A-D405418CADDF"><p>Delete the asynchronous
+callback objects and notification objects created by this client to
+avoid memory leak. </p> </li>
+</ul> <p><b>Omissions </b> </p> <p>PRM APIs cannot be called from
+a Null thread, ISR or from DFC thread1. However it might be possible
+that ISR need to operate on a power resource, for example, a power
+supply may need to be turned on before a hardware register that an
+ISR is interested on can be read. In this case Base port developers
+need to access the power resource directly. In order for the PRM to
+provide a consistent view of power resources any resource manipulators
+in an ISR must leave them unchanged, so in the above example, the
+ISR must turn OFF the power supply after it read the registers. </p> </section>
+</conbody><related-links>
+<link href="GUID-2ECF13A1-9D56-5740-A09F-8267E6A45DD9.dita"><linktext>Porting
+the Power Resource Manager</linktext></link>
+<link href="GUID-B1CE51BC-B452-5FC9-9C00-35447AF40671.dita"><linktext>Implement
+the controllable power resources</linktext></link>
+<link href="GUID-66FD040B-133E-57CF-80DD-9369F62709C6.dita"><linktext>Implement
+the PSL for the target</linktext></link>
+<link href="GUID-C8DF0CB0-92F4-5F9E-A8F1-7DE50954C4F1.dita"><linktext>Debugging
+the PRM</linktext></link>
+<link href="GUID-66E5F769-1156-54CA-94BC-8912159A1240.dita"><linktext>Testing
+the PRM PSL</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E90DBF35-0A05-4751-904D-4F06987FFF48.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E90DBF35-0A05-4751-904D-4F06987FFF48" xml:lang="en"><title>Memory
+Management</title><shortdesc>These documents describe how device drivers handle memory buffers
+and transfer data.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E96E4542-7017-4069-BD9C-97467A99F211.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E96E4542-7017-4069-BD9C-97467A99F211" xml:lang="en"><title>Testing and performance issues</title><shortdesc>This section describes testing and performance issues.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-E9999276-6861-4ECA-B542-1B6C3471BFC9.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-E9999276-6861-4ECA-B542-1B6C3471BFC9" xml:lang="en"><title>IIC Tools Guide</title><shortdesc>Describes the tools required for building the IIC platform
+service.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There are no specific tools required to build the IIC platform
+service. Refer to <xref href="GUID-7305526C-17A4-579D-B2A0-8A373784E4A2.dita">Using ROM tools</xref> section for standard ROMBUILD tools.</p>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-EA0C5715-7CE8-5415-A915-D5701E3C957A-master.png has changed
Binary file Adaptation/GUID-EA0C5715-7CE8-5415-A915-D5701E3C957A_d0e10709_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,613 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5" xml:lang="en"><title>Thread
+Synchronisation</title><shortdesc>Kernel-side techniques to protect critical regions in code or to
+allow safe access to shared data.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Kernel-side code can use a number of techniques to perform thread synchronisation,
+to protect critical regions within threads or to ensure that shared data can
+be safely read or modified. </p>
+<ul>
+<li id="GUID-F76D1379-CEA0-5CEA-A050-88CCF23AFAC6"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-86E98109-EC1A-58B7-8AB2-EFD100739261">Mutexes</xref>  </p> </li>
+<li id="GUID-614F64B3-04C0-5ED0-9286-C64B8B1C4235"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-00E1F006-3D2C-52A3-BFCB-4D6A59321B26">Semaphores</xref> </p> </li>
+<li id="GUID-7970F858-7480-5EEB-A924-2157E40FB44E"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-7E632FD5-03B6-5D39-8A97-8F1948F2BB5B">Thread critical section</xref>  </p> </li>
+<li id="GUID-A3BFB534-95F0-5B32-A996-955AE40C19E6"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-7AECE882-9D48-5109-AE38-38BF0F8F717F">Atomic operations</xref>  </p> </li>
+<li id="GUID-C4B47444-2A35-5E0C-92EF-C33DDD68D0E1"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-A0FB7718-F39C-5FB3-B67C-430B490F6430">The system lock</xref>  </p> </li>
+<li id="GUID-ECFF18B2-9279-5B68-9939-78C897F32FB8"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-1806CDC5-9941-5CFC-B1F1-82BBA8D4F65B">The kernel lock</xref>  </p> </li>
+<li id="GUID-AF3CD2DE-B4FD-5D1B-B9CC-FB2E32380D38"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-961912E5-2D89-518A-A6EA-3AAC15D17B81">Disabling interrupts</xref>  </p> </li>
+</ul>
+<section id="GUID-86E98109-EC1A-58B7-8AB2-EFD100739261"><title>Mutexes</title> <p>A
+mutex (mutual exclusion) is a mechanism to prevent more than one thread from
+executing a section of code concurrently. The most common use is to synchronise
+access to data shared between two or more threads. </p> <p>There are two types
+of mutex: the fast mutex, and a more general heavyweight mutex - the Symbian
+platform mutex. Which one you use depends on the needs of your code and the
+context in which it runs. </p> <ul>
+<li id="GUID-737BE53A-9A91-5CEA-9073-E47D3B3DB9E8"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-09377BC3-770A-5558-B3A9-A7E2CE11EBC3">The fast mutex</xref>  </p> </li>
+<li id="GUID-5952D847-0802-5B05-9CE8-6316DCA96245"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-F5B59A23-48E0-5596-B589-10DD2549F124">The Symbian platform mutex</xref>  </p> </li>
+</ul> <p id="GUID-09377BC3-770A-5558-B3A9-A7E2CE11EBC3"><b>The fast mutex</b> </p> <p>A
+fast mutex is the fundamental way of allowing mutual exclusion between <i>nanokernel</i> threads.
+Remember that a Symbian platform thread, and a thread in a personality layer
+are also nanokernel threads. </p> <p>A fast mutex is represented by a <xref href="GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953.dita"><apiname>NFastMutex</apiname></xref> object.
+It is designed to be as fast as possible, especially in the case where there
+is no contention, and is also designed to occupy as little RAM as possible.
+A fast mutex is intended to protect <i>short</i> critical sections of code </p> <ul>
+<li id="GUID-646DB0EC-1627-5BDF-8068-D6717106DB17"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-4EE0B5C4-0473-54CD-A585-F2905FA76968">Rules</xref> </p> </li>
+<li id="GUID-3C470241-DD9E-52CF-B58D-C86A9301BEEE"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-083C9D63-A69D-5E66-9274-178F329F8445">How to use</xref>  </p> </li>
+<li id="GUID-D7C801A7-B0C1-5AF1-8594-CB994BDECF7B"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-111E74A3-8442-5598-8BB9-F78E2A77610A">Example using NFastmutex to protect a critical region</xref>  </p> </li>
+</ul> <p id="GUID-4EE0B5C4-0473-54CD-A585-F2905FA76968"><b>Rules</b> </p> <p>A
+fast mutex is, be definition, fast and the price to be paid is that there
+are a few rules that must be obeyed: </p> <ul>
+<li id="GUID-25FC4814-1BBB-5C6D-90FB-12E75274C388"><p>a thread can only hold
+one fast mutex at a time, i.e. a thread cannot wait on a fast mutex if it
+already holds another fast mutex </p> </li>
+<li id="GUID-693AB846-4629-5E3C-A14C-53A0879F1DB8"><p>a thread cannot wait
+on the same fast mutex more than once </p> </li>
+<li id="GUID-11EEC812-0BC7-5FFA-8D7B-DBD400CA5958"><p>a thread must not block
+or exit while holding a fast mutex because the thread is in an implied <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-7E632FD5-03B6-5D39-8A97-8F1948F2BB5B">critical
+section</xref>. </p> </li>
+</ul> <p>In the moving memory model, the user address space is not guaranteed
+to be consistent while a kernel thread holds a fast mutex. </p> <p id="GUID-083C9D63-A69D-5E66-9274-178F329F8445"><b>How
+to use</b> </p> <p>Typically you declare a fast mutex in a class declaration,
+for example: </p> <codeblock id="GUID-D1839B94-A1AF-5693-841F-F58C583F5D7E" xml:space="preserve">class DImpSysTest : public DLogicalChannelBase
+    {
+    ...
+public:
+    ...
+    NFastMutex iMutex;
+    ...
+    };
+</codeblock> <p>When you want to get hold of the fast mutex, i.e. when you
+are about to enter a section of code that no other thread is executing concurrently,
+you wait on that fast mutex. If no other thread has the mutex, then your thread
+gets the mutex, and control flows into your critical code. On exiting the
+section of code, you signal the fast mutex, which relinquishes it. </p> <p>If,
+on the other hand, another thread already has the fast mutex, then your thread
+blocks, and only resumes when the other thread exits the code section by signalling
+the fast mutex. </p> <p>Getting and relinquishing the mutex is done using
+the <codeph>Wait()</codeph> and <codeph>Signal()</codeph> functions of the <xref href="GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953.dita"><apiname>NFastMutex</apiname></xref> class.
+However, you will normally use the nanokernel functions: </p> <ul>
+<li id="GUID-E2D93FB0-7E2B-5497-AAC1-DF1F2DA388E0"><p> <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-133C9428-F0BE-399E-A986-5AE72460C720"><apiname>NKern::FMWait()</apiname></xref>  </p> </li>
+<li id="GUID-4E620FA6-4146-5C90-8B67-20050A1A88D1"><p> <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-FBD38D01-21A1-3E92-BA1D-719EBCC7AF1D"><apiname>NKern::FMSignal()</apiname></xref>  </p> </li>
+</ul> <p>respectively, passing a pointer to your <xref href="GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953.dita"><apiname>NFastMutex</apiname></xref> object. </p> <p>The
+kernel lock must be held when <xref href="GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953.dita#GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953/GUID-76E5AE32-9A70-344A-9E6B-5B439622715A"><apiname>NFastMutex::Wait()</apiname></xref> and <xref href="GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953.dita#GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953/GUID-CA8C65D8-E59A-385A-92B8-2B22A4A2F1CB"><apiname>NFastMutex::Signal()</apiname></xref> are
+called. <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-133C9428-F0BE-399E-A986-5AE72460C720"><apiname>NKern::FMWait()</apiname></xref> and <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-FBD38D01-21A1-3E92-BA1D-719EBCC7AF1D"><apiname>NKern::FMSignal()</apiname></xref> do
+this for you. They make sure that the kernel lock is on while <xref href="GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953.dita#GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953/GUID-76E5AE32-9A70-344A-9E6B-5B439622715A"><apiname>NFastMutex::Wait()</apiname></xref> and <xref href="GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953.dita#GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953/GUID-CA8C65D8-E59A-385A-92B8-2B22A4A2F1CB"><apiname>NFastMutex::Signal()</apiname></xref> are
+called by wrapping them in a pair of <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-7CBBF72B-4519-38DD-92CA-38AF636AFD8A"><apiname>NKern::Lock()</apiname></xref> and <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-A1A42137-906C-30F1-AF61-4F786FC372DE"><apiname>NKern::Unlock()</apiname></xref> calls. </p> <p>Although
+this sounds like you will be blocking while holding the kernel lock, in reality
+you do not because the thread is not blocked until after the kernel lock is
+released. </p> <p>Be aware however that there may be situations where you
+already have the kernel lock, or in the case of IDFCs, you do not need to
+acquire it as no preemption can occur. In these cases, you just call <xref href="GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953.dita#GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953/GUID-76E5AE32-9A70-344A-9E6B-5B439622715A"><apiname>NFastMutex::Wait()</apiname></xref> and <xref href="GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953.dita#GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953/GUID-CA8C65D8-E59A-385A-92B8-2B22A4A2F1CB"><apiname>NFastMutex::Signal()</apiname></xref>. </p> <p>The following diagram illustrates the general principle: </p> <fig id="GUID-30A0EA62-83CF-5AB9-A07E-525D0972E55B">
+<title>Fast mutex</title>
+<image href="GUID-3AFE0D8B-FB9B-5355-A63B-FB71DD13E7D0_d0e73917_href.png" placement="inline"/>
+</fig> <p>There are a number of assumptions here, one of which is that the
+priorities are such that thread T1 does not run until a reschedule occurs,
+after T2 has been interrupted. </p> <p id="GUID-111E74A3-8442-5598-8BB9-F78E2A77610A"><b>Example
+using NFastmutex to protect a critical region</b> </p> <p>The file <filepath>...\f32test\nkern\d_implicit.cpp</filepath> is
+a device driver that contains 3 threads and 3 separate sub-tests. The third
+test, identified as <codeph>ETestDummy</codeph>, shows how to protect a critical
+region using a nanokernel fast mutex. </p> <p>The mutex itself is declared
+in the channel class: </p> <codeblock id="GUID-7EFD970B-9500-5F68-8BAD-21718F3953BC" xml:space="preserve">class DImpSysTest : public DLogicalChannelBase
+    {
+    ...
+public:
+    ...
+    NFastMutex iMutex;
+    ...
+    };
+</codeblock> <p>The function <codeph>Start()</codeph> takes an argument that
+sets the test number. This function initialises some test variables, creates
+three threads, and also initialises the mutex: </p> <codeblock id="GUID-A131C888-FAE0-53D3-BF12-E06D54E6A093" xml:space="preserve">TInt DImpSysTest::Start(TInt aTest)
+    {
+    ...
+    new (&amp;iMutex) NFastMutex;
+    ...    
+    }
+</codeblock> <p>The overloaded <codeph>new</codeph> operator is called with
+the existing mutex as its argument, with the side effect of calling the constructor
+to initialise the mutex. There is also a corresponding <codeph>Stop()</codeph> function
+to kill the threads and return the results to the caller. </p> <p>Look at
+the test case for <codeph>iTestNum == ETestDummy</codeph>, where thread 1
+and thread 3 use the mutex as if sharing a critical resource. </p> <codeblock id="GUID-A97F5CF0-F7D8-5A08-9033-908AEF2AE576" xml:space="preserve">void DImpSysTest::Thread1(TAny* aPtr)
+    {
+    DImpSysTest&amp; d=*(DImpSysTest*)aPtr;
+    ...    
+    FOREVER
+        {
+        NKern::FMWait(&amp;d.iMutex);
+        // this is a critical region protected by d.iMutex
+        NKern::FMSignal(&amp;d.iMutex);
+        ...
+        }
+    }</codeblock> <codeblock id="GUID-8D0EA108-B735-5189-99EE-0FE895B3A933" xml:space="preserve">void DImpSysTest::Thread3(TAny* aPtr)
+    {
+    DImpSysTest&amp; d=*(DImpSysTest*)aPtr;
+    ...
+    if (d.iTestNum==RImpSysTest::ETestPriority)
+        {
+        ...
+        }
+    else if (d.iTestNum==RImpSysTest::ETestDummy)
+        {
+        FOREVER
+            {
+            ...
+            if (x&lt;85)
+                {
+                ...
+                }
+            else
+                {
+                NKern::FMWait(&amp;d.iMutex);
+                // this is a critical region protected by d.iMutex
+                NKern::FMSignal(&amp;d.iMutex);
+                }
+            }
+        }
+    }
+</codeblock> <p>Each thread takes a pointer to the channel object as an argument,
+this is the <codeph>aPtr</codeph> value passed to both <codeph>Thread1()</codeph> and <codeph>Thread3()</codeph> and
+each thread dereferences it to find the mutex. The important point is that
+there is only one mutex object, which is accessed by all interested threads. </p> <p>Before
+entering the critical region, the threads call <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-133C9428-F0BE-399E-A986-5AE72460C720"><apiname>NKern::FMWait()</apiname></xref> to
+gain ownership of the mutex. Before leaving the critical region, they call <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-FBD38D01-21A1-3E92-BA1D-719EBCC7AF1D"><apiname>NKern::FMSignal()</apiname></xref> to
+relinquish ownership. </p> <p id="GUID-F5B59A23-48E0-5596-B589-10DD2549F124"><b>The
+Symbian platform mutex</b> </p> <p>The Symbian platform mutex provides mutual
+exclusion between Symbian platform threads without the restrictions imposed
+by the fast mutex. </p> <p>The Symbian platform mutex is represented by a <codeph>DMutex</codeph> object. </p> <ul>
+<li id="GUID-AAE481BE-1ABB-5E0E-AB89-1D53393B0C5B"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-94F9C4EF-24D5-514A-BD21-B10B1A83CE28">Characteristics</xref> </p> </li>
+<li id="GUID-BDA5D5F8-B508-5D9D-97DC-65AE2166817F"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-61387415-4A5B-5C98-A028-F62DA7114790">How to use</xref>  </p> </li>
+<li id="GUID-7DF42A70-D80B-5883-B96D-3452A11CD137"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-EF2F2EBB-CDC2-5367-957A-2A004453F6C7">Example using DMutex to protect critical regions</xref>  </p> </li>
+</ul> <p id="GUID-94F9C4EF-24D5-514A-BD21-B10B1A83CE28"><b>Characteristics</b> </p> <p>Operations
+on a <codeph>DMutex</codeph> are more complicated, and therefore slower, than
+those on a <xref href="GUID-D5B555DA-3D17-3ED2-A931-CB35BD93A953.dita"><apiname>NFastMutex</apiname></xref>. However, a <codeph>DMutex</codeph> gives
+you the following: </p> <ul>
+<li id="GUID-62A9B213-D77A-5151-B50A-8DA2EBA88433"><p>it is possible to wait
+on a Symbian platform mutex multiple times, provided it is signalled the exact
+same number of times </p> </li>
+<li id="GUID-EEB436F1-3F54-50BC-9009-E1EAB055199A"><p>It is possible to hold
+several Symbian platform mutexes simultaneously, although care is needed to
+avoid deadlock situations </p> </li>
+<li id="GUID-324BD7DC-7CDB-57DD-879B-E88CEA7CD194"><p>A thread can block while
+holding a Symbian platform mutex </p> </li>
+<li id="GUID-EA7C07F8-58D3-59C9-9C2A-6D82D4F6FC3B"><p>A Symbian platform mutex
+provides priority inheritance, although there is a limit on the number of
+threads that can wait on any <codeph>DMutex</codeph> (currently this is 10). </p> </li>
+</ul> <p>When a Symbian platform mutex is created it is given an 'order' value.
+This is a deadlock prevention mechanism, although it is used only in debug
+builds. When waiting on a mutex the system checks that the order value is
+less than the order value of any mutex that the thread is already waiting
+on. </p> <p>In general, most code written for device drivers should use values
+which are greater than any used by the kernel itself. There are 8 constants
+defined in <filepath>kernel.h</filepath> that are available for this purpose: <xref href="GUID-815054D8-4894-3DAB-9272-C8AAF3A11FD1.dita"><apiname>KMutexOrdGeneral0</apiname></xref> through <xref href="GUID-52E535B0-67FC-3353-89F7-BC2AF3947635.dita"><apiname>KMutexOrdGeneral7</apiname></xref>. </p> <p>The kernel faults with “Mutex Ordering Violation” if you try to
+wait on a mutex that violates the ordering rules. </p> <p>Note: the only time
+when these values would not be suitable is when the kernel calls back into
+non-kernel code while a mutex is already held by the kernel. This occurs in
+only two cases: </p> <ul>
+<li id="GUID-BE5D7153-03EC-5E07-9E50-6A164ED7976F"><p>The debug event handler
+callback </p> </li>
+<li id="GUID-C13DA224-565F-582C-8255-872D87D31CC2"><p>The various timer classes
+like <xref href="GUID-342B7499-4702-3C0F-B42A-66A5CA515F85.dita"><apiname>TTimer</apiname></xref>. This should not be an issue because device
+drivers should use the <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita"><apiname>NTimer</apiname></xref> class which does not callback
+while <codeph>DMutexes</codeph> are held. </p> </li>
+</ul> <p id="GUID-61387415-4A5B-5C98-A028-F62DA7114790"><b>How to use</b> </p> <p>Typically
+you declare the mutex in a class declaration, for example: </p> <codeblock id="GUID-1704CB00-7A0E-54AB-8197-23264A487621" xml:space="preserve">class DCrashHandler : public DKernelEventHandler
+    {
+    ...
+private:
+    DMutex* iHandlerMutex;
+    ...
+    };
+
+</codeblock> <p>You do not create a <codeph>DMutex</codeph> object directly;
+instead you use the kernel function <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-FEBBDA4F-412E-3AE5-9098-8E2F6BF3E969"><apiname>Kern::MutexCreate()</apiname></xref>.
+You pass a <codeph>DMutex*</codeph> type to the kernel function, which creates
+the <codeph>DMutex</codeph> object and returns a reference to it through the <codeph>DMutex</codeph> pointer. </p> <p>Getting
+and relinquishing the mutex is done using the kernel functions: </p> <ul>
+<li id="GUID-703EEF8E-D70F-57F6-8ED8-56CCC7EA00DB"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-1F0C28A8-9E9A-3AA3-A441-BA8406B3A06A"><apiname>Kern::MutexWait()</apiname></xref>  </p> </li>
+<li id="GUID-A80C8CA6-8E2C-5174-BC2A-EB3B1F18C49A"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-B8080F86-1342-31EA-9A28-205354CA0CB9"><apiname>Kern::MutexSignal()</apiname></xref>  </p> </li>
+</ul> <p>respectively, passing a reference to the <codeph>DMutex</codeph> object
+created earlier. Note that although you pass a <codeph>DMutex</codeph> object
+around, the member functions and member data of the class are considered as
+internal to Symbian platform. However, you can call <codeph>Open()</codeph> and <codeph>Close()</codeph> on <codeph>DMutex</codeph> as
+they are members of the base class <xref href="GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497.dita"><apiname>DObject</apiname></xref>. </p> <p id="GUID-EF2F2EBB-CDC2-5367-957A-2A004453F6C7"><b>Example
+using DMutex to protect critical regions</b> </p> <p>This example code fragment
+uses two <codeph>DMutex</codeph> objects to protect a critical region of code
+in a device driver. It implements a minimal debug agent in a device driver.
+When a channel is opened to the device driver, the <codeph>DoCreate()</codeph> function
+creates a crash handler (in 2 phases). The <codeph>DCrashHandler</codeph> class
+contains two <codeph>DMutex</codeph> objects: </p> <codeblock id="GUID-C8EE7472-E897-53EC-BAC5-C8C6299ED512" xml:space="preserve">class DCrashHandler : public DKernelEventHandler
+    {
+    ...
+private:
+    DMutex* iHandlerMutex;    // serialise access to crash handler
+    ...
+    DMutex* iDataMutex;    // serialise access to following members
+    ...
+    };</codeblock> <p>The two <codeph>DMutex</codeph> objects are created
+in the second phase of the crash handler creation, i.e. when the member function <codeph>DCrashHandler::Create()</codeph> is
+called. Here's the code: </p> <codeblock id="GUID-A23289A3-3E5D-595A-A039-E4BE73A133D8" xml:space="preserve">TInt DCrashHandler::Create(DLogicalDevice* aDevice)
+    {
+    TInt r;
+    ...
+    r = Kern::MutexCreate(iHandlerMutex, KHandlerMutexName, KMutexOrdDebug);
+    ...
+    r = Kern::MutexCreate(iDataMutex, KDataMutexName, KMutexOrdDebug-1);
+    ...
+    }</codeblock> <p>The names of the mutexes are passed as the literal descriptors: <codeph>KHandlerMutexName</codeph> and <codeph>KDataMutexName</codeph>, and have the values <i>CtHandlerMutex</i> and <i>CtDataMutex</i> respectively. </p> <p>Notice
+that the data mutex has an order value less than the handler mutex. This guards
+against deadlock - we are asking the kernel to check that any thread waits
+on the handler mutex before it waits on the data mutex. </p> <p>When a thread
+panics, or an exception occurs, program control eventually reaches <codeph>DCrashHandler::HandleCrash()</codeph>.
+The device driver is derived from <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita"><apiname>DLogicalChannelBase</apiname></xref>,
+and the current thread is the one that crashed and this is a Symbian platform
+thread, which means that it can wait on a <codeph>DMutex</codeph>. In fact,
+it waits on two mutexes, and does so in the order mentioned above. The mutexes
+are signalled further on in the same function. </p> <codeblock id="GUID-2F3C91C3-3323-5025-B7C3-2490595463FB" xml:space="preserve">void DCrashHandler::HandleCrash(TAny* aContext)
+    {
+    ...
+    // Ensure that, at any time, at most one thread executes the
+    // following code.  This simplifies user-side API.
+    Kern::MutexWait(*iHandlerMutex);
+    ...
+    Kern::MutexWait(*iDataMutex);
+    ...
+    // access crash handler data &lt;-------------------------------------
+    ...
+    Kern::MutexSignal(*iDataMutex);
+    ...
+    Kern::MutexSignal(*iHandlerMutex);
+    }</codeblock> <p> <codeph> iHandlerMutex</codeph> ensures that only one
+thread at a time uses the above code. <codeph>iDataMutex</codeph> protects
+a smaller critical region where the crash handler’s data is accessed. This
+data is also protected by <codeph>iDataMutex</codeph> in the <codeph>DCrashHandler::Trap()</codeph> function. </p> <codeblock id="GUID-D202D9A0-FB4B-5BD2-BE7A-5B843AC83A97" xml:space="preserve">void DCrashHandler::Trap(TRequestStatus* aRs, TAny* aCrashInfo)
+    {
+    ...
+    Kern::MutexWait(*iDataMutex);
+    ...
+    // access crash handler data &lt;-------------------------------------
+    ...
+    Kern::MutexSignal(*iDataMutex);
+    ...
+    } 
+</codeblock> <p>A <codeph>DMutex</codeph> is a reference counting object,
+and is derived from <xref href="GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497.dita"><apiname>DObject</apiname></xref>. This means that once you have
+finished with it, you must call <codeph>Close()</codeph> on it to reduce the
+number of open references. </p> <p>In this example, both <codeph>DMutex</codeph> objects
+are closed in the <codeph>DCrashHandler</codeph> destructor: </p> <codeblock id="GUID-9FAC3B34-D484-53FA-87D9-9AF5EC5C21D2" xml:space="preserve">DCrashHandler::~DCrashHandler()
+    {
+    ...
+    if (iDataMutex)
+        {
+        iDataMutex-&gt;Close(NULL);
+        }
+    if (iHandlerMutex)
+        {
+        iHandlerMutex-&gt;Close(NULL);
+        }
+    ...
+    }</codeblock> </section>
+<section id="GUID-00E1F006-3D2C-52A3-BFCB-4D6A59321B26"><title>Semaphores</title> <p>A
+semaphore is synchronisation primitive that you can use: </p> <ul>
+<li id="GUID-FDB08035-E850-54D3-8D4B-3F589AAC66EC"><p>to signal one thread
+from another thread </p> </li>
+<li id="GUID-A9E08C05-C149-5E6A-8062-D26A00BAFBA4"><p>to signal a thread from
+an Interrupt Service Routine using an IDFC. </p> </li>
+</ul> <p>In EKA2, there are two types of semaphore: the fast semaphore, and
+a more general semaphore - the Symbian platform semaphore. Which one you use
+depends on the needs of your code and the context in which it is runs. </p> <ul>
+<li id="GUID-381F815A-4B74-519E-AC95-2DF5983DAED2"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-371EE12E-56D6-5520-8FB9-B9B2CE8AB0E1">The fast semaphore</xref>  </p> </li>
+<li id="GUID-EF9B5D15-914F-5E6B-B47E-BE93612DC322"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-6132B7FF-C664-5E21-8BF5-1BC9BAF00061">The Symbian platform semaphore</xref>  </p> </li>
+</ul> <p id="GUID-371EE12E-56D6-5520-8FB9-B9B2CE8AB0E1"><b>The fast semaphore</b> </p> <p>A
+fast semaphore is a fast lightweight mechanism that a thread can use to wait
+for events. It provides a way of posting events to a single thread because
+the semaphore can keep count of the number of events posted. </p> <p>A fast
+semaphore is represented by a <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita"><apiname>NFastSemaphore</apiname></xref> object, and
+this is implemented by the <i>nanokernel</i>. Remember that a Symbian platform
+thread, and a thread in a personality layer are also nanokernel threads. </p> <ul>
+<li id="GUID-F5F04369-2F0B-5FEA-B49A-E90C7C1CAF2D"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-DF231F3F-A702-50DC-9E98-199808D228FD">Rules</xref> </p> </li>
+<li id="GUID-4AF23A2C-FD0C-557F-93A9-BCDF9D8EC162"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-E75C6B54-64D2-5936-BF38-9AF40F9F7400">How to use</xref>  </p> </li>
+<li id="GUID-73BE532A-3A55-5995-8615-BE50C615C3BF"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-1F74B3EC-A2E3-5B1E-9C8E-FFF15084C6DF">Example using NFastSemaphore and the NKern functions</xref>  </p> </li>
+<li id="GUID-45269DDA-FE9C-5075-BEAB-8030A5DC2DC0"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-2C0E4009-3E15-5197-B327-06699BFE2221">Example using the NFastSemaphore::Signal() function</xref>  </p> </li>
+</ul> <p id="GUID-DF231F3F-A702-50DC-9E98-199808D228FD"><b>Rules</b> </p> <p>Because
+of its lightweight structure, only the <i>owning thread</i> is allowed to
+wait on it. </p> <p id="GUID-E75C6B54-64D2-5936-BF38-9AF40F9F7400"><b>How
+to use</b> </p> <p>Typically you declare a fast semaphore in a class declaration,
+for example: </p> <codeblock id="GUID-7C06D593-07EC-5A00-950A-FA71A0611753" xml:space="preserve">class DCrashHandler : public DKernelEventHandler
+    {
+    ...
+private:
+    NFastSemaphore iSem;
+    ...
+    };
+
+</codeblock> <p>You need to initialise the <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita"><apiname>NFastSemaphore</apiname></xref> by: </p> <ul>
+<li id="GUID-76AA23BF-787E-5F02-9293-651D6A2ABCD4"><p>constructing the semaphore </p> </li>
+<li id="GUID-9DCCF8D9-8196-540F-A843-3E8771CFBBDC"><p>setting the thread that
+owns the semaphore, i.e. the thread that will be allowed to wait in it. </p> </li>
+</ul> <p>The semaphore is initialised when its constructor is called. However,
+setting the owning thread requires explicit code. For example, the following
+code fragment is typical and sets the owning thread to be the current thread: </p> <codeblock id="GUID-CF5E165F-3512-57C1-9CC3-8EE3077904CA" xml:space="preserve">iSem.iOwningThread = (NThreadBase*)NKern::CurrentThread();</codeblock> <p>Waiting
+and signalling the fast semaphore is done by using the <codeph>Wait()</codeph> and <codeph>Signal()</codeph> functions
+of the <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita"><apiname>NFastSemaphore</apiname></xref> class. However, you will normally
+use the nanokernel functions: </p> <ul>
+<li id="GUID-238D3B34-3E98-5388-8B33-F0FB47679CDD"><p> <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-D2691899-C802-3A4F-9E72-487B07E6E1D0"><apiname>NKern::FSWait()</apiname></xref>  </p> </li>
+<li id="GUID-94485609-3EAC-5986-ACE6-8485942D2273"><p> <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-B4B058FF-F077-3F0A-A344-F6FB36D987C6"><apiname>NKern::FSSignal()</apiname></xref>  </p> </li>
+</ul> <p>respectively, passing a pointer to your <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita"><apiname>NFastSemaphore</apiname></xref> object. </p> <p>The
+kernel lock must be held when <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita#GUID-22982E51-E746-37CB-9672-97B58C2672BF/GUID-F6262C01-5999-36D1-AF7D-F7E3741ED411"><apiname>NFastSemaphore::Wait()</apiname></xref> and <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita#GUID-22982E51-E746-37CB-9672-97B58C2672BF/GUID-B1104DF4-7490-33D9-BB64-83E16D9BA723"><apiname>NFastSemaphore::Signal()</apiname></xref> are
+called. <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-D2691899-C802-3A4F-9E72-487B07E6E1D0"><apiname>NKern::FSWait()</apiname></xref> and <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-B4B058FF-F077-3F0A-A344-F6FB36D987C6"><apiname>NKern::FSSignal()</apiname></xref> do
+this for you. They make sure that the kernel lock is on while <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita#GUID-22982E51-E746-37CB-9672-97B58C2672BF/GUID-F6262C01-5999-36D1-AF7D-F7E3741ED411"><apiname>NFastSemaphore::Wait()</apiname></xref> and <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita#GUID-22982E51-E746-37CB-9672-97B58C2672BF/GUID-B1104DF4-7490-33D9-BB64-83E16D9BA723"><apiname>NFastSemaphore::Signal()</apiname></xref> are called by wrapping them in a pair of <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-7CBBF72B-4519-38DD-92CA-38AF636AFD8A"><apiname>NKern::Lock()</apiname></xref> and <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-A1A42137-906C-30F1-AF61-4F786FC372DE"><apiname>NKern::Unlock()</apiname></xref> calls. </p> <p>Although
+this sounds like you will be blocking while holding the kernel lock, in reality
+you do not because the thread is not blocked until after the kernel lock is
+released. </p> <p>Be aware however that there may be situations where you
+already have the kernel lock, or in the case of IDFCs, you do not need to
+acquire it as no preemption can occur. In these cases, you just call <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita#GUID-22982E51-E746-37CB-9672-97B58C2672BF/GUID-F6262C01-5999-36D1-AF7D-F7E3741ED411"><apiname>NFastSemaphore::Wait()</apiname></xref> and <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita#GUID-22982E51-E746-37CB-9672-97B58C2672BF/GUID-B1104DF4-7490-33D9-BB64-83E16D9BA723"><apiname>NFastSemaphore::Signal()</apiname></xref>. </p> <p>You can use use a fast semaphore to block a thread until an interrupt
+occurs, but you cannot signal the semaphore directly from the interrupt service
+routine (ISR) that services that interrupt; instead, you must queue an IDFC,
+and signal from there. </p> <p id="GUID-1F74B3EC-A2E3-5B1E-9C8E-FFF15084C6DF"><b>Example
+using NFastSemaphore and the NKern functions</b> </p> <p>This is an example
+that synchronises threads using the <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita"><apiname>NFastSemaphore</apiname></xref> class,
+and is part of code that implements a minimal debug agent in a device driver.
+The full code for this can be found in <filepath>...\e32utils\d_exc\minkda.cpp</filepath>. </p> <p>When
+a channel is opened, the <codeph>DoCreate()</codeph> function creates a crash
+handler (in 2 phases).This is a <codeph>DCrashHandler</codeph> object, and
+importantly, contains a <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita"><apiname>NFastSemaphore</apiname></xref>. </p> <codeblock id="GUID-C092DA58-C4AF-528C-B648-481A3B6EC5A6" xml:space="preserve">class DCrashHandler : public DKernelEventHandler
+    {
+    ...
+private:
+    NFastSemaphore iSuspendSem; // for suspending crashed thread
+    ...
+    };</codeblock> <p>When a thread panics, or an exception occurs, program
+control eventually reaches <codeph>DCrashHandler::HandleCrash()</codeph>.
+It is in this function that the owning thread is set – to the current nanokernel
+thread (i.e. the one that crashed). This is the only thread allowed to wait
+on the semaphore. The wait is just a few lines further down in the same function: </p> <codeblock id="GUID-B3543353-C441-542E-B0AA-737F5DFA1ADA" xml:space="preserve">void DCrashHandler::HandleCrash(TAny* aContext)
+    {
+    DThread* pC = &amp;Kern::CurrentThread();
+    ...
+    if (iTrapRq != NULL)
+        {
+        iCrashedThread = pC;
+        iSuspendSem.iOwningThread = &amp;(iCrashedThread-&gt;iNThread);
+        ...
+        }
+    ...
+    if (iCrashedThread)
+        {
+        ...
+        NKern::FSWait(&amp;(iSuspendSem)); // Waits on the semaphore
+        ...
+        }
+    ...
+    }</codeblock> <p>At a later time, the debugger calls the driver’s <codeph>Request()</codeph> function
+with either the <codeph>ECancelTrap</codeph> or <codeph>EKillCrashedThread</codeph> parameters.
+One or other of the corresponding functions is called; each function is implemented
+to signal the semaphore. </p> <codeblock id="GUID-E1D04D58-4614-58B1-B5A4-CA898B58B0E6" xml:space="preserve">void DCrashHandler::CancelTrap()
+    {
+    ...
+    if (iCrashedThread != NULL)
+        {
+        NKern::FSSignal(&amp;(iSuspendSem));
+        }
+    ...
+    }</codeblock> <codeblock id="GUID-FB4B9BE1-272B-5F62-8C88-13FAF89BAE88" xml:space="preserve">void DCrashHandler::KillCrashedThread()
+    {
+    ...
+    NKern::FSSignal(&amp;iSuspendSem);
+    }</codeblock> <p id="GUID-2C0E4009-3E15-5197-B327-06699BFE2221"><b>Example
+using the NFastSemaphore::Signal() function</b> </p> <p>This is an example
+code fragment taken from <filepath>...\e32test\misc\d_rndtim.cpp</filepath>. </p> <p>This
+a device driver that uses a timer. The driver's logical channel can start
+the timer, and it can wait for the timer to expire. The expiry of the timer
+results in an interrupt; this results in a call to an ISR that schedules an
+IDFC, which, in turn, signals the driver's logical channel. </p> <p>Because
+the kernel is implicitly locked when the IDFC runs, there is no need to explicitly
+lock the kernel, and <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita#GUID-22982E51-E746-37CB-9672-97B58C2672BF/GUID-B1104DF4-7490-33D9-BB64-83E16D9BA723"><apiname>NFastSemaphore::Signal()</apiname></xref> can be called
+instead of <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-B4B058FF-F077-3F0A-A344-F6FB36D987C6"><apiname>NKern::FSSignal()</apiname></xref>. </p> <p>The relevant part
+of the driver's logical channel class is: </p> <codeblock id="GUID-30E361DA-817C-5792-8E61-6CEB37F28FB3" xml:space="preserve">class DRndTim : public DLogicalChannelBase
+    {
+    ...
+public:
+    NFastSemaphore iSem;
+    ...
+    };</codeblock> <p>The semaphore's owning thread is set in the logical
+channel's constructor. Note that the constructor is called in the context
+of the client thread, and it is this thread that is the owner of the semaphore.
+This must also be the thread that waits for the semaphore, which it does when
+at some later time it sends an <codeph>EControlWait</codeph> request to the
+device driver to wait for the timer to expire. </p> <codeblock id="GUID-D32ABAEB-32C2-5D68-B76E-7C45D5828EED" xml:space="preserve">DRndTim::DRndTim()
+    {
+    iThread=&amp;Kern::CurrentThread();
+    iThread-&gt;Open();
+    iSem.iOwningThread = &amp;iThread-&gt;iNThread;
+    ...
+    }</codeblock> <p>The following code shows the implementation of this wait.
+Note that it assumes that the timer has already been started, which we have
+not shown here. </p> <p>The wait is initiated using the <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-D2691899-C802-3A4F-9E72-487B07E6E1D0"><apiname>NKern::FSWait()</apiname></xref> function
+as the kernel must be locked when the wait operation is done on the <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita"><apiname>NFastSemaphore</apiname></xref>. </p> <codeblock id="GUID-52D3817F-3214-5166-A998-35C468CC9BBE" xml:space="preserve">TInt DRndTim::Request(TInt aFunction, TAny* a1, TAny* a2)
+    {
+    TInt r = KErrNotSupported;
+    switch (aFunction)
+        {
+    case RRndTim::EControlWait:
+        NKern::FSWait(&amp;iSem);
+        r = KErrNone;
+        break;
+        ...
+        }
+    ...
+    }</codeblock> <p>When the timer expires, the ISR runs, and this schedules
+the IDFC, which in turn signals the client thread. The following code is the
+IDFC implementation. </p> <codeblock id="GUID-907D7F1C-BEE5-5651-9F2A-F7E3421E4BA0" xml:space="preserve">void DRndTim::IDfcFn(TAny* aPtr)
+    {
+    DRndTim* d = (DRndTim*)aPtr;
+    d-&gt;iSem.Signal();
+    }</codeblock> <p>Note that this calls <xref href="GUID-22982E51-E746-37CB-9672-97B58C2672BF.dita#GUID-22982E51-E746-37CB-9672-97B58C2672BF/GUID-B1104DF4-7490-33D9-BB64-83E16D9BA723"><apiname>NFastSemaphore::Signal()</apiname></xref> rather
+that <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-B4B058FF-F077-3F0A-A344-F6FB36D987C6"><apiname>NKern::FSSignal()</apiname></xref> because IDFCs are called with the
+kernel locked. </p> <p id="GUID-6132B7FF-C664-5E21-8BF5-1BC9BAF00061"><b>The
+Symbian platform semaphore</b> </p> <p>Symbian platform semaphores are standard
+counting semaphores that can be used by one or more Symbian platform threads.
+The most common use of semaphores is to synchronise processing between threads,
+i.e. to force a thread to wait until some processing is complete in one or
+more other threads or until one or more events have occurred. </p> <p>The
+Symbian platform semaphore is represented by a <xref href="GUID-48D9A672-11AA-3F21-8AB6-AB01032C52A5.dita"><apiname>DSemaphore</apiname></xref> object. </p> <ul>
+<li id="GUID-FE9B937B-9B60-5C92-A1CA-6FDE7E1623EE"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-A396E34A-2B84-5EFC-8FE8-6DBE68A21A80">Characteristics</xref> </p> </li>
+<li id="GUID-3880A591-1512-518E-8607-E5737C7B84A5"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-6131CDB0-6249-5B9A-A969-9B25F8BCECF5">Rules</xref> </p> </li>
+<li id="GUID-B97B8B09-CD5B-57E2-9E7F-AD1DD90847AA"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-915A061E-C85E-5165-A12F-B3B214756AE0">How to use</xref>  </p> </li>
+</ul> <p id="GUID-A396E34A-2B84-5EFC-8FE8-6DBE68A21A80"><b>Characteristics</b> </p> <p>A
+Symbian platform semaphore is based on the value of a count, which the <codeph>DSemaphore</codeph> object
+maintains. The value of the count indicates whether there are any threads
+waiting on it. The general behaviour is: </p> <ul>
+<li id="GUID-D71A8532-4D3B-5748-81C5-8E40C91FB4D3"><p>if the count is positive
+or zero, then there are no threads waiting </p> </li>
+<li id="GUID-8C86A1DF-14D4-55DD-8511-FA51C4706FBF"><p>if the count is negative,
+the magnitude of the value is the number of threads that are waiting on it. </p> </li>
+</ul> <p>There are two basic operations on semaphores: </p> <ul>
+<li id="GUID-4193B915-82FB-5648-AD41-C1D5E345A8F1"><p>WAIT - this decrements
+the count atomically. If the count remains non-negative the calling thread
+continues to run; if the count becomes negative the calling thread is blocked. </p> </li>
+<li id="GUID-F39A0E98-8662-5B7B-B266-027885DB3F6A"><p>SIGNAL - this increments
+the count atomically. If the count was originally negative the next highest
+priority waiting thread is released. </p> </li>
+</ul> <p>Waiting threads are released in descending order of priority. Note
+however that threads that are explicitly suspended as well as waiting on a
+semaphore, are not kept on the semaphore wait queue; instead they are kept
+on a separate suspended queue. Such threads are not regarded as waiting for
+the semaphore; this means that if the semaphore is signalled, they will not
+be released, and the semaphore count will just increase and may become positive. </p> <p>Symbian
+platform semaphore operations are protected by the <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-A0FB7718-F39C-5FB3-B67C-430B490F6430">system lock</xref> fast mutex rather than by locking the kernel. To guarantee
+this, semaphore operations are done through kernel functions. </p> <p>Although
+somewhat artificial, and not based on real code, the following diagram nevertheless
+shows the basic idea behind Symbian platform semaphores. </p> <fig id="GUID-505BC4A5-BBCB-5A63-9795-C751719661BB">
+<title>Symbian platform semaphore</title>
+<image href="GUID-0FE0B646-A62F-55A8-A6E6-587D0909CE19_d0e74784_href.png" placement="inline"/>
+</fig> <p id="GUID-6131CDB0-6249-5B9A-A969-9B25F8BCECF5"><b>Rules</b> </p> <p>There
+are a few rules about the use of Symbian platform semaphores: </p> <ul>
+<li id="GUID-B850F00A-D7E6-5542-9D9D-F07F2625E29B"><p>Only Symbian platform
+threads are allowed to use Symbian platform semaphores </p> </li>
+<li id="GUID-C848306E-7407-5397-8638-DB6AB7250A4E"><p>An IDFC is not allowed
+to signal a Symbian platform semaphore. </p> </li>
+</ul> <p id="GUID-915A061E-C85E-5165-A12F-B3B214756AE0"><b>How to use</b> </p> <p>Typically
+you declare the Symbian platform semaphore in a class declaration, for example: </p> <codeblock id="GUID-19168C17-C570-5FEE-9339-FEA37E6D0043" xml:space="preserve">class X
+    {
+    ...
+private:
+    DSemaphore* iSemaphore;
+    ...
+    };
+
+</codeblock> <p>You cannot create a <codeph>DSemaphore</codeph> object directly;
+instead you must use the kernel function <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-8D0C749E-BB1E-3DC1-85CD-945313F07146"><apiname>Kern::SemaphoreCreate()</apiname></xref>.
+You pass a <codeph>DSemaphore*</codeph> type to the kernel function, which
+creates the <codeph>DSemaphore</codeph> object and returns a reference to
+it through the <codeph>DSemaphore</codeph> pointer. </p> <p>Waiting on the
+semaphore and signalling the semaphore are done using the kernel functions: </p> <ul>
+<li id="GUID-258E8300-3E13-502F-95C4-42DBA956BA0E"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-B7442064-FD21-3DCE-A412-4233D36A8D10"><apiname>Kern::SemaphoreWait()</apiname></xref>  </p> </li>
+<li id="GUID-4FF62788-06FB-5F71-A8AE-3539E498E05A"><p> <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-F25FACED-5030-304D-95FA-8A1AE48565F3"><apiname>Kern::SemaphoreSignal()</apiname></xref>  </p> </li>
+</ul> <p>respectively, passing a reference to the <codeph>DSemaphore</codeph> object
+created earlier. Note that although you pass a <codeph>DSemaphore</codeph> object
+around, the member functions and member data of the class are considered as
+internal to Symbian platform, and indeed the member functions are not exported
+and are not accessible except to the kernel itself. However, you can call <codeph>Open()</codeph> and <codeph>Close()</codeph> on <codeph>DSemaphore</codeph> as they are members of the base class <xref href="GUID-E48F1435-14B6-37F1-BE47-2EA803AFE497.dita"><apiname>DObject</apiname></xref>. </p> </section>
+<section id="GUID-7E632FD5-03B6-5D39-8A97-8F1948F2BB5B"><title>Thread critical
+section</title> <p>Putting a thread into a thread critical section prevents
+it being killed or panicked. Any kill or panic request is deferred until the
+thread leaves the critical section. </p> <p>A thread critical section is used
+to protect a section of code that is changing a global data structure or some
+other global resource. Killing a thread that is in the middle of manipulating
+such a global data structure might leave it in a corrupt state, or marked
+is being "in use". </p> <p>A thread critical section only applies to code
+that is running on the kernel side but in the context of a user thread. Only
+user threads can be terminated or panicked by another thread. </p> <p>In practice,
+a thread critical section only applies to code implementing a <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita#GUID-E7550422-5121-3393-A85E-BB797969CD2A/GUID-FD4DA73F-45E7-37BE-9380-1D8ED36114F7"><apiname>DLogicalChannelBase::Request()</apiname></xref> function
+or a HAL function handler. </p> <p id="GUID-F66BB67F-DFC4-5580-966B-C9F94359474A"><b>How
+to use</b> </p> <p>Enter a thread critical section by calling: <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-841D587C-E9E6-34EE-8ED0-E9A206F64379"><apiname>NKern::ThreadEnterCS()</apiname></xref>. </p> <p>Exit
+a thread critical section by calling: <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-2C897BA5-2BD7-3ABA-9F2B-F0B1AC14D1AE"><apiname>NKern::ThreadLeaveCS()</apiname></xref>. </p> <p>Note: </p> <ul>
+<li id="GUID-370A2F89-8D66-5328-8805-211EF1E46601"><p>it is important that
+you only hold a thread critical section for the absolute minimum amount of
+time it takes to access and change the resource. </p> </li>
+<li id="GUID-85613CB2-247E-5030-A971-2942B948FF09"><p>you do not need to be
+in a critical section to hold a <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-09377BC3-770A-5558-B3A9-A7E2CE11EBC3">fast
+mutex</xref> because a thread holding a fast mutex is implicitly in a critical
+section. </p> </li>
+</ul> <p>There are a large number of examples scattered throughout Symbian
+platform source code. </p> </section>
+<section id="GUID-7AECE882-9D48-5109-AE38-38BF0F8F717F"><title>Atomic operations</title> <p>There
+are a number of functions provided by the <i>nanokernel</i> that allow you
+to do atomic operations, and may be useful when synchronising processing or
+ensuring that data is safely read and/or updated. </p> <p>This is a list of
+the functions that are available. The function descriptions provide sufficient
+information for their use. </p> <ul>
+<li id="GUID-24420BA8-DC26-5B60-86B5-6D5511C7212E"><p> <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-D8F0CA07-9810-3AE0-8473-546D91D43572"><apiname>NKern::SafeSwap()</apiname></xref>  </p> </li>
+<li id="GUID-105922AC-FC67-59B8-A945-E7CEF77B3DEF"><p> <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-D953B3A2-5C7A-30E2-9917-3C4DD33DCEF4"><apiname>NKern::SafeSwap8()</apiname></xref>  </p> </li>
+<li id="GUID-D71AF10C-7251-58A7-A4C5-0B3D54CD518C"><p> <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-605C9857-3E5F-3202-B0CC-02F5C717B872"><apiname>NKern::LockedInc()</apiname></xref>  </p> </li>
+<li id="GUID-AE5C0560-D159-5AC9-804E-11F8EB9F9677"><p> <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-91FFC47D-2350-35A9-B3EA-F045902B68FE"><apiname>NKern::LockedDec()</apiname></xref>  </p> </li>
+<li id="GUID-414F83A6-6934-567C-BD90-AB5818BE76A5"><p> <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-2E36C0A3-D0EC-36AF-A018-4F4C793C1EF4"><apiname>NKern::LockedAdd()</apiname></xref>  </p> </li>
+<li id="GUID-DB617589-FED2-53A4-83A8-97089AC6F67E"><p> <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-0B55EEDB-942D-3F5F-BF81-6FD52EEBBE0F"><apiname>NKern::LockedSetClear()</apiname></xref>  </p> </li>
+<li id="GUID-18F0D485-0FD6-5532-94C8-3A1B7182CE66"><p> <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-0AD0756E-41BE-33CF-A3D3-7802A15534B4"><apiname>NKern::LockedSetClear8()</apiname></xref>  </p> </li>
+</ul> </section>
+<section id="GUID-A0FB7718-F39C-5FB3-B67C-430B490F6430"><title>The system
+lock</title> <p>The system lock is a specific fast mutex that only provides
+exclusion against other threads acquiring the same fast mutex. Setting, and
+acquiring the system lock means that a thread enters an implied critical section. </p> <p>The
+major items protected by the system lock are: </p> <ul>
+<li id="GUID-F7AF7E09-EE89-5B0E-B220-355E19F2C5DD"><p> <codeph>DThread</codeph> member
+data related to thread priority and status. </p> </li>
+<li id="GUID-BFF35EE1-7173-5827-BCE1-0A6AF9473289"><p>the consistency of the
+memory map. On the kernel side, the state of user side memory or the mapping
+of a process is not guaranteed unless one or other of the following conditions
+is true: </p> <ul>
+<li id="GUID-1A853DAF-83D9-5787-BD55-E33153248B0B"><p>you are a thread belonging
+to the process that owns the memory. </p> </li>
+<li id="GUID-2ADC2FDE-75F8-5E50-B4E7-9699559CADEB"><p>you hold the system
+lock. </p> </li>
+</ul> </li>
+<li id="GUID-6F41B4EB-C060-5FC6-BF74-DBFDFA0E3343"><p>the lifetime of <codeph>DObject</codeph> type
+objects and references to them, including handle translation in Exec dispatch. </p> </li>
+</ul> <p>Note that the system lock is different from the kernel lock; the
+kernel lock protects against any rescheduling. When the system lock is set,
+the calling thread can still be preempted, even in the locked section. </p> <ul>
+<li id="GUID-CD6EB1A4-E0D1-5D3B-8351-954C2612E1E8"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-87724201-9A89-5AFB-A035-D07A7DC0510F">How to use</xref>  </p> </li>
+<li id="GUID-9B6B6A29-9AC7-5048-A1CF-0F4EC6C929E8"><p> <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-3337309D-C048-57D5-9A86-7F3BFF5E239C">When to use</xref>  </p> </li>
+</ul> <p id="GUID-87724201-9A89-5AFB-A035-D07A7DC0510F"><b>How to use</b> </p> <p>The
+system lock is set by a call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-B3837744-B8CC-3DC0-BA1D-417016E88EE9"><apiname>NKern::LockSystem()</apiname></xref>. </p> <p>The
+system lock is unset by a call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-63B882C8-C5D0-3595-BBF1-74E942A5060A"><apiname>NKern::UnlockSystem()</apiname></xref>  </p> <p id="GUID-3337309D-C048-57D5-9A86-7F3BFF5E239C"><b>When to use</b> </p> <p>Only
+use the system lock when you access a kernel resource that is protected by
+the system lock. Generally you will not access these directly but will use
+a kernel function, and the preconditions will tell you whether you need to
+hold the system lock. </p> </section>
+<section id="GUID-1806CDC5-9941-5CFC-B1F1-82BBA8D4F65B"><title>The kernel
+lock</title> <p>The kernel lock disables the scheduler so that the currently
+running thread cannot be pre-empted. It also prevent IDFCs from running. If
+the kernel lock is not set, then IDFCs can run immediately after ISRs </p> <p>Its
+main purpose is to prevent code from being reentered and corrupting important
+global structures such as the thread-ready list. </p> <p id="GUID-493A2BEA-E268-5476-90DE-3C12DB91E25C"><b>How
+to use</b> </p> <p>The kernel lock is set by a call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-7CBBF72B-4519-38DD-92CA-38AF636AFD8A"><apiname>NKern::Lock()</apiname></xref>. </p> <p>The
+kernel lock is unset by a call to <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-A1A42137-906C-30F1-AF61-4F786FC372DE"><apiname>NKern::Unlock()</apiname></xref>  </p> <p id="GUID-6B734C56-8473-5C3C-803D-24D6E8CBEFAD"><b>When to use</b> </p> <p> <b> ALMOST
+NEVER</b>. </p> <p>The kernel exports this primarily for use by personality
+layers, which need to modify the thread-ready list. In general, you should
+use a <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-09377BC3-770A-5558-B3A9-A7E2CE11EBC3">fast
+mutex</xref> for thread synchronisation. </p> </section>
+<section id="GUID-961912E5-2D89-518A-A6EA-3AAC15D17B81"><title>Disabling interrupts</title> <p>This
+is the most drastic form of synchronisation. With interrupts disabled, timeslicing
+cannot occur. If interrupts are disabled for any length of time, the responsiveness
+of the whole system may be threatened, and real time guarantees may be invalidated. </p> <p><b>How
+to use</b> </p> <p>There are three functions supplied by the <i>nanokernel</i> involved
+in disabling and enabling interrupts. </p> <ul>
+<li id="GUID-3D0B9AC3-8033-5E65-AE05-21042D11C2B5"><p> <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-CA1C36B7-02EE-31D5-B700-27DE4769ECCF"><apiname>NKern::DisableInterrupts()</apiname></xref>  </p> </li>
+<li id="GUID-EFFAF15F-180B-5A0E-B4E2-106917125E27"><p> <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-8C251C65-FDE7-3161-8D2B-61401FB6487F"><apiname>NKern::DisableAllInterrupts()</apiname></xref>  </p> </li>
+<li id="GUID-A0575FE2-E5B3-5C72-A99A-F017AEE580CD"><p> <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-2D328082-3A9F-3467-81CF-B1C68866E163"><apiname>NKern::RestoreInterrupts()</apiname></xref>  </p> </li>
+</ul> <p><b>When to use</b> </p> <p> <b> NEVER</b>. </p> <p>Unless there is
+absolutely no other suitable technique. You would probably only use this to
+protect some data that is shared between an interrupt service routine and
+a thread (or a DFC). Nevertheless, you may find that <xref href="GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5.dita#GUID-EAA6A9FB-A470-550C-B7B4-FF68A733A2D5/GUID-7AECE882-9D48-5109-AE38-38BF0F8F717F">atomic operations</xref> are more suitable. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,281 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3" xml:lang="en"><title>Migration
+Tutorial: Demand Paging and Media Drivers</title><shortdesc>Describes how to change media drivers when demand paging is used.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Demand paging is a change made from Symbian platform v9.3 to how the Kernel
+uses RAM and storage media. This topic </p>
+<section id="GUID-AD70C4EE-F7E8-473D-B917-819B9852CB31"><title>Introduction</title> <p>If the ROM has been built with paging
+enabled, the image is divided into two sections: an unpaged section and a
+paged section. In addition to this, code that is not part of the ROM can be
+loaded on demand into RAM from other non-XIP partitions and/or media, for
+example FAT or ROFS partitions. </p> <p>Two types of paging are currently
+supported: </p> <ul>
+<li id="GUID-E838F239-2F8A-5441-AE76-59382AA75FF6"><p>ROM paging - paging
+from the paged section of the ROM image </p> </li>
+<li id="GUID-28970AFC-33C6-56B7-BBD3-383220359A90"><p>code paging - paging
+from non-removable media, for example, a FAT partition on an internal Multi
+Media Card (MMC) drive or an internal NAND ROFS/FAT partition. </p> <p>See
+also <xref href="GUID-90B5FDD9-7D59-5035-BF53-2B177655DCD6.dita">Paging from an
+internal MMC</xref>. </p> </li>
+</ul> <p> <note>: A difference between ROM paging and code paging is that
+all ROM pages are contiguous, whereas code that is paged from other drives
+may be split over several potentially non-contiguous clusters. This puts an
+extra burden on the paging subsystem as it needs to identify the layout of
+the DLL on the media before it is deemed pageable. This is achieved by using
+the file servers blockmap API.</note> </p> <p>Media drivers are typically
+PDDs with a filename of <filepath>med.pdd</filepath>. Normally they are declared
+in the <filepath>rombuild.oby</filepath> file with the keyword <codeph>extension</codeph> or <codeph>device</codeph> and
+are therefore flagged as unpaged. That is, once loaded their code and read-only
+data sections are not paged out. </p> <p>A media driver that is capable of
+servicing page requests from the paging subsystem must ensure that the thread
+in which the media driver runs takes the page fault itself otherwise a deadlock
+could occur. In theory, the only time this can happen is when a media driver
+accepts a write request from a user side client that points to data in the
+paged section of the ROM or to code that has been loaded into RAM from code
+paging enabled media. To remedy this, the local media subsystem has been modified
+to lock write requests to paging media drivers before they are dispatched
+and to split large write requests into a series of smaller ones to avoid exhausting
+available RAM. </p> <p>The two initial stages relevant to this discussion
+are: </p> <ul>
+<li id="GUID-02D2CBAA-8393-52C2-B940-31603B4AF9FA"><p>the kernel extension
+entry point - identified by the <codeph>DECLARE_STANDARD_EXTENSION</codeph> macro </p> </li>
+<li id="GUID-1EFE9978-780D-507C-B408-E0C3AE97A0A7"><p>the PDD entry point
+- identified by the <codeph>DECLARE_EXTENSION_PDD</codeph> macro. </p> </li>
+</ul> <p>To enable demand paging as soon as possible in the boot sequence
+it is desirable to instantiate and install the PDD factory object earlier,
+for example in the kernel extension entry point. </p> <p> <note> Some media
+drivers have no kernel extension entry point defined, the MMC media driver
+is an example. These drivers have a <xref href="GUID-73947402-2F32-35C7-94C4-22B4D63D5FB3.dita"><apiname>DECLARE_STANDARD_PDD</apiname></xref> macro
+defined rather than <xref href="GUID-52853C0D-CA98-3B92-B7D4-FF1C1F06C1A6.dita"><apiname>DECLARE_EXTENSION_PDD</apiname></xref>. They require
+modification to have a <xref href="GUID-52853C0D-CA98-3B92-B7D4-FF1C1F06C1A6.dita"><apiname>DECLARE_EXTENSION_PDD</apiname></xref> and a <xref href="GUID-8B6DF6D7-4995-3564-9303-272500D7E747.dita"><apiname>DECLARE_STANDARD_EXTENSION</apiname></xref>.</note> </p> <p>The
+steps needed to support ROM and/or code paging are as follows: </p> <ol id="GUID-CADDDC61-A3A2-5AC3-AD69-739FD61FA9CC">
+<li id="GUID-4D14D36E-5F3A-55E6-BAB8-A45243B34928"><p>determine whether code
+paging is supported, and if so, identify the relevant local drive number or
+numbers </p> </li>
+<li id="GUID-F97B3965-020F-5C16-9D09-5861C0B6C695"><p> <xref href="GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3.dita#GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3/GUID-77FBA53A-CC78-5CD1-8FDF-F6A8001DE466">modify variantmediadef.h</xref>  </p> </li>
+<li id="GUID-D608C61F-E297-5A0C-B0FD-4F0F98B36EEF"><p> <xref href="GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3.dita#GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3/GUID-686EFEF4-A514-51BC-8378-962A8899F270">modify the media drivers kernel extension entry point</xref> to register
+the media driver with the paging subsystem and to instantiate and install
+the <xref href="GUID-A5484A7F-94B9-34C7-9F88-82B1BF516930.dita"><apiname>DPhysicalDevice</apiname></xref> derived factory object </p> </li>
+<li id="GUID-5DEA2654-8954-52EC-B498-066AE05AB209"><p> <xref href="GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3.dita#GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3/GUID-C32CF25E-553B-5786-88ED-4587AC0DF3BA">modify the DLocalDrive::Ecaps() handling</xref>  </p> </li>
+<li id="GUID-CED0CA1D-44EF-51DC-BC56-60B88A9D0494"><p>modify the media drivers <xref href="GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC.dita#GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC/GUID-EB244422-0BEC-3D3F-BDDA-3F050A2697A7"><apiname>DMediaDriver::Request</apiname></xref> function
+to accept the four new <xref href="GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3.dita#GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3/GUID-AE44672E-F60D-563C-BB6A-B70AF187C366">paging
+request</xref> types </p> </li>
+<li id="GUID-A7CFB8AA-4D95-5DD3-AF3F-0FAB0448F218"><p> <xref href="GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3.dita#GUID-EB2566BD-8F65-5A81-B215-E8B05CFE21C3/GUID-0EA673E6-FEE4-51F6-9C84-9411316D7357">Handling fragmented write requests</xref>. </p> </li>
+</ol> </section>
+<section id="GUID-77FBA53A-CC78-5CD1-8FDF-F6A8001DE466"><title>Changes to
+variantmediadef.h</title> <p>The following should be defined using appropriate
+names in the variant's <i>variantmediadef.h</i> file: </p> <ul>
+<li id="GUID-F5EFB1C8-B7C4-52AD-88A2-8A7659527373"><p> <codeph>PAGING_TYPE</codeph> -
+flags that indicate whether code paging and/or ROM paging is supported </p> </li>
+<li id="GUID-2745304A-2FAF-5DCB-88D3-74BD56B475E0"><p> <codeph>NAND_PAGEDRIVELIST</codeph> -
+a list of the paging drives </p> </li>
+<li id="GUID-507FB105-E254-501E-B22A-33E93C3CABA5"><p> <codeph>NAND_PAGEDRIVECOUNT</codeph> -
+the total number of paging drives </p> </li>
+<li id="GUID-F3D6494E-A14D-5FB1-A3E7-3D75D3753E12"><p> <codeph>NUM_PAGES</codeph> -
+if a write request points to data that resides in paged ROM, the request is
+split up into separate fragments of the specified size. This value needs to
+be chosen with care, as if it is too small writes can take too long to finish. </p> </li>
+</ul><p> <note> Normal write requests which point to data that is not in paged
+ROM are not fragmented. However, large requests are split up into smaller
+requests by the file server, providing clients with a more responsive system.</note> </p> <p>The
+macros defined in the file <i>variantmediadef.h</i> are passed to <xref href="GUID-9E60E8D9-619E-3A76-BAC8-93A60D62C7DF.dita#GUID-9E60E8D9-619E-3A76-BAC8-93A60D62C7DF/GUID-5FDD89C6-C34A-3A0D-A422-D148DDE23E42"><apiname>LocDrv::RegisterPagingDevice()</apiname></xref>.
+This function is similar to <xref href="GUID-9E60E8D9-619E-3A76-BAC8-93A60D62C7DF.dita#GUID-9E60E8D9-619E-3A76-BAC8-93A60D62C7DF/GUID-647D0858-FE04-3A4F-99CE-81CD0B34CE7B"><apiname>LocDrv::RegisterMediaDevice()</apiname></xref> in
+that it takes a drive list as a parameter, but it identifies the drive or
+drives to be used for code paging. If code only ROM paging is needed, set
+the drive count to zero. </p> <p>Changes made to support paging on NAND: </p> <codeblock id="GUID-1425F457-8F28-5CD7-B8A4-3FC3D2777D73" xml:space="preserve">// Variant parameters for NAND flash media driver (mednand.pdd)
+#define NAND_DRIVECOUNT 8
+#define NAND_DRIVELIST 2,3,5,6,7,9,10,11
+#define NAND_NUMMEDIA 1
+#define NAND_DRIVENAME "Nand"
+
+#define PAGING_TYPE DPagingDevice::ERom | DPagingDevice::ECode
+
+// code paging from writeable FAT, Composite FAT and first ROFS
+#define NAND_PAGEDRIVELIST 2,5,6    
+#define NAND_PAGEDRIVECOUNT 3
+
+// defines the size of fragment
+#define NUM_PAGES 8</codeblock> </section>
+<section id="GUID-686EFEF4-A514-51BC-8378-962A8899F270"><title>Changes to
+the media driver kernel extension point</title> <p>The kernel-extension entry
+point must create a DFC queue to satisfy any page fault that occurs in the
+drive thread. Failure to do so results in a kernel fault. The entry point
+must then create a <xref href="GUID-3715787E-9ADD-39E7-B22A-62CBBD2CEF1B.dita"><apiname>DPrimaryMediaBase</apiname></xref> object and register
+it with the local media subsystem. To support paging, the entry point needs
+altering to register the paging device with the demand paging subsystem and
+instantiate and install the factory object. </p> <codeblock id="GUID-885C8178-46FB-5F4B-9755-E048A48C42A7" xml:space="preserve">DECLARE_STANDARD_EXTENSION()
+    {   
+    TInt r=Kern::DfcQInit(&amp;TestMediaDfcQ,KTestThreadPriority,&amp;KTestMediaThreadName);
+    if (r|=KErrNone)
+        return r;
+ 
+    DPrimaryMediaBase* pM=new DPrimaryMediaBase;
+    if (!pM)
+        return r;
+
+    pM-&gt;iDfcQ=&amp;TestMediaDfcQ;
+    r=LocDrv::RegisterMediaDevice(
+        MEDIA_DEVICE_NAND,
+        NAND_DRIVECOUNT,
+        NAND_DRIVELIST,
+        pM,
+        NAND_NUMMEDIA,
+        NAND_DRIVENAME);
+    if (r != KErrNone)
+        return r;
+
+    r = LocDrv::RegisterPagingDevice(
+        pM,
+        NAND_PAGEDRIVELIST,
+        NAND_PAGEDRIVECOUNT,
+        PAGING_TYPE,
+        SECTOR_SHIFT,
+        NUM_PAGES);
+    if (r == KErrNone)
+        {
+        device = new DPhysicalDeviceMediaTest;
+        if (device == NULL)
+            return KErrNoMemory;
+        r = Kern::InstallPhysicalDevice(device);
+        }
+    // Ignore error if demand paging not supported by kernel
+    else if (r == KErrNotSupported)
+        r = KErrNone;
+    else
+        return r;
+
+    pM-&gt;iMsgQ.Receive();
+    return KErrNone;
+    }</codeblock> <p>The fifth parameter passed to the function <xref href="GUID-9E60E8D9-619E-3A76-BAC8-93A60D62C7DF.dita#GUID-9E60E8D9-619E-3A76-BAC8-93A60D62C7DF/GUID-5FDD89C6-C34A-3A0D-A422-D148DDE23E42"><apiname>LocDrv::RegisterPagingDevice()</apiname></xref> named <codeph>SECTOR_SHIFT</codeph> is the log2 of the sector size for the given media. For example, passing
+a value of 9 corresponds to a sector size of 512 for most media. </p> <p> <note> The <xref href="GUID-52853C0D-CA98-3B92-B7D4-FF1C1F06C1A6.dita"><apiname>DECLARE_EXTENSION_PDD</apiname></xref> entry
+point is called some time later when the file server tries to load all the
+media drivers in the system. When this happens a second factory object is
+created by the media driver, but this is deleted by the kernel when it discovers
+that another factory object bearing the same name is already in its internal
+list.</note> </p> </section>
+<section id="GUID-C32CF25E-553B-5786-88ED-4587AC0DF3BA"><title>Changes to
+DLocalDrive::ECaps handling</title> <p>The <xref href="GUID-C57F8D34-DAB5-388F-A99F-A952916B7EA6.dita"><apiname>TLocalDriveCaps</apiname></xref> structure
+needs to be modified so that: </p> <ul>
+<li id="GUID-FECDE295-A9D3-5373-BD01-F2A7EAB83897"><p>the <xref href="GUID-FF7F3425-9F7C-3146-BA0A-FB68D1A2381C.dita"><apiname>KMediaAttPageable</apiname></xref> flag
+is set in <xref href="GUID-722A1F4D-3A76-3BE3-95AB-2AA7745930D0.dita"><apiname>iMediaAtt</apiname></xref>  </p> </li>
+<li id="GUID-82EC6B7C-FF34-5E2C-BFF1-832C0769B517"><p>the <xref href="GUID-ED80FF32-9226-31E4-8717-D4A29948A75B.dita"><apiname>KDriveAttPageable</apiname></xref> flag
+is set if a particular drive has been registered as code paging. This is determined
+by testing <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-F5F80522-E23D-3A3D-86B5-6DC6C9E5C3B1"><apiname>TLocDrvRequest::Drive()</apiname></xref> <codeph>-&gt;iPagingDrv</codeph>. </p> </li>
+</ul> <p>Additionally, the <xref href="GUID-C57F8D34-DAB5-388F-A99F-A952916B7EA6.dita"><apiname>TLocalDriveCaps</apiname></xref> <codeph>::iDriveAtt</codeph> must
+have the <xref href="GUID-89ABFCAC-65EF-3DF3-83B8-2B0A169CCAFA.dita"><apiname>KDriveAttLocal</apiname></xref> and <xref href="GUID-78343374-6F5D-365D-BF3E-9AD19C77FB80.dita"><apiname>KDriveAttInternal</apiname></xref> bits
+set and the <xref href="GUID-88C9C181-3BC3-35FB-BF82-A81C40EEDEB8.dita"><apiname>KDriveAttRemovable</apiname></xref> bit cleared. </p> <codeblock id="GUID-04F15DFB-144E-5966-88B5-227B7FC97B55" xml:space="preserve">TInt DMediaDriverTest::Request(TLocDrvRequest&amp; aRequest)
+    {
+    TInt r=KErrNotSupported;
+    TInt id=aRequest.Id();
+
+    if (id == DLocalDrive::ECaps)
+        {
+        TLocDrv* drive = aRequest.Drive();
+        TLocalDriveCapsV4&amp; c = *(TLocalDriveCapsV4*)aRequest.RemoteDes();   
+        r=Caps(*drive,c);
+        }
+    // etc…
+    }
+
+TInt DMediaDriverTest::Caps(TLocDrv&amp; aDrive, TLocalDriveCapsV4&amp; caps)
+    {
+    // fill in rest of caps structure as usual…
+
+    if(aDrive.iPrimaryMedia-&gt;iPagingMedia)
+        caps.iMediaAtt|=KMediaAttPageable;
+    if(aDrive.iPagingDrv)
+        caps.iDriveAtt|=KDriveAttPageable; 
+    }</codeblock> </section>
+<section id="GUID-AE44672E-F60D-563C-BB6A-B70AF187C366"><title>Handling page
+requests</title> <p>Four new request types need to be handled to support paging: </p> <ul>
+<li id="GUID-703713F1-9276-583A-9963-325C04F8D4B6"><p> <xref href="GUID-951FB996-24B3-3340-8386-24B1A895EA16.dita"><apiname>EWriteRequestFragment</apiname></xref> marks
+the start and middle of a sequence of writes. </p> </li>
+<li id="GUID-F40CCE14-17DF-52EB-937F-CEBC2B78CC94"><p>Each sequence is terminated
+by a <xref href="GUID-8B4109E6-B9F8-3C18-9F9A-0AB20FDA5E86.dita"><apiname>EWriteRequestFragmentLast</apiname></xref> request as long as none
+of the prior requests completed with an error. </p> </li>
+<li id="GUID-47C8C482-77B4-5447-8497-E8185BF1350B"><p> <xref href="GUID-F20251F4-A72D-32E5-B2AF-87F71CD5CD87.dita"><apiname>ERomPageInRequest</apiname></xref> is
+treated as a normal read except that: </p> <ol id="GUID-DEEF7484-32E1-5739-839D-D1257A51B83C">
+<li id="GUID-A90D4A45-05E4-5F9C-B47E-26F67F5462EE"><p>the list of partitions
+reported by <xref href="GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC.dita#GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC/GUID-B2F42829-028C-341A-B34D-A8243CA434EB"><apiname>DMediaDriver::PartitionInfo</apiname></xref> does not normally
+include the partition containing the ROM image. Therefore, the local media
+subsystem does not know the absolute position from the start of the media
+of a particular ROM page. The position stored in <xref href="GUID-F20251F4-A72D-32E5-B2AF-87F71CD5CD87.dita"><apiname>ERomPageInRequest</apiname></xref> is
+offset from the start of the ROM image, rather than the start of the media.
+Therefore, the media driver must add the offset of the start of the ROM image
+to the position stored in <xref href="GUID-F20251F4-A72D-32E5-B2AF-87F71CD5CD87.dita"><apiname>ERomPageInRequest</apiname></xref> to obtain the
+absolute position before issuing a read request. </p> </li>
+<li id="GUID-E020A5D1-82FA-5857-AB1D-42A59D337EFD"><p>when the read is complete
+the media driver needs to call <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-362AB6B2-9C3D-342F-BB4A-F252ECD7EF3A"><apiname>TLocDrvRequest::WriteToPageHandler</apiname></xref> to
+write the data back to the client, rather than <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-2AC4DBA4-5C87-39C7-B6CF-95ECB7286339"><apiname>TLocDrvRequest::WriteRemote</apiname></xref> as
+for a normal read, </p> </li>
+</ol> </li>
+<li id="GUID-50298F39-D1A0-5731-8E50-D18514941D70"><p> <xref href="GUID-E42B407D-8E18-337B-9CBB-4DCDD0AABBE9.dita"><apiname>ECodePageInRequest</apiname></xref> is
+treated as a normal read, except that the function <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-362AB6B2-9C3D-342F-BB4A-F252ECD7EF3A"><apiname>TLocDrvRequest::WriteToPageHandler</apiname></xref> should
+be used to write the data back to the demand paging subsystem. However, the
+position in the request is offset from the start of the media as for a normal
+read. </p> </li>
+</ul> <p>These request types are enumerated in the <xref href="GUID-6C039CFA-BF2F-3272-80FE-71430C12F0F4.dita"><apiname>DMediaPagingDevice</apiname></xref> class: </p> <codeblock id="GUID-AD9B48CF-7757-5C8A-A2EF-B27F2DC9BDD8" xml:space="preserve">NONSHARABLE_CLASS(DMediaPagingDevice) : public DPagingDevice
+    {
+public:
+    enum TPagingRequestId
+        {
+        /** 
+        Identifies any middle fragment of a Write request on a partition of a media that supports paging.
+        */
+        EWriteRequestFragment = 
+            DLocalDrive::EFirstReqNumberReservedForPaging,
+
+        /** 
+        Identifies the last fragment of a Write request on a partition of a media that supports paging.
+        */
+        EWriteRequestFragmentLast = 
+            DLocalDrive::EFirstReqNumberReservedForPaging+1,
+
+        /** 
+        Request for paging in (read) data from the ROM store area.
+        */
+        ERomPageInRequest =
+            DLocalDrive::EFirstReqNumberReservedForPaging+2,
+
+        /** 
+        Request for paging in (read) data from the code store area.
+        */
+        ECodePageInRequest =
+            DLocalDrive::ELastReqNumberReservedForPaging
+        };
+        //etc…
+    }</codeblock> </section>
+<section id="GUID-0EA673E6-FEE4-51F6-9C84-9411316D7357"><title>Handling fragmented
+write requests</title> <p>In many respects, <xref href="GUID-951FB996-24B3-3340-8386-24B1A895EA16.dita"><apiname>EWriteRequestFragment</apiname></xref> and <xref href="GUID-8B4109E6-B9F8-3C18-9F9A-0AB20FDA5E86.dita"><apiname>EWriteRequestFragmentLast</apiname></xref> can
+be treated as normal write requests. It should be noted however, that these
+write requests can be interleaved with requests from other file server threads
+if the media supports more than one partition, the resulting operations may
+be perceived as a functional break in behaviour. </p> <p>If it is important
+to maintain backwards compatibility and to prevent write requests from being
+interleaved, the media driver must keep track of the current write-request
+chain and defer requests from other drive threads while a write-fragment chain
+is in progress by: </p> <ul>
+<li id="GUID-311A0DF2-601D-5623-A059-7E20FAFEEF1C"><p>ensuring the local media
+subsystem LDD has been built with the <codeph>__ALLOW_CONCURRENT_FRAGMENTATION__</codeph> macro
+undefined. This ensures that the local media subsystem never issues more than
+one write fragment at a time </p> </li>
+<li id="GUID-9504A0D1-2147-5968-AB8C-2B9D99A48C0F"><p>modifying the paging-media
+driver so that it keeps track of write-request chains and defers any read
+or format requests received after the first fragment and before the last in
+a sequence. When undefined, the macro subsystem does not issue more than one
+write-request chain at a time. </p> </li>
+</ul><p><note> Write fragments should never be deferred, only read or format
+requests may be deferred. </note></p>  <p>To achieve this the media driver
+can maintain a bit mask, each bit of which represents a write in progress
+flag for a particular drive: </p> <codeblock id="GUID-CB127C9B-51D5-5D1A-BAF6-4F8CEF308912" xml:space="preserve">iFragmenting|=(0x1&lt;&lt;iCurrentReq-&gt;Drive()-&gt;iDriveNumber);</codeblock> <p>If a read or format request is received while any of the bits in <codeph>iFragmenting</codeph> are
+set, that request may be deferred. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-EB76FAF8-CD4B-5CB6-9F23-C852ED91866F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-EB76FAF8-CD4B-5CB6-9F23-C852ED91866F" xml:lang="en"><title>Concepts</title><shortdesc>This section describes the architecture and behavior of
+the Keyboard Driver. </shortdesc><prolog><metadata><keywords/></metadata></prolog><related-links>
+<link href="GUID-2E42E7EA-FED8-522C-8A5F-F65D799476C9.dita"><linktext>Keyboard
+  Driver Implementation Tutorial</linktext></link>
+<link href="GUID-D34DB4A1-1B17-5FAF-A48B-E06D247B0A83.dita"><linktext>Keyboard
+  Mapping DLL Tutorial</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-EBF025DB-1552-5E99-8C07-09932DB60552.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,543 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-EBF025DB-1552-5E99-8C07-09932DB60552" xml:lang="en"><title>Physical
+Channel Implementation</title><shortdesc>A media driver must implement a physical channel class derived
+from the <codeph>DMediaDriver</codeph> base class. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p/>
+<p>This includes those drivers associated with fixed media, such as the internal
+drive, or removable media, such as a PC Card or MultiMediaCard. </p>
+<p> <codeph>DMediaDriver</codeph> is an abstract class that has virtual functions
+that must be implemented by your derived class. The following class definition
+is typical: </p>
+<codeblock id="GUID-B39837DA-6037-58D2-A1BE-3E7F1E218F7B" xml:space="preserve">class DMyMediaDriver : public DMediaDriver
+    {
+public:
+    DMyMediaDriver (TInt aMediaId);
+    ~DMmcMediaDriver ();
+public:    
+    virtual void Close();
+public:    
+    virtual void Disconnect(DLocalDrive* aLocalDrive, TThreadMessage*);
+    virtual TInt Request(TLocDrvRequest&amp; aRequest);
+    virtual TInt PartitionInfo(TPartitionInfo&amp; anInfo);
+    virtual void NotifyPowerDown();
+    virtual void NotifyEmergencyPowerDown();
+public:
+    TInt DoCreate(TInt aMediaId);
+    };
+      </codeblock>
+<p>All the functions except the constructor and <codeph>DoCreate()</codeph> either
+implement or re-implement virtual functions defined by <codeph>DMediaDriver</codeph>. </p>
+<p>The framework does not require the <codeph>DoCreate()</codeph> function,
+but it is useful to implement such a function to act as a second-phase constructor
+in the creation of the media driver. In the example code fragments, we call <codeph>DoCreate()</codeph> from
+the <xref href="GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930.dita#GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930/GUID-32B157E9-0F71-5C1B-A0FA-08D5B1ACA700">PDD
+factory object's Create()</xref> function that is responsible for creating
+the media driver. </p>
+<p>There is, of course, nothing to stop you from adding your own functions
+and data members, if this is appropriate for your implementation. In addition,
+your are also free to add other classes, functions and enums to your media
+driver implementation. </p>
+<ul>
+<li id="GUID-E17276B8-4595-5A45-89B0-D053A659A17E"><p> <xref href="GUID-EBF025DB-1552-5E99-8C07-09932DB60552.dita#GUID-EBF025DB-1552-5E99-8C07-09932DB60552/GUID-FE5BB479-7AC4-5DB8-87A3-55E855E1A176">Constructor</xref> </p> </li>
+<li id="GUID-927ED2FA-9A58-5C99-85B6-44BAD9F2F47A"><p> <xref href="GUID-EBF025DB-1552-5E99-8C07-09932DB60552.dita#GUID-EBF025DB-1552-5E99-8C07-09932DB60552/GUID-D308D7F7-25B9-5A3A-BC19-A01C5948B949">DoCreate() - second phase constructor</xref>  </p> </li>
+<li id="GUID-380702AD-FBC8-584A-B875-B7C23AC841DE"><p> <xref href="GUID-EBF025DB-1552-5E99-8C07-09932DB60552.dita#GUID-EBF025DB-1552-5E99-8C07-09932DB60552/GUID-4ABC799E-33EE-5260-9CD0-71F0A5E7F980">PartitionInfo() - return the partition information</xref>  </p> </li>
+<li id="GUID-D0EC11D5-CC9C-5A45-BF5B-06CDBEB8738B"><p> <xref href="GUID-EBF025DB-1552-5E99-8C07-09932DB60552.dita#GUID-EBF025DB-1552-5E99-8C07-09932DB60552/GUID-EC193360-31C2-5012-8ED2-19F1C48C8FC5">Request() - handling requests</xref>  </p> </li>
+</ul>
+<section id="GUID-FE5BB479-7AC4-5DB8-87A3-55E855E1A176"><title>Constructor</title> <p>The
+media driver object is created by your PDD factory object's implementation
+of the <xref href="GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930.dita#GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930/GUID-32B157E9-0F71-5C1B-A0FA-08D5B1ACA700">Create()</xref> function.
+The following is the relevant line of code: </p> <codeblock id="GUID-012D3CB1-7C35-590E-AA5D-FBD0F21F957F" xml:space="preserve">...
+//Create my DMediaDriver derived object
+DMyMediaDriver* pD=new DMyMediaDriver (aMediaId);
+...</codeblock> <p>Your constructor, prototyped as: </p> <codeblock id="GUID-66FD6B05-D32B-5CD6-A546-B1B8E7733EE5" xml:space="preserve">DMyMediaDriver (TInt aMediaId);</codeblock> <p>gives you the chance to do any initialisation that is safe, i.e. that
+cannot fail. Typically, this is the kind of initialisation that does not need
+to acquire resources. This is the first phase of the typical Symbian platform
+two-phase construction process. </p> <codeblock id="GUID-A1C95B09-C03B-531A-9E38-0E77F9E574F5" xml:space="preserve">DMyMediaDriver::DMyMediaDriver (TInt aMediaId)
+    :DMediaDriver(aMediaId)
+    {
+    //…do safe initialisation here
+    }
+        </codeblock> <p>As this code fragment shows, you need to call the
+base class constructor first, forwarding the <codeph>TInt aMediaId</codeph> value.
+You do not need to do anything else with this value. Note that this value
+is the unique media ID used when the media driver was registered. </p> </section>
+<section id="GUID-D308D7F7-25B9-5A3A-BC19-A01C5948B949"><title>DoCreate()
+- second phase constructor</title> <p>The media driver object is created by
+your PDD factory object's implementation of the <xref href="GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930.dita#GUID-A6D14A03-ADBF-570D-8AC7-E8BC2700F930/GUID-32B157E9-0F71-5C1B-A0FA-08D5B1ACA700">Create()</xref> function. The following is the relevant line of code, which is called after
+successful creation of the media driver object: </p> <codeblock id="GUID-003B4A82-853B-5ABF-A33F-69ED7AC520F9" xml:space="preserve">...
+// Call my media driver’s second-stage constructor
+Tint r = KErrNoMemory;
+    if(pD)
+        {
+        r = pD-&gt;DoCreate(aMediaId);
+        }
+...
+        </codeblock> <p>This is a second-phase constructor that allows you
+to do more complex initialisation, and initialisation that might fail. Typically,
+this is initialisation that acquires resources (including memory). The outline
+implementation of <codeph>DoCreate()</codeph> is: </p> <codeblock id="GUID-4380C850-B722-52E5-A849-602312C2441D" xml:space="preserve">TInt DMyMediaDriver::DoCreate(TInt aMediaId)
+    {
+    TInt r = KErrNone;
+    //…do complex initialisation here
+    return r;
+    }
+        </codeblock> <p>Depending on the complexity of your initialisation,
+you can either do all your initialisation here, and complete immediately,
+or you can do the initialisation as an asynchronous operation, in which case
+initialisation will complete at some later time. </p> <p>If you do this <i>synchronously</i>,
+then the return code should reflect the success or failure of the operation.
+In practice, this will almost always be <codeph>KErrNone</codeph>. </p> <p>If
+you do this <i>asynchronously</i>, then, on completion of the initialisation
+processing, a call should be made to: <codeph>DMediaDriver::OpenMediaDriverComplete()</codeph> passing
+either <codeph>KErrNone</codeph> or one of the other system-wide codes as
+appropriate. </p> </section>
+<section id="GUID-4ABC799E-33EE-5260-9CD0-71F0A5E7F980"><title>PartitionInfo()
+- return the partition information</title> <p>Once the media driver has been
+successfully created and initialised, and has informed the media driver subsystem
+of this fact by a call to <codeph>DMediaDriver::OpenMediaDriverComplete()</codeph>,
+then the subsystem makes a call to the media driver's <codeph>PartitionInfo()</codeph> function
+to get partition information for the media device. </p> <p>The prototype function
+is: </p> <codeblock id="GUID-C22CA159-CDD5-5900-B753-64E1A481B6F1" xml:space="preserve">TInt PartitionInfo(TPartitionInfo&amp; anInfo);</codeblock> <p>A <xref href="GUID-00D1DAB7-C23A-30F4-B5A3-B47EED5A5DD3.dita"><apiname>TPartitionInfo</apiname></xref> object is passed to the function, which the media driver must fill in. </p> <p>Decoding
+of partition information may require media access, and as such may be a long
+running activity. Support is provided that allows this to be done asynchronously.
+You use the <i>return code</i> from <codeph>PartitionInfo()</codeph> to tell
+the media driver subsystem which operational mode you are using: </p> <ul>
+<li id="GUID-6A5496C7-3896-5EA4-AF92-72BFAEAEED55"><p>return <b>KErrNone</b>,
+if the decoding operation is to be done <b>asynchronously</b>. Note that on
+completion, the asynchronous operation must call <xref href="GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC.dita#GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC/GUID-1E38DA87-4D5C-3D3C-8FE9-145E5877D02A"><apiname>DMediaDriver::PartitionInfoComplete()</apiname></xref>,
+returning <codeph>KErrNone</codeph>, or one of the other system-wide error
+codes, if appropriate. </p> </li>
+<li id="GUID-4F34B295-062F-5FCB-809B-73F19E4DE1A2"><p>return a value <b>other
+than KErrNone </b>, if the decoding operation has been done <b>synchronously</b>.
+If the synchronous operation is successful, return <i>KErrCompletion</i>,
+otherwise return one of the other system-wide error codes, but not KErrNone. </p> </li>
+</ul> <p><b>Decoding
+simple partitions</b> </p> <p>The following example shows the implementation
+of a simple <codeph>PartitionInfo()</codeph> function. Such an implementation
+would be provided for non-removable media, such as internal Flash memory,
+where the layout is simple and known to the system. </p> <p>This implementation
+reports a single partition with the size of the entire media. The partition
+expects to be mounted with the FAT filesystem. </p> <p>Note that this operation
+is done synchronously, and the function returns <codeph>KErrCompletion</codeph> to
+indicate this. </p> <codeblock id="GUID-3D99CC4D-5996-502B-8A3F-6DE4675EAFE5" xml:space="preserve">TInt DMyMediaDriver::PartitionInfo(TPartitionInfo&amp; aInfo)
+    {
+    aInfo.iPartitionCount                = 1;
+    aInfo.iEntry[0].iPartitionBaseAddr    = 0;
+    aInfo.iEntry[0].iPartitionLen        = TotalSizeInBytes();
+    aInfo.iEntry[0].iPartitionType        = KPartitionTypeFAT12;
+    
+    aInfo.iMediaSizeInBytes                = TotalSizeInBytes();
+
+    return KErrCompletion;
+    }
+          </codeblock> <p><b>Decoding
+FAT Partitions</b> </p> <p>More complex implementations of <codeph>PartitionInfo()</codeph> may
+be required when handling removable media or more complex internal media where
+the layout of the media is unknown to the system. </p> <p>This example shows
+a typical implementation for a FAT based removable media device. Here, <codeph>PartitionInfo()</codeph> starts
+the operation, which is done asynchronously by the <codeph>DoPartitionInfo()</codeph> function. </p> <p>Note
+that <codeph>PartitionInfo()</codeph> returns <codeph>KErrNone</codeph>, which
+tells the media driver subsystem that the operation will be done asynchronously. </p> <p>Note
+also that on completion, <codeph>DoPartitionInfo()</codeph> calls <codeph>PartitionInfoComplete()</codeph> to
+tell the media driver subsystem that the operation is complete. </p> <codeblock id="GUID-17F9AD37-7D5F-5F8F-960B-EF36FBE03A04" xml:space="preserve">TInt DMyMediaDriverFlash::PartitionInfo(TPartitionInfo&amp; aInfo)
+    {
+    iPartitionInfo = &amp;anInfo                        // Store aInfo until needed
+
+    TInt errCode = LaunchPartitionInfoRequest();    // Start the asynchronous request
+
+    return(errCode);    // This needs to be KErrNone to indicate that the operation
+                        // will be completed asynchronously (unless an error occurs launching
+                        // the asynchronous request!)
+    }
+          </codeblock> <p>This is the function that runs asynchronously </p> <codeblock id="GUID-84368231-7B29-5EE9-A93B-851C7E5C0B62" xml:space="preserve">TInt DMyMediaDriver::DoPartitionInfo()
+    {
+    TInt partitionCount = iPartitionInfo-&gt;iPartitionCount = 0;
+
+    // Read of the first sector successful so check for a Master Boot Record
+    if (*(TUint16*)(&amp;iIntBuf[KMBRSignatureOffset])!=0xAA55)
+        {
+        return(KErrCorrupt);
+        }
+
+    // Move the partition entries to a 4 byte boundary
+    memcpy(&amp;iIntBuf[0],&amp;iIntBuf[KMBRFirstPartitionEntry],(sizeof(TMBRPartitionEntry)&lt;&lt;2)); 
+
+    // Search for a x86 default boot partition - let this be the first
+    TMBRPartitionEntry *pe=(TMBRPartitionEntry*)(&amp;iIntBuf[0]);
+
+    TInt i;
+    TInt defaultPartitionNumber=-1;
+    for (i=0;i&lt;KMaxPartitionEntries;i++,pe++)
+        {
+        if (pe-&gt;IsDefaultBootPartition())
+            {
+            SetPartitionEntry(&amp;iPartitionInfo-&gt;iEntry[0],pe-&gt;iFirstSector,pe-&gt;iNumSectors);
+            iHiddenSectors=pe-&gt;iFirstSector;
+            defaultPartitionNumber=i;
+            partitionCount++;
+            break;
+            }
+        }
+
+    // Now add any other partitions
+    pe=(TMBRPartitionEntry*)(&amp;iIntBuf[0]);     // Reset it
+    for (i=0;i&lt;KMaxPartitionEntries;i++,pe++)
+        {
+        if (defaultPartitionNumber==i)
+            {
+            continue;    // Already sorted
+            }
+        if (pe-&gt;IsValidDosPartition())
+            {
+            SetPartitionEntry(&amp;iPartitionInfo-&gt;iEntry[partitionCount],pe-&gt;iFirstSector,pe-&gt;iNumSectors);
+            if (partitionCount==0)
+            iHiddenSectors=pe-&gt;iFirstSector;
+            partitionCount++;
+            }
+        }
+
+    if (defaultPartitionNumber==(-1) &amp;&amp; partitionCount==0)
+        {
+        // Assume it has no MBR, and the Boot Sector is in the 1st sector
+        SetPartitionEntry(&amp;iPartitionInfo-&gt;iEntry[0], 0, iMediaSize);
+        iHiddenSectors=0;
+        partitionCount=1;
+        }
+        
+    iPartitionInfo-&gt;iPartitionCount=partitionCount;
+    iPartitionInfo-&gt;iMediaSizeInBytes=TotalSizeInBytes();
+
+    PartitionInfoComplete(err);
+    
+    return(KErrNone);
+    }
+          </codeblock> </section>
+<section id="GUID-EC193360-31C2-5012-8ED2-19F1C48C8FC5"><title>Request() -
+handling requests</title> <p>You handle requests by implementing your media
+driver's <codeph>Request()</codeph> function. This is prototyped as: </p> <codeblock id="GUID-2DABBFE2-5F74-5DC4-B1A5-E50A41258E8A" xml:space="preserve">TInt Request(TLocDrvRequest&amp; aRequest)=0;</codeblock> <p>This
+function is usually called in the context of the client thread that originally
+initiated the I/O request to the file server, although you should never assume
+so. Note that you may also see the originating thread referred to as <i>the
+remote thread</i>. </p> <p>The request type, as identified by the request
+ID, and the information associated with the request is accessed through the <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita"><apiname>TLocDrvRequest</apiname></xref> object,
+which is passed to the <codeph>Request()</codeph> function. The information
+supplied includes offsets, data lengths, the requesting thread etc, but clearly
+depends on the request ID. You get the request ID by calling <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-615CA1FE-0FDA-39F4-875D-FBB7B6F6FAD8"><apiname>TLocDrvRequest::Id()</apiname></xref>,
+and this will be one of the <xref href="GUID-720001A0-79E6-3E25-B5F0-4B39EAF95D12.dita#GUID-720001A0-79E6-3E25-B5F0-4B39EAF95D12/GUID-0559A1ED-05A1-386E-B728-0D500ED4E3EA"><apiname>DLocalDrive::TRequestId</apiname></xref> enum
+values. </p> <p>Each request ID, as defined by <xref href="GUID-720001A0-79E6-3E25-B5F0-4B39EAF95D12.dita#GUID-720001A0-79E6-3E25-B5F0-4B39EAF95D12/GUID-0559A1ED-05A1-386E-B728-0D500ED4E3EA"><apiname>DLocalDrive::TRequestId</apiname></xref> has
+a specific meaning. The information that is available also depends on the
+request ID. </p> <p>Depending on the request ID, the operation can be done
+synchronously or asynchronously. However, it is the responsibility of the
+implementor of the media driver to handle the incoming requests and to handle
+them as appropriate to the specific media, i.e. synchronously or asynchronously. </p> <p>In
+general, the function should return once the request is initiated. If the
+entire operation cannot be completed immediately, then further request processing
+must occur within ISRs and DFCs, i.e. using some hardware specific mechanism
+to indicate completion, or by the use of considerate poll timers to considerately
+poll the device for it’s current status, with the final request completion
+being done from within a DFC. The code that implements the asynchronous requests
+can run within its own thread, or use one of the default threads provided
+by the kernel (DFC queue thread 0). </p> <p>The underlying media driver framework
+allows multiple requests to be processed simultaneously. However, other than
+being able to issue multiple requests, there is no inherent support in the
+media driver framework to support the handling of multiple requests, so such
+functionality must be handled by the media driver itself. The underlying media
+driver framework does, however, provide basic support for deferring requests
+for later processing should the media driver not be capable of supporting
+multiple requests. </p> <table id="GUID-A216F849-6301-5C82-8D54-40BE612770F8">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p>ECaps </p> </entry>
+<entry><p>This is a request for information about the size, type, attributes
+etc of the media. <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-F16E34E3-7DB1-3C6C-800D-173814AADC22"><apiname>TLocDrvRequest::RemoteDes()</apiname></xref> gives you
+access to the object into which the media driver should put the requested
+information. The object passed across is a <xref href="GUID-414CD5E5-216F-3D97-9F04-A93B1A0EA74F.dita"><apiname>TLocalDriveCapsV2</apiname></xref> type,
+and this is passed by the media driver subsystem in the form of a package
+buffer, a <xref href="GUID-C7A094BD-846F-3ED2-8CCE-C0743DB3712A.dita"><apiname>TPckgBuf</apiname></xref> type. </p> <p>In practice, you just
+need to use a simple cast to access the object. The following code fragment
+is always used: </p> <codeblock id="GUID-35711E5C-5F23-5EC6-8B43-81C2168E1437" xml:space="preserve">...
+if (id == DLocalDrive::ECaps)
+    {
+    TLocalDriveCapsV2&amp; c = *(TLocalDriveCapsV2*)aRequest.RemoteDes();
+    ...
+    }
+....
+              </codeblock> <p>This request type is synchronous. </p> </entry>
+</row>
+<row>
+<entry><p>ERead </p> </entry>
+<entry><p>This is a request to read data from the media device asynchronously. </p> <p>You
+need to start an asynchronous operation that reads <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-5D4ABE07-1186-392F-911F-5586150A5FB4"><apiname>TLocDrvRequest::Length()</apiname></xref> bytes
+from the media, starting at position <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-0BF048C8-81F1-3E71-B13C-7605A6668A30"><apiname>TLocDrvRequest::Pos()</apiname></xref> on
+the media. </p> <p>You transfer the data to the requesting thread's process
+by calling <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-842F91FF-C780-3E2A-8860-8F34815452FC"><apiname>TLocDrvRequest::WriteRemote()</apiname></xref>, where the first
+parameter is the source descriptor representing the data you have just read.
+For example: </p> <codeblock id="GUID-80E5A231-3F69-5C33-ADE0-1E0C7674992E" xml:space="preserve">...
+TPtrC8 des((const TUint8*)(iBase),len);
+TInt r=iReadReq-&gt;WriteRemote(&amp;des,0);
+...
+              </codeblock> <p>In this example, <codeph>iBase</codeph> is the
+location of the data that has just been read in from the device, and <codeph>len</codeph> is
+the length of this data. The code fragment also assumes that the data to be
+returned starts at iBase, and not at some offset from iBase. </p> <p>As this
+is an asynchronous operation, then when all data has been transferred, the
+request must be completed by calling <xref href="GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC.dita#GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC/GUID-8B9BB560-808F-3424-9638-7DED6737423E"><apiname>DMediaDriver::Complete()</apiname></xref>,
+passing the original request and a completion code. </p> </entry>
+</row>
+<row>
+<entry><p>EWrite </p> </entry>
+<entry><p>This is a request to write data to the media device asynchronously. </p> <p>You
+need to start an asynchronous operation that writes <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-5D4ABE07-1186-392F-911F-5586150A5FB4"><apiname>TLocDrvRequest::Length()</apiname></xref> bytes
+to the media, starting at position <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-0BF048C8-81F1-3E71-B13C-7605A6668A30"><apiname>TLocDrvRequest::Pos()</apiname></xref> on
+the media. </p> <p>Before doing the write, then you need to transfer the data
+to be written from the requesting thread's process by calling <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-96B80631-AD1C-35E8-8613-0A630BD7D9E9"><apiname>TLocDrvRequest::ReadRemote()</apiname></xref>,
+where the first parameter is the target descriptor. </p> <p>As this is an
+asynchronous operation, then when all data has been transferred, the request
+must be completed by calling <xref href="GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC.dita#GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC/GUID-8B9BB560-808F-3424-9638-7DED6737423E"><apiname>DMediaDriver::Complete()</apiname></xref>,
+passing the original request and a completion code. </p> </entry>
+</row>
+<row>
+<entry><p>EFormat </p> </entry>
+<entry><p>This is a request to format a section of the media asynchronously. </p> <p>The
+start position of the section to be formatted can be found by calling <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-0BF048C8-81F1-3E71-B13C-7605A6668A30"><apiname>TLocDrvRequest::Pos()</apiname></xref>,
+and the number of bytes to be formatted can be found by calling <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-5D4ABE07-1186-392F-911F-5586150A5FB4"><apiname>TLocDrvRequest::Length()</apiname></xref>. </p> <p>Following
+a format operation, the state of the formatted section depends on the type
+of media. In practice, you should access locations within the specified section,
+so that bad regions can be detected and reported. </p> <p>The length of each
+format request is usually based on the value of <xref href="GUID-414CD5E5-216F-3D97-9F04-A93B1A0EA74F.dita#GUID-414CD5E5-216F-3D97-9F04-A93B1A0EA74F/GUID-BDF05FE9-56B5-328B-B562-9F59EF14DAB2"><apiname>TLocalDriveCapsV2::iEraseBlockSize</apiname></xref>,
+as returned by the <codeph>ECaps</codeph> request. If you need to adjust the
+start address of the next format request, you can return a positive value
+that is interpreted as indicating the actual number of bytes formatted in
+the current step. This feature is useful for media that prefers format operations
+to be performed on specific boundaries; for example MultiMedia Cards. </p> <p>As
+this is an asynchronous operation, then when the format operation has been
+done, the request must be completed by calling <xref href="GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC.dita#GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC/GUID-8B9BB560-808F-3424-9638-7DED6737423E"><apiname>DMediaDriver::Complete()</apiname></xref>,
+passing the original request and a completion code. </p> </entry>
+</row>
+<row>
+<entry><p>EEnlarge </p> </entry>
+<entry><p>This is a request to enlarge the accessible range of the media asynchronously.
+For example, this is used on the internal RAM drive. </p> <p>Calling <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-5D4ABE07-1186-392F-911F-5586150A5FB4"><apiname>TLocDrvRequest::Length()</apiname></xref> gives
+you the number of bytes by which the accessible range is to be increased. </p> <p>The
+media attributes, as defined by the settings in <xref href="GUID-414CD5E5-216F-3D97-9F04-A93B1A0EA74F.dita#GUID-414CD5E5-216F-3D97-9F04-A93B1A0EA74F/GUID-886205BC-3234-3FDC-B17E-F9293C957097"><apiname>TLocalDriveCapsV2::iMediaAtt</apiname></xref> returned
+by the <codeph>ECaps</codeph> request, must have <xref href="GUID-8F5CB589-F631-3216-9BB0-DCCF96836E4E.dita"><apiname>KMediaAttVariableSize</apiname></xref> set,
+otherwise the request fails with <codeph>KErrNotSupported</codeph>. </p> <p>As
+this is an asynchronous operation, then when the operation is complete, the
+request must be completed by calling <xref href="GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC.dita#GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC/GUID-8B9BB560-808F-3424-9638-7DED6737423E"><apiname>DMediaDriver::Complete()</apiname></xref>,
+passing the original request and a completion code. </p> </entry>
+</row>
+<row>
+<entry><p>EReduce </p> </entry>
+<entry><p>This is a request to reduce the accessible range of the media asynchronously.
+For example, this is used on the internal RAM drive. </p> <p>The range to
+be removed is defined as <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-5D4ABE07-1186-392F-911F-5586150A5FB4"><apiname>TLocDrvRequest::Length()</apiname></xref> bytes
+starting at <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-0BF048C8-81F1-3E71-B13C-7605A6668A30"><apiname>TLocDrvRequest::Pos()</apiname></xref>. In effect, the request
+removes the section from <codeph>Pos()</codeph> to <codeph>Pos()</codeph> + <codeph>Length()</codeph>,
+and the length is reduced by <codeph>Length()</codeph>. </p> <p>The media
+attributes, as defined by the settings in <xref href="GUID-414CD5E5-216F-3D97-9F04-A93B1A0EA74F.dita#GUID-414CD5E5-216F-3D97-9F04-A93B1A0EA74F/GUID-886205BC-3234-3FDC-B17E-F9293C957097"><apiname>TLocalDriveCapsV2::iMediaAtt</apiname></xref> returned
+by the <codeph>ECaps</codeph> request, must have <xref href="GUID-8F5CB589-F631-3216-9BB0-DCCF96836E4E.dita"><apiname>KMediaAttVariableSize</apiname></xref> set,
+otherwise the request fails with <codeph>KErrNotSupported</codeph>. </p> <p>As
+this is an asynchronous operation, then when the operation is complete, the
+request must be completed by calling <xref href="GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC.dita#GUID-A0D4EB25-0BA4-39EE-874B-465EB9628DCC/GUID-8B9BB560-808F-3424-9638-7DED6737423E"><apiname>DMediaDriver::Complete()</apiname></xref>,
+passing the original request and a completion code. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-E6DF6D45-ACB1-5C0C-A4F1-02778EA69D34"><b>A simple implementation</b> </p> <codeblock id="GUID-6AABA189-4F0A-586D-B3DC-DC38F54A8721" xml:space="preserve">TInt DMyMediaDriver::Request(TLocDrvRequest&amp; aRequest)
+    {
+    TInt err = KErrNotSupported;
+    TInt id  = aRequest.Id();
+
+    if (id == DLocalDrive::ECaps)
+        {
+        TLocalDriveCapsV2&amp; c = *(TLocalDriveCapsV2*)aRequest.RemoteDes();
+        err = Caps(c);
+        c.iSize = m.Drive()-&gt;iPartitionLen;
+        c.iPartitionType = m.Drive()-&gt;iPartitionType;
+        return(err);
+        }
+
+    if(iCurrentReq != NULL)
+        {
+        return(KMediaDriverDeferRequest);
+        }
+
+    iCurrentReq = &amp;aRequest;
+
+    switch(id)
+        {
+        case DLocalDrive::ERead:
+            r = StartRead();
+            break;
+        case DLocalDrive::EWrite:
+            r = StartWrite();
+            break;
+        case DLocalDrive::EFormat:
+            r = StartErase();
+            break;
+        }
+
+    if (err &lt; 0)
+        {
+        iCurrentReq = NULL;
+        DMediaDriver::Complete(aRequest, err);
+        }
+    
+    return(err);
+    }
+            </codeblock> <p>This demonstrates the following behaviour: </p> <ul>
+<li id="GUID-12FE8B56-D998-5FDC-B3B8-CAAD3CBDD6C8"><p>The <codeph>ECaps</codeph> request
+is inherently synchronous, and must complete immediately. </p> </li>
+<li id="GUID-4188EC10-8F2D-5755-BC7A-9BEB663114E5"><p>This example only handles
+a single request at a time. If the media driver is busy handling a request,
+it can return the value <xref href="GUID-4E76E7B3-202A-3FE1-AAF2-5B41FF13843D.dita"><apiname>KMediaDriverDeferRequest</apiname></xref> which
+defers the message until the current request is complete. </p> </li>
+<li id="GUID-2A148BC4-E4B8-5EF5-ACF7-50BA52E5A02E"><p>Each message is passed
+on to the specific function that is responsible for handling the message.
+This provides readability and ease of maintenance. </p> </li>
+<li id="GUID-648C0A4B-3481-55A9-B0A4-887378B0EB7A"><p>If an error occurs,
+the request is completed immediately with the specified error code. </p> </li>
+</ul> <p>The following code is the implementation of the <codeph>StartWrite()</codeph> function
+that initiates the asynchronous write operation. It gets the length and position
+information, and then calls <codeph>DoWriteStep()</codeph>: </p> <codeblock id="GUID-B853FBC7-7A25-5A6B-8799-CB577595B461" xml:space="preserve">TInt DMyMediaDriver::StartWrite()
+    {
+    // Start an asynchronous write operation
+
+    iCurrentPos = iCurrentReq-&gt;Pos();
+    iCurrentLength = iCurrentReq-&gt;Length();
+
+    TInt err = DoWriteStep();
+        
+    return(err);
+    }
+                </codeblock> <p> <codeph>DoWriteStep()</codeph> performs a
+single write operation. In this example, a single write operation cannot exceed
+the capabilities of the hardware, so the request is split up into chunks of <codeph>KMyMediaDriverWriteLength</codeph> bytes. </p> <codeblock id="GUID-3C11FDAE-EA06-5B7C-9FC5-DA2C591FFF49" xml:space="preserve">TInt DMyMediaDriver::DoWriteStep()
+    {
+    // Perform a single write step
+
+    TUint8* destAddress = iBaseAddress + iCurrentPos;
+    TInt writeLength = MIN(iCurrentLength, KMyMediaDriverWriteLength);
+        
+    TPtr8 des(iData, writeLength);
+    TInt err = iCurrentReq-&gt;ReadRemote(&amp;des, iCurrentPos - iCurrentReq-&gt;Pos());
+    if (err != KErrNone)
+        {
+        return(err);
+        }
+
+        iCurrentPos += writeLength;
+        iCurrentLength -= writeLength;
+
+        TheHardware::StartWrite(iCurrentPos, writeLength, iData);
+    }
+                </codeblock> <p>The write operation to the hardware is performed
+by <codeph>TheHardware::StartWrite()</codeph>. For most hardware, completion
+is signalled by an interrupt, and the ISR handling the interrupt will queue
+a DFC. This in turn can call a function like <codeph>WriteComplete()</codeph> shown
+below: </p> <codeblock id="GUID-E1F615B2-E148-5C79-8F78-41407C0C2013" xml:space="preserve">TInt DMyMediaDriver::WriteComplete(TInt aResult)
+    {
+    // Called upon completion of the write operation
+    // (ie – in DFC after completion interrupt or polled status completion)
+
+    TBool completeRequest = (iCurrentLength == 0) || (aResult ! = KErrNone);
+        
+    if(!completeRequest)
+        {
+        // There is more data remaining, so write some more data…
+        if((aResult = DoWriteStep()) != KErrNone)
+            {
+            completeRequest = ETrue;
+            }
+        }
+        
+    if(completeRequest)
+        {
+        // We are all done, or an error occurred…
+        DMediaDriver::Complete(iCurrentReq, aResult);
+        iCurrentReq = NULL;
+        }
+    }
+                </codeblock> <p> <codeph>WriteComplete()</codeph> is an example
+of a callback or completion function, and shows how a single request may be
+broken up into a number of smaller chunks. The write request is only completed
+when the entire write operation is complete or an error occurs. </p> <p>This
+simple example has demonstrated how a simple <codeph>EWrite</codeph> request
+may be handled. The <codeph>ERead</codeph> and <codeph>EFormat</codeph> requests
+are handled in exactly the same way, taking into account the message parameters
+shown in the previous table. </p> <p id="GUID-2FF89E43-6F12-5A63-A8A5-298667C5D7A2"><b>Issues about physical addresses</b> </p> <p>If
+the media driver can use physical addresses, you need to be aware of a number
+of issues. </p> <ul>
+<li id="GUID-3CCA7A0E-B245-5221-AA0F-AA9CA1F33869"><p> <i>The address scheme
+used by the hardware</i>  </p> <p>All media devices have a minimum number
+of bytes that they can transfer. For example, the architecture of some memory
+card types requires data transfer in blocks of 512 bytes. To read one byte
+from this type of media device, the media driver must read a block of 512
+bytes and extract the byte from the block. To write one byte to a media device,
+the media driver must read a block of 512 bytes, change the content of the
+byte, and write the block to the media device. </p> </li>
+<li id="GUID-6AA344A1-607A-5220-AE65-70F1A5B35967"><p> <i>Data transfer smaller
+than the minimum size</i>  </p> <p>If the local media subsystem receives a
+request to transfer data with a length smaller than the minimum transfer size,
+the local media subsystem does not make a physical address available to the
+media driver. A call to <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-DD6773B4-9EF5-322F-B53D-29174DF3B3BF"><apiname>TLocDrvRequest::IsPhysicalAddress()</apiname></xref> returns
+false. It is considered unsafe to give access to the physical data surrounding
+the requested memory location. </p> </li>
+<li id="GUID-B5CA6F1A-CCD3-5DA0-9297-547F0E80506A"><p> <i>Data transfer not
+aligned to the media device block boundary</i>  </p> <p>If the local media
+subsystem receives a request to transfer data, and the address on the media
+device is <i>not aligned</i> to the media device block boundary, you need
+to adopt the technique suggested below. The local media subsystem will make
+the physical address available to the media driver. A call to <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-DD6773B4-9EF5-322F-B53D-29174DF3B3BF"><apiname>TLocDrvRequest::IsPhysicalAddress()</apiname></xref> returns
+true. </p> <p>Consider the following case. A request has been made to read
+1024 bytes from a media device that has a block size of 512 bytes. The 1024
+bytes start at offset +256 on the media device. </p> <fig id="GUID-30EA5683-9B12-59D6-88EF-21F4E84988B3">
+<image href="GUID-12CD8E91-4102-5253-A7DE-E5436028764F_d0e18431_href.png" placement="inline"/>
+</fig> <p>To get the first 256 bytes, you must read the first block of 512
+bytes from the media device. This can corrupt the physical memory passed in
+the I/O request. The solution is to read the first block from the media device
+into an intermediate buffer. Copy the 256 bytes from that buffer into the
+physical memory passed in the I/O request. </p> <p>To get the last 256 bytes,
+you must read the third block of 512 bytes from the media device into the
+intermediate buffer. Copy the 256 bytes from that buffer into the correct
+position in the physical memory passed in the I/O request. </p> <p>The middle
+512 bytes are aligned on the media device block boundary. The media driver
+can read this data into the correct position in the physical memory passed
+in the I/O request. </p> </li>
+<li id="GUID-27C1D94D-09CB-5C70-94DF-B1FDC8784DE9"><p> <i>Scatter/Gather DMA
+controllers</i>  </p> <p>DMA controllers can support the Scatter/Gather mode
+of operation. Each request in this mode of operation consists of a set of
+smaller requests chained together. This chain of requests is called the Scatter/Gather
+list. Each item in the list consists of a physical address and a length. </p> <p>Use <xref href="GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C.dita#GUID-D84A9903-AE0F-3F54-8833-E8956A88E26C/GUID-9879145B-D996-327E-87F6-3B8337A86A56"><apiname>TLocDrvRequest::GetNextPhysicalAddress()</apiname></xref> to
+help you populate the Scatter/Gather list. </p> <p>The following code fragment
+shows how you do this. The example assumes that the DMA controller supports
+a Scatter/Gather list with an unlimited number of entries. In practice, the
+number of entries in the list is finite. </p> <codeblock id="GUID-51D14E43-D388-507C-826E-8249EAA83287" xml:space="preserve">TPhysAddr physAddr; 
+   TInt physLength;
+   TInt err = KErrNone;
+
+   while (iRemaining &gt; 0)
+      {
+      err = iCurrentReq-&gt;GetNextPhysicalAddress(physAddr, physLength);
+      if(err != KErrNone)
+         return err;
+
+      iRemaining -= physLength;
+      PopulateScatterGatherList(physAddr, physLength);
+      }                            
+
+   return DoDataTransfer(pos, length);</codeblock> </li>
+</ul> <p>See also <xref href="GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B.dita#GUID-E55B4FE5-517C-5A23-8ACA-E28EE202330B/GUID-575211BC-BF66-5817-9825-EE402648D0CD">Register
+media driver support for physical addresses</xref>  </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-EBF4F1F1-F76B-455B-B8EE-B7965CF0717E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-EBF4F1F1-F76B-455B-B8EE-B7965CF0717E" xml:lang="en"><title>The LDD/PDD
+Model</title><shortdesc>This document describes how device drivers are implemented as logical
+device drivers (LDDs) and physical device drivers (PDDs).</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-4549DF88-EEB0-4CF2-BC93-A234E3ED553F">             <p>Device
+driver DLLs come in two types - the logical device driver (LDD), and the physical
+device driver (PDD). Typically, a single LDD supports functionality common
+to a class of hardware devices, whereas a PDD supports a specific member of
+that class. This means that the generic code in the LDD only needs to be written
+once, and the same user-side API can be used for all variants of a device. </p> <p>Many
+PDDs may be associated with a single LDD. For example, there is a single serial
+communications LDD (<filepath>ECOMM.LDD</filepath>) which is used with all
+UARTs. This LDD provides buffering and flow control functions that are required
+with all types of UART. On a particular hardware platform, this LDD will be
+accompanied by one or more PDDs, which support the different types of UART
+present. A single PDD can support more than one UART of the same type; separate
+PDDs are only required for UARTs with different programming interfaces. Typically,
+the PDD is kept as small as possible. </p> <p>Only LDDs communicate with user-side
+code; PDDs communicate only with the corresponding LDD, with the variant or
+kernel extensions, and with the hardware itself. Device drivers provide their
+interface for user side applications by implementing a class derived from
+the Kernel API <xref href="GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066.dita"><apiname>RBusLogicalChannel</apiname></xref>. The functions of the
+derived class form a thin layer over the functions defined in <codeph>RBusLogicalChannel</codeph> and
+are commonly implemented inline and published in a header file. However, if
+the API functions need to do more complex tasks, then they can be implemented
+in their own DLL. The kernel also provides a API <xref href="GUID-92BAC78E-8ACF-3952-8E77-CCF93ED3BDC9.dita"><apiname>RDevice</apiname></xref>,
+which enables user side code to get information about a device. </p> <p>The
+following diagram shows the general idea: </p><fig id="GUID-CB291406-75EC-572E-8A21-280A5F0A6B9E">
+<title>              Device driver LDD/PDD model            </title>
+<image href="GUID-6EB38F10-849D-5763-96A0-A0A108982D67_d0e63496_href.png" placement="inline"/>
+</fig><p>To make porting to particular hardware platforms easier, some drivers
+make a further logical split in their PDD code between a platform-independent
+layer (PIL), which contains code that is common to all the hardware platforms
+that the driver could be deployed on, and a platform-specific layer (PSL),
+which contains code such as the reading and writing of hardware-specific registers. </p> <p>Depending
+on the device or the type of device to access, this split between LDD and
+PDD may not be necessary; the device driver may simply consist of an LDD alone. </p> 
+   </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,606 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D" xml:lang="en"><title>Publish
+and Subscribe</title><shortdesc>Publish and Subscribe allows global variables to be set and retrieved,
+and allows subscribers to be notified that variables have changed. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The general pattern for using on the kernel side is almost the same as
+for the user side. However, different classes are used on the kernel side.
+It may be useful to compare kernel side usage with user side usage as described
+in the <xref href="GUID-A81C65CF-CF4E-571C-8080-9D387F46AAD6.dita">Publish and
+Subscribe</xref> guide for the user-side API. </p>
+<ul>
+<li id="GUID-BDAE8BFE-B0F9-5A3D-9E2B-6AC6280195E5"><p> <xref href="GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D.dita#GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D/GUID-AD33A76A-9A27-5D66-B583-64F360EC996E">Properties</xref> </p> </li>
+<li id="GUID-3D892E85-C506-5FF6-A8E2-3A9458800CBB"><p> <xref href="GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D.dita#GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D/GUID-E2261227-E747-53E0-9EE3-9CEC824C1832">Creating and closing a reference to a property</xref>  </p> </li>
+<li id="GUID-728CCCEB-8F5F-5CA1-A650-803C94E64194"><p> <xref href="GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D.dita#GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D/GUID-C41886EF-24EC-58C2-A906-C4890CED3F3A">Defining a property</xref>  </p> </li>
+<li id="GUID-FB0EC3DC-38E1-5701-AF84-47A814238163"><p> <xref href="GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D.dita#GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D/GUID-60F19D41-F9B5-5A21-9654-5D96CA6EE83E">Deleting a property</xref>  </p> </li>
+<li id="GUID-FAE51C6E-1C39-593C-B2AD-7BEFAA257F72"><p> <xref href="GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D.dita#GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D/GUID-EBAA6B5C-CC73-5AE2-85CA-68B445828608">Publishing a property value</xref>  </p> </li>
+<li id="GUID-2F1A3E2F-44C8-5532-8FA2-F49A4FC58623"><p> <xref href="GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D.dita#GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D/GUID-CA858A2A-4BF0-565D-8A6D-58AE32FEE304">Retrieving a property value</xref>  </p> </li>
+<li id="GUID-C39FCE8D-082E-56E8-85B2-137B25B88C61"><p> <xref href="GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D.dita#GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D/GUID-984AB90D-FCCD-5383-B5D9-8D80AA83D989">Subscribing to, and unsubscribing from, a property </xref>  </p> </li>
+<li id="GUID-E02C9293-56B4-5AC0-9DA8-F47E6796A07D"><p> <xref href="GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D.dita#GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D/GUID-21D8ADCA-9B39-5079-B4AD-FEBFCCB92049">Usage patterns</xref>  </p> </li>
+</ul>
+<section id="GUID-AD33A76A-9A27-5D66-B583-64F360EC996E"><title>Properties</title> <p>A
+property has the two attributes: identity and type. </p> <p><b>Identity</b> </p> <p>A
+property is identified by a 64-bit integer made up of two 32-bit parts: the
+category and the key. </p> <p>A property belongs to a category, and a category
+is identified by a UID. </p> <p>A key is a 32-bit value that identifies a
+specific property within a category. The meaning applied to the key depends
+on the kind of enumeration scheme set up for the category. At its simplest,
+a key can be an index value. It can also be another UID, if the category is
+designed to be generally extensible. </p> <p><b>Type</b> </p> <p>A property
+can be: </p> <ul>
+<li id="GUID-083AF1CA-ACA1-53A3-A251-370DD1D06554"><p>a single 32-bit value </p> </li>
+<li id="GUID-6EA61CFF-F549-5FA2-A6AA-43683C802B8D"><p>a contiguous set of
+bytes, referred to as a byte-array, whose length can vary from 0 to 512 bytes </p> </li>
+</ul><p>Once defined, a property value can change, but the property type cannot.
+Byte-array type properties can also change length provided the length does
+not exceed the value <xref href="GUID-C4776034-D190-3FC4-AF45-C7F195093AC3.dita#GUID-C4776034-D190-3FC4-AF45-C7F195093AC3/GUID-57E64054-610A-31D1-AD7F-E2F9F9FC1DCB"><apiname>RProperty::KMaxPropertySize</apiname></xref>. The limit
+on size of property ensures some limit on RAM usage. </p><p>The API allows
+a byte-array text type property to be pre-allocated when it is defined. This
+means that the time taken to set the values is bounded. However, if the length
+of this property type subsequently increases, then memory allocation may take
+place, and no guarantees can be made on the time taken to set them.</p><p>Note
+that the <xref href="GUID-C4776034-D190-3FC4-AF45-C7F195093AC3.dita#GUID-C4776034-D190-3FC4-AF45-C7F195093AC3/GUID-F8DE443B-B208-353C-A98E-AA52C4FE6530"><apiname>RProperty::ELargeByteArray</apiname></xref> property type can never
+provide a real-time guarantee. </p><p>For code running kernel side, properties
+and their values are defined, set and retrieved using a <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita"><apiname>RPropertyRef</apiname></xref> object.</p> </section>
+<section id="GUID-E2261227-E747-53E0-9EE3-9CEC824C1832"><title>Creating and
+closing a reference to a property</title> <p>On the kernel side, all accesses
+to a property <i>must</i> be done through a property reference, an instance
+of a <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita"><apiname>RPropertyRef</apiname></xref>. </p> <p>You must create a reference
+to a property, before doing any operation on that property. By operation,
+we mean defining a property, subscribing to a property, publishing and retrieving
+a property value. The kernel will fault if you have not first created a reference. </p> <p>Only
+one property, as uniquely identified by its category and key, can be accessed
+by an instance of <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita"><apiname>RPropertyRef</apiname></xref>; however a property can
+be referenced by more than one instance of <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita"><apiname>RPropertyRef</apiname></xref>. </p> <p>Internally,
+properties are represented by <codeph>TProperty</codeph> objects, and these
+are reference counted. The act of creating a reference to a property results
+either in the creation of a <codeph>TProperty</codeph> object or an increase
+in the reference count of an existing object. The property itself has no attributes
+or "structure" until it is defined. </p> <p>Please note that the structure
+and management of <codeph>TProperty</codeph> objects are part of Symbian platform's
+internal implementation and will not be discussed further. </p> <fig id="GUID-8A0D9C1E-00D7-5369-AD9C-28AA9151612F">
+<title>Objects internal to Symbian platform</title>
+<image href="GUID-31CE66F2-B36C-56ED-A399-BA9EFA179DED_d0e75538_href.png" placement="inline"/>
+</fig> <p>To establish a reference to a property, create an <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita"><apiname>RPropertyRef</apiname></xref> object,
+and then use one of the following functions: </p> <ul>
+<li id="GUID-87D76A73-6429-5D4C-8321-A98F756C30F5"><p> <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-DBEDDC3A-AE6F-3CAF-B251-4AA556EAF21C"><apiname>RPropertyRef::Attach()</apiname></xref> -
+tries to open the property identified by the category and key, if it exists,
+but creates that property if it does not exist. Creation is simply the act
+of creating the internal <codeph>TProperty</codeph> object. The object has
+no type or "structure" associated with it other than the use of the category
+and key as identification markers. </p> </li>
+<li id="GUID-7D1AFF17-BB0A-57B9-9782-001E983D9EDE"><p> <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-6F8EB0AB-C01A-3BFD-B334-D9C9FB923865"><apiname>RPropertyRef::Open()</apiname></xref> -
+tries to open the property identified by the category and key, and assumes
+that the property already exists; this fails if the property does not exist. </p> </li>
+</ul> <p>You can call these functions from a user thread running in supervisor
+mode, from a kernel thread or from a DFC. If calling from a user thread running
+in supervisor mode, then your thread must be running in a critical section.
+In debug mode, if a user thread is not in a critical section, then the kernel
+will fault. </p> <p>On successful return from these functions, the <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita"><apiname>RPropertyRef</apiname></xref> object
+owns a resource, the property, and this can then be defined and accessed through
+the <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita"><apiname>RPropertyRef</apiname></xref> object. </p> <p>It is difficult to make
+firm rules as to which one your code should use, but generally, you use <codeph>Open()</codeph> if
+you have no responsibility or interest in ensuring that the property exists.
+You would use <codeph>Attach()</codeph> if you were to have single or <i>joint</i> responsibility
+for ensuring that the property exists. It depends on the intent of the property
+and the role of your driver code in the system. </p> <p>Note that responsibility
+for creating the property does not necessarily align with who can define,
+delete, publish (write) or retrieve (read) a property value. This is governed
+by the intent of the property and, for retrieving and publishing, by the security
+policies in place. </p> <p>When the property is no longer needed, you can
+release it by calling <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-3465CD78-C107-3AD9-AEAF-F97A94C1C462"><apiname>RPropertyRef::Close()</apiname></xref>. Closing the
+reference does not cause the property to disappear. This only happens when
+the <i>final</i> reference to the property is closed. </p> <p>Note that it
+is quite legitimate to attach to, or to open, a property that has not been
+defined, and in this case no error will be returned either. This enables the
+lazy definition of properties as used in some of the usage patterns. </p> <codeblock id="GUID-7F4295E4-F822-5128-B4EC-3AD3E71BD444" xml:space="preserve">const TUid KMyPropertyCat={0x10012345};
+enum TMyPropertyKeys={EMyPropertyCounter,EMyPropertyName};
+
+. . .
+
+// Attach to the ‘counter’ property. This creates the property
+// if it does not already exist.
+RPropertyRef counter;
+TInt r;
+r=counter.Attach(KMyPropertyCat,EMyPropertyCounter);
+
+// r should be KErrNone if sucessful or KErrNoMemory if there
+// is an out of memory failure.
+if (r != KErrNone)
+    {
+    // Handle the bad return value
+    }
+
+// use the counter object...
+
+// when finished, release the property
+counter.Close();
+    </codeblock> </section>
+<section id="GUID-C41886EF-24EC-58C2-A906-C4890CED3F3A"><title>Defining a
+property </title> <p>Defining a property gives it "structure" i.e. attributes
+such as the property type, and the security policies that define the capabilities
+that a process must have to publish and retrieve the property value. </p> <p>A
+property is defined using the <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-47F367CB-E663-3F97-AC0C-31A9DD6BD5E5"><apiname>RPropertyRef::Define()</apiname></xref> function.
+You can call this function from a user thread running in supervisor mode,
+from a kernel thread or from a DFC. If calling from a user thread running
+in supervisor mode, then your thread must be running in a critical section.
+In debug mode, if a user thread is not in a critical section, then the kernel
+will fault. </p> <p>You can call this function from a user thread running
+in supervisor mode, from a kernel thread or from a DFC. If calling from a
+user thread running in supervisor mode, then your thread must be running in
+a critical section. In debug mode, if a user thread is not in a critical section,
+then the kernel will fault. </p> <p>The information needed to define the property
+is passed to <codeph>Define()</codeph>. Note that a reference to the property
+must already have been established using <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-DBEDDC3A-AE6F-3CAF-B251-4AA556EAF21C"><apiname>RPropertyRef::Attach()</apiname></xref> or <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-6F8EB0AB-C01A-3BFD-B334-D9C9FB923865"><apiname>RPropertyRef::Open()</apiname></xref>. </p> <p>A
+property does not need to be defined before it can be accessed. This supports
+programming patterns where both publishers and subscribers may define the
+property. </p> <p>Once defined, a property persists until the system reboots,
+or the property is explicitly deleted. Its lifetime is not tied to that of
+the thread or process that originally defined it. This means that, when defining
+a property, it is important to check the return code from the call to <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-47F367CB-E663-3F97-AC0C-31A9DD6BD5E5"><apiname>RPropertyRef::Define()</apiname></xref> to
+deal with the possibility that the property has previously been defined. </p> <p>The
+following code shows the definition of two properties, which we call: 'name'
+and 'counter': </p> <codeblock id="GUID-318DC2A6-FFE4-5781-9F78-5D5B4392585F" xml:space="preserve">const TUid KMyPropertyCat={0x10012345};
+enum TMyPropertyKeys={EMyPropertyCounter,EMyPropertyName};
+
+static _LIT_SECURITY_POLICY_PASS(KAllowAllPolicy);
+static _LIT_SECURITY_POLICY_C1(KPowerMgmtPolicy,ECapabilityPowerMgmt);
+
+TInt r;
+
+// Attaches to the ‘counter’ property. 
+// If the property already exists, a new reference to it is created.
+// If the property does not exist, it is created.
+RPropertyRef counter;
+r=counter.Attach(KMyPropertyCat,EMyPropertyCounter);
+if (r != KErrNone)
+    {
+    // Handle the bad return value
+    }
+
+// Attaches to the ‘name’ property. 
+// If the property already exists, a new reference to it is created.
+// If the property does not exist, it is created.
+RPropertyRef name;
+r=name.Attach(KMyPropertyCat,EMyPropertyName);
+if (r != KErrNone)
+    {
+    // Handle the bad return value
+    }
+
+// Now define the 'counter' property:
+// 1. Integer type
+// 2. Pre-allocated size has no meaning, and must be zero.
+// 3. Allow all processes to retrieve (read) the property.
+// 4. Only processes with power managament capability can write.
+// 5. Capability checks to be done against client thread's process.
+
+r=counter.Define(RProperty::EInt,KAllowAllPolicy,KPowerMgmtPolicy,0,iClientProcess);
+
+// You will probably need to check the return value.
+// It may legitimately by non-KErrNone.
+
+...
+
+// Now define the 'name' property:
+// 1. Byte array
+// 2. Pre-allocate 100 bytes.
+// 3. Allow all processes to retrieve (read) the property.
+// 4. Only processes with power managament capability can write.
+// 5. Capability checks to be done against client thread's process.
+
+r=name.Define(RProperty::EByteArray,KAllowAllPolicy,KPowerMgmtPolicy,100,iClientProcess);
+
+// You will probably need to check the return value.
+// It may legitimately be non-KErrNone.
+...</codeblock> <p>Once defined, a property value can change, but the property
+type cannot. Byte-array type properties can also change length provided the
+length does not exceed the 512 bytes, for <xref href="GUID-C4776034-D190-3FC4-AF45-C7F195093AC3.dita#GUID-C4776034-D190-3FC4-AF45-C7F195093AC3/GUID-19066DA4-B407-3C31-8472-371CA341BDC7"><apiname>RProperty::EByteArray</apiname></xref> types
+or 65535 bytes or <xref href="GUID-C4776034-D190-3FC4-AF45-C7F195093AC3.dita#GUID-C4776034-D190-3FC4-AF45-C7F195093AC3/GUID-F8DE443B-B208-353C-A98E-AA52C4FE6530"><apiname>RProperty::ELargeByteArray</apiname></xref> types. </p> <p>The
+API allows byte-array type properties to be pre-allocated when they are defined.
+This means that the time taken to set the values is bounded. However, if the
+length of these property types subsequently increases, then memory allocation
+may take place, and no guarantees can then be made on the time taken to set
+them. </p> <p> <b>Security notes:</b>  </p> <ul>
+<li id="GUID-E46B65DD-5D93-5796-8762-D8637947350D"><p>Symbian platform defines
+a property category known as the system category that is reserved for system
+services, and is identified by the <xref href="GUID-A85740BD-BC85-345E-B24A-92F68EA56270.dita"><apiname>KUidSystemCategoryValue</apiname></xref> UID.
+To define a property within this category, then the process on whose behalf
+your code is doing the define operation must have the <i>writeDeviceData</i> capability, <xref href="GUID-C607209F-6FC5-31DE-8034-E5B799B857A8.dita"><apiname>ECapabilityWriteDeviceData</apiname></xref>. </p> <p>To
+ensure that this security check is made, you must pass a pointer to the appropriate <codeph>DProcess</codeph> object
+as the second parameter to <codeph>Define()</codeph>. If you omit this parameter,
+a null pointer is assumed by default, and <i>the security check is bypassed</i>.
+This may be legitimate if you are doing this on behalf of the kernel or on
+behalf of the driver itself. </p> </li>
+<li id="GUID-18AA5E54-23AE-564F-BCB0-0F9FF70DEFD5"><p>Whether you pass a <codeph>DProcess</codeph> pointer
+or not, the owner of the property is deemed to be the process that is <i>current</i> when
+the code runs. It is this, the current process, that you will need to pass
+to <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-73FB49F1-E9EF-3CE3-A317-8888BAE49403"><apiname>RPropertyRef::Delete()</apiname></xref> at a later time. </p> </li>
+<li id="GUID-A941BD4F-E288-5A71-9F78-08351665AE73"><p>You also need to define
+two security policies: one to define the capabilities that will be required
+to publish (write to) the property, and the other to define the capabilities
+that will be required to retrieve (read) the property. Security policies are <xref href="GUID-81A285F6-3F87-3E77-9426-61BB16BC7109.dita"><apiname>TSecurityPolicy</apiname></xref> objects
+or their static equivalents. </p> <p>In the above code fragment, we specify
+that all processes in the system will be able to read the defined property
+but only those with power management capability will be able to write to the
+property - this is an arbitrary choice and is for illustration only. </p> </li>
+</ul> <p>In the above code fragments, <codeph>iClientProcess</codeph> is a
+pointer to the client thread's owning process object, and assumes that the
+driver code is making the request on behalf of a client, although this may
+not necessarily be so. Typically, if you need to keep this information, you
+could set this up in the logical channel constructor using the following code: </p> <codeblock id="GUID-33D0D5EA-8BB2-57DB-A327-D17A6A5C2D8E" xml:space="preserve">iClientProcess=&amp;Kern::CurrentProcess();</codeblock> <p>The
+constructor code runs in the context of the client user thread. Note that <codeph>DProcess</codeph> is
+internal to Symbian. </p> </section>
+<section id="GUID-60F19D41-F9B5-5A21-9654-5D96CA6EE83E"><title>Deleting a
+property </title> <p>Deleting a property is the opposite of defining it. It
+removes type and security information. It does <i>not</i> remove a reference
+to the property. </p> <p>A property is deleted using the <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-73FB49F1-E9EF-3CE3-A317-8888BAE49403"><apiname>RPropertyRef::Delete()</apiname></xref> function.
+You can call this function from a user thread running in supervisor mode,
+from a kernel thread or from a DFC. If calling from a user thread running
+in supervisor mode, then your thread must be running in a critical section.
+In debug mode, if a user thread is not in a critical section, then the kernel
+will fault. </p> <p>Any outstanding subscriptions for this property complete
+with <xref href="GUID-5E653C17-372C-32E1-A1B2-9E69A9991C40.dita"><apiname>KErrNotFound</apiname></xref>. </p> <p> <b>Security notes:</b>  </p> <ul>
+<li id="GUID-1B901363-70E9-560B-9C56-C63BB6D180C0"><p>Only the owning process
+is allowed to delete the property. This is deemed to be the process that was
+current when the property was defined. However, to enforce this, you <i>must</i> pass
+into <xref href="GUID-331FCC3D-B326-37A1-8AF5-381320224BBE.dita#GUID-331FCC3D-B326-37A1-8AF5-381320224BBE/GUID-2838E746-C917-3FB0-B2BA-464C38B5944B"><apiname>RPropertyref::Delete()</apiname></xref> a pointer to the <codeph>DProcess</codeph> object
+that represents the owning process. If you omit to pass this parameter to <codeph>Delete()</codeph>,
+a null pointer is assumed by default, and <i>the security check is bypassed.</i>.
+This may be legitimate if you are doing this on behalf of the kernel or on
+behalf of the driver itself. </p> </li>
+</ul> <p>For example, extending the code fragment introduced in defining a
+property above: </p> <codeblock id="GUID-25FBD12A-4461-5A92-9961-960DB26FE3F8" xml:space="preserve">const TUid KMyPropertyCat={0x10012345};
+enum TMyPropertyKeys={EMyPropertyCounter,EMyPropertyName};
+
+static _LIT_SECURITY_POLICY_PASS(KAllowAllPolicy);
+static _LIT_SECURITY_POLICY_C1(KPowerMgmtPolicy,ECapabilityPowerMgmt);
+
+TInt r;
+
+// Attaches to the ‘counter’ property. 
+// If the property already exists, a new reference to it is created.
+// If the property does not exist, it is created.
+RPropertyRef counter;
+r=counter.Attach(KMyPropertyCat,EMyPropertyCounter);
+if (r != KErrNone)
+    {
+    // Handle the bad return value
+    }
+
+// Attaches to the ‘name’ property. 
+// If the property already exists, a new reference to it is created.
+// If the property does not exist, it is created.
+RPropertyRef name;
+r=name.Attach(KMyPropertyCat,EMyPropertyName);
+if (r != KErrNone)
+    {
+    // Handle the bad return value
+    }
+
+// Now define the 'counter' property:
+// 1. Integer type
+// 2. Pre-allocated size has no meaning, and must be zero.
+// 3. Allow all processes to retrieve (read) the property.
+// 4. Only processes with power managament capability can write.
+// 5. Capability checks to be done against client thread's process.
+
+r=counter.Define(RProperty::EInt,KAllowAllPolicy,KPowerMgmtPolicy,0,iClientProcess);
+
+// You will probably need to check the return value.
+// It may legitimately by non-KErrNone.
+
+...
+
+// Now define the 'name' property:
+// 1. Byte array
+// 2. Pre-allocate 100 bytes.
+// 3. Allow all processes to retrieve (read) the property.
+// 4. Only processes with power managament capability can write.
+// 5. Capability checks to be done against client thread's process.
+
+r=name.Define(RProperty::EByteArray,KAllowAllPolicy,KPowerMgmtPolicy,100,iClientProcess);
+
+// You will probably need to check the return value.
+// It may legitimately by non-KErrNone.
+
+...
+
+// Delete the ‘name’ property.
+// Assumes that the owning process is iClientProcess. This will be checked
+// as being the valid owner of the property.
+r=name.Delete(iClientProcess);
+if (r != KErrNone)
+    {
+    // deal with a non-KErrNone return value.
+    }
+
+// Delete the ‘counter’ property.
+// Assumes that the owning process is iClientProcess. This will be checked
+// as being the valid owner of the property.
+r=name.Delete(iClientProcess);
+if (r != KErrNone)
+    {
+    // deal with a non-KErrNone return value.
+    }</codeblock> </section>
+<section id="GUID-EBAA6B5C-CC73-5AE2-85CA-68B445828608"><title>Publishing
+a property value </title> <p>A property is published (written), using the <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-D4B0220A-EB30-327C-B878-FBC5294A08F6"><apiname>RPropertyRef::Set()</apiname></xref> family
+of functions. </p> <p>This is guaranteed to have bounded execution time, suitable
+for high-priority, real-time tasks, except when publishing a byte-array property
+that requires the allocation of a larger space for the new value, or when
+publishing a large byte-array property type, as identified by <xref href="GUID-0B4D1D87-8C1B-3AEF-9C3D-3091FBDF3A6B.dita"><apiname>ELargeByteArray</apiname></xref>. </p> <p>Property
+values are written atomically. This means that it is not possible for threads
+reading a property to get a garbled value. </p> <p>All outstanding subscriptions
+for a property are completed when the value is published, even if it is exactly
+the same as the existing value. This means that a property can be used as
+a simple broadcast notification service. </p> <p>Publishing a property that
+is not defined is not necessarily a programming error. The <codeph>Set()</codeph> functions
+just return an error. If this is not expected for any particular usage, then
+the error must be checked and processed by the caller. </p> <p> <b>Security
+notes:</b>  </p> <ul>
+<li id="GUID-DA84723A-B9F7-525C-908A-BC51AA8B0366"><p>If you pass a pointer
+to a <codeph>DProcess</codeph> object, then the capabilities of that process
+will be checked against those contained in the write security policy that
+was created and passed to <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-47F367CB-E663-3F97-AC0C-31A9DD6BD5E5"><apiname>RPropertyRef::Define()</apiname></xref>. If you
+omit this <codeph>DProcess</codeph> parameter, a null pointer is assumed by
+default, and <i>the security check is bypassed</i>. This may be legitimate
+if you are doing this on behalf of the kernel or on behalf of the driver itself. </p> </li>
+</ul> <p>See the code fragment in the section <xref href="GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D.dita#GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D/GUID-CA858A2A-4BF0-565D-8A6D-58AE32FEE304">Retrieving
+a property value</xref>  </p> </section>
+<section id="GUID-CA858A2A-4BF0-565D-8A6D-58AE32FEE304"><title>Retrieving
+a property value </title> <p>The current value of a property is retrieved
+(read) using the <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-745E29E7-A26B-3207-ACA3-F8CC41FC7081"><apiname>RPropertyRef::Get()</apiname></xref> family of functions. </p> <p>This
+is guaranteed to have bounded execution time, suitable for high-priority,
+real-time tasks, except when retrieving a large byte-array property type,
+as identified by <xref href="GUID-0B4D1D87-8C1B-3AEF-9C3D-3091FBDF3A6B.dita"><apiname>ELargeByteArray</apiname></xref>. </p> <p>Property values
+are read atomically. This means that it is not possible for threads reading
+a property to get a garbled value. </p> <p>Retrieving a property that is not
+defined is not necessarily a programming error. The <codeph>Get()</codeph> functions
+just return an error. If this is not expected for any particular usage, then
+the error must be checked and processed by the caller. </p> <p>Integer properties
+must be accessed using the overload that takes an integer reference, whereas
+a byte-array property is accessed using the overload that takes a descriptor
+reference. </p> <p>The following code fragment shows publication and retrieval
+of a property. Note that it contains a race condition, especially if another
+thread is executing the same sequence to increment the ‘counter’ value. </p> <p> <b>Security
+notes:</b>  </p> <ul>
+<li id="GUID-B117308F-416E-5BAE-880C-A162869799AD"><p>If you pass a pointer
+to a <codeph>DProcess</codeph> object, then the capabilities of that process
+will be checked against those contained in the read security policy that was
+created and passed to <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-47F367CB-E663-3F97-AC0C-31A9DD6BD5E5"><apiname>RPropertyRef::Define()</apiname></xref>. If you omit
+this <codeph>DProcess</codeph> parameter, a null pointer is assumed by default,
+and <i>the security check is bypassed</i>. This may be legitimate if you are
+doing this on behalf of the kernel or on behalf of the driver itself. </p> </li>
+</ul> <codeblock id="GUID-75549D12-A2CA-5039-BB91-2ABF19058DE5" xml:space="preserve">const TUid KMyPropertyCat={0x10012345};
+enum TMyPropertyKeys={EMyPropertyCounter,EMyPropertyName};
+
+TInt r;
+
+RPropertyRef counter;
+RPropertyRef name;
+
+
+// Assume that the 'name' and 'counter' property references have
+// already been created. They may have been defined.
+//
+// Assume that the process to be used for security checking is iClientProcess.
+
+...
+
+// publish a new name value. 
+_LIT8(KSomeExampleName,"My example name");
+r=name.Set(KSomeExampleName, iClientProcess);
+if (r != KErrNone)
+    {
+    // Check the return value. KErrNotFound means that the property has not yet been    
+    // defined which may be legitimate.
+    // KErrArgument is a serious problem at this stage.
+    // KErrPermissionDenied is a security violation; the process iClientProcess has 
+    // insufficient capability to do this operation. 
+    }
+
+
+// Retrieve the first 10 characters of the name value.
+// We are not doing any security checking for this operation, so no DProcess pointer 
+// is passed to Get(). 
+TBuf&lt;10&gt; n;
+r=name.Get(n);
+
+if ((r!= KErrNone) &amp;&amp; (r != KErrOverflow))
+    {
+    // Handle error value.
+    }
+
+// retrieve and publish a new value using the attached ‘counter’ property
+TInt count;
+r=counter.Get(count);
+if (r==KErrNone)
+    {
+    r=counter.Set(++count);
+    }
+else
+    {
+    // Handle bad return value
+    }
+...
+
+// When finised, release the property references.
+counter.Close();
+name.Close();</codeblock> </section>
+<section id="GUID-984AB90D-FCCD-5383-B5D9-8D80AA83D989"><title>Subscribing
+to, and unsubscribing from, a property </title> <p>Subscribing to a property
+is the act of making an asynchronous request to be notified of a change to
+that property. </p> <p>You make a request for notification of a change to
+a property by calling the <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-6DC06192-78AF-3B3D-8077-8479789AF006"><apiname>RPropertyRef::Subscribe()</apiname></xref> member
+function on a property reference object. Only one subscription request can
+be outstanding at any time for a given <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita"><apiname>RPropertyRef</apiname></xref> instance. </p> <p>You
+can cancel an outstanding subscription request by calling <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-4AFB3074-E523-3404-8F0D-39995C35E045"><apiname>RPropertyRef::Cancel()</apiname></xref>.
+This is unsubscribing from the property. </p> <p>Subscribing to a property
+is a single request to be notified when the property is next updated, it does
+not generate an ongoing sequence of notifications for every change to that
+property's value. Neither does it provide the caller with the new value. In
+essence, the act of notification should be interpreted as “Property X has
+changed” rather than “Property X has changed to Y”. This means that the new
+value must be explicitly retrieved, if required. As a result, multiple updates
+may be collapsed into one notification, and subscribers may not have visibility
+of all intermediate values. </p> <p>This might appear to introduce a window
+of opportunity for a subscriber to be out of synchronisation with the property
+value – in particular, if the property is updated again before the subscriber
+thread has had the chance to process the original notification. However, a
+simple programming pattern, outlined in the second example below ensures this
+does not happen. The principle is that, before dealing with a subscription
+completion event, you should re-issue the subscription request. </p> <p>Note
+that if the property has not been defined, then a subscription request does
+not complete until the property is subsequently defined and published. Note
+that the request will complete with <xref href="GUID-213DE05E-24F7-3E94-9B35-F4A72B3EBFD8.dita"><apiname>KErrPermissionDenied</apiname></xref> if
+the subscribing process does not have sufficient capability as defined by
+the <xref href="GUID-81A285F6-3F87-3E77-9426-61BB16BC7109.dita"><apiname>TSecurityPolicy</apiname></xref> object supplied by the process defining
+the property. </p> <p>If the property is already defined, then the request
+completes immediately with <xref href="GUID-213DE05E-24F7-3E94-9B35-F4A72B3EBFD8.dita"><apiname>KErrPermissionDenied</apiname></xref> if the
+subscribing process does not have sufficient capability. </p> <p>The essence
+of subscribing to a property is that you pass a function into <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-6DC06192-78AF-3B3D-8077-8479789AF006"><apiname>RPropertyRef::Subscribe()</apiname></xref> and
+that this function is called when the property value is published. You pass
+the function by wrapping it in <xref href="GUID-8A0F75CD-DC61-37EA-A23A-3A82080F0751.dita"><apiname>TPropertySubsRequest</apiname></xref> object
+and then pass this into <codeph>Subscribe()</codeph>. What the function does
+depends on the implementation, but you may want to re-subscribe to the property
+and then retrieve the property value, or you may want to set some flag. It
+all depends on the intent of the property and the driver code. </p> <p>The
+following code fragments show the general idea. </p> <codeblock id="GUID-DF8201DF-7812-5B39-8B0F-3CB664BA00FA" xml:space="preserve">const TUid KMyPropertyCat={0x10012345};
+enum TMyPropertyKeys={EMyPropertyCounter,EMyPropertyName};</codeblock> <codeblock id="GUID-2162EE7C-B834-50ED-9C84-3CE004C0B7D6" xml:space="preserve">class DMyLogicalChannel : public DLogicalChannel
+    {
+    public :
+        DMyLogicalChannel();
+        void OpenReference();
+        void SetUpSubscription();
+        ...
+    private :
+        static void HandleSubsComplete(TAny* aPtr, TInt aReason);
+        ...
+    private:
+        RCounterRef iName;
+        TBuf&lt;10&gt;    iNameValue;
+        DProcess    iClientProcess;
+        TPropertySubsRequest iSubsRequest;
+        TInt iReason;
+    }</codeblock> <codeblock id="GUID-4A655D83-07CD-5998-A540-16D4A5EABFC5" xml:space="preserve">DMyLogicalChannel::DMyLogicalChannel() : iSubsRequest(&amp;HandleSubsComplete, this)
+    {
+    iClientProcess = &amp;Kern::CurrentProcess();
+    // Other code omitted 
+    }</codeblock> <codeblock id="GUID-DB6F4AF7-8866-50C5-95FD-5BCA1F2B55CE" xml:space="preserve">void DMyLogicalChannel::OpenReference()
+    {
+    // Open a reference to the ‘name’ property, and assume that
+    // the property has already been created and defined.
+  
+    TInt r
+    ...
+    r=iName.Open(KMyPropertyCat,EMyPropertyName);
+    if (r != KErrNone)
+        {
+        // Handle bad return value.
+        }
+    ...
+    }</codeblock> <codeblock id="GUID-217CFAF4-2CA6-588B-B3A2-667EB9A04FCA" xml:space="preserve">void DMyLogicalChannel::SetUpSubscription()
+    {
+    // Now ask to be notified when the 'name' property is updated.
+    // This will eventually result in a call to the function HandleSubsComplete()
+    // at some later time (asynchronously).
+    // When eventually called, the pointer to this DMyLogicalChannel object will
+    // be passed to HandleSubsComplete().
+    //
+    ...
+    iReason = KRequestPending;
+    TInt r = iName.Subscribe(iSubsRequest); // ignoring security issues here.
+    if (r != KErrNone)
+        {
+        // handle bad return code.
+        }
+    return;
+    }</codeblock> <codeblock id="GUID-C2CD229F-F6CE-5EE3-9EBA-A69CED50FA07" xml:space="preserve">void DMyLogicalChannel::CancelSubscription()
+    {
+    if (iReason == KRequestPending)
+        {
+        iName.Cancel(iSubsRequest);
+        }
+    }</codeblock> <codeblock id="GUID-D5E046B5-4D56-5B82-B4B8-D943DC601338" xml:space="preserve">void DMyLogicaChannel::SubsCompleteFn(TAny* aPtr, TInt aReason)
+    {
+    // A static function called when a change to the property occurs.
+    // aPtr will point to the DMyLogicalChannel object 
+    // (see the DMyLogicalChannel constructor)
+    // aReason is the reason for the subscription completing. This may be:
+    //     KErrNone - for a normal completion.
+    //     KErrPermissionDenied - if the security check has failed.
+    //     KErrCancel - if the request was cancelled.
+    // For a normal completion, setup another notification request before
+    // getting the current value of the property.
+    //
+    DMyLogicaChannel* self = (DMyLogicaChannel*) aPtr;
+       self-&gt;iReason = aReason;
+    if (iReason == KErrNone)
+        {
+        self-&gt;SetUpSubscription();
+        self-&gt;Get(iNameValue,iClientProcess);
+        return;
+        }
+    // Investigate the non-zero reason code.
+    }</codeblock> </section>
+<section id="GUID-21D8ADCA-9B39-5079-B4AD-FEBFCCB92049"><title>Usage patterns</title> <p>There
+are three usage patterns that can easily be identified, labelled as: standard
+state, pure event distribution, and speculative publishing. </p> <p id="GUID-98103A8A-10E1-58FE-9613-A616E142AA2A"><b>Standard state</b> </p> <p>This
+pattern is used for events and state that are known to be used widely in the
+system. Examples of this might be battery level and signal strength, which
+are important in every phone. </p> <p>The publisher calls <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-47F367CB-E663-3F97-AC0C-31A9DD6BD5E5"><apiname>RPropertyRef::Define()</apiname></xref> to
+create the appropriate property. For byte array or text properties, a size
+sufficient for all possible values should be reserved. An error of <xref href="GUID-D1D25122-F2B8-3C78-8599-84905BFD47B8.dita"><apiname>KErrAlreadyExists</apiname></xref> should
+be ignored. The publisher then publishes the property values as, and when,
+appropriate. If the <codeph>RPropertyRef::Set()</codeph> call fails, this
+should be treated as a serious error, since it indicates that important system
+state is not getting through. Appropriate action might include panicking or
+rebooting the system. Subscribers will use <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-6DC06192-78AF-3B3D-8077-8479789AF006"><apiname>RPropertyRef::Subscribe()</apiname></xref> to
+request notification, and <codeph>RPropertyRef::Get()</codeph> to retrieve
+the property value on notification. </p> <p>The memory to store the property
+value will be permanently allocated, even if it turns out that no-one in the
+system needs that value. This does ensure that the value can always be published,
+even if the system is in an out of memory situation. For this reason, this
+approach should be limited to widely used and important state. The <xref href="GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D.dita#GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D/GUID-8D9E6222-DDBA-55CA-A96F-1DCBD99E3FD3">Speculative publishing</xref> pattern offers an approach for dealing with
+less important state. </p> <p id="GUID-5C82A92C-168D-5CD2-BE43-EE79AB500B14"><b>Pure event distribution</b> </p> <p>This
+pattern is used when events need to be distributed, not values. </p> <p>The
+publisher of the event simply uses an integer property, and calls <codeph>RPropertyRef::Set()</codeph> with
+any value. Even if the value of the property is not changed by this operation,
+all subscribers will be notified that a <codeph>Set()</codeph> has occurred,
+and by implication that the related event has occurred. </p> <p>Subscribers
+will be able to detect that an event has occurred, but will get no other information.
+The minimum possible memory is wasted on storage for the dummy value. </p> <p id="GUID-8D9E6222-DDBA-55CA-A96F-1DCBD99E3FD3"><b>Speculative publishing</b> </p> <p>This
+pattern is used when it is not known whether a value will be of interest to
+others or not. Unlike the <xref href="GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D.dita#GUID-EBFD653D-6E6A-5F6F-88D7-8CCE07B4002D/GUID-98103A8A-10E1-58FE-9613-A616E142AA2A">standard
+state</xref> pattern, the publisher of the event does not call <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-47F367CB-E663-3F97-AC0C-31A9DD6BD5E5"><apiname>RPropertyRef::Define()</apiname></xref> to
+create the property. Instead, it simply calls <codeph>RPropertyRef::Set()</codeph> as
+appropriate, and ignores any <xref href="GUID-5E653C17-372C-32E1-A1B2-9E69A9991C40.dita"><apiname>KErrNotFound</apiname></xref> error. </p> <p>When
+other code in the system, i.e. a potential subscriber, is interested in the
+state, it calls <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-47F367CB-E663-3F97-AC0C-31A9DD6BD5E5"><apiname>RPropertyRef::Define()</apiname></xref> to create the property
+and allocate the memory for the value. An error of <xref href="GUID-D1D25122-F2B8-3C78-8599-84905BFD47B8.dita"><apiname>KErrAlreadyExists</apiname></xref> should
+be ignored, as this only indicates that some other code in the system is also
+interested in the value and has already created the property. </p> <p>The
+subscriber then calls <xref href="GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2.dita#GUID-39D6B924-3FA3-39E6-A6EA-88E2D1927AC2/GUID-6DC06192-78AF-3B3D-8077-8479789AF006"><apiname>RPropertyRef::Subscribe()</apiname></xref> and <codeph>RPropertyRef::Get()</codeph> as
+usual to interact with the property. On the first <codeph>Get()</codeph>,
+the subscriber may retrieve the property default value (zero, or a zero length
+descriptor). This must be substituted with a sensible default value for the
+property in question. </p> <p>Using this pattern, no memory is wasted on properties
+that have no subscribers, while the publisher code is simpler as there is
+no need for configuration as to which properties to publish. </p> <p>The publisher,
+however, wastes some time attempting to publish unneeded values, but this
+should not be an issue unless the value is very frequently updated. </p> <p>Where
+events are published very infrequently, the subscriber could have a dummy
+value for a long time, until the next publish event updates the value. Often
+this is not a problem as a default value can be substituted. For example a
+full/empty indicator for a battery level, none for signal strength etc. This
+pattern is unlikely to be useful if there is no suitable default value. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,172 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1" xml:lang="en"><title>Remapping
+Cache Attributes and Access Permissions on ARMv6K and ARMv7 Platforms</title><shortdesc>Describes the behavior change brought about by remapping the cache
+attributes and the access permissions on the ARMv6K (ARM1176 &amp; ARM11MPCore),
+ARMv7 (Cortex-8N), and future platforms.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<ul>
+<li id="GUID-50632F8E-91A0-597C-8176-9FE352A8B9ED-GENID-1-2-1-8-1-1-5-1-1-20-1-3-1-1"><p> <xref href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1.dita#GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1/GUID-B8EA1997-C922-5E98-A32E-A77D641D11BC-GENID-1-2-1-8-1-1-5-1-1-20-1-3-2">Reduced set access permissions</xref>  </p> <ul>
+<li id="GUID-9225B023-192F-5D04-92BA-0278768872FF-GENID-1-2-1-8-1-1-5-1-1-20-1-3-1-1-2-1"><p> <xref href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1.dita#GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1/GUID-ABBF3854-B8B8-52A0-B3F6-1DF44A37194A-GENID-1-2-1-8-1-1-5-1-1-20-1-3-2-3">Affected kernel interface</xref>  </p> </li>
+</ul> </li>
+<li id="GUID-9851FDDF-8F0E-5AF1-AF7F-9C6273E9B0A8-GENID-1-2-1-8-1-1-5-1-1-20-1-3-1-2"><p> <xref href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1.dita#GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1/GUID-E137E4E9-AADA-5BCE-8FC8-504ACD486394-GENID-1-2-1-8-1-1-5-1-1-20-1-3-3">Remapping cache attributes</xref>  </p> <ul>
+<li id="GUID-6B59981E-754F-5E9B-80F1-99D53D464B70-GENID-1-2-1-8-1-1-5-1-1-20-1-3-1-2-2-1"><p> <xref href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1.dita#GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1/GUID-EDFD1FE0-ACD7-54B4-9633-0149E3FDF551-GENID-1-2-1-8-1-1-5-1-1-20-1-3-3-6">Types of memory supported</xref>  </p> </li>
+<li id="GUID-057483C0-F40F-503D-82D7-B2CC199AC9F9-GENID-1-2-1-8-1-1-5-1-1-20-1-3-1-2-2-2"><p> <xref href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1.dita#GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1/GUID-548E9689-F7AB-5F61-A8AE-EA2043E70D34-GENID-1-2-1-8-1-1-5-1-1-20-1-3-3-11">Mapping existing memory types</xref>  </p> </li>
+<li id="GUID-4D7899BC-B6AD-5C9F-9135-7E37F2CFC21E-GENID-1-2-1-8-1-1-5-1-1-20-1-3-1-2-2-3"><p> <xref href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1.dita#GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-8-1-1-5-1-1-20-1/GUID-F90E6B00-6492-5471-975F-3C078046627A-GENID-1-2-1-8-1-1-5-1-1-20-1-3-3-14">Mapping ARMv6K or ARMv7 onto TMappingAttributes</xref>. </p> </li>
+</ul> </li>
+</ul>
+<section id="GUID-B8EA1997-C922-5E98-A32E-A77D641D11BC-GENID-1-2-1-8-1-1-5-1-1-20-1-3-2"><title>Reduced set
+access permissions</title> <p>The ARMv6-style page table reserves three bits
+in the page/directory table for access permission, so eight possible values
+are available. The use of four possible access permissions is sufficient.
+Therefore, removing the surplus access permissions frees up one page table
+bit that is used by Symbian platform internally. </p> <p id="GUID-ABBF3854-B8B8-52A0-B3F6-1DF44A37194A-GENID-1-2-1-8-1-1-5-1-1-20-1-3-2-3"><b>Affected kernel interface</b> </p> <p>The
+shadow pages kernel interface is valid on all platforms except for the emulator.
+On ARMv6 and previous platforms, shadow pages are created using access permission <codeph>PrivilegedRW/UserRO</codeph>,
+this is not supported by the limited set of encoding. Shadow pages are now
+mapped as <codeph>PrivilegedRO/UserRO</codeph>, instead. </p> <codeblock id="GUID-9197EF7D-F549-5144-A322-4C04CD80CFCC-GENID-1-2-1-8-1-1-5-1-1-20-1-3-2-5" xml:space="preserve">class Epoc
+    {
+public:
+    ...
+    IMPORT_C static TInt AllocShadowPage(TLinAddr aRomAddr);
+    IMPORT_C static TInt FreeShadowPage(TLinAddr aRomAddr);
+    IMPORT_C static TInt FreezeShadowPage(TLinAddr aRomAddr);
+    ...
+    };</codeblock> <p>This represents a serious behaviour break in the kernel
+interface. A device driver (running on ARMv7) that creates a shadow page and
+then attempts to alter the content of the page now panics. </p> <p>This is
+a common use case for run-mode debuggers. However, a debugging interface is
+already provided, see <xref href="GUID-E91A8060-77E3-35F0-A945-7081406C79CE.dita"><apiname>DebugSupport</apiname></xref> in <filepath>...\memmodel\epoc\platform.h</filepath>,
+where breakpoints are managed internally by the kernel. Therefore, it is believed
+that a run-time debugger that uses the <codeph>CodeModifier</codeph> implementation
+in the kernel should not be affected by this change. </p> <p>After a shadow
+page is created using <xref href="GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680.dita#GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680/GUID-4FA10D18-3BA2-3307-B2E1-77C9CD8D2B6B"><apiname>Epoc::AllocShadowPage()</apiname></xref>, the kernel
+allows the device driver to alter its content using <xref href="GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680.dita#GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680/GUID-5B889008-BC18-3127-89EF-B8EAB0834190"><apiname>Epoc::CopyToShadowMemory()</apiname></xref>. </p> <p><note> <xref href="GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680.dita#GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680/GUID-EF014DA2-EE35-3DBD-A325-C5648AD27C36"><apiname>Epoc::FreezeShadowPage()</apiname></xref> is obsolete for platforms that use the reduced set of access permissions,
+as the shadow memory is always in a “frozen” state, because it can only be
+changed through the kernel interface.</note> </p> </section>
+<section id="GUID-E137E4E9-AADA-5BCE-8FC8-504ACD486394-GENID-1-2-1-8-1-1-5-1-1-20-1-3-3"><title>Remapping cache
+attributes </title> <p>ARMv6 architecture uses a large number of bits in the
+page table to describe all of the options for inner and outer cachability.
+No applications use all of these options simultaneously so a smaller number
+of configurable options has been implemented to meet the needs of the system. </p> <p>This
+alternative cache mapping allows up to eight different mappings in page tables.
+The Symbian platform kernel and device drivers do not need more
+than four or five different cache mappings. </p> <p>Cache mapping cannot be
+altered during run-time. It must be configured before the MMU is initialised. </p> <p>See
+the Bootstrap <xref href="GUID-5EB03086-A87D-5588-8927-7A7F8DB38366.dita">Port
+Implementation Tutorial</xref>. </p> <p id="GUID-EDFD1FE0-ACD7-54B4-9633-0149E3FDF551-GENID-1-2-1-8-1-1-5-1-1-20-1-3-3-6"><b>Types of memory supported</b> </p> <p>The
+kernel supports the following types of memory: </p> <table id="GUID-23FAD8A6-579B-5E3D-A705-A53BA304D529-GENID-1-2-1-8-1-1-5-1-1-20-1-3-3-8">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Memory type</b>  </p> </entry>
+<entry><p> <b>Description</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttStronglyOrdered</codeph>  </p> </entry>
+<entry><p>Writes are not combined. The order of memory accesses is preserved.
+Serves as a memory barrier, which means: </p> <ul>
+<li id="GUID-800FC168-69E5-5A89-B5A4-F34AF25E7F9E-GENID-1-2-1-8-1-1-5-1-1-20-1-3-3-8-1-3-2-2-2-1"><p>previous accesses to
+any type of memory must complete before accesses to strongly ordered memory
+start </p> </li>
+<li id="GUID-75C9FA7F-3BCC-50FE-B053-A48DEF46A2D2-GENID-1-2-1-8-1-1-5-1-1-20-1-3-3-8-1-3-2-2-2-2"><p>accesses to strongly
+ordered memory must complete before any further access to any type of memory
+takes place. </p> </li>
+</ul> <p>This type is used for hardware mapping. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttDevice</codeph>  </p> </entry>
+<entry><p>Writes are not combined. The order of memory accesses is preserved.
+This type is used for hardware mapping. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttNormalUncached</codeph>  </p> </entry>
+<entry><p>Non cacheable memory: The order of accesses is not preserved. Writes
+may be combined. For example, this is used for video memory. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttNormalCached</codeph>  </p> </entry>
+<entry><p>Write-back read/write allocate cached memory, inner and outer. Used
+for “ordinary” memory. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p> <note> Device memory and normal memory can be set as shared or
+non-shared, strongly ordered accesses are assumed to be shared. </note></p> <p>The
+complete set of memory types supported by Symbian platform are represented
+by the values of the <xref href="GUID-7CB34E6F-CBF7-3F04-8CB1-2D6C29C73992.dita"><apiname>TMemoryType</apiname></xref> enum. </p> <p id="GUID-548E9689-F7AB-5F61-A8AE-EA2043E70D34-GENID-1-2-1-8-1-1-5-1-1-20-1-3-3-11"><b>Mapping existing memory
+types</b> </p> <p>The <xref href="GUID-1CE7A793-6313-372C-AC1A-6D3F6C6F5042.dita"><apiname>TMappingAttributes</apiname></xref> constants allow
+the cache attributes to be manipulated. On remapped platforms, these map into <xref href="GUID-7CB34E6F-CBF7-3F04-8CB1-2D6C29C73992.dita"><apiname>TMemoryType</apiname></xref> as
+follows: </p> <table id="GUID-24B0E1CD-67D9-5FAD-8984-9E202975F7EA-GENID-1-2-1-8-1-1-5-1-1-20-1-3-3-13">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b> Memory type described by TMappingAttributes</b>  </p> </entry>
+<entry><p> <b>Memory type</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-27DA5FEE-8F76-3D9E-8726-FA5CB808680A.dita"><apiname>EMapAttrFullyBlocking</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-F6F245E9-9DB7-3BEF-8F58-9A7F8E0F5D59.dita"><apiname>EMemAttStronglyOrdered</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B8ACFB0F-B457-358F-96EF-94BFBA6FE4A5.dita"><apiname>EMapAttrBufferedNC</apiname></xref>  </p> <p> <xref href="GUID-468C3800-7AEE-3219-9EBB-9C52971B3E0E.dita"><apiname>EMapAttrBufferedC</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-922F4FB9-57C0-31BF-ADFB-CC6B8376A39B.dita"><apiname>EMemAttDevice</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-AE44E6A7-5CD2-31D9-A701-188B26CDEBB0.dita"><apiname>EMapAttrL1Uncached</apiname></xref>  </p> <p> <xref href="GUID-5ADA8BB4-A7B9-3347-B9A8-B50BE92F66BC.dita"><apiname>EMapAttrCachedWTRA</apiname></xref>  </p> <p> <xref href="GUID-54A8E3DA-996D-3317-A129-9AD12201E3C1.dita"><apiname>EMapAttrCachedWTWA</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-FD4404AF-192C-3D20-A4BC-AE1181A14E43.dita"><apiname> EMemAttNormalUncached</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-FA3DD609-9C88-38C9-8719-4AB28B8E84EA.dita"><apiname>EMapAttrCachedWBRA</apiname></xref>  </p> <p> <xref href="GUID-9B211A60-6B45-31D5-A096-2B7944E651A0.dita"><apiname>EMapAttrCachedWBWA</apiname></xref>  </p> <p> <xref href="GUID-BB620F1F-FD18-3FCB-B1FC-7C3555F471B6.dita"><apiname>EMapAttrL1CachedMax</apiname></xref>  </p> <p> <xref href="GUID-72222BDB-E369-3D03-B3EE-A04B125EB2A3.dita"><apiname>EmapAttrCachedMax</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-2191E3C7-5F22-38D1-BB16-BD78B44AE7AA.dita"><apiname>EMemAttNormalCached</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A647726F-5569-3EAA-9E24-70FBEAF6F94B.dita"><apiname>EMapAttrAltCacheWTRA</apiname></xref>  </p> <p> <xref href="GUID-23C6459E-65F4-317E-B22D-6AB91A2F3462.dita"><apiname>EMapAttrAltCacheWTWA</apiname></xref>  </p> <p> <xref href="GUID-4F97DE5E-3031-3AB5-9646-996DD1EB9C15.dita"><apiname>EMapAttrAltCacheWBRA</apiname></xref>  </p> <p> <xref href="GUID-D34AE0F7-21A3-3B8C-B768-1A7840257780.dita"><apiname>EMapAttrAltCacheWBWA</apiname></xref>  </p> </entry>
+<entry><p>Return error </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-1E6DD28F-F53C-34F0-B5A1-88263389ACF7.dita"><apiname>EMapAttrL2CachedWTRA</apiname></xref>  </p> <p> <xref href="GUID-1695C568-36F8-3860-8253-D25CC6F2100E.dita"><apiname>EMapAttrL2CachedWTWA</apiname></xref>  </p> <p> <xref href="GUID-E82A15FB-6A92-388F-A6F2-AA0DBAC720E8.dita"><apiname>EMapAttrL2CachedWBRA</apiname></xref>  </p> <p> <xref href="GUID-CAD3DE19-9508-319E-9C61-1E7910D30AC9.dita"><apiname>EMapAttrL2CachedWBWA</apiname></xref>  </p> <p> <xref href="GUID-CE3B3839-E9B5-3B8F-AB41-3F589CD3347C.dita"><apiname>EMapAttrL2CachedMax</apiname></xref>  </p> </entry>
+<entry><p>Takes no effect. Only the inner cache description matters. </p> <p>This
+policy is already in place on ARMv5 platforms with L210, where the page table
+does not support a separate description of the inner and outer cache attributes. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-F90E6B00-6492-5471-975F-3C078046627A-GENID-1-2-1-8-1-1-5-1-1-20-1-3-3-14"><b> Mapping ARMv6K or ARMv7
+onto TMappingAttributes</b> </p> <p>To describe memory on ARMv6K or ARMv7
+using the original <xref href="GUID-1CE7A793-6313-372C-AC1A-6D3F6C6F5042.dita"><apiname>TMappingAttributes</apiname></xref> bit mask, the device
+driver should use the following values: </p> <table id="GUID-C5D9F8B3-670A-5595-BE7A-288E34E077ED-GENID-1-2-1-8-1-1-5-1-1-20-1-3-3-16">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>ARMv6K/v7 memory type TMemoryType</b>  </p> </entry>
+<entry><p> <b>TMappingAttributes mask to use</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttStronglyOrdered</codeph>  </p> </entry>
+<entry><p> <codeph>EMapAttrFullyBlocking</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttDevice</codeph>  </p> </entry>
+<entry><p> <codeph>EMapAttrBufferedNC</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttNormalUncached</codeph>  </p> </entry>
+<entry><p> <codeph>EMapAttrL1Uncached</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttNormalCached</codeph>  </p> </entry>
+<entry><p> <codeph>EmapAttrCachedMax</codeph>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-9-1-8-1-16-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,172 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-9-1-8-1-16-1" xml:lang="en"><title>Remapping
+Cache Attributes and Access Permissions on ARMv6K and ARMv7 Platforms</title><shortdesc>Describes the behavior change brought about by remapping the cache
+attributes and the access permissions on the ARMv6K (ARM1176 &amp; ARM11MPCore),
+ARMv7 (Cortex-8N), and future platforms.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<ul>
+<li id="GUID-50632F8E-91A0-597C-8176-9FE352A8B9ED-GENID-1-2-1-9-1-8-1-16-1-3-1-1"><p> <xref href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-9-1-8-1-16-1.dita#GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-9-1-8-1-16-1/GUID-B8EA1997-C922-5E98-A32E-A77D641D11BC-GENID-1-2-1-9-1-8-1-16-1-3-2">Reduced set access permissions</xref>  </p> <ul>
+<li id="GUID-9225B023-192F-5D04-92BA-0278768872FF-GENID-1-2-1-9-1-8-1-16-1-3-1-1-2-1"><p> <xref href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-9-1-8-1-16-1.dita#GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-9-1-8-1-16-1/GUID-ABBF3854-B8B8-52A0-B3F6-1DF44A37194A-GENID-1-2-1-9-1-8-1-16-1-3-2-3">Affected kernel interface</xref>  </p> </li>
+</ul> </li>
+<li id="GUID-9851FDDF-8F0E-5AF1-AF7F-9C6273E9B0A8-GENID-1-2-1-9-1-8-1-16-1-3-1-2"><p> <xref href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-9-1-8-1-16-1.dita#GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-9-1-8-1-16-1/GUID-E137E4E9-AADA-5BCE-8FC8-504ACD486394-GENID-1-2-1-9-1-8-1-16-1-3-3">Remapping cache attributes</xref>  </p> <ul>
+<li id="GUID-6B59981E-754F-5E9B-80F1-99D53D464B70-GENID-1-2-1-9-1-8-1-16-1-3-1-2-2-1"><p> <xref href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-9-1-8-1-16-1.dita#GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-9-1-8-1-16-1/GUID-EDFD1FE0-ACD7-54B4-9633-0149E3FDF551-GENID-1-2-1-9-1-8-1-16-1-3-3-6">Types of memory supported</xref>  </p> </li>
+<li id="GUID-057483C0-F40F-503D-82D7-B2CC199AC9F9-GENID-1-2-1-9-1-8-1-16-1-3-1-2-2-2"><p> <xref href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-9-1-8-1-16-1.dita#GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-9-1-8-1-16-1/GUID-548E9689-F7AB-5F61-A8AE-EA2043E70D34-GENID-1-2-1-9-1-8-1-16-1-3-3-11">Mapping existing memory types</xref>  </p> </li>
+<li id="GUID-4D7899BC-B6AD-5C9F-9135-7E37F2CFC21E-GENID-1-2-1-9-1-8-1-16-1-3-1-2-2-3"><p> <xref href="GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-9-1-8-1-16-1.dita#GUID-EC2D5CA5-538C-5375-B00D-3107CD87CFFC-GENID-1-2-1-9-1-8-1-16-1/GUID-F90E6B00-6492-5471-975F-3C078046627A-GENID-1-2-1-9-1-8-1-16-1-3-3-14">Mapping ARMv6K or ARMv7 onto TMappingAttributes</xref>. </p> </li>
+</ul> </li>
+</ul>
+<section id="GUID-B8EA1997-C922-5E98-A32E-A77D641D11BC-GENID-1-2-1-9-1-8-1-16-1-3-2"><title>Reduced set
+access permissions</title> <p>The ARMv6-style page table reserves three bits
+in the page/directory table for access permission, so eight possible values
+are available. The use of four possible access permissions is sufficient.
+Therefore, removing the surplus access permissions frees up one page table
+bit that is used by Symbian platform internally. </p> <p id="GUID-ABBF3854-B8B8-52A0-B3F6-1DF44A37194A-GENID-1-2-1-9-1-8-1-16-1-3-2-3"><b>Affected kernel interface</b> </p> <p>The
+shadow pages kernel interface is valid on all platforms except for the emulator.
+On ARMv6 and previous platforms, shadow pages are created using access permission <codeph>PrivilegedRW/UserRO</codeph>,
+this is not supported by the limited set of encoding. Shadow pages are now
+mapped as <codeph>PrivilegedRO/UserRO</codeph>, instead. </p> <codeblock id="GUID-9197EF7D-F549-5144-A322-4C04CD80CFCC-GENID-1-2-1-9-1-8-1-16-1-3-2-5" xml:space="preserve">class Epoc
+    {
+public:
+    ...
+    IMPORT_C static TInt AllocShadowPage(TLinAddr aRomAddr);
+    IMPORT_C static TInt FreeShadowPage(TLinAddr aRomAddr);
+    IMPORT_C static TInt FreezeShadowPage(TLinAddr aRomAddr);
+    ...
+    };</codeblock> <p>This represents a serious behaviour break in the kernel
+interface. A device driver (running on ARMv7) that creates a shadow page and
+then attempts to alter the content of the page now panics. </p> <p>This is
+a common use case for run-mode debuggers. However, a debugging interface is
+already provided, see <xref href="GUID-E91A8060-77E3-35F0-A945-7081406C79CE.dita"><apiname>DebugSupport</apiname></xref> in <filepath>...\memmodel\epoc\platform.h</filepath>,
+where breakpoints are managed internally by the kernel. Therefore, it is believed
+that a run-time debugger that uses the <codeph>CodeModifier</codeph> implementation
+in the kernel should not be affected by this change. </p> <p>After a shadow
+page is created using <xref href="GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680.dita#GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680/GUID-4FA10D18-3BA2-3307-B2E1-77C9CD8D2B6B"><apiname>Epoc::AllocShadowPage()</apiname></xref>, the kernel
+allows the device driver to alter its content using <xref href="GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680.dita#GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680/GUID-5B889008-BC18-3127-89EF-B8EAB0834190"><apiname>Epoc::CopyToShadowMemory()</apiname></xref>. </p> <p><note> <xref href="GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680.dita#GUID-3DC7B5F2-512E-3FF3-BC08-945DDE2AE680/GUID-EF014DA2-EE35-3DBD-A325-C5648AD27C36"><apiname>Epoc::FreezeShadowPage()</apiname></xref> is obsolete for platforms that use the reduced set of access permissions,
+as the shadow memory is always in a “frozen” state, because it can only be
+changed through the kernel interface.</note> </p> </section>
+<section id="GUID-E137E4E9-AADA-5BCE-8FC8-504ACD486394-GENID-1-2-1-9-1-8-1-16-1-3-3"><title>Remapping cache
+attributes </title> <p>ARMv6 architecture uses a large number of bits in the
+page table to describe all of the options for inner and outer cachability.
+No applications use all of these options simultaneously so a smaller number
+of configurable options has been implemented to meet the needs of the system. </p> <p>This
+alternative cache mapping allows up to eight different mappings in page tables.
+The Symbian platform kernel and device drivers do not need more
+than four or five different cache mappings. </p> <p>Cache mapping cannot be
+altered during run-time. It must be configured before the MMU is initialised. </p> <p>See
+the Bootstrap <xref href="GUID-5EB03086-A87D-5588-8927-7A7F8DB38366.dita">Port
+Implementation Tutorial</xref>. </p> <p id="GUID-EDFD1FE0-ACD7-54B4-9633-0149E3FDF551-GENID-1-2-1-9-1-8-1-16-1-3-3-6"><b>Types of memory supported</b> </p> <p>The
+kernel supports the following types of memory: </p> <table id="GUID-23FAD8A6-579B-5E3D-A705-A53BA304D529-GENID-1-2-1-9-1-8-1-16-1-3-3-8">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Memory type</b>  </p> </entry>
+<entry><p> <b>Description</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttStronglyOrdered</codeph>  </p> </entry>
+<entry><p>Writes are not combined. The order of memory accesses is preserved.
+Serves as a memory barrier, which means: </p> <ul>
+<li id="GUID-800FC168-69E5-5A89-B5A4-F34AF25E7F9E-GENID-1-2-1-9-1-8-1-16-1-3-3-8-1-3-2-2-2-1"><p>previous accesses to
+any type of memory must complete before accesses to strongly ordered memory
+start </p> </li>
+<li id="GUID-75C9FA7F-3BCC-50FE-B053-A48DEF46A2D2-GENID-1-2-1-9-1-8-1-16-1-3-3-8-1-3-2-2-2-2"><p>accesses to strongly
+ordered memory must complete before any further access to any type of memory
+takes place. </p> </li>
+</ul> <p>This type is used for hardware mapping. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttDevice</codeph>  </p> </entry>
+<entry><p>Writes are not combined. The order of memory accesses is preserved.
+This type is used for hardware mapping. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttNormalUncached</codeph>  </p> </entry>
+<entry><p>Non cacheable memory: The order of accesses is not preserved. Writes
+may be combined. For example, this is used for video memory. </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttNormalCached</codeph>  </p> </entry>
+<entry><p>Write-back read/write allocate cached memory, inner and outer. Used
+for “ordinary” memory. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p> <note> Device memory and normal memory can be set as shared or
+non-shared, strongly ordered accesses are assumed to be shared. </note></p> <p>The
+complete set of memory types supported by Symbian platform are represented
+by the values of the <xref href="GUID-7CB34E6F-CBF7-3F04-8CB1-2D6C29C73992.dita"><apiname>TMemoryType</apiname></xref> enum. </p> <p id="GUID-548E9689-F7AB-5F61-A8AE-EA2043E70D34-GENID-1-2-1-9-1-8-1-16-1-3-3-11"><b>Mapping existing memory
+types</b> </p> <p>The <xref href="GUID-1CE7A793-6313-372C-AC1A-6D3F6C6F5042.dita"><apiname>TMappingAttributes</apiname></xref> constants allow
+the cache attributes to be manipulated. On remapped platforms, these map into <xref href="GUID-7CB34E6F-CBF7-3F04-8CB1-2D6C29C73992.dita"><apiname>TMemoryType</apiname></xref> as
+follows: </p> <table id="GUID-24B0E1CD-67D9-5FAD-8984-9E202975F7EA-GENID-1-2-1-9-1-8-1-16-1-3-3-13">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b> Memory type described by TMappingAttributes</b>  </p> </entry>
+<entry><p> <b>Memory type</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-27DA5FEE-8F76-3D9E-8726-FA5CB808680A.dita"><apiname>EMapAttrFullyBlocking</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-F6F245E9-9DB7-3BEF-8F58-9A7F8E0F5D59.dita"><apiname>EMemAttStronglyOrdered</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-B8ACFB0F-B457-358F-96EF-94BFBA6FE4A5.dita"><apiname>EMapAttrBufferedNC</apiname></xref>  </p> <p> <xref href="GUID-468C3800-7AEE-3219-9EBB-9C52971B3E0E.dita"><apiname>EMapAttrBufferedC</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-922F4FB9-57C0-31BF-ADFB-CC6B8376A39B.dita"><apiname>EMemAttDevice</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-AE44E6A7-5CD2-31D9-A701-188B26CDEBB0.dita"><apiname>EMapAttrL1Uncached</apiname></xref>  </p> <p> <xref href="GUID-5ADA8BB4-A7B9-3347-B9A8-B50BE92F66BC.dita"><apiname>EMapAttrCachedWTRA</apiname></xref>  </p> <p> <xref href="GUID-54A8E3DA-996D-3317-A129-9AD12201E3C1.dita"><apiname>EMapAttrCachedWTWA</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-FD4404AF-192C-3D20-A4BC-AE1181A14E43.dita"><apiname> EMemAttNormalUncached</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-FA3DD609-9C88-38C9-8719-4AB28B8E84EA.dita"><apiname>EMapAttrCachedWBRA</apiname></xref>  </p> <p> <xref href="GUID-9B211A60-6B45-31D5-A096-2B7944E651A0.dita"><apiname>EMapAttrCachedWBWA</apiname></xref>  </p> <p> <xref href="GUID-BB620F1F-FD18-3FCB-B1FC-7C3555F471B6.dita"><apiname>EMapAttrL1CachedMax</apiname></xref>  </p> <p> <xref href="GUID-72222BDB-E369-3D03-B3EE-A04B125EB2A3.dita"><apiname>EmapAttrCachedMax</apiname></xref>  </p> </entry>
+<entry><p> <xref href="GUID-2191E3C7-5F22-38D1-BB16-BD78B44AE7AA.dita"><apiname>EMemAttNormalCached</apiname></xref>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-A647726F-5569-3EAA-9E24-70FBEAF6F94B.dita"><apiname>EMapAttrAltCacheWTRA</apiname></xref>  </p> <p> <xref href="GUID-23C6459E-65F4-317E-B22D-6AB91A2F3462.dita"><apiname>EMapAttrAltCacheWTWA</apiname></xref>  </p> <p> <xref href="GUID-4F97DE5E-3031-3AB5-9646-996DD1EB9C15.dita"><apiname>EMapAttrAltCacheWBRA</apiname></xref>  </p> <p> <xref href="GUID-D34AE0F7-21A3-3B8C-B768-1A7840257780.dita"><apiname>EMapAttrAltCacheWBWA</apiname></xref>  </p> </entry>
+<entry><p>Return error </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-1E6DD28F-F53C-34F0-B5A1-88263389ACF7.dita"><apiname>EMapAttrL2CachedWTRA</apiname></xref>  </p> <p> <xref href="GUID-1695C568-36F8-3860-8253-D25CC6F2100E.dita"><apiname>EMapAttrL2CachedWTWA</apiname></xref>  </p> <p> <xref href="GUID-E82A15FB-6A92-388F-A6F2-AA0DBAC720E8.dita"><apiname>EMapAttrL2CachedWBRA</apiname></xref>  </p> <p> <xref href="GUID-CAD3DE19-9508-319E-9C61-1E7910D30AC9.dita"><apiname>EMapAttrL2CachedWBWA</apiname></xref>  </p> <p> <xref href="GUID-CE3B3839-E9B5-3B8F-AB41-3F589CD3347C.dita"><apiname>EMapAttrL2CachedMax</apiname></xref>  </p> </entry>
+<entry><p>Takes no effect. Only the inner cache description matters. </p> <p>This
+policy is already in place on ARMv5 platforms with L210, where the page table
+does not support a separate description of the inner and outer cache attributes. </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p id="GUID-F90E6B00-6492-5471-975F-3C078046627A-GENID-1-2-1-9-1-8-1-16-1-3-3-14"><b> Mapping ARMv6K or ARMv7
+onto TMappingAttributes</b> </p> <p>To describe memory on ARMv6K or ARMv7
+using the original <xref href="GUID-1CE7A793-6313-372C-AC1A-6D3F6C6F5042.dita"><apiname>TMappingAttributes</apiname></xref> bit mask, the device
+driver should use the following values: </p> <table id="GUID-C5D9F8B3-670A-5595-BE7A-288E34E077ED-GENID-1-2-1-9-1-8-1-16-1-3-3-16">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>ARMv6K/v7 memory type TMemoryType</b>  </p> </entry>
+<entry><p> <b>TMappingAttributes mask to use</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttStronglyOrdered</codeph>  </p> </entry>
+<entry><p> <codeph>EMapAttrFullyBlocking</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttDevice</codeph>  </p> </entry>
+<entry><p> <codeph>EMapAttrBufferedNC</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttNormalUncached</codeph>  </p> </entry>
+<entry><p> <codeph>EMapAttrL1Uncached</codeph>  </p> </entry>
+</row>
+<row>
+<entry><p> <codeph>EMemAttNormalCached</codeph>  </p> </entry>
+<entry><p> <codeph>EmapAttrCachedMax</codeph>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-EDC1C30B-4078-4434-95AC-2E37AF809A51.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-EDC1C30B-4078-4434-95AC-2E37AF809A51" xml:lang="en"><title>DMA Implementation </title><shortdesc>How to implement the Platform Specific Layer (PSL) for
+your particular hardware.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The DMA Framework provides the DMA platform service API to clients
+(usually drivers). It is necessary to implement a number of hardware-specific
+functions when adapting the framework to a new board. hardware. This
+section contains information about the Framework's implementation
+and hardware requirements.</p>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-EE2F64B2-A2E3-524F-8E04-68BE9AA9EA36-master.png has changed
Binary file Adaptation/GUID-EE2F64B2-A2E3-524F-8E04-68BE9AA9EA36_d0e29378_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-EE50283A-543C-446F-A5D1-E64043F988ED.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-EE50283A-543C-446F-A5D1-E64043F988ED" xml:lang="en"><title>DMA Device Driver Guide</title><shortdesc>Explains the key concepts that the device driver creator
+needs to know before developing a device driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The DMA framework bypasses the CPU for data transfers. Without
+DMA, the CPU would have to copy each piece of data from the source
+to the destination.<ul>
+<li><p><b>Device Driver:</b> A set of methods that tells the platform
+how to use a specific piece of hardware.</p></li>
+</ul><ul>
+<li><p><b>DMA Framework:</b> The DMA framework provides a simplified
+and unified access to DMA resources in a device. Generic transfer
+parameters abstract the underlying DMA hardware for basic services,
+and fine-grained control is still available for platform-specific
+features. </p></li>
+</ul><ul>
+<li><p><b>DMA Operation:</b> Before any DMA transfers can be undertaken,
+the DMA channel to be used and the source and destination addresses
+of the data to be transferred have to be specified. The transfer details
+are placed onto a queue for the DMA channel specified. The item at
+the head of the queue will be the active transfer and the rest of
+the queue will be pending transfers. </p></li>
+</ul></p>
+</conbody><related-links>
+<link href="GUID-AB5370D9-9F0B-4583-A825-11CBF7C6365C.dita"><linktext>DMA
+Tutorials Overview</linktext></link>
+<link href="GUID-EDC1C30B-4078-4434-95AC-2E37AF809A51.dita"><linktext>DMA
+Implementation Overview</linktext></link>
+<link href="GUID-4E3C086B-25BE-4DAC-9E21-CFC4F8B792A5.dita"><linktext>DMA
+Technology Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-EE7086B4-A60A-55B2-85DC-28F07F9E227E-master.png has changed
Binary file Adaptation/GUID-EE7086B4-A60A-55B2-85DC-28F07F9E227E_d0e55772_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-EF73C56D-AEB1-558B-BAD1-D076BA6EA889.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,109 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-EF73C56D-AEB1-558B-BAD1-D076BA6EA889" xml:lang="en"><title>Impact
+of Data Paging on User Side Code Guide</title><shortdesc>Explains cases in which data paging degrades the performance of
+user side code and sets out strategies to mitigate these effects. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-FCD37C40-C547-483C-AB65-B6465955DE70"><title>Purpose</title> <p>Data paging degrades the performance of
+user side code. This document describes strategies to mitigate these effects.
+It is intended for application developers whose code uses device drivers. </p> <p><b>Intended Audience:</b> </p> <p>Application developers writing modules
+which involve device drivers. </p> </section>
+<section id="GUID-2F31D78F-C2E9-42E1-B489-46B69A2A0AED"><title>Mitigating the impact of data paging on user side code</title> <p>Data
+paging is a technique which increases the size of virtual RAM by holding data
+on external media and read into physical RAM when accessed. The technique
+trades off an increase in available RAM against decreased performance. Developers
+must allow for the impact on performance and aim to mitigate it by using the
+practices described in this document. </p> <p>Data paging is mainly a property
+of processes. Processes can be configured to be paged or unpaged when they
+are built or put into a ROM image. Threads and the data which they use inherit
+the data paging configuration of the creating process and that configuration
+can be modified at the level of the thread or the individual items of data. </p> <p><b>Thread scheduling</b> </p> <p>When a platform uses data paging there is
+a higher risk of delays, timing-related defects and race conditions. </p> <p>When
+a thread accesses paged memory, the required page may be paged in (actually
+in RAM) or paged out (stored in media). If it is paged out, a page fault results,
+slowing performance by a factor of thousands and sometimes up to a million.
+The delay can also expose latent race conditions and timing-related defects
+in existing code: for instance an asynchronous request to a server may appear
+to complete synchronously, returning control to the client before the request
+has completed with incorrect behavior as a result. </p> <p>The cure for this
+problem is to configure data paging when chunks, heaps and threads are created. </p> <p>When
+creating a thread of class <xref href="GUID-B0E661BC-4058-3256-B9C3-5A4FD52F6DE5.dita"><apiname>RThread</apiname></xref> you can call the creating
+function <xref href="GUID-B0E661BC-4058-3256-B9C3-5A4FD52F6DE5.dita#GUID-B0E661BC-4058-3256-B9C3-5A4FD52F6DE5/GUID-6C840907-C3F7-34B7-97DB-CEDBA68EA277"><apiname>RThread::Create()</apiname></xref> with an argument of class <xref href="GUID-1D0D14AD-43CF-3B52-AD8D-641F75B8098C.dita"><apiname>TThreadCreateInfo</apiname></xref> as
+argument. You use an instance of this class to configure the data paging attributes
+to one of </p> <ul>
+<li id="GUID-E4F9029C-DEF9-5305-8006-BC56EA509F72"><p> <xref href="GUID-B1A7F7DF-9A43-3C7E-8602-503B7ED5A1A1.dita"><apiname>EUnspecified</apiname></xref> (the
+thread inherits the paging attributes of the creating process), </p> </li>
+<li id="GUID-FC939BA1-0822-53AB-B5BC-26CCD4D77075"><p> <xref href="GUID-7B309F53-DF64-389A-8D74-394D9F16E532.dita"><apiname>EPaged</apiname></xref> (the
+thread will data page its stack and heap), or </p> </li>
+<li id="GUID-973FCF18-4D8D-56F2-8263-46BF47B179B5"><p> <xref href="GUID-1F1551D0-77AE-33CE-940B-A9E0C4D4881B.dita"><apiname>EUnpaged</apiname></xref> (the
+thread will not data page its stack and heap). </p> </li>
+</ul> <p>When creating a chunk of class <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita"><apiname>RChunk</apiname></xref> you can
+call the creating function <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita#GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07/GUID-EA7C4105-6D64-3F87-83B6-C97DCDEDB94A"><apiname>RChunk::Create()</apiname></xref> with an argument
+of class <xref href="GUID-51F7DBCF-BFB6-31F9-8882-5D263A1AD4B4.dita"><apiname>TChunkCreateInfo</apiname></xref> as argument. You use an instance
+of this class to configure the data paging attributes to one of </p> <ul>
+<li id="GUID-A5BF2717-0814-5CBD-9EA5-296890B633C6"><p> <xref href="GUID-B1A7F7DF-9A43-3C7E-8602-503B7ED5A1A1.dita"><apiname>EUnspecified</apiname></xref> (the
+chunk inherits the paging attributes of the creating process), </p> </li>
+<li id="GUID-FAC297A5-27A3-5BA3-94CA-64D548368132"><p> <xref href="GUID-7B309F53-DF64-389A-8D74-394D9F16E532.dita"><apiname>EPaged</apiname></xref> (the
+chunk will be data paged), or </p> </li>
+<li id="GUID-86BE6A49-1B9B-59C7-A90B-BF7498138714"><p> <xref href="GUID-1F1551D0-77AE-33CE-940B-A9E0C4D4881B.dita"><apiname>EUnpaged</apiname></xref> (the
+chunk will not be data paged). </p> </li>
+</ul> <p>The <xref href="GUID-326A2F4D-0E99-31C0-A35D-E8BF45913F07.dita"><apiname>RChunk</apiname></xref> class also has a function <xref href="GUID-D848C0BA-F931-3F95-96B3-B64133FD5928.dita"><apiname>IsPaged()</apiname></xref> to
+test whether a chunk is data paged. </p> <p>When creating a chunk heap of
+class <xref href="GUID-C5D0C7E7-061F-3BA5-AE24-B83237684B01.dita"><apiname>UserHeap</apiname></xref> you can call the creating function <xref href="GUID-C5D0C7E7-061F-3BA5-AE24-B83237684B01.dita#GUID-C5D0C7E7-061F-3BA5-AE24-B83237684B01/GUID-18A6B89B-4844-37E5-B46E-32188760A8C0"><apiname>UserHeap::ChunkHeap()</apiname></xref> with
+an argument of class <xref href="GUID-3DCB92FB-9C74-3B73-B229-BF7944087EE9.dita"><apiname>TChunkHeapCreateInfo</apiname></xref> as argument.
+You use an instance of this class to configure the data paging attributes
+to one of </p> <ul>
+<li id="GUID-EC970D3F-05F3-52AD-A22C-A512209569A9"><p> <xref href="GUID-B1A7F7DF-9A43-3C7E-8602-503B7ED5A1A1.dita"><apiname>EUnspecified</apiname></xref> (the
+heap inherits the paging attributes of the creating process), </p> </li>
+<li id="GUID-66682630-3718-5FE2-AFCC-CB6697DFFC58"><p> <xref href="GUID-7B309F53-DF64-389A-8D74-394D9F16E532.dita"><apiname>EPaged</apiname></xref> (the
+heap will be data paged), or </p> </li>
+<li id="GUID-6E922E2B-31EF-58C9-9083-C4590BA11FE2"><p> <xref href="GUID-1F1551D0-77AE-33CE-940B-A9E0C4D4881B.dita"><apiname>EUnpaged</apiname></xref> (the
+heap will not be data paged). </p> </li>
+</ul> <p><b>Inter-process
+communication</b> </p> <p>Data paging impacts on inter-process communication
+when a non-paged server accesses paged memory passed from a client. If the
+memory being accessed is not paged in, unpredictable delays may occur, and
+when the server offers performance guarantees to its clients, all the other
+clients will be affected as well. There are three separate solutions to this
+problem: </p> <ul>
+<li id="GUID-86BB0F84-2660-5682-AA4E-B6922AF54F5F"><p>pinning memory automatically, </p> </li>
+<li id="GUID-4B6D47CE-9585-5CFF-AFE2-8987FAF9899A"><p>pinning memory as requested
+by the client, and </p> </li>
+<li id="GUID-09AC4F78-64A0-5572-AA8A-791176807734"><p>using separate threads
+for paged and unpaged clients. </p> </li>
+</ul> <p>Pinning paged memory means paging it into the RAM cache (if it is
+not already present) and preventing it from being paged out until it is unpinned. </p> <p>You
+can set a server so that all memory passed to it by a client call gets pinned
+for the duration of the call. You do so by calling the function <xref href="GUID-E5D22145-1B40-39F4-9242-72B64A0FB29C.dita"><apiname>SetPinClientDescriptors()</apiname></xref> of
+a <xref href="GUID-8E316AC4-4676-301A-9A23-659E83AA1D1C.dita"><apiname>CServer2</apiname></xref> object after construction but before calling <xref href="GUID-8E316AC4-4676-301A-9A23-659E83AA1D1C.dita#GUID-8E316AC4-4676-301A-9A23-659E83AA1D1C/GUID-3B6AC8A4-251C-39A7-BFB2-30AD454DF590"><apiname>CServer2::Start()</apiname></xref> for
+the first time. This method is easy but wasteful, as all memory gets pinned
+not just the data needs and the performance of the paging cache is impacted.
+Automatic pinning should therefore only be used as a last resort. </p> <p>You
+can pin specified items of memory at the request of the client by calling
+the <xref href="GUID-349EE025-F5DB-3430-9BA9-9FBF685F6B07.dita"><apiname>PinArgs()</apiname></xref> function of the <xref href="GUID-4AD02F14-1142-372F-9D11-224595932034.dita"><apiname>TIpcArgs</apiname></xref> class.
+This is the more efficient method as it allows fine-grained control over what
+memory is pinned. </p> <p>Separate threads for paged and unpaged clients. </p> <p><b>Thread performance</b> </p> <p>The set of pages accessed by a thread over
+a given period of time is called its working set. If the working set is paged,
+the performance of the thread degrades as the working set increases. When
+working with paged memory it is therefore important to minimise the working
+set. </p> <p>The main solution to this problem is to choose data structures
+with high locality, that is data structure residing in single or adjacent
+pages. An example of this is a preference for arrays rather than linked lists,
+since arrays are usually in adjacent pages while the elements of linked lists
+may reside on multiple pages. </p> </section>
+</conbody><related-links>
+<link href="GUID-E21E7992-607A-5A49-B022-189ECA9E76D1.dita"><linktext>Code Paging
+Overview</linktext></link>
+<link href="GUID-BDB847A2-557A-5902-AA6D-C1AE10D8E493.dita"><linktext>Code Paging
+Guide</linktext></link>
+<link href="GUID-B35A70D2-1BC8-51DE-95BF-F315DB394582.dita"><linktext>Demand Paging
+Overview</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-EFEACBE5-B9E1-5315-88CA-DA3B7C1BFCE0-master.png has changed
Binary file Adaptation/GUID-EFEACBE5-B9E1-5315-88CA-DA3B7C1BFCE0_d0e29694_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F09740DA-015B-449D-A124-0BEABBDDCB52.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F09740DA-015B-449D-A124-0BEABBDDCB52" xml:lang="en"><title>Enabling
+and Disabling</title><shortdesc>This document describes how device drivers enable and disable interrupts.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Drivers can enable and disable the interrupts on the relevant interrupt
+sources while handling the interrupts using the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita"><apiname>Interrupt</apiname></xref> class.
+Typically, handling an interrupt is done with disabled interrupts. The interrupt
+is then enabled after the completion of interrupt handling. </p>
+<codeblock id="GUID-7805933A-51F6-5169-81D0-C1A8E9647C0D" xml:space="preserve">Interrupt::Disable(aIntId);
+...
+// handle interrupt
+...
+Interrupt::Enable(aIntId);
+</codeblock>
+<codeblock id="GUID-87C0A4CF-BA67-58DE-A180-EA30189BEDF4" xml:space="preserve">/**
+ Interrupt Service Routine (ISR) for the UART driver. This function
+ is associated with the UART interrupt, EUartIrq (value obtained from 
+ TRM). This function is called whenever there is an interrupt on this 
+ interrupt line and the interrupt source is enabled. The ISR must be a 
+ static void function, taking a single TAny* parameter, which is an 
+ object passed at the time of binding, usually a pointer to the owning
+ class. Interrupt::Enable() must be called to start receiving 
+ interrupts.
+ 
+ The ISR implementation is hardware and driver specific. The ISR must
+ be self-contained as the state of the system is indeterminate. It
+ should not signal threads, allocate or de-allocate memory, copy
+ memory to or from user processes, or call most Kernel functions.
+ Also the whole system is blocked while the ISR is running, so it must be
+ kept as short as possible. Any lengthy processing must be done in a
+ delayed function call (DFC).
+ 
+ A typical ISR would,
+   Clear the interrupt in the peripheral.
+   Disable the interrupt.
+   Read or write peripheral registers, e.g. to determine errors, or 
+   to start a new task.
+   Read data from, or write data to, the peripheral.
+   Start or stop NTimers or DMA transfer operations.
+   Queue DFCs.
+ 
+ @param     aParam
+         pointer to object passed as parameter while binding
+ */    
+
+void DExUartPhysicalChannelH4::UartIsr(TAny* aParam)
+    {
+    // Do the high priority device specific interrupt handling
+    // i.e. read the interrupt type from device, clear the 
+    // interrupt.
+    ...
+    // Defer the remaining processing by queuing the respective 
+    // DFC based on the interrupt type
+    ...
+    }</codeblock>
+<p>Some operations may need to be performed with all the interrupts, not just
+the particular interrupt source, disabled. In this case, the <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita"><apiname>NKern</apiname></xref> class
+must be used to disable and enable all interrupts globally at the Interrupt
+controller. <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-8C251C65-FDE7-3161-8D2B-61401FB6487F"><apiname>NKern::DisableAllInterrupts()</apiname></xref> can disable all
+IRQs, or IRQs and FIQs. <xref href="GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02.dita#GUID-3A3C08F3-3D33-3D9E-80E7-7855C7B21E02/GUID-2D328082-3A9F-3467-81CF-B1C68866E163"><apiname>NKern::RestoreInterrupts()</apiname></xref> can
+restore the interrupts to their state before disabling. </p>
+<codeblock id="GUID-A34A1AEB-9B00-556D-A280-9BFF7A6BAA8C" xml:space="preserve">alevel = 1; // 1 to disable IRQs and 2 to disable IRQs and FIQs
+state = NKern::DisableAllInterrupts(aLevel);
+...
+// perform the required operations
+...
+NKern::RestoreInterrupts(state);
+</codeblock>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F123D574-44DE-528A-806C-DB64229BCEA2.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F123D574-44DE-528A-806C-DB64229BCEA2" xml:lang="en"><title>Demand Paging</title><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Describes the concepts of Demand Paging and how to use Demand Paging. </p>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-F12437C5-BD96-5B43-AD76-614CFAB104D2-master.png has changed
Binary file Adaptation/GUID-F12437C5-BD96-5B43-AD76-614CFAB104D2_d0e69275_href.png has changed
Binary file Adaptation/GUID-F127644A-6072-52CA-9B17-E9DDEA784BE0-master.png has changed
Binary file Adaptation/GUID-F127644A-6072-52CA-9B17-E9DDEA784BE0_d0e8997_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F20D5802-7B83-5B78-8753-A88E74E28398.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,256 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F20D5802-7B83-5B78-8753-A88E74E28398" xml:lang="en"><title>PSL Implementation</title><shortdesc>This topic describes how to implement the <codeph>DUsbClientController</codeph> interface to provide a platform-specific layer implementation for
+the USB client controller.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The platform-specific layer only contains functionality that cannot
+be abstracted and made generic because different USB device controller
+designs operate differently. For example, the internal (and therefore
+external) management of the endpoint FIFOs can be different. In some
+USB device controller designs, the endpoints have hardwired FIFOs
+of specific sizes, which may possibly be configured, whereas other
+designs have a defined maximum amount of FIFO RAM available that has
+to be shared by all endpoints in use in a given configuration. The
+way that the chip is programmed can also differ. Some designs have
+a single register into which all commands and their parameters are
+written, whereas others are programmed via a number of special purpose
+control registers. </p>
+<p>Everything else that has to be common because it is defined in
+the USB specification, is contained in the <i>platform-independent
+layer</i>. </p>
+<p>The operation of the USB device controller is hardware specific
+and the implementers of the platform-specific layer is free to do
+whatever is necessary to use the hardware. All of this is transparent
+to the platform-independent layer, which uses only the fixed set of
+pure virtual functions defined in <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita"><apiname>DUsbClientController</apiname></xref> to communicate with the platform-specific layer, and therefore with
+the hardware. </p>
+<p>The platform-specific layer is also responsible for managing the
+transfer of data over the endpoints, and it is important that it can
+provide the services expected by the platform-independent layer. Data
+transfers are normally set up by the platform-independent layer by
+calling one of the following member functions of <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita"><apiname>DUsbClientController</apiname></xref>: </p>
+<codeblock id="GUID-34B3EEE2-F83F-5063-9885-5CC0092FB518" xml:space="preserve">TInt SetupEndpointRead(TInt aRealEndpoint, TUsbcRequestCallback&amp; aCallback) = 0;
+TInt SetupEndpointWrite(TInt aRealEndpoint, TUsbcRequestCallback&amp; aCallback) = 0;
+TInt SetupEndpointZeroRead() = 0;
+TInt SetupEndpointZeroWrite(const TUint8* aBuffer, TInt aLength, TBool aZlpReqd=EFalse) = 0;
+TInt SendEp0ZeroByteStatusPacket() = 0;</codeblock>
+<p>which the platform-specific layer implements. </p>
+<p>These data transfer functions fall into two groups: one for handling
+endpoint-0 and another for handling general endpoints. Endpoint-0
+is handled differently from general endpoints throughout the USB stack.
+The functions for handling general endpoints are used to transfer
+user data. In addition to taking an endpoint number, these functions
+also take a reference to a <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita"><apiname>TUsbcRequestCallback</apiname></xref> object. This is a request callback, it is key to the data transfer
+mechanism. </p>
+<section id="GUID-B9C7FD99-E5D9-5E08-A219-AD1FE89ED139"><title>Reading
+data</title> <ul>
+<li id="GUID-96C81B48-9C6A-5EDB-86B3-8F8EC9F94DF0"><p> <xref href="GUID-F20D5802-7B83-5B78-8753-A88E74E28398.dita#GUID-F20D5802-7B83-5B78-8753-A88E74E28398/GUID-4076097E-5FC3-594B-BA00-4A45B78E84CD">General endpoints</xref>  </p> </li>
+<li id="GUID-260D22D3-5BA7-50A3-B382-D2E5F74CA5D5"><p> <xref href="GUID-F20D5802-7B83-5B78-8753-A88E74E28398.dita#GUID-F20D5802-7B83-5B78-8753-A88E74E28398/GUID-DD28FFFD-9433-57C9-A517-81BA8E001129">Endpoint-0</xref>  </p> </li>
+</ul> <p id="GUID-4076097E-5FC3-594B-BA00-4A45B78E84CD"><b>General endpoints</b> </p> <p>The platform-independent layer issues a request to read
+data by calling <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-907F6988-4336-3160-BD41-7FBECE9C6E88"><apiname>DUsbClientController::SetupEndpointRead()</apiname></xref>, which is implemented by the platform-specific layer, passing it
+the endpoint and a <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita"><apiname>TUsbcRequestCallback</apiname></xref> object. </p> <p>Data is read into a large buffer, whose address and length are
+passed as data members of the <codeph>TUsbcRequestCallback</codeph> object: <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita#GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F/GUID-B8507E01-B472-3FE6-82E7-281094A491C5"><apiname>TUsbcRequestCallback::iBufferStart</apiname></xref> and <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita#GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F/GUID-565F9CC5-15CE-3AF3-87DD-539737E0E628"><apiname>TUsbcRequestCallback::iLength</apiname></xref> respectively. For Bulk reads,
+this buffer is intended to catch a burst of data transmitted from
+the host rather than just a single packet. </p> <p>For all other transfer
+types (Control, Interrupt, Isochronous) it is usual to return only
+single packets to the LDD. The amount of data returned is controlled
+– and limited - by the USB client driver (the LDD) through the <codeph>iLength</codeph> value. </p> <p>The <codeph>TUsbcRequestCallback</codeph> object also supplies a pair of arrays: </p> <ul>
+<li id="GUID-D1993F45-0E58-5ECA-A845-3B300558759B"><p> <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita#GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F/GUID-843E57D1-4703-3127-B1BE-4C93F1AD54FC"><apiname>TUsbcRequestCallback::iPacketIndex</apiname></xref> containing the offset(s) into the data buffer of the single packet
+or burst data. </p> </li>
+<li id="GUID-6A2DDA06-DCB4-5675-AF62-6A9A5226AA2B"><p> <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita#GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F/GUID-2C7B48F0-5A57-3D72-91ED-9FABC99D25EE"><apiname>TUsbcRequestCallback::iPacketSize</apiname></xref> containing the size(s) of the packet or burst data. </p> </li>
+</ul> <p>These arrays are logically linked; both are the same size
+and can hold information for two entries each. </p> <p>Therefore,
+received single packets have to be merged into one 'superpacket' in
+the read buffer. It is assumed that these merged packets consist of
+maximum packet sized packets, possibly terminated by a short packet.
+A zero length packet or ZLP must appear separately; this would be
+the optional second packet in the respective array. </p> <p>For example,
+for a Bulk endpoint with a maximum packet size of 64 bytes: </p> <ul>
+<li id="GUID-65A91C14-FD6C-5FDD-9DDF-9E9A5F11271A"><p>If 10 x 64 byte
+packets and one 10 byte packet arrive, then these are marked as a
+single large 650 byte packet. </p> </li>
+<li id="GUID-AEA01430-333D-5A6E-B32D-017FEF9B93F7"><p>If 10 x 64 byte
+packets and one ZLP arrive, then these should be entered as two packets
+in the arrays; one of size 640 bytes and one of size zero. </p> </li>
+</ul> <p>The general aim when servicing a Bulk read request from the
+platform-independent layer is to capture as much data as possible
+whilst not holding onto data too long before returning the data to
+the LDD and receiving another buffer. There is considerable flexibility
+in how this is achieved and the design does not mandate any particular
+method; it also depends to a certain extent on the USB device controller
+hardware used. </p> <p>The platform implementation can use a re-startable
+timer to see whether data has been received in the time (usually milliseconds)
+since the last data was received. If data has been received, then
+the timer is restarted. If data has not been received, then the timer
+is not restarted, and the buffer is marked as complete for the platform-independent
+layer by calling <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-30D6B783-B27B-3ECD-AF34-D22ADF34A12D"><apiname>DUsbClientController::EndpointRequestComplete()</apiname></xref>. </p> <p>Note the following: </p> <ul>
+<li id="GUID-60992745-5A02-5177-9707-B9DD6F087AE0"><p>In the interrupt
+service routine (ISR), the flag <codeph>iRxMoreDataRcvd</codeph> is
+used to indicate that data has been received. </p> </li>
+<li id="GUID-2B15F54F-66A6-5788-89E9-68D12D3EB8AF"><p>The timer is
+not restarted in the ISR - the timer is allowed to expire and then
+a test is made for received data. </p> </li>
+<li id="GUID-F5FEF7D6-8DD1-5B12-9AF3-2EBBB18F75A4"><p>Typical values
+for the timer range from 1—5 ms. </p> </li>
+<li id="GUID-D46B9ABA-5719-5FC3-89F0-3745779F5900"><p>Each OUT endpoint
+requires a separate timer. </p> </li>
+<li id="GUID-585E00C0-FE41-5176-8DEF-54C0AD8F55E2"><p>The read is
+not flagged as complete to the platform-independent layer if no data
+has been received. The timer is only started once the first packet/transfer
+has been received. </p> </li>
+<li id="GUID-62CCCC78-AD45-5570-BC15-050BD4509BC7"><p>The bare minimum
+of work is done in the ISR. After draining the FIFO, update the <codeph>iPacketSize</codeph> and <codeph>iPacketIndex</codeph> arrays and
+recalculate the buffer address ready for the next packet, taking into
+account any alignment restrictions. </p> </li>
+</ul> <p>The platform-specific layer completes a non endpoint-0 read
+request by calling the platform-independent layer function <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-30D6B783-B27B-3ECD-AF34-D22ADF34A12D"><apiname>DUsbClientController::EndpointRequestComplete()</apiname></xref>. This function
+takes as its sole argument a pointer to the updated request callback
+structure that was initially passed to the platform-specific layer
+for that read. Members that need to be updated, in addition to the
+packet arrays <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita#GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F/GUID-843E57D1-4703-3127-B1BE-4C93F1AD54FC"><apiname>TUsbcRequestCallback::iPacketIndex</apiname></xref> and <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita#GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F/GUID-2C7B48F0-5A57-3D72-91ED-9FABC99D25EE"><apiname>TUsbcRequestCallback::iPacketSize</apiname></xref>, are: </p> <ul>
+<li id="GUID-7EF9E9C2-DE14-5290-B3FE-B91918669AE2"><p> <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita#GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F/GUID-8B2D125B-9943-386F-9A27-11CC1A25A0C2"><apiname>TUsbcRequestCallback::iRxPackets</apiname></xref>, with possible values: 1 or 2. </p> </li>
+<li id="GUID-9E1800A9-8D39-5D5D-92D0-13AF9CD3EF2A"><p> <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita#GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F/GUID-A00F6B27-655A-3182-96E2-8B3D2404CB7C"><apiname>TUsbcRequestCallback::iError</apiname></xref>  </p> </li>
+</ul> <p><b>Summary of Completion Criteria for general Endpoints</b> </p> <p>The platform-specific layer completes a read request by calling <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-30D6B783-B27B-3ECD-AF34-D22ADF34A12D"><apiname>DUsbClientController::EndpointRequestComplete()</apiname></xref> when any
+of the following conditions are met: </p> <ul>
+<li id="GUID-F66AF5EC-56D4-5133-A930-2BB793478B31"><p>The requested
+number of bytes has been received. </p> </li>
+<li id="GUID-91D9D4E4-2196-55C9-9595-1BA6AE2C2848"><p>A short packet,
+including a ZLP, is received. In the case of a ZLP being received,
+it must be represented separately in the <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-E5FD5F91-B22B-31A9-8482-635B2F1EB0B4"><apiname>DUsbClientController::iPacketIndex</apiname></xref> and <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-BFB565F1-C8F9-3E44-88FB-E81E88D2DF3A"><apiname>DUsbClientController::iPacketSize</apiname></xref> arrays. </p> </li>
+<li id="GUID-42124450-1AC8-59F3-9C30-8C74EC425CAE"><p>If the number
+of bytes in the current packet (still in the FIFO) were to cause the
+total number of bytes to exceed the buffer length <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-A0A7399A-A51E-3544-A181-5C45B69AB121"><apiname>DUsbClientController::iLength</apiname></xref>. </p> </li>
+<li id="GUID-09281AB5-7240-5B29-B0C1-C5A4A8289B7F"><p>The timer has
+expired, data is available, but no further packets have been received. </p> </li>
+</ul> <p id="GUID-DD28FFFD-9433-57C9-A517-81BA8E001129"><b>Endpoint-0</b> </p> <p>The handling of endpoint-0 read requests is similar to general
+endpoints except for the following: </p> <ul>
+<li id="GUID-D9361990-1591-522E-9F9E-7E38A6EB0B08"><p>The platform-independent
+layer issues the request by calling <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-B3B4793E-7B75-3C40-A6FA-CD17B460CC73"><apiname>DUsbClientController::SetupEndpointZeroRead()</apiname></xref>. This function does not take any parameters because: </p> <ul>
+<li id="GUID-4AED5324-65B5-5BD3-AACA-5EA9FB7CB90A"><p>The endpoint
+number is known, this is zero. </p> </li>
+<li id="GUID-9CEAFC92-DF2D-5B07-B623-5BA562EC61BE"><p>The request
+is completed after every received packet, and a <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita"><apiname>TUsbcRequestCallback</apiname></xref> object is not needed. </p> </li>
+</ul> </li>
+</ul> <p>All the platform-specific layer needs to know is where to
+place the received data, and its size. Both are fixed values: <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-BC2DF410-292B-354A-BCEF-2C9E520024B8"><apiname>DUsbClientController::iEp0_RxBuf</apiname></xref> and <xref href="GUID-D0DFABCF-15B4-347E-BAE5-0F050E137949.dita"><apiname>KUsbcBufSzControl</apiname></xref> respectively. </p> <p>An endpoint-0 read request is completed by
+calling <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-71E33976-C185-34FA-A8BF-7DB3404DDA78"><apiname>DUsbClientController::Ep0RequestComplete()</apiname></xref>, passing the endpoint number (0, or symbolically, <codeph>KEp0_Out</codeph>), the number of bytes received, and the resulting error code for
+this request. </p> </section>
+<section id="GUID-2617EDBD-6792-53B9-9CE0-6B0CC729728C"><title>Writing
+data</title> <ul>
+<li id="GUID-97BDD391-F5BE-509C-AF67-51AD4822FD11"><p> <xref href="GUID-F20D5802-7B83-5B78-8753-A88E74E28398.dita#GUID-F20D5802-7B83-5B78-8753-A88E74E28398/GUID-69839EA3-9DC0-5A3C-BE62-AC91708477BA">General endpoints</xref>  </p> </li>
+<li id="GUID-8E0F6F8F-D3DA-5E67-8E8C-E4BE983DBF1A"><p> <xref href="GUID-F20D5802-7B83-5B78-8753-A88E74E28398.dita#GUID-F20D5802-7B83-5B78-8753-A88E74E28398/GUID-C674608C-393B-5397-A1E4-3C8368E2144C">Endpoint-0</xref>  </p> </li>
+</ul> <p id="GUID-69839EA3-9DC0-5A3C-BE62-AC91708477BA"><b>General endpoints</b> </p> <p>The platform-independent layer issues a request to write
+data by calling <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-F7880D1C-7E7D-3214-BF84-8811DA935B0C"><apiname>DUsbClientController::SetupEndpointWrite()</apiname></xref>, which is implemented by the platform-specific layer, passing the
+function an endpoint and a <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita"><apiname>TUsbcRequestCallback</apiname></xref> object. </p> <p>The address of the buffer, containing the data to
+be written, is passed into the data member <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita#GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F/GUID-B8507E01-B472-3FE6-82E7-281094A491C5"><apiname>TUsbcRequestCallback::iBufferStart</apiname></xref>. The length of this buffer is passed into <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita#GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F/GUID-565F9CC5-15CE-3AF3-87DD-539737E0E628"><apiname>TUsbcRequestCallback::iLength</apiname></xref>. The buffer is a single contiguous piece of memory. </p> <p>The
+platform-specific layer's implementation needs to set up the transfer,
+either using DMA or a conventional interrupt driven mechanism, and
+then wait for the host to collect, by sending an IN token, the data
+from the respective endpoint’s primed FIFO. This continues until all
+data from the buffer has been transmitted to the host. </p> <p>If
+the ZLP request flag <codeph>iZlpReqd</codeph> in the <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita"><apiname>TUsbcRequestCallback</apiname></xref> structure is set (=<xref href="GUID-781E8158-805B-3784-8FED-D7A191822FC3.dita"><apiname>ETrue</apiname></xref>), then the platform
+specific layer must determine, after all data has been sent, whether
+to send a ZLP or not. The decision is based on the size of the last
+packet sent and the current maximum packet size of the endpoint. </p> <p>To summarize, a ZLP should be sent at the end of a write request
+if: </p> <ul>
+<li id="GUID-B3AFEC6D-EB74-57FE-9618-E44C6AE10460"><p>The ZLP flag
+is set. </p> </li>
+<li id="GUID-970EE707-24D1-53B8-A830-3824562F2AA8"><p>The last packet
+of the write request was not a short packet (i.e. it was a max-packet-sized
+packet). </p> </li>
+</ul> <p>The platform-specific layer completes a non endpoint-0 write
+request by calling the platform-independent layer function <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-30D6B783-B27B-3ECD-AF34-D22ADF34A12D"><apiname>DUsbClientController::EndpointRequestComplete()</apiname></xref>. This function
+takes only one argument, a pointer to the updated request callback
+structure passed to the platform-specific layer for this write. Members
+that need to be updated are: </p> <ul>
+<li id="GUID-F02F662E-ABAE-5519-A80C-DA4D66F7A51A"><p> <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita#GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F/GUID-31AF87D2-C1F3-3367-93AA-52924612A7D0"><apiname>TUsbcRequestCallback::iTxBytes</apiname></xref>  </p> </li>
+<li id="GUID-D8416C51-7A46-560F-9F6F-2565DA445004"><p> <xref href="GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F.dita#GUID-D395BF82-65B3-3A98-800B-E6EF43150E8F/GUID-A00F6B27-655A-3182-96E2-8B3D2404CB7C"><apiname>TUsbcRequestCallback::iError</apiname></xref>  </p> </li>
+</ul> <p id="GUID-C674608C-393B-5397-A1E4-3C8368E2144C"><b>Endpoint-0</b> </p> <p>The handling of endpoint-0 write requests is similar to general
+endpoints except for the following: </p> <p>The platform-independent
+layer issues the request by calling <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-DBE7AC29-8B85-3D98-BAF9-8EF059B33331"><apiname>DUsbClientController::SetupEndpointZeroWrite()</apiname></xref>. Unlike the equivalent read function, this function takes a number
+of parameters: </p> <ul>
+<li id="GUID-9831D5A3-2032-5C6C-B2AF-C78D9E00D09C"><p>the address
+of the location containing the data to be written </p> </li>
+<li id="GUID-C7F55C63-4AD4-5A37-B25B-1249850C5A92"><p>the length of
+the data to be written </p> </li>
+<li id="GUID-C2D21E5A-6FB9-5170-80F2-6B6351E5B11A"><p>a <xref href="GUID-4B942C06-1BAC-3A21-B3B1-89FB5C51ADA0.dita"><apiname>TBool</apiname></xref> parameter that indicates whether a zero length packet (ZLP) is to
+be sent immediately after the data has been sent. </p> </li>
+</ul> <p>An endpoint-0 write request is completed by calling <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-71E33976-C185-34FA-A8BF-7DB3404DDA78"><apiname>DUsbClientController::Ep0RequestComplete()</apiname></xref>, in the platform-independent
+layer, passing the function the endpoint number (0, or symbolically <codeph>KEp0_In</codeph>), the number of bytes written, and the error code
+for this write request. </p> <p>There is another endpoint-0 write
+function, <xref href="GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941.dita#GUID-82FA9C04-0B7E-3FAD-9AAD-3A68E1E6A941/GUID-95CCCE69-C8AA-39B1-8152-37AA0A7B9CEB"><apiname>DUsbClientController::SendEp0ZeroByteStatusPacket()</apiname></xref>, which is used for sending a zero length packet (ZLP) on its own.
+This separate function is provided because the USB device controller
+mechanism for transmitting a ZLP on its own can be different to the
+mechanism for transmitting the ZLP at the end of a data transmission. </p> </section>
+<section id="GUID-0805DDC6-2C17-50A2-97B6-F51C77DF3E4F"><title>Using
+DMA</title> <p>When planning to use DMA for transferring data from
+and to the endpoints’ FIFOs, there are two things that must be considered: </p> <ul>
+<li id="GUID-0E6B3A5B-CA84-5BB1-9447-70C7E493D8D2"><p> <xref href="GUID-F20D5802-7B83-5B78-8753-A88E74E28398.dita#GUID-F20D5802-7B83-5B78-8753-A88E74E28398/GUID-838483AC-BDDD-5A6A-AB8A-F26587851D9E">Flushing cached information for the data buffers</xref>  </p> </li>
+<li id="GUID-B9545262-93E4-5AA9-837F-D909B278B19F"><p> <xref href="GUID-F20D5802-7B83-5B78-8753-A88E74E28398.dita#GUID-F20D5802-7B83-5B78-8753-A88E74E28398/GUID-840EB8C0-8C29-5FDE-9505-D6D7131E61A4">Implementing DMA mode for OUT transfers (DMA reads)</xref>  </p> </li>
+</ul> <p id="GUID-838483AC-BDDD-5A6A-AB8A-F26587851D9E"><b>Flushing cached
+information for the data buffers</b> </p> <p>The cached information
+for the data buffers must be flushed before a DMA write operation,
+(i.e. transfer memory to a FIFO), and both before and after a DMA
+read operation, (i.e. transfer a FIFO to memory). </p> <p>The kernel
+provides three functions for that purpose. These are static functions
+in the class <xref href="GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F.dita"><apiname>Cache</apiname></xref>, declared in <filepath>...\e32\include\kernel\cache.h</filepath>: </p> <ul>
+<li id="GUID-4402C336-1638-5830-90A8-0A9746BC3CC7"><p> <xref href="GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F.dita#GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F/GUID-5F08DEAA-1237-32DE-AE41-CE7B18230972"><apiname>Cache::SyncMemoryBeforeDmaWrite()</apiname></xref>  </p> </li>
+<li id="GUID-BD880077-FF37-5604-BECF-EB4D86803EB4"><p> <xref href="GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F.dita#GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F/GUID-3FF3C567-C1BD-3D4E-97E1-B036456A374E"><apiname>Cache::SyncMemoryBeforeDmaRead()</apiname></xref>  </p> </li>
+<li id="GUID-49E1143C-2B5C-5E92-8ED8-66F75EB41D69"><p> <xref href="GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F.dita#GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F/GUID-78E6DE46-61F0-3840-B555-6926D21141BF"><apiname>Cache::SyncMemoryAfterDmaRead()</apiname></xref>  </p> </li>
+</ul> <p id="GUID-840EB8C0-8C29-5FDE-9505-D6D7131E61A4"><b>Implementing DMA
+mode for OUT transfers (DMA reads)</b> </p> <p>The implementation
+of DMA mode for IN transfers is normally relatively straightforward,
+however complications can occur with OUT transfers (DMA reads), depending
+on the DMA controller, the USB device controller and the way the two
+are connected. </p> <p>There are two issues: </p> <ol id="GUID-324F21A0-F3EB-5994-B23C-B0AD18973C2B">
+<li id="GUID-7513B814-D305-50A0-B18D-779D8F5B741E"><p>If we set up
+a DMA read for 4kB, for example, and this request returns after a
+short packet, we must be able to tell how much data has been received
+and is now in our buffer. In other words, the DMA controller must
+provide a way of finding out how many bytes have been received, otherwise
+we cannot complete the read request to the LDD. </p> <p>Here is a
+theoretical solution for a Scatter/Gather controller that doesn’t
+provide information about the number of bytes transferred directly. <b>Note: </b> This proposal has not been tested in practice! </p> <p>Instead of using one large DMA descriptor for 4kB, we could set up
+a chain of descriptors for max-packet-size bytes each. When the DMA
+completes, it will be: </p> <ul>
+<li id="GUID-B088943E-BEC6-568B-8E0E-7AA177566599"><p>for the whole
+transfer, in which case we know the number of bytes received. </p> </li>
+<li id="GUID-33974049-2069-57A3-A784-4A312BA846D8"><p>because it is
+a short packet. In this case we can try and find out which descriptor
+was being served at the time. The number of bytes received is then </p> <codeblock id="GUID-56C3A794-4077-5A83-BA17-E6BE58A675D4" xml:space="preserve">number of completed descriptors * max-packet-size + number of bytes in short packet.</codeblock> </li>
+</ul> </li>
+<li id="GUID-E7406164-A6C4-5508-AD5D-A8DA4F2E4AAC"><p>Another potential
+problem is posed by the restartable OUT endpoint timer described in
+the section <xref href="GUID-F20D5802-7B83-5B78-8753-A88E74E28398.dita#GUID-F20D5802-7B83-5B78-8753-A88E74E28398/GUID-B9C7FD99-E5D9-5E08-A219-AD1FE89ED139">Reading data</xref>. The situation in the timer callback DFC, when
+the LDD read request is about to complete, has to be handled with
+care in order to avoid data loss. If at this point the pending DMA
+request has already started transferring data from the endpoint FIFO
+into our data buffer, then we cannot complete the LDD request anymore
+(this data would be lost because the LDD would not know about it as
+the variables in the request structure do not take account of it).
+The buffer cannot be removed while it is receiving data from a DMA
+transfer. A possible solution would be as follows: (again, this is
+just an idea and therefore untested). In the timer DFC, before we
+complete to the LDD, we cancel the pending DMA request. If a DMA transfer
+was already happening, then this will somehow complete and the DMA
+complete DFC will be queued. What we need to find out in that situation
+is whether or not that DFC is pending: </p> <ul>
+<li id="GUID-EA31A9E0-5783-5E3C-BFAF-AE041FBC61F1"><p>if not, then
+there was no DMA transfer ongoing, and we can just complete our read
+request to the LDD. </p> </li>
+<li id="GUID-E971CEC8-B0EA-5924-83A6-6FF4E4EB8C9E"><p>otherwise we
+have to abandon, at this point, the plan to complete and return from
+the timer callback (without doing any damage). In this case, the DMA
+complete DFC will run next, the LDD read request structure will be
+updated, the RX timer will be set again, and we can proceed as normal. </p> </li>
+</ul> </li>
+</ol> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F367F6C9-66F7-4061-81A7-0C845D8F39C4.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,61 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F367F6C9-66F7-4061-81A7-0C845D8F39C4" xml:lang="en"><title>Cancellation
+of Asynchronous Requests</title><shortdesc>This document describes how a device driver cancels an asynchronous
+request.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Any outstanding asynchronous request can be cancelled. <xref href="GUID-675860FB-AA37-3467-AF52-7D1B17FEE0A6.dita"><apiname>DoCancel()</apiname></xref> is
+implemented to handle cancel requests. Cancel requests are either explicitly
+made by the user or made when there is a close message. Any pending requests
+and queued DFCs are cancelled and the request is completed with <xref href="GUID-6F4A88DA-F54E-3848-9C32-942D6F5F4F3E.dita"><apiname>KErrCancel</apiname></xref>. </p>
+<codeblock id="GUID-AEE32663-E6E2-50CC-A756-10CAC0CA503D" xml:space="preserve">/** 
+ Cancel Asynchronous Requests. This is called from HandleMsg() to 
+ cancel pending asynchronous requests. This function determines which    
+ operation is to be cancelled and tidies up the resources specific to 
+ the request being cancelled, any outstanding DFCs, and timers, and   
+ signals the client that the operation is completed.
+ 
+ @param aMask
+ Mask containing the request number that has to be cancelled 
+ */
+void DExDriverLogicalChannel::DoCancel(TUint aMask)
+    {
+    ...
+    // Any pending asynchronous operation can be 
+    // cancelled. Check a valid asynchronous request 
+    // to cancel has been specified.
+    //
+    if(aMask&amp;(1&lt;&lt;RExDriverChannel::ERequestTransmitData))
+        {
+        if (iTxDataStatus)
+            {
+            // If it is a Transmit request, cancel the Transmit DFC. 
+            // TDfc::Cancel() cancels the DFC if it is already 
+            // queued. It does nothing if the DFC is not queued.
+            //
+            iTxDfc.Cancel();
+
+            // Notify the client (iClient) that the request is 
+            // completed. The TRequestStatus object is updated with the 
+            // status and the completion code is provided to the
+            // client. KErrCancel indicates that the request has been 
+            // cancelled. Typically, a client thread, waiting on 
+            // User::WaitForRequest(TRequestStatus &amp;aStatus) or using
+            // the active object framework, is unblocked and notified. 
+            // Then the client may read the request status from the 
+            // TRequestStatus object. 
+            //                                              
+            Kern::RequestComplete(iClient,iTxDataStatus,KErrCancel);
+            }
+        }
+    ...
+    }</codeblock>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F3B93325-E30E-456A-B281-5451B7C47AAE.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F3B93325-E30E-456A-B281-5451B7C47AAE" xml:lang="en"><title>Baseport Template Implementation</title><shortdesc>Provides information on implementation, build and testing
+of Baseport Template platform service.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F461CBB3-F8D1-5961-AD51-5741143A1CB1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,255 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F461CBB3-F8D1-5961-AD51-5741143A1CB1" xml:lang="en"><title>Client of Slave Channel Tutorial</title><shortdesc>This document describes a simple implementation of a client
+of an IIC slave channel. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-803E9D3A-19F4-58EA-A3F8-1912C7223FE2"><title>Required
+background</title> <p>Before you start, you must: </p> <ul>
+<li id="GUID-E20D2D65-CB2C-52A0-B694-B26EC96B6F99"><p>Have installed
+the platform specific implementation of IIC channels that is required
+to support the IIC platform service API. </p> </li>
+<li id="GUID-F675A381-8125-5077-8D9E-70188B1ACA6C"><p>Ensure that
+the <filepath>iic.dll</filepath> has been included in the <filepath>kernel.iby</filepath> file. </p> </li>
+<li id="GUID-638684A5-4938-5F60-9BB1-97F5AFD199B4"><p>Include the <filepath>iic.h</filepath> and <filepath>iic_channel.h</filepath> header files. </p> </li>
+</ul> </section>
+<section id="GUID-D71B8CE6-AD6B-56A4-835F-44B80FB2E0A6"><title>Introduction</title> <p>An application communicates over an IIC channel by operating
+as a client of the channel. When the channel uses a slave node, a
+transmission must be conducted at the level of the transfer because
+slaves react to transfers between it and a master node. For this reason,
+a large part of the client functionality is implemented as a callback
+function which is passed to the channel object and placed on the client
+thread’s DFC queue for execution. The callback notifies the client
+of the individual transfers and is the entry point to the application
+functionality which uses the data being transmitted. The other client
+API functions control the transmission as a whole. </p> </section>
+<section id="GUID-F6E864D9-F951-4A2D-B933-166F5DE4F5C3"><title>Procedure
+for writing a client</title> <ol id="GUID-E1360AA1-59E2-53FE-9CED-967D731F17CA">
+<li id="GUID-D8ABA659-47A9-536E-9EC6-E8741909CAFF"><p>Capture the
+channel by calling <xref href="GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF.dita#GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF/GUID-0078D2B4-07B7-3936-8CB2-6A967C9B1FCD"><apiname>IicBus::CaptureChannel()</apiname></xref>. </p> <ol id="GUID-A0A19CF5-5A45-588A-8C15-A11C12800055">
+<li id="GUID-37BA179D-1D7F-560C-8C81-6C9EE7674459"><p>Pass the channel
+Id as its <codeph>TInt aBusId</codeph> parameter. </p> </li>
+<li id="GUID-BF8B3291-626A-59F1-897A-25A73D22FCCD"><p>Pass the channel
+configuration header as <codeph>TDes8* aConfigHdr</codeph>. </p> </li>
+<li id="GUID-E1BA9A5F-81CE-522E-8CC0-CF38D0BC474B"><p>Pass a pointer
+to the callback function as <codeph>TIicBusSlaveCallback* aCallback</codeph>. </p> </li>
+<li id="GUID-DB6262F2-51D4-5D2D-857B-7F54E6EF1521"><p>Pass the boolean <xref href="GUID-781E8158-805B-3784-8FED-D7A191822FC3.dita"><apiname>ETrue</apiname></xref> as <codeph>TBool aAsynch</codeph> to specify asynchronous
+channel capture and otherwise pass <xref href="GUID-A759CA2D-8327-348F-9337-4886E619D920.dita"><apiname>EFalse</apiname></xref>. </p> </li>
+</ol> <p><codeblock id="GUID-713BDFF9-83E2-5A63-BD3A-A36556E5A70C" xml:space="preserve">
+    TInt channelId = 0;
+    // capture channel..
+    r = IicBus::CaptureChannel(TInt aBusId, &amp;header, iSlaveCallback, channelId, aAsynch);
+    if (r != KErrNone)
+        {
+        __KTRACE(Kern::Printf("Error capturing the channel, r %d", r));
+        }
+</codeblock> </p> <p>In synchronous transmission when the function
+returns the parameter <codeph>TInt&amp; aChannelId</codeph> is set
+to a token value, the channel Id, which is used by the other functions
+to acquire the exclusive use of the channel. In asynchronous transmission
+the channel Id is set immediately before calling the client callback. </p> </li>
+<li id="GUID-1D366FFE-DEE0-59E1-9FC7-507C06C58964"><p>Register receive
+and transmit buffers by calling <xref href="GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF.dita#GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF/GUID-E6D971CA-E09C-36B2-92B2-759CC81AF3F1"><apiname>IicBus::RegisterRxBuffer()</apiname></xref> and <xref href="GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF.dita#GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF/GUID-E885DF1D-2192-3BC7-8165-1E5A194ABA28"><apiname>IicBus::RegisterTxBuffer()</apiname></xref>. </p> <ol id="GUID-7722A592-4EB3-5701-9F7F-79EEB8E6221D">
+<li id="GUID-520C3DF1-91AE-5FAC-AFFC-806361672660"><p>Pass the channel
+Id as the <codeph>aChannelId</codeph> parameter. </p> </li>
+<li id="GUID-E4971790-1830-5CA3-90DB-89F3FA169758"><p>A buffer is
+represented by a descriptor containing a point to the start of the
+buffer, its total size in bytes and an indication of how much of it
+is in use. Initialise a descriptor with these values and pass it as <codeph>TPtr8 aRxBuffer</codeph>, and similarly for <codeph>TPtr8 aTxBuffer</codeph>  </p> </li>
+</ol> <p><codeblock id="GUID-6585AF43-450D-5A6A-A55E-39CEDACF0CA1" xml:space="preserve">
+    TPtr8 rxBuf(0, 0);
+    TPtr8 txBuf(0, 0);
+
+    rxBuf.Set((TUint8*) iRxBuf.Ptr(), iSlaveBufSize, iRxBuf.MaxLength());
+    txBuf.Set((TUint8*) iTxBuf.Ptr(), iSlaveBufSize, iTxBuf.MaxLength());
+
+    r = IicBus::RegisterRxBuffer(iChannelId, rxBuf, 8, iSlaveBufSize, 0);
+    if(r != KErrNone)
+        {
+        __KTRACE(Kern::Printf("Error Register Rx Buffer, r %d", r));
+        }
+    else
+        {
+        r = IicBus::RegisterTxBuffer(iChannelId, txBuf, 8, iSlaveBufSize, 0);
+        }
+
+    return r;
+</codeblock> </p> </li>
+<li id="GUID-BC801368-74D3-504D-95D6-A802C34062C9"><p>Call <xref href="GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF.dita#GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF/GUID-8FD1E53D-5C7C-38ED-8B2C-59B4BCF8940B"><apiname>IicBus::SetNotificationTrigger()</apiname></xref>. This function informs
+the channel of the conditions under which the callback is to be called. </p> <ol id="GUID-FB921A67-1B9D-5B7A-9B9E-1587F32328A6">
+<li id="GUID-4DB389EA-2BC7-5275-AF4C-D6EE411B2400"><p>Pass the channel
+Id as <codeph>TInt&amp; aChannelId</codeph>. </p> </li>
+<li id="GUID-0F57322E-3D82-5E67-932C-9C6145B4E7C6"><p>The callback
+is called when the state of the channel satisfies one of a number
+of conditions called triggers which are specified in the enumeration <xref href="GUID-5216FF3E-19BA-3862-B188-A3871D7D1BF5.dita"><apiname>TIicBusSlaveTrigger</apiname></xref>. Determine which triggers are appropriate,
+create a bitmask of them and pass it as <codeph>TInt aTrigger</codeph>. </p> </li>
+</ol> <p><codeblock id="GUID-03217DC6-FD76-5786-8103-55BB847533CB" xml:space="preserve">
+/*
+    ERxAllBytes            = 0x01,    // Master has written the required number of bytes
+    ERxUnderrun            = 0x02,    // Master has written less than the required number of bytes, and ceased transmitting
+    ERxOverrun            = 0x04,    // Master has written the required number of bytes and is continuing to transmit
+    ETxAllBytes            = 0x08,    // Master has read the required number of bytes
+    ETxUnderrun            = 0x10,    // Master has read the required number of bytes and is continuing to read
+    ETxOverrun            = 0x20,    // Master has read less than the required number of bytes, and ceased reading
+    EGeneralBusError    = 0x40,    // An error has occurred during a transaction
+    EAsyncCaptChan        = 0x80     // Completion of asynchronous CaptureChannelr = IicBus::SetNotificationTrigger(iChannelId, aTrigger);
+*/
+ r = SetNotificationTrigger(iChannelId, aTrigger);
+    if (r != KErrNone)
+        {
+        __KTRACE(Kern::Printf("Error setting notification trigger, r %d", r));
+        }
+
+    return r;
+</codeblock> </p> <p>The transmission of data will now take place,
+controlled by the mechanism of callback and triggers. Different buses
+signal that a transmission has been completed in different ways: for
+instance I2C uses a stop bit and SPI changes the voltage on Chip Select. </p> </li>
+<li id="GUID-488F34BF-E6E8-5316-8484-14560A689CD8"><p>When you have
+finished using the channel, release it by calling <xref href="GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF.dita#GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF/GUID-C1B69722-1316-3C7D-BB8B-0E54B8F44C5D"><apiname>IicBus::ReleaseChannel()</apiname></xref> with the channel Id as its argument. </p> <p><codeblock id="GUID-06528860-5B5D-5909-BBD5-BABE2146F616" xml:space="preserve">
+        r = IicBus::ReleaseChannel(iChannelId);
+        if (r == KErrNone)
+            {
+   // resetting channel Id
+            iChannelId = 0;
+            if(iSlaveCallback)
+                {
+    // callback object no longer needed, so delete
+                delete iSlaveCallback;
+                iSlaveCallback = NULL;
+                }
+
+            }
+</codeblock> </p> </li>
+</ol> </section>
+<section id="GUID-C82AB1DF-2988-4E29-92D1-235662B0485C"><title>Next
+steps</title> <ul>
+<li id="GUID-FD946C48-CC78-5E04-A682-65DAC3CF31C2"><p>Implement the
+callback as a function containing a series of conditions on the triggers.
+Its prototype must match the typedef for (*<xref href="GUID-7EB83085-7D28-3914-802B-44D8260E9074.dita"><apiname>TIicBusSlaveCbFn</apiname></xref>). </p> <codeblock id="GUID-A0F3DD87-11B7-5AD1-B3F1-F5515B4A97BD" xml:space="preserve">typedef void (*TIicBusSlaveCbFn)(TInt   /*aChannelId*/,
+                                 TInt   /*aReturn*/,
+                                 TInt   /*aTrigger*/,
+                                 TInt16 /*aRxWords*/,
+                                 TInt16 /*aTxWords*/,
+                                 TAny*  /*aParam*/);
+</codeblock> <p>These functions serve three purposes. </p> <ul>
+<li id="GUID-7E871B53-4DA7-5C38-9485-A7FAD2ACCC4B"><p>The callback
+must react to the completion of an asynchronous transmission between
+it and the bus master. </p> </li>
+<li id="GUID-068201FA-B27E-55F5-AF14-CBA53A8D1AAD"><p>It must implement
+the actual functionality of the application by doing something with
+the data which is written to or read from the buffers. </p> </li>
+<li id="GUID-7F9AFCB8-6C3F-51C4-B1B9-C5DA492ED039"><p>It must react
+to cases where the physical transfer of the data has not taken place
+exactly as expected. For example there may be more data to transfer
+than had been anticipated. </p> </li>
+</ul> <ul>
+<li id="GUID-74EA3A8B-8DEE-57E8-90F3-606FE671588A"><p>Implement the
+reaction to a completed asynchronous transmission as a conditional
+statement where <xref href="GUID-DAAA6E18-9E78-3ED2-A686-EC28E5C92A24.dita"><apiname>EAsyncaptChan</apiname></xref> is true. The callback
+should return and control should revert to the client. </p> <codeblock id="GUID-F6ECA83D-E4D8-5015-A88C-B76228DA74BB" xml:space="preserve">
+  // aTrigger and aReturn are the arguments provided to the clients 
+  // callback functions as defined by TIicBusSlaveCbFn
+        if(aTrigger &amp; (EAsyncCaptChan))
+            {
+            if(aReturn == KErrCompletion)
+                {
+    // a is a pointer to the client's object
+    // which stores the channel Id, client Id etc
+                a-&gt;iChannelId = aChannelId;
+                __KTRACE(Kern::Printf("channelId %d", aChannelId));
+                }
+
+            Kern::RequestComplete(a-&gt;iClient, a-&gt;iSlaveReqStatus, aReturn);
+            return;
+            }
+</codeblock> </li>
+<li id="GUID-16448D59-2A11-5D89-806F-763D96CEFEC6"><p>Implement the
+actual functionality of the application as a conditional statement
+where <xref href="GUID-CC0F0C9A-25B6-3A18-93D1-EC0710DFB6A7.dita"><apiname>EAllBytes</apiname></xref> is true. The callback should return
+at the end of this condition. </p> <codeblock id="GUID-905D54F9-A19E-51C9-98A5-A95471BAFB53" xml:space="preserve">
+        if(aReturn &amp; (ETxAllBytes | ERxAllBytes))
+            {
+            Kern::RequestComplete(a-&gt;iClient, a-&gt;iSlaveReqStatus, KErrNone);
+            }
+
+        if(aTrigger &amp; (/*ERxAllBytes |*/ ETxAllBytes))
+            {
+            Kern::RequestComplete(a-&gt;iClient, a-&gt;iSlaveReqStatus, KErrNone);
+            }
+        }
+</codeblock> </li>
+<li id="GUID-9725BAF2-14B1-5CC7-8DE4-46FB3DDF609E"><p>Implement the
+other cases as conditional statements where the other triggers in <xref href="GUID-5216FF3E-19BA-3862-B188-A3871D7D1BF5.dita"><apiname>TIicBusSlaveTrigger</apiname></xref> are true. In the event of <xref href="GUID-1D10124D-F27E-33C3-B803-FEBDEB2B7964.dita"><apiname>EGeneralBusError</apiname></xref> the callback should simply complete. The
+other triggers involve buffer underruns and overruns which may require
+new buffers which the unexpected data can be read from and written
+to. </p> <ul>
+<li id="GUID-67BAE1C9-1A2B-524D-B3D0-7E28CC309BDA"><p>Register the
+new buffers by calling <xref href="GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF.dita#GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF/GUID-E6D971CA-E09C-36B2-92B2-759CC81AF3F1"><apiname>IicBus::RegisterRxBuffer()</apiname></xref> and <xref href="GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF.dita#GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF/GUID-E885DF1D-2192-3BC7-8165-1E5A194ABA28"><apiname>IicBus::RegisterTxBuffer()</apiname></xref> as explained before. </p> </li>
+<li id="GUID-C6711DE9-F3B1-53F2-B0F9-03B3550F1487"><p>Start data transfer
+to and from the new buffers by calling <xref href="GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF.dita#GUID-69949E47-8FDF-3651-BEEF-43726EBEB5FF/GUID-8FD1E53D-5C7C-38ED-8B2C-59B4BCF8940B"><apiname>IicBus::SetNotificationTrigger()</apiname></xref> as explained before. </p> <p>The channel is implemented as a state
+machine as illustrated. The channel starts and finishes in the <codeph>EInactive</codeph> state. During operation it alternates between
+the two states <codeph>EWaitForClient</codeph> and <codeph>EWaitForMaster</codeph> as the client notifies the channel of new triggers and the channel
+reacts to them. There is a timer on these two states and the state
+machine returns to <codeph>EInactive</codeph> either when there are
+no triggers remaining to be detected or the timers time out. When
+the client fails to respond on time it enters the state <xref href="GUID-68E03A23-AE1E-3412-B831-7770882B8C2B.dita"><apiname>EClientTimeout</apiname></xref>. </p> </li>
+</ul> <codeblock id="GUID-73A80A1E-4C07-55DB-AFCF-608B48B68460" xml:space="preserve">
+        if(aTrigger &amp; ETxUnderrun)
+            {
+            TPtr8 txBuf(0, 0);
+
+            txBuf.Set((TUint8*) a-&gt;iTxBuf.Ptr(), a-&gt;iTxBuf.MaxLength(), a-&gt;iTxBuf.MaxLength());
+
+   // if there is more data to transmit
+            // use aTxWords as an offset..
+             if(aTxWords + 32 &lt;= KMaxSlaveTestBufferSize)
+                {
+    // register the next buffer
+                r = IicBus::RegisterTxBuffer(a-&gt;iChannelId, txBuf, 8, 32, aTxWords);
+    // check it was successful
+                if (r != KErrNone)
+                    {
+                     Kern::Printf("Error Register Tx Buffer, r %d", r);
+                    }
+                else
+                    {
+     // set the trigger to transmit the required number of bytes
+                    r = IicBus::SetNotificationTrigger(a-&gt;iChannelId, ETxAllBytes);
+     // check the request was accepted
+                    if (r != KErrNone)
+                        {
+                        Kern::Printf("Error setting notification trigger, r %d", r);
+                        }
+                    }
+
+                // updated the buffer - so return..
+                return;
+                }
+            }
+</codeblock> </li>
+</ul> </li>
+</ul> <fig id="GUID-2A41FE33-8734-5A13-ACB0-B971E4429C85">
+<title>              Client state machine 1            </title>
+<image href="GUID-8A78D678-D1C8-4A4E-9BF1-81C7019815C3_d0e94711_href.png" placement="inline"/>
+</fig> <fig id="GUID-2178C529-1F08-5504-9C04-C46D59F4951F">
+<image href="GUID-4CB3C746-606F-4533-8BBB-4A1254A74772_d0e94716_href.png" placement="inline"/>
+</fig> <fig id="GUID-FB2C9F89-6148-5AE2-A07A-C0D643407044">
+<title>              Client state machine 3            </title>
+<image href="GUID-ACC010D4-B419-4CDD-8091-C85579575D46_d0e94724_href.png" placement="inline"/>
+</fig> </section>
+</conbody><related-links>
+<link href="GUID-9986DCC6-EE73-59FB-BDAC-9B09DC64FBCE.dita"><linktext>Client
+of Master Channel Tutorial</linktext></link>
+<link href="GUID-B2F86F54-EF50-56DB-ADF7-15325AC9324D.dita"><linktext>IIC
+Concepts</linktext></link>
+<link href="GUID-3A30DA16-ECA8-5639-A9DC-6BE2AD55420B.dita"><linktext>I2C
+Technology Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F4B2D20B-8F1D-4A4B-8ECB-65BE8E9824DD.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,103 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F4B2D20B-8F1D-4A4B-8ECB-65BE8E9824DD" xml:lang="en"><title>Interrupt Overview</title><shortdesc>Hardware or software uses interrupts to indicate an event
+has occurred, such as a data buffer being ready or a key has been
+pressed.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Interrupts are sent by hardware or software to indicate an event
+has occurred. Interrupts typically cause an Interrupt Service Routine
+(ISR) to be executed. The Interrupt platform service specifies the
+interface APIs for setting up the ISRs and connecting them to specific
+Interrupt IDs. </p>
+<p>Interrupts can be managed using the <xref href="GUID-A5D862E4-3EC3-45C0-B635-23A02E5BB11F.dita">GPIO</xref> platform
+service when an interrupt source is connected through GPIO pins. </p>
+<p>The Interrupt platform service is used by the device drivers that
+use an interrupt source routed directly to the interrupt controller
+hardware. For more information on how to use GPIO to manage interrupts,
+see <xref href="GUID-745273E3-BB3A-59BF-9C33-6C8BB3D850A9.dita">GPIO Design
+Considerations</xref>.</p>
+<p>Not all hardware events are indicated by interrupts; hardware may
+indicate a status change by setting a value in a register or sending
+a command/signal over a bus.</p>
+<section id="GUID-DEAC516A-6147-5EFE-A6F9-5069F4B3310C"><title>What
+is the Interrupt platform service</title> <p>The Interrupt platform
+service specifies certain APIs for attaching an Interrupt Service
+Routine to an API. It is the low level interface between hardware/software
+interrupts, and the kernel and kernel level device drivers.</p> </section>
+<section id="GUID-E075BEC5-7112-4280-A65D-67933977AE01"><title>Required
+background</title> <p>You should be familiar with the following: </p> <ul>
+<li id="GUID-D06AC743-F0CD-5EDB-807E-04498CC89C92"><p>Writing a C++
+function that is either global or is in a static class so that the
+function address can be used for the ISR.</p> </li>
+<li id="GUID-C81342F9-001D-5E17-ABC2-A44D4A7837D2"><p>The specification
+for your hardware, including determining interrupt IDs.</p> </li>
+</ul> </section>
+<section id="GUID-FE8CA9F1-F07D-4D41-B0BC-CE08FFA6C9C9"><title>Key
+concepts and terms</title> <p>The following concepts are relevant
+to this component: </p> <dl>
+<dlentry>
+<dt>Interrupt ID</dt>
+<dd><p>An identifier which says which interrupt has occurred. Typically
+an unsigned integer.</p> </dd>
+</dlentry>
+<dlentry>
+<dt>Interrupt Service Routine (ISR)</dt>
+<dd><p>An ISR is a static function which is called when an interrupt
+is received. It should be very short, allocate no memory on the heap,
+store any volatile information that needs to be captured for that
+event, and, if required, queue a DFC for further processing.</p> </dd>
+</dlentry>
+<dlentry>
+<dt>Bind</dt>
+<dd><p>Connects an Interrupt ID to an Interrupt Service Routine. Unbind
+removes the connection.</p> </dd>
+</dlentry>
+<dlentry>
+<dt>Enable</dt>
+<dd><p>When an interrupt occurs, execute the associated Interrupt
+Service Routine.</p> </dd>
+</dlentry>
+</dl> </section>
+<section id="GUID-FE6584D8-C6E9-43F4-AF97-0DBBA0240E88-GENID-1-2-1-10-1-5-1-7-1-1-4-1-3-8"><title>The
+Interrupt class</title> <p>The interrupt interface is provided by
+functions of the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita"><apiname>Interrupt</apiname></xref> class. The class is
+defined in the <filepath>os/kernelhwsrv/kernel/eka/include/kernel/arm/assp.h</filepath> file. </p> </section>
+<section id="GUID-3D6816E8-2B1E-4709-81B5-D0A469A2A268"><title>Key
+users</title> <p>The key users of the Interrupt platform service are
+kernel and kernel-level device driver writers, and anyone who needs
+to specify code to be run when a system event occurs. </p> </section>
+<section id="GUID-FE6584D8-C6E9-43F4-AF97-0DBBA0240E88-GENID-1-2-1-10-1-5-1-7-1-1-4-1-3-10"><title>Limitations</title><ul>
+<li><p>The ISR needs to complete in short and finite time to prevent
+excessive interrupt latency.</p></li>
+<li><p>To keep ISRs short, most of the event processing should be
+delegated to a DFC. The DFC will execute in the context of a DFC thread
+allocated to itself by the device driver.</p></li>
+<li><p>It is safe to access the device driver objects using appropriate
+synchronization techniques such as spin-locks.</p></li>
+<li><p>The ISR should store critical data which may not be available
+later. </p></li>
+<li><p>Interrupts can happen in the middle of updating kernel heap
+free list or other non-atomic actions. ISRs must be coded with that
+in mind.</p></li>
+</ul><p>This means that ISRs cannot:</p><ul>
+<li><p>access user process memory.  This includes completing an asynchronous
+request.</p></li>
+<li><p>perform any allocation / de-allocation on heaps.  The current
+interrupt might have occurred when a heap operation is already in
+progress.</p></li>
+</ul><p>It is therefore necessary that ISRs must only use pre-allocated
+objects on the kernel heap.</p> </section>
+</conbody><related-links>
+<link href="GUID-862CA4C4-C6E8-4D60-8DD0-F3590C92E15D.dita"><linktext>Interrupt
+Client Interface</linktext></link>
+<link href="GUID-2E54DA7D-1094-41C6-AFB0-9999471991F8.dita"><linktext>Interrupt
+Implementation Guide</linktext></link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-F4E04E00-D9C6-5E8F-9EC6-F90BC951D4D0-master.png has changed
Binary file Adaptation/GUID-F4E04E00-D9C6-5E8F-9EC6-F90BC951D4D0_d0e63912_href.png has changed
Binary file Adaptation/GUID-F50E1C81-E80F-5692-996B-3AC2BE995425-master.png has changed
Binary file Adaptation/GUID-F50E1C81-E80F-5692-996B-3AC2BE995425_d0e39862_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F5430A12-D89D-4936-B846-E917B434F755.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F5430A12-D89D-4936-B846-E917B434F755" xml:lang="en"><title>Power management</title><shortdesc>Provides background information on power management.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody/></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F54BB3B5-D069-4524-A215-6F2CCA372666.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,65 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F54BB3B5-D069-4524-A215-6F2CCA372666" xml:lang="en"><title>Nanokernel
+Timer</title><shortdesc>This document describes nanokernel timers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-2788AEE3-FF4A-49CD-9093-00D28EEA49A6"><title>Creation</title> <p> <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita"><apiname>NTimer</apiname></xref> is
+a basic relative timer provided by the nanokernel. It can generate either
+a single interrupt or periodic interrupts. A timeout handler is called when
+the timer expires, either from the timer ISR or from the nanokernel timer
+thread. These timer objects can manipulated from any context. The timers are
+driven from a periodic system tick interrupt, usually a 1ms period. The use
+of <codeph>NTimer</codeph> is as follows: </p></section>
+<section id="GUID-AA99FC77-5D00-41C5-A000-A2692DB32B10"><title>Start</title> <p>The
+nanokernel timer can be used in either single mode or in periodic mode. Typically,
+the timer is started with <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita#GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2/GUID-0491D2BD-CF23-33A0-8531-28DD41AABE44"><apiname>NTimer::OneShot()</apiname></xref> for a timeout
+period and then is made periodic by calling <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita#GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2/GUID-F544F71E-3BB8-3570-A8DE-44009BBFFD3D"><apiname>NTimer::Again()</apiname></xref>.
+The timeout value specified for the timer is in nanokernel ticks. The time
+out callback function can be chosen to be called in either an ISR context
+or a DFC context (running in the kernel's nanokernel timer thread, called <codeph>DfcThread1</codeph>). </p> <codeblock id="GUID-680FD449-139A-57D2-AEC1-527E44ABC3AC" xml:space="preserve">TInt NTimer::OneShot(TInt aTime, TBool aDfc);
+// If aDfc is TRUE then, the timeout function is called in a DFC context; 
+// if aDfc is FALSE, the timeout function is called in a ISR context.
+
+// Starts timer in zero-drift mode, to avoid delays in re-queuing
+// the timer
+TInt NTimer::Again(TInt aTime); 
+
+// NTimer::OneShot() starts a nanokernel timer in one-shot mode with 
+// ISR callback. It queues the timer to expire in the specified number 
+// of nanokernel ticks. The actual wait time will be at least that 
+// much and may be up to one tick more. The expiry handler will be 
+// called in ISR context.
+//
+iRxPollTimer.OneShot(KRxTimeout);</codeblock></section>
+<section id="GUID-96D4B91A-580A-4D0C-BFA5-2FFDDA8DF12A"><title>Callback function </title> <p>The
+timeout callback function is called when a timer started with <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita#GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2/GUID-0491D2BD-CF23-33A0-8531-28DD41AABE44"><apiname>NTimer::OneShot()</apiname></xref> or <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita#GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2/GUID-F544F71E-3BB8-3570-A8DE-44009BBFFD3D"><apiname>NTimer::Again()</apiname></xref> expires.
+A driver should implement the function to process the timeout event as appropriate
+for the situation. </p> <codeblock id="GUID-68C267FE-87B0-5B68-AB6B-69BEBB77B1D9" xml:space="preserve">/**
+ Timer callback function. Called when the NTimer expires
+ typedef void(* NTimerFn)(TAny*); is the nanokernel timer callback
+ function. This is used for Rx timeout.
+
+ @params    aPtr
+         pointer refernce passed during timer initialization
+ */
+void DExUartPhysicalChannelH4::RxPollTimerCallback(TAny* aPtr)
+    {
+    ... // design specific
+    }</codeblock></section>
+<section id="GUID-3D2ED5C0-35AD-4695-8945-256B5866BF61"><title>Cancellation</title> <p>A
+timer can be cancelled using <xref href="GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2.dita#GUID-D8CF05A3-5C9B-3662-92DA-3290C6EE7FD2/GUID-F03A72CF-AD7F-363E-A351-8DA50416D949"><apiname>NTimer::Cancel()</apiname></xref>. It removes
+the timer object from the nanokernel timer queue. If the timer has already
+expired, or is inactive, then it does nothing. </p> <p>If a timer was queued
+and a DFC callback was requested, then the expiry handler might run even after <codeph>Cancel()</codeph> has
+been called. This occurs when the <codeph>DfcThread1</codeph> is preempted
+just before calling the expiry handler for this timer, and the preempting
+thread/ISR/IDFC calls <codeph>Cancel()</codeph> on the timer. </p></section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-F55A0CB4-0AB6-4DE3-9DFA-FBCB7131BB3A-master.png has changed
Binary file Adaptation/GUID-F55A0CB4-0AB6-4DE3-9DFA-FBCB7131BB3A_d0e98263_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F5DC77CD-4730-4FD8-A483-F5D22F34887E.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F5DC77CD-4730-4FD8-A483-F5D22F34887E" xml:lang="en"><title>IIC Client Interface</title><shortdesc>The basic steps to use the client interface of IIC.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The IIC client interface API provides the IIC bus interface functionality
+to the OS.</p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F60E5156-38B0-4781-8088-180E6716FC63.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F60E5156-38B0-4781-8088-180E6716FC63" xml:lang="en"><title>IIC Tutorials</title><shortdesc>The tutorials relating to the IIC platform service API.</shortdesc><prolog><metadata><keywords/></metadata></prolog></concept>
\ No newline at end of file
Binary file Adaptation/GUID-F67AFC0F-5245-48DE-8901-79461FB6EADE-master.png has changed
Binary file Adaptation/GUID-F67AFC0F-5245-48DE-8901-79461FB6EADE_d0e93180_href.png has changed
Binary file Adaptation/GUID-F67AFC0F-5245-48DE-8901-79461FB6EADE_d0e94068_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F67FA7B5-F6D1-5C5C-8E10-A8E317A778E4.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,178 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F67FA7B5-F6D1-5C5C-8E10-A8E317A778E4" xml:lang="en"><title>Public
+Functions</title><shortdesc>Describes how to implement the three exported functions of the
+platform-specific layer.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-C111DA06-F7EE-5E70-8D86-26BA2213B506"><title><codeph>InitialiseHardware()</codeph></title> <p>See
+the Template port (<filepath>os/kernelhwsrv/bsptemplate/asspandvariant/template_variant/bootstrap/template.s</filepath>)
+to see how this function is coded in practice. </p><p>The code can be found
+at the label: </p><codeblock id="GUID-A8AF4F2B-735C-56A7-A0F0-22861C7B25DB" xml:space="preserve">    ...
+    EXPORT    InitialiseHardware
+InitialiseHardware    ROUT
+    ...</codeblock> <p><b>Entry
+conditions</b> </p><p>This function is called immediately after reset with
+the CPU in supervisor mode, with all interrupts disabled, and <codeph>R12</codeph> pointing
+to the ROM header (a <xref href="GUID-DE701BC5-4AA8-345F-BDD5-5737DB8C0098.dita"><apiname>TRomHeader</apiname></xref> object). There is no valid
+stack on entry to this function, i.e. <codeph>R13</codeph> is undefined. </p><p><b>What the function should do</b> </p><p>The function is intended to perform
+the basic hardware initialisation that is required immediately after reset.
+It also sets up the address of the <xref href="GUID-9595FD6F-1EDE-51A8-B00D-029CFDFE0F38.dita">boot
+table</xref>. </p><p>In detail, it should: </p> <ol id="GUID-59A1A7B0-E06E-5C32-B860-E8B93C9CF66B">
+<li id="GUID-8993124C-D161-5BF6-9B1E-AE7A1ED2261C"><p>Initialise the CPU/MMU
+registers. This is done by making a call to the generic function <codeph>InitCpu()</codeph>,
+passing the address of the boot parameter table. For more information on the
+boot parameter table, see <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-4DEA1D4C-EC7B-5F9A-A293-A7F80899044B">BTF_Params</xref>,
+which is one of the <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita">boot
+table functions</xref>. </p> <p> <codeph>InitCpu()</codeph> flushes all caches,
+sets up the MMU control registers, and enables the instruction cache (on a
+split cache device). Note that <codeph>R14</codeph> needs to be preserved
+before making the function call. As there is no valid stack, R14 is typically
+saved in R13. </p> </li>
+<li id="GUID-D17DE836-C90C-5021-9A4B-BD9C9C047CB2"><p>Interrogate the hardware
+to determine the reset reason. In a transparent reset, all RAM contents are
+preserved and the reset should be invisible to the user, for example waking
+up from a low power mode such as the SA1110 sleep mode. In this case, perform
+whatever device-dependent sequence is required to restore the processor state,
+and jump back into the power down code: <codeph>InitialiseHardware()</codeph> will
+never return to the generic boot code. </p> <p>For bootloader bootstraps,
+if the reset reason is <i>power on reset</i> or <i>hardware cold reset</i>,
+or if it is a <i>software reset</i> and a rerun of the bootloader was requested
+(i.e. <codeph>Kern::Restart()</codeph> was called with a parameter value of <codeph>0x80000000</codeph>),
+then proceed to step 3. If these conditions are not true, for example when
+the reset reason is <i>software reset</i> with any other parameter value or
+a reset caused by waking up from a low power mode, then control should immediately
+be transferred to the image already loaded. The state of the system at the
+point where control is transferred should be as close as possible to the state
+immediately after reset, to provide proper conditions for the bootstrap in
+the already loaded image. </p> <p>If the system contains FLASH memory which
+can be programmed with a ROM image, an additional check may be needed to see
+if an image already present in FLASH should be run instead of the bootloader
+following a hardware reset. A spare switch on the board is often used for
+this purpose. </p> </li>
+<li id="GUID-E017D1A4-389C-54B1-A2CF-D5E42A36AF3A"><p>Initialise enough hardware
+to satisfy the rest of the bootstrap. The precise split between what is initialised
+here, what is initialised later in the bootstrap, and what is done during
+variant initialisation is flexible, but as an absolute minimum this function
+must make some RAM accessible. Typically this function should set up ROM and
+RAM controllers, set the CPU clock frequency, set sensible states for GPIO
+lines and set up whatever bus controller is necessary to communicate with
+any external peripheral chips present. Note also that it is often useful to
+allow the ROM image to run from either ROM or RAM - this is one of the main
+reasons for making the bootstrap position independent. To allow for this,
+the intialisation code must check the PC when setting up the memory controllers;
+if code is already running from RAM then RAM must already have been initialised
+and it may not be necessary to touch the RAM controller. </p> </li>
+<li id="GUID-17E0D947-0F65-587C-A05C-AFCB4784C5EF"><p>Determine the physical
+address of the super page. This will usually be at the beginning of physical
+RAM, unless there is a good reason for it not to be. The main reason why the
+super page might not be at the beginning of physical RAM is usually because
+either that address is reserved for hardware (e.g. video RAM), or that code
+is running from that address. <codeph>R10</codeph> should be loaded with the
+physical address determined. Note that, if it is not possible to determine
+the final address of the super page here, a temporary address can be used
+and the super page relocated to its final address later on. See <xref href="GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE.dita#GUID-B3F6FC45-3BF0-5F92-8325-44C705BA47AE/GUID-4C8986CB-0D5A-5D61-8A4B-DAC1B9D2C8B5">BTF_Alloc</xref> for more detail. </p> <p>The super page is defined by the <codeph>SSuperPageBase</codeph> struct
+in <filepath>os/kernelhwsrv/kernel/eka/include/kernel/kernboot.h</filepath>  </p> </li>
+<li id="GUID-D31E7F12-0E3E-5100-A2C8-1C0901743241"><p>Fill in valid values
+for the following minimum set of super page fields: </p> <ul>
+<li id="GUID-9EF8675B-56CD-5F22-A1BC-5DA7E8B9815D"><p> <codeph>iBootTable</codeph> should
+contain the address of the <xref href="GUID-9595FD6F-1EDE-51A8-B00D-029CFDFE0F38.dita">boot
+table</xref>. </p> </li>
+<li id="GUID-AEC1640A-D28E-5835-8300-093D5EE3BB8F"><p> <codeph>iCodeBase</codeph> should
+contain the base address of the bootstrap code. It is used to resolve offset
+addresses such as those in the boot table. </p> </li>
+<li id="GUID-00172B3D-94CE-519D-A560-1F54EAED3723"><p> <codeph>iActiveVariant</codeph> is
+the hardware variant discriminator (such as 05040001) for the hardware platform
+in use. It is used to find the corresponding primary (kernel) executable image. </p> </li>
+<li id="GUID-6A8D97CE-0B64-5F12-8220-695C64AEC0A3"><p> <codeph>iCpuId</codeph> should
+be set to the value of the CP15 main ID register, obtained by MRC P15, 0,
+Rd, C0, C0, 0. </p> </li>
+</ul> </li>
+<li id="GUID-CE64A7CA-E90E-5CC5-9993-C2CFCD7430D8"><p>The super page field <codeph>iMachineData</codeph> is
+used to communicate hardware-specific data between the bootstrap and the variant.
+It must be set to point to somewhere in the super page or CPU page. Typically,
+it points to the beginning of the CPU page. </p> </li>
+<li id="GUID-BD601948-A9E6-5111-8468-38183E507819"><p>The super page field <codeph>iHwStartupReason</codeph> is
+used to pass the detailed reset reason to the variant. It is a hardware specific
+value. </p> </li>
+<li id="GUID-968C3623-9C19-579B-BBB2-7DFEB73ED27B"><p>In debug builds of the
+bootstrap, as indicated by the symbol <codeph>CFG_DebugBootRom</codeph> being <codeph>TRUE</codeph>,
+the debug tracing port should be initialised here. See also <xref href="GUID-2E4F8732-F253-5E0D-9A37-9476541E6004.dita">Platform-Specific
+Configuration Header</xref>. </p> </li>
+<li id="GUID-022CAC0D-75E5-5D9F-A3DC-82CEEF62A2CC"><p>If Level 2 cache is
+included in the bootstrap (i.e. specifically L210 cache or L220 cache), then: </p> <ul>
+<li id="GUID-A4F41EF7-88D6-53CE-B09F-B26709CCEC93"><p>the function must initialise
+the cache. This involves setting cache properties: size, type, N-ways and
+cache invalidation. The following code is an example of L210 cache initialisation,
+but it is also valid for L220 cache initialisation: </p> <codeblock id="GUID-3290ED70-4A4B-5205-B8EE-7065E574B5A8" xml:space="preserve">;Configure L2 cache
+;-------------------
+    
+    LDR     r0, =L210CtrlBasePhys    ; Base phys. addr. of L210 Cache Controller
+    ;Set L210 Control Register 
+    
+    LDR r1, #L210CTRLReg        ; L210CTRLReg comes from Ref.Manual
+    STR r1, [r0, #0x104]  ; 104h is address offset of Control Register
+    
+    ;Invalidate entire L2 cache by way (8 ways are presumed)
+    MOV r1, #0xFF
+    STR r1, [r0, #0x77c]  ; 77Ch is address offset of InvalidateByWay Register
+    
+    ;Loop while invalidate is completed
+_L2loop
+    LDR r1, [r0, #0x77c]
+    CMP r1, #0    
+    BNE _L2loop
+</codeblock> </li>
+<li id="GUID-14AABD62-2C28-5858-BD8A-DD783EE60E2A"><p>the superpage field <xref href="GUID-0D646171-1989-39F0-A254-5B6D060D8C25.dita#GUID-0D646171-1989-39F0-A254-5B6D060D8C25/GUID-D0AD6575-8912-30E0-ADB8-17FB435290FF"><apiname>SSuperPageBase::iArmL2CacheBase</apiname></xref> must
+be set to the base physical address of the L2 cache control area, like in
+the following example: </p> <codeblock id="GUID-B52C68DF-F321-5F51-811A-A60765B6F3F9" xml:space="preserve">    ;Initialise SSuperPageBase::iArmL2CacheBase
+    ;------------------------------------------
+    LDR r0, =L210CtrlBasePhys    ; this is base physical address of L210 cache controller
+    STR r0, [r10, #SSuperPageBase_iArmL2CacheBase];r10 holds the base address of super page
+</codeblock> <p>Note that the superpage is defined by the <xref href="GUID-0D646171-1989-39F0-A254-5B6D060D8C25.dita"><apiname>SSuperPageBase</apiname></xref> struct
+in <filepath>os/kernelhwsrv/kernel/eka/include/kernel/kernboot.h</filepath>  </p> </li>
+</ul></li>
+</ol><p><b>Exit
+conditions</b> </p><p>The function can modify any CPU registers subject to
+the conditions that: </p><ul>
+<li id="GUID-CF4947C7-F581-51AF-A154-183516C29E2C"><p>it returns in supervisor
+mode with all interrupts disabled </p> </li>
+<li id="GUID-E9D9500E-347F-5A7F-A4A8-5F4DF1FAD4C8"><p>it returns the physical
+address of the super page in <codeph>R10</codeph>. </p> </li>
+</ul> </section>
+<section id="GUID-F8351937-F6F1-5CC0-A4F1-1EF05B155330"><title>Fault()</title> <p><b>Entry conditions</b> </p> <p>The processor state is completely undefined
+except that <codeph>R14</codeph> of the current mode points to the instruction
+after the fault. </p> <p><b>What
+the function should do</b> </p> <p>This function is called if a fatal error
+is detected during boot. </p> <p>The implementation should halt the system
+and produce whatever diagnostics are possible. Typically, if debug tracing
+is enabled, the CPU state can be dumped over the debug port. A generic function
+is provided to do this, as the minimal implementation is simply: </p> <codeblock id="GUID-B1266ACD-6862-5074-B684-9A9D764B6842" xml:space="preserve">        EXPORT Fault
+Fault    ROUT
+        B BasicFaultHandler ; generic handler dumps registers via
+                            ; debug serial port
+</codeblock> </section>
+<section id="GUID-BC227FC6-8F59-5CE2-8970-A287A2CD1AEE"><title>RestartEntry()</title> <p><b>Entry conditions</b> </p> <p>On entry the CPU state is indeterminate,
+as the restart may be caused by a kernel fault, with the exception that <codeph>R0</codeph> contains
+the reboot reason, the parameter passed to <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-936EA5BE-DBBE-3298-9F77-0384886E058A"><apiname>Kern::Restart()</apiname></xref>. </p> <p>This
+value is hardware specific except for the following two values: </p> <ul>
+<li id="GUID-7414830B-7758-5834-A47F-13A674D11443"><p> <codeph> 0x00000000</codeph> means
+restart the same ROM image, preserving RAM contents if possible. </p> </li>
+<li id="GUID-0A55988A-FF04-55E0-99A7-E73C7F2433C3"><p> <codeph>0x80000000</codeph> means
+restart the boot loader and load a new image. This code is generated by the
+crash debugger in response to the <xref href="GUID-08E14B34-5144-5AA8-AA55-7AF03671676C.dita#GUID-08E14B34-5144-5AA8-AA55-7AF03671676C/GUID-4E12A080-AC83-5872-A66D-4C14A65C5CFA">X
+command</xref> of the crash debugger. </p> </li>
+</ul> <p><b>What
+the function should do</b> </p> <p>The function is called by the kernel when
+a system restart is required, and should perform whatever actions are necessary
+to restart the system. If possible, a hardware reset should be used. Failing
+that, it should reset all peripheral controllers and CPU registers, disable
+the MMU and jump back to the reset vector. </p> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F6E83530-3F8E-5930-8C6C-4D58B675E67A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F6E83530-3F8E-5930-8C6C-4D58B675E67A" xml:lang="en"><title>Digitizer
+Driver Technology</title><shortdesc>Describes how screen coordinates work with the Digitizer Driver.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The digitizer hardware provides coordinate values that are digitized raw
+voltage values. These values are not the same as screen coordinates, which
+are based on pixel positions. The digitizer converts the raw values into screen
+coordinates and vice-versa. </p>
+<p>Screen coordinates always have their origin at the top left hand corner
+of the screen, but the digitizer has no such constraint - its origin, orientation
+and scaling are generally different from the screen coordinate system. This
+means that the digitizer needs to be calibrated so that digitizer coordinates
+can be translated to screen coordinates. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F7249C66-B62F-45DF-B733-BC6D5FCDA003.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F7249C66-B62F-45DF-B733-BC6D5FCDA003" xml:lang="en"><title>Completion and Notification</title><shortdesc>This document describes how a device driver notifies completion
+of an asynchronous request.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>On completion of the request, the driver calls <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-D720BB4C-5E31-3213-BB16-859AA325FE98"><apiname>Kern::RequestComplete()</apiname></xref>,
+passing the <codeph>TRequestStatus</codeph> object and completion error code,
+to notify the request completion to the user. This API internally sets the
+passed error code in the <codeph>TRequestStatus</codeph> object. It also signals
+the client's thread semaphore. </p>
+<codeblock id="GUID-D6016CEF-C1F8-5743-97E3-E0E9E2C92547" xml:space="preserve">void DExDriverLogicalChannel::DoTxDataComplete()
+    {
+    ...
+    // Notify the client (iClient) that the request is completed. The  
+    // TRequestStatus object is updated with the status and the 
+    // completion code is provided to the client. Typically, the client 
+    // thread, waiting using User::WaitForRequest(TRequestStatus 
+    // &amp;aStatus) or the active object framework, is unblocked and 
+    // notified. Then the client may read the request status from the 
+    // TRequestStatus object.
+    // 
+    Kern::RequestComplete(iClient,iTxDataStatus,iTxResult);
+    }</codeblock>
+<p>The user retrieves the result of the request by calling <xref href="GUID-8005774C-A9AA-3335-B918-51190A125134.dita#GUID-8005774C-A9AA-3335-B918-51190A125134/GUID-BC53014D-0801-3168-9FDE-9D5897A7AA8A"><apiname>TRequestStaus::Int()</apiname></xref>. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F75F975B-A490-4EB5-96CD-B2F8DFC63C7C.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F75F975B-A490-4EB5-96CD-B2F8DFC63C7C" xml:lang="en"><title>Asynchronous
+Requests</title><shortdesc>This document describes how device drivers use asynchronous requests.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-834B2C34-5C8B-4D6D-85F3-FADD357AD330">             <p>An
+asynchronous request is one which is used, typically, to communicate with
+the hardware itself. The time taken for such a request to complete depends
+on the hardware, and the client user-side thread may want to continue with
+some other processing.  The user-side thread is not blocked and can continue
+with other operations, including issuing other requests (synchronous or asynchronous).</p> <p>An
+asynchronous request is started by a call to <xref href="GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066.dita#GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066/GUID-FCC4A3A9-69F5-3947-8D0F-2AD12086F1E2"><apiname>RBusLogicalChannel::DoRequest()</apiname></xref>.
+Control normally returns as soon as the request has been issued, successfully
+or otherwise. Typically, the hardware indicates completion of an operation
+by generating an interrupt. This is handled by an Interrupt Service Routine
+(ISR) provided by the driver. This, in turn, schedules a DFC, which at some
+later time, runs in the context of a kernel-side thread, and signals the client-user
+side thread, marking the asynchronous request as complete. </p> <p>More than
+one asynchronous request can be outstanding at the same time, each one associated
+with its own <xref href="GUID-E0B34F3E-D4C4-3232-B8B1-7DB35B454646.dita"><apiname>TRequestStatus</apiname></xref> object and each identified
+by a specific request number. The device driver framework puts no explicit
+limit on the number of concurrent outstanding asynchronous requests; any limit
+must be enforced by the driver itself. However, the API to cancel a request
+implicitly prevents you from uniquely identifying more than 32 concurrent
+requests. </p> <p>An outstanding asynchronous request can be cancelled by
+a call to <xref href="GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066.dita#GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066/GUID-16E139F5-4473-33C0-BCDD-A92152D4E8E6"><apiname>RBusLogicalChannel::DoCancel()</apiname></xref>. </p>     </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-F7ABA3C6-60DD-4AE1-916B-BE2BCF6285CE-master.png has changed
Binary file Adaptation/GUID-F7ABA3C6-60DD-4AE1-916B-BE2BCF6285CE_d0e89266_href.png has changed
Binary file Adaptation/GUID-F7ABA3C6-60DD-4AE1-916B-BE2BCF6285CE_d0e91217_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F84E18B8-5883-5A3A-A9DB-EC25BB86149F.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F84E18B8-5883-5A3A-A9DB-EC25BB86149F" xml:lang="en"><title>Timers</title><shortdesc>The kernel implements timing functions using a 1 millisecond
+tick timer.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> The phone hardware must therefore provide a high-speed timer that
+can provide regular 1 ms interrupts. The ASSP/Variant part of the
+base port must use this timer hardware to call the kernel every millisecond. </p>
+<p>The base port provides the timer service in an interrupt-service
+routine called a tick handler. The functions used for this are as
+follows: </p>
+<ul>
+<li id="GUID-6CFD0FFF-9D8D-5FBC-867C-88933476D896"><p>The tick handler
+must be started by the Variant's implementation of the <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita#GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D/GUID-FE55E398-7F08-384F-9E74-2CC2E45002B6"><apiname>Asic::Init3()</apiname></xref> function. </p> </li>
+<li id="GUID-9F148C98-2FA8-529D-A0E8-DB5A4705E063"><p>The tick handler
+calls the kernel's <xref href="GUID-C4EB9F55-9A40-3B4D-B90A-FD39A5E68AE1.dita#GUID-C4EB9F55-9A40-3B4D-B90A-FD39A5E68AE1/GUID-BC7CAC2D-97F2-3B82-AF80-7F8535315052"><apiname>NTImer::TickQ()</apiname></xref> function. </p> </li>
+<li id="GUID-DC16C15E-221B-5945-9F5A-349FAD35921D"><p>The Variant
+reports the exact number of microseconds between ticks in its implementation
+of <xref href="GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D.dita#GUID-A83A7C3C-7DC0-3B9C-842F-70FCC751365D/GUID-6EAD3751-9F37-3C1B-9910-678A286D80E9"><apiname>Asic::MsTickPeriod()</apiname></xref>. </p> </li>
+</ul>
+<p>The ASSP/Variant must decide how to implement a repeating tick
+interrupt for the hardware available. Typically this involves using
+either a free running timer with a match register, which is reset
+on each match, or a self-reloading countdown timer, to generate a
+periodic interrupt. </p>
+<p>A base port can implement other timers that are required by peripherals
+that have sub-millisecond timing requirements. This is optional, and
+depends on the available hardware. </p>
+</conbody><related-links>
+<link href="GUID-E0DCBDCF-C056-53E5-A375-778327F848E4.dita#GUID-E0DCBDCF-C056-53E5-A375-778327F848E4/GUID-F5275882-BBD0-561F-B617-683AA2004BB9">
+<linktext>Asic::Init3()                 implementation</linktext></link>
+<link href="http://developer.symbian.org/wiki/index.php/Symbian_OS_Internals/5._Kernel_Services" scope="external"><linktext>Symbian OS Internals - Chapter 5.5 Timers</linktext>
+</link>
+</related-links></concept>
\ No newline at end of file
Binary file Adaptation/GUID-F8A32666-5003-5B14-A700-C6E6388D2D38-master.png has changed
Binary file Adaptation/GUID-F8A32666-5003-5B14-A700-C6E6388D2D38_d0e63938_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F8B8C030-B5E1-5EB3-A672-83BF35555801.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F8B8C030-B5E1-5EB3-A672-83BF35555801" xml:lang="en"><title>halcfg.pl
+Syntax</title><shortdesc><filepath>halcfg.pl</filepath> is a Perl script that is used by
+the build system to generate the C++ source files from the Config and Values
+files. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p> </p>
+<p>There are four modes in which the Perl script <codeph>halcfg.pl</codeph> can
+be used. </p>
+<ul>
+<li id="GUID-9EABDCC1-4C8A-5850-9631-0FC96CCC50F8"><codeblock id="GUID-4E07A1C2-DAD6-5603-BD1B-6FECE39B419D" xml:space="preserve">perl halcfg.pl hal_data.h values.hda values.cpp</codeblock> <p>takes the <filepath>values.hda</filepath> text file and generates a table
+of initial values for items stored by the HAL. </p> </li>
+<li id="GUID-04ABED61-2606-50DF-AD74-C80A12F0692F"><codeblock id="GUID-38B36C83-FCDF-597B-B73D-F6A2CE8CC3D9" xml:space="preserve">perl halcfg.pl -x hal_data.h config.hcf config.cpp</codeblock> <p>generates three tables: </p> <ul>
+<li id="GUID-054BE9E6-8582-527E-BEA3-FED29CD9DFD3"><p>the properties, i.e.
+whether valid and/or writable, for each item </p> </li>
+<li id="GUID-0D4A169F-4E5D-5569-9D77-CA45E94402D4"><p>the offset of each item
+within the <codeph>DllGlobal</codeph> block </p> </li>
+<li id="GUID-28AF093B-5D68-57CF-900B-206F29F67003"><p>the function implementing
+each item, for derived attributes (i.e. those attributes that are not simply
+stored by the HAL. </p> </li>
+</ul> </li>
+<li id="GUID-82EDD6DB-9256-560B-8400-39789B02504D"><codeblock id="GUID-495F247E-1ED9-533A-9780-8D328E3499D7" xml:space="preserve">perl halcfg.pl -s hal_data.h config.hcf source.cpp</codeblock> <p>generates a source file containing skeleton code for the implementation
+of the accessor function for each derived attribute </p> </li>
+<li id="GUID-33E34298-1367-5FBC-B582-37EB413345AF"><codeblock id="GUID-B291494F-3D32-5A32-A775-3425E4F1750A" xml:space="preserve">perl halcfg.pl -h hal_data.h config.hcf header.h</codeblock> <p>generates a header file containing prototypes for the accessor functions
+for each derived attribute </p> </li>
+</ul>
+<p>Note that the header file <filepath>hal_data.h</filepath> containing the
+attributes and values used by the HAL is passed on all calls to the Perl script. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F8BD699A-E926-5434-9F35-3DC6DC9FFBB6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,43 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F8BD699A-E926-5434-9F35-3DC6DC9FFBB6" xml:lang="en"><title>Build</title><shortdesc>This topic describes how to include the ported driver in
+a ROM.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The USB client driver, <filepath>EUSBC.LDD</filepath>, and the
+USB client controller, <filepath>USBCC.DLL</filepath> (the PDD) and
+any other required component (a USB transceiver DLL) must be added
+to the ROM image by adding suitable definitions to the ROM <filepath>.oby</filepath> files. In the template port add definitions to two
+files: </p>
+<ul>
+<li id="GUID-864989F1-76E7-5F34-99E4-FB8534DB9D3C"><p>the <filepath>kernel.iby</filepath> file in <filepath>...\template_variant\rom\</filepath>, if building a text-shell ROM image; it contains the lines: </p> <codeblock id="GUID-8DE82039-4C0E-542F-8ADB-A9934F454C9B" xml:space="preserve">// USB Client
+device[VARID]=        \Epoc32\Release\##KMAIN##\##BUILD##\USBC.LDD                    \sys\bin\EUSBC.LDD
+// USB Device Driver
+extension[VARID]=    \Epoc32\Release\##KMAIN##\##BUILD##\_##VARIANT##_USBCC.DLL        \sys\bin\USBCC.DLL
+</codeblock> </li>
+<li id="GUID-D1C9E3F8-C6C1-5DF5-9865-047E7DA859B3"><p>the <filepath>base_template.iby</filepath> file in <filepath>...\template_variant\rom\</filepath>, if building a full ROM image; it contains the lines: </p> <codeblock id="GUID-C1D03A4A-919A-574F-B5FA-EA211993B9B4" xml:space="preserve">// USB Drivers
+extension[VARID]=KERNEL_DIR\DEBUG_DIR\_template_usbcc.dll                \sys\bin\usbcc.dll
+device[VARID]=    KERNEL_DIR\DEBUG_DIR\usbc.ldd                            \sys\bin\eusbc.ldd
+</codeblock> </li>
+</ul>
+<p>Add the command line test applications. This can be done in a special
+purpose <filepath>.oby</filepath> file which is used to create the
+text shell, test ROM image: </p>
+<codeblock id="GUID-4C906093-24A2-5407-BA2A-415E2646B1B7" xml:space="preserve">FILE=/EPOC32/RELEASE/ARMV5/UREL/T_USB.EXE    SYS\BIN\T_USB.EXE 
+FILE=/EPOC32/RELEASE/ARMV5/UREL/T_USBAPI.EXE    SYS\BIN\T_USBAPI.EXE 
+</codeblock>
+<note> Both these test applications are also pulled in by default
+by the standard <filepath>e32tests.oby</filepath> file.</note>
+<p>The macro <codeph>EUSBC</codeph> needs to be defined
+for the base port to pull in the user-mode components (e.g. <codeph>USBMan</codeph>) for a full ROM image. For template, this is done
+in <filepath>...\template_variant\template.oby</filepath>: </p>
+<codeblock id="GUID-42001655-A282-5804-9ACB-04520AA96231" xml:space="preserve">REM Define whether or not to include USB client support:
+#define EUSBC</codeblock>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F8E8CCB1-E239-5285-BA99-48E2168C9E31.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F8E8CCB1-E239-5285-BA99-48E2168C9E31" xml:lang="en"><title>Reference</title><shortdesc>Provides a summary of related documentation for the Serial Port
+Driver to which you can refer.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-E72EF589-A3D3-5E32-9029-6BBB8CC5F442"><title>API Reference</title><p>Kernel
+Architecture</p><table id="GUID-D9A0ED50-EDF2-5578-A554-A8DE9B063B86">
+<tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
+<tbody>
+<row>
+<entry><p> <b>Item</b>  </p> </entry>
+<entry><p> <b>Header</b>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-AC009E73-628B-365F-898C-B9E8E01944E5.dita"><apiname>DComm</apiname></xref>  </p> </entry>
+<entry><p> <filepath>comm.h</filepath>  </p> </entry>
+</row>
+<row>
+<entry><p> <xref href="GUID-2D987113-17F8-3A19-8D93-17F21135C27C.dita"><apiname>TStopMode</apiname></xref>  </p> </entry>
+<entry><p> <filepath>comm.h</filepath>  </p> </entry>
+</row>
+</tbody>
+</tgroup>
+</table> </section>
+<section id="GUID-92A19BDD-421C-4810-B2B0-3AAAD3A058F8"><title>Engineering Specifications</title><p>No specifications are
+published. </p></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F9051D21-3E4C-4645-BD04-06606E849AEF.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F9051D21-3E4C-4645-BD04-06606E849AEF" xml:lang="en"><title>Interrupt Interface Overview</title><shortdesc>Provides a summary of the Interrupt platform service interface.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Interrupt interface is provided by functions of the <xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita"><apiname>Interrupt</apiname></xref> class. The class is defined in the <filepath>os/kernelhwsrv/kernel/eka/include/kernel/arm/assp.h</filepath> file.
+The <codeph>Interrupt</codeph> class functions must be implemented
+by the baseport variant to enable device drivers and other kernel
+side code to handle the interrupts.</p>
+<section id="GUID-77EF021F-41F9-4126-A8C6-B93885B64C27">         
+   <title>Interrupt handling functions</title>   <table id="GUID-08A082CA-81EA-4B50-8901-BE0DB06093EA">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-B594B453-899D-3066-9E45-A9A1AE54CAE4"><apiname>Interrupt::Bind(TInt anId, TIsr anIsr, TAny* aPtr)</apiname></xref></entry>
+<entry>Allows an Interrupt Service Routine (ISR) to be associated
+with a specified interrupt ID in the <codeph>anId </codeph> parameter.</entry>
+</row>
+<row>
+<entry><xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-AE029812-8220-3970-80F6-6322B9D933BC"><apiname>Interrupt::Unbind(TInt anId)</apiname></xref></entry>
+<entry>Unbinds an ISR from a specified interrupt ID.</entry>
+</row>
+<row>
+<entry><xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-A0D94710-E832-36F9-B324-823BFA537C2E"><apiname>Interrupt::Enable(TInt anId)</apiname></xref></entry>
+<entry>Enables a specified interrupt to be active and allows the associated
+ISR to handle the interrupts.</entry>
+</row>
+<row>
+<entry><xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-410A0ED1-CA83-396C-921B-766C4D0BEFF6"><apiname>Interrupt::Disable(TInt anId)</apiname></xref></entry>
+<entry>Disable a specified interrupt.</entry>
+</row>
+<row>
+<entry><xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-63C93F0D-F236-35D0-8E21-9FF1F96074B3"><apiname>Interrupt::Clear(TInt anId)</apiname></xref></entry>
+<entry>Clears the interrupt pending condition in the interrupt controller
+hardware.</entry>
+</row>
+<row>
+<entry><xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-CD40CF24-7732-34FB-8FA1-34E0DCB9B474"><apiname>Interrupt::SetPriority(TInt anId, TInt aPriority)</apiname></xref></entry>
+<entry>Change the priority of a specified interrupt.</entry>
+</row>
+<row>
+<entry><xref href="GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3.dita#GUID-E7A7083C-97B9-39B9-A147-4A6E314EE3A3/GUID-C46E48EE-6F4A-3A61-A3C9-84B145119541"><apiname>Interrupt::AddTimingEntropy()</apiname></xref></entry>
+<entry>Adds high resolution timestamp to the interrupt. This function
+should be called by the device driver where the timing of the interrupts
+are considered to be random. </entry>
+</row>
+</tbody>
+</tgroup>
+</table> <p>The header file for the Interrupt platform service can
+be found <xref href="http://developer.symbian.org/xref/oss/xref/MCL/sf/os/kernelhwsrv/kernel/eka/include/kernel/arm/assp.h.dita">here</xref>.</p>        <note> The Interrupt platform service is
+only used to associate an interrupt with an ISR. The Interrupt platform
+service is not used to dispatch interrupts.</note></section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-F9558573-7C79-57C5-809A-9257BF84758A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,65 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-F9558573-7C79-57C5-809A-9257BF84758A" xml:lang="en"><title>Architecture</title><shortdesc>This topic describes the architecture of keyboard drivers
+and related components.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>This topic describes the architecture of keyboard drivers and related
+components on Symbian platform. </p>
+<p>There are five components involved in this process: </p>
+<ul>
+<li id="GUID-0C41EB6F-3AD4-5B89-863E-EA7E108C73C9"><p> <i> The keyboard
+hardware</i>. </p> </li>
+<li id="GUID-F965ADEC-3367-509F-A1B2-C5A5613410F6"><p> <i> A keyboard
+device driver</i>. </p> <p>The keyboard driver is implemented as a
+standard kernel extension, and is loaded by the kernel at boot time.
+A keyboard driver must be implemented in the base port, and has no
+platform independent parts. </p> </li>
+<li id="GUID-CBF257DE-AB08-5B96-AC15-E9981EA3484D"><p> <i>A keyboard
+mapping DLL</i>. </p> <p>A keyboard mapping DLL provides a set of
+lookup tables that map codes for the hardware keys to standard logical
+keycodes that user-side applications can process. </p> <p>The DLL
+is platform specific. It must be implemented in the base port, and
+has no platform independent parts. It is usually called <filepath>ekdata.dll</filepath>. </p> </li>
+<li id="GUID-52F97FEE-9B5B-5046-BF0C-EF1E4E2EB2BC"><p> <i>The Window
+Server</i>. </p> <p>The Window Server is a system server that manages
+access to the screen and input devices for user-side programs. </p> </li>
+<li id="GUID-216989CD-45CE-5F59-831B-03B49BE4E73D"><p> <i>The keyboard
+translator</i>. </p> <p>The keyboard translator DLL translates scancodes
+into keycodes using the data in the platform specific keyboard mapping
+DLL. </p> <p>It is part of Symbian platform generic code and is built
+as part of the Text Window Server component. </p> </li>
+</ul>
+<p>The following diagram shows how these components fit together and
+gives an overview of the data flow. </p>
+<fig id="GUID-D05ABF3B-3A1D-5F02-B268-FC1A992EE4DB">
+<title>Overview of data flow</title>
+<image href="GUID-9CC514E9-85C2-5F4B-9F3B-F9FA1F4CB20A_d0e14358_href.png" placement="inline"/>
+</fig>
+<p>Depending on the keyboard hardware, key presses in the form of
+key-down and key-up events are registered by the keyboard driver,
+either as a result of hardware interrupts, or as a result of polling
+the hardware. The driver assigns a standard scancode value to the
+key. This is one of the values defined by the <xref href="GUID-4D92CE24-E651-3584-BDE0-F26046B4175B.dita"><apiname>TStdScanCode</apiname></xref> enum. The value is a representation of the hardware key. </p>
+<p>The driver creates <xref href="GUID-668CEA36-3933-3BBE-A980-CAB62617B4FD.dita"><apiname>TRawEvent</apiname></xref> objects, of type <xref href="GUID-668CEA36-3933-3BBE-A980-CAB62617B4FD.dita#GUID-668CEA36-3933-3BBE-A980-CAB62617B4FD/GUID-ED6DCE25-227F-3353-8BE8-1C8F735198A8"><apiname>TRawEvent::EKeyUp</apiname></xref> and <xref href="GUID-9398BE98-2C09-333C-97D3-EFAD86400F8F.dita"><apiname>TRawEvent:EKeyDown</apiname></xref>, and includes the standard scancode value and modifiers as part
+of the object. These objects are added to the kernel's event queue,
+using the <xref href="GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D.dita#GUID-C6946ECB-775F-3EC2-A56F-78F25B9FBE3D/GUID-81C82FED-0E26-351A-901E-806843C808FE"><apiname>Kern::AddEvent()</apiname></xref> function. </p>
+<p>The Window Server captures these events and passes the scancode
+value to <filepath>ektran.dll</filepath>, which has the responsibility
+for translating this value into a keycode value. A keycode value is
+a logical representation of the key; it is this logical representation
+that has meaning for the generic Symbian platform. The logical keycode
+is one of the values defined by the <xref href="GUID-B67B6ED5-6C8F-3B36-934C-B47A109A515F.dita"><apiname>TKeyCode</apiname></xref> enum.
+Also, <filepath>ektran.dll</filepath> tells the Window Server whether
+a capture key has been pressed - this is explained in <xref href="GUID-110DB7EF-5E85-5BC4-9BBB-9A37B2D0C3A6.dita">Dynamic Behaviour</xref>. </p>
+<p> <filepath>ekdata.dll</filepath> encapsulates a set of tables that
+are used to map hardware scancodes to logical keycode values. This
+is platform specific code, and is used by the generic <filepath>ektran.dll</filepath> when doing the translation. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-FA026EBD-7867-4A2C-9FA4-EC70A5243526.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,193 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE task
+  PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
+<task id="GUID-FA026EBD-7867-4A2C-9FA4-EC70A5243526" xml:lang="en"><title>Transferring Data with DMA</title><shortdesc>Explains how to transfer data using DMA.</shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody>
+<prereq id="GUID-FCC97364-77B5-4AB9-AEBD-0F63500A522D"><p>The client
+will typically have a DMA class containing pointers to:</p><ul>
+<li><p>a <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref> object, </p> </li>
+<li><p>one or more <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita"><apiname>DDmaRequest</apiname></xref> objects, </p></li>
+<li><p>a <xref href="GUID-E675237D-0D05-30A3-9B82-DDD3D0F41E79.dita"><apiname>TDfcQueue</apiname></xref> object, and</p></li>
+<li><p>a callback which returns when the data transfer completes (successfully
+or not).</p></li>
+</ul><p>These classes are discussed in <xref href="GUID-D5ED62EB-744D-42EB-B8CF-D5623BDA5B38.dita">DMA OS Interface</xref>.</p></prereq>
+<context id="GUID-EAC78622-0692-4FBE-81FE-553F838A77DD"><p>To allow
+a client application to receive or transmit a block of data by DMA
+you set up a transfer between a source or a destination buffer and
+a source or a destination peripheral. Data is copied between the client
+process and kernel memory by IPC form data transfer between two buffers.
+When a shared chunk or a shared data buffer is used, copying of data
+to kernel memory is required. At the level of implementation there
+is no difference between receiving and transmitting. Client drivers
+using DMA sometimes have separate receive and transmit functions defined
+from the driver point of view.</p><p>You transfer data in this sequence:</p><ul>
+<li><p>Open a DMA channel.</p></li>
+<li><p>Fragment the data if necessary.</p></li>
+<li><p>Queue the transfer.</p></li>
+<li><p>Close the channel.</p></li>
+</ul><p>Example code in this tutorial is taken from the <xref href="GUID-8CC3B265-C29E-3FDB-ACE8-ACC49B9E69D5.dita"><apiname>DMemoryCardDma</apiname></xref> class which transfers data to and from MMC cards by DMA.</p></context>
+<steps id="GUID-4DD07DEC-6017-4237-BE46-1D69E5FBD744-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-7-1-3-3">
+<step id="GUID-9A69E5AD-E938-4092-A8C2-CB65C37C8962-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-7-1-3-3-1"><cmd>Initialize
+the client object by allocating a request and setting buffers.</cmd>
+<info><codeblock xml:space="preserve">     //pre-allocate space for DDmaRequest
+     iDMARequest = (DDmaRequest*)Kern::AllocZ(sizeof(DDmaRequest));       
+ 
+     // Check Buffer Length
+     if (aBuffLen)
+         {
+         // Set Buffer Start
+         iBufferStart = (TUint32)aBuffer;
+         // Set Buffer End
+         iBufferEnd   = iBufferStart + aBuffLen;
+         // Set DFC Queue
+         iDfcQue      = aDfcQue;
+ 
+         return KErrNone;
+         }
+</codeblock></info>
+<stepresult>The client object is now initialized.</stepresult>
+</step>
+<step id="GUID-9A69E5AD-E938-4092-A8C2-CB65C37C8962-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-7-1-3-3-2"><cmd>Open the
+channel by creating an <xref href="GUID-4057074E-2543-3F01-B24A-7FF8A19F79AF.dita"><apiname>SCreateInfo</apiname></xref> object and initializing
+it as follows:</cmd>
+<substeps id="GUID-53B21565-D779-4B76-A8BA-8C9059CB15B4">
+<substep id="GUID-3620E00A-FDE2-4EA3-9FB2-9D67AD0370AC"><cmd>Set the <xref href="GUID-B05C7976-F917-3CFC-9979-86FAC864CB4E.dita"><apiname>iCookie</apiname></xref> member to a platform specific channel identifier.</cmd>
+</substep>
+<substep id="GUID-1890DE64-D53B-4003-9419-ECC778D663FB"><cmd>Set the <xref href="GUID-84246C3A-C8C9-3839-B8C1-8BF05C826338.dita"><apiname>iDesCount</apiname></xref> member to the number of descriptors the channel
+can use.</cmd>
+<info><p>The value should be set to a value based on number of simultaneous
+transfers, transfer length and type of memory used for transfer. If
+you select too high a value, no descriptors will be left for other
+clients, and if you select too low a value the transfer may fail. </p></info>
+</substep>
+<substep id="GUID-FF5BB11D-C922-47A1-ADB8-1A7321C0931F"><cmd>Set the <xref href="GUID-D9C831A3-4841-3E4F-BFEC-8D3997BEEFFF.dita"><apiname>iDfcPriority</apiname></xref> member to the DFC priority. </cmd>
+</substep>
+<substep id="GUID-F1D4A3C1-6E81-4FA4-99D0-E127FCD2C004"><cmd>Set the <xref href="GUID-EC191BDB-5C89-3359-9C45-748C96EF08C1.dita"><apiname>iDfcQueue</apiname></xref> member to the client class queue: it will be
+used to service transfer completion events.</cmd>
+</substep>
+</substeps>
+<stepxmp><codeblock xml:space="preserve">     // Open and configure the channel
+     if (!iDMAChannelOpen)
+         {
+         if (!iDfcQue)
+             return KErrGeneral;
+ 
+         TDmaChannel::SCreateInfo info;
+ 
+         info.iCookie = (TUint32)iChannelId;
+         info.iDesCount = 3;
+         info.iDfcPriority = 3;
+         info.iDfcQ = iDfcQue;
+ 
+</codeblock></stepxmp>
+<stepresult>The channel is now initialized.</stepresult>
+</step>
+<step id="GUID-9A69E5AD-E938-4092-A8C2-CB65C37C8962-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-7-1-3-3-3"><cmd>Pass the <xref href="GUID-4057074E-2543-3F01-B24A-7FF8A19F79AF.dita"><apiname>SCreateInfo</apiname></xref> object and a channel ID to the <xref href="GUID-20D0D10F-3401-3F72-8AF6-DC35F6025DC2.dita"><apiname>Open()</apiname></xref> function of <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref> to open a DMA channel.</cmd>
+<info><p> This is not necessary if the channel is already open due
+to a previous transfer request by the same application on the same
+channel.</p></info>
+<stepxmp><codeblock xml:space="preserve">         // Open DMA Channel
+         r = TDmaChannel::Open(info, iDMAChannel);
+ 
+         if (r)
+             return r;
+ 
+         // Set DMA Channel Open
+         iDMAChannelOpen = ETrue;
+</codeblock></stepxmp>
+<info>At what point you open the channel depends on platform configuration.
+If a channel is dedicated to a particular function such as USB, it
+is typically opened by the channel constructor method and closed by
+the destructor as there is never any contention for it. In other cases,
+you must open the channel at the start of a transfer and close it
+at the end.</info>
+<stepresult>The channel is now open.</stepresult>
+</step>
+<step id="GUID-9A69E5AD-E938-4092-A8C2-CB65C37C8962-GENID-1-2-1-10-1-5-1-5-1-1-7-1-9-1-7-1-3-3-4"><cmd>Call the <xref href="GUID-27816E89-D612-30BE-BC4B-50B892223918.dita"><apiname>Fragment()</apiname></xref> function of <xref href="GUID-780F4D53-5546-3B69-B328-0226C70EBDE2.dita"><apiname>DDmaRequest</apiname></xref> to
+fragment the data.</cmd>
+<info>:If your buffers are cacheable you must flush them before a
+write transfer and both before and after a read transfer, using these
+functions of the <xref href="GUID-4425E698-EE8A-369B-92CD-09B1CBD2911F.dita"><apiname>Cache</apiname></xref> class:<ul>
+<li><p><codeph>Cache::SyncMemoryBeforeDmaWrite()</codeph> (takes source
+buffer as argument)</p></li>
+<li><p><codeph>Cache::SyncMemoryBeforeDmaRead()</codeph> (takes destination
+buffer as argument)</p></li>
+<li><p><codeph>Cache::SyncMemoryAfterDmaRead()</codeph> (takes destination
+buffer as argument)</p></li>
+</ul></info>
+<stepresult>The data is now fragmented.</stepresult>
+</step>
+<step id="GUID-99DC4339-5C3E-42AC-BE71-5FED662A6C3A"><cmd>Call the <xref href="GUID-78F37FB6-1286-39CD-80A5-24DA9F27A9AF.dita"><apiname>Queue()</apiname></xref> function of <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref> to queue
+the data on the channel.</cmd>
+<stepxmp><codeblock xml:space="preserve">     TInt retval = KErrNone;
+ 
+     if (iDMABusy)
+         {
+         if (iDMAChannel)
+             {
+             iDMAChannel-&gt;CancelAll();
+             }
+         }
+ 
+     iDMABusy = ETrue;
+ 
+     iDMAReadStarted = EFalse;
+ 
+     if (!iDMAChannelOpen)
+         {
+          retval = Open();
+         }
+ 
+     if (iDMAChannelOpen)
+         {
+         iDMADestination = aDest;
+         iDMACount       = aCount;
+ 
+         // aDest cached, ivalidate RAM
+         Cache::SyncMemoryBeforeDmaRead(aDest, aCount);
+         retval = iDMARequest ? iDMARequest-&gt;Fragment(EDmaSDMMC, aDest, aCount, KDmaMemDest | KDmaIncDest, 0 /* no HW Flags*/) : KErrGeneral;
+ 
+         if (retval)
+             {
+            return retval;
+             }
+ 
+         iDMAReadStarted = ETrue;
+         if (iDMARequest)
+             {
+             iDMARequest-&gt;Queue();
+             }
+         }
+</codeblock></stepxmp>
+<stepresult><p>The data is now queued on the channel.</p></stepresult>
+</step>
+<step id="GUID-DA024D3E-F088-4BEC-BC20-DD467D11928F"><cmd>Close the
+channel. First check whether the channel is busy and take appropriate
+action if it is (in the following example code you cancel all pending
+transfers). Then call the <xref href="GUID-01D2AF56-21E1-3FF3-BF86-0C356A1658EF.dita"><apiname>Close()</apiname></xref> function of <xref href="GUID-83882548-FAC5-3EFF-92ED-14D1D9A85D37.dita"><apiname>TDmaChannel</apiname></xref>.</cmd>
+<stepxmp><codeblock xml:space="preserve">    if (iDMAChannelOpen &amp;&amp; iDMAChannel &amp;&amp; !iDMABusy)
+         {
+         iDMAChannel-&gt;CancelAll();
+         iDMARequestsCount = 0;      // All DMA requests have been now canceled!
+ 
+         if (iDMARequest)
+             {
+             //just call destructor explicitly and the object can reused
+             iDMARequest-&gt;~DDmaRequest();
+             }
+			...
+         iDMAChannel-&gt;Close();
+</codeblock></stepxmp>
+<stepresult><p>The channel is now closed.</p></stepresult>
+</step>
+</steps>
+<result id="GUID-7BF6DAFD-2B40-4F3F-889D-F8FDDEFF091C"><p>You have
+now conducted a data transfer by DMA.</p></result>
+</taskbody></task>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-FB063C1A-EF9F-4292-827F-A3DBC7C7F13A.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-FB063C1A-EF9F-4292-827F-A3DBC7C7F13A" xml:lang="en"><title>Adaptation Glossary</title><shortdesc>This section provides definitions of terms that are commonly
+used in the adaptation documentation.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-86307168-C878-4AED-B756-50B282770ACD">         
+                       </section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-FB69F45C-2256-5F2D-8D2C-98C93B865962-master.png has changed
Binary file Adaptation/GUID-FB69F45C-2256-5F2D-8D2C-98C93B865962_d0e14972_href.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-FBE6E61F-5A2E-5A7A-BC59-51F072EBED7D.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,68 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-FBE6E61F-5A2E-5A7A-BC59-51F072EBED7D" xml:lang="en"><title>Media
+Driver Migration Guide</title><shortdesc>Describes the issues that need to be considered, when migrating
+media drivers to a writable data demand paging environment. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-AB10DA2D-B7CC-47FD-B68A-1610B6BEAAE6"><title>Purpose</title> <p>This
+document explains the points that have to be considered when migrating existing
+media drivers to a writable data paging environment. </p>  </section>
+<section id="GUID-EB26A48A-3A34-44E8-9651-C7ED658CED51"><title>Issues Involved</title> <p>The
+two main issues that have to be addressed when migrating existing media drivers
+are: </p> <ul>
+<li id="GUID-68A44C67-6D4E-5D7E-A13B-0A82154073B2"><p>A deadlock condition
+can occur between the driver and the client process, where both are trying
+to access the same page of paged memory</p> </li>
+<li><p>A deadlock condition can occur between the driver and the client process,
+where the client is allocating on the kernel heap, the paging system tries
+to page out some data and the media driver also tries to allocate on the kernel
+heap while servicing the resulting request.</p></li>
+<li id="GUID-56A3815D-E07B-5195-85C3-0B93C08745C3"><p>Unpredictable delays
+in servicing a DFC can occur, since memory might need to be paged in.</p> </li>
+</ul> <p>To address the above issues, the following points will have to be
+considered/undertaken: </p> <ul>
+<li id="GUID-A15DB387-AB22-51BB-A4AD-0353932B788C"><p>Pass data by value to
+DoRequest/DoControl </p> </li>
+<li id="GUID-0FB5B141-94FE-54E4-9915-2DD50F840879"><p>Return results by using
+a return code </p> </li>
+<li id="GUID-9B3D3D25-010E-58C3-9C48-13AF494C3E62"><p>Use of a dedicated DFC
+queue </p> </li>
+<li id="GUID-AADA0BD7-75E7-5A11-98EB-F7EF3E1B5139"><p>Determine if unpredictable
+delays in servicing DFCs are acceptable </p> </li>
+<li id="GUID-E5B45EC9-DF21-51A9-814C-17CF3C13DFAE"><p>Validate the arguments
+in the client context as far as possible </p> </li>
+<li id="GUID-E6E4F7E2-1BE4-5590-AB05-777637C9B32B"><p>Move user memory accesses
+to client context where possible </p> </li>
+<li id="GUID-F4B44B27-9AE6-5A8C-B88C-C1809DAF6B89"><p>Replace the use of small
+fixed-size structures with the use of the TClientDataRequest object </p> </li>
+<li id="GUID-990D43F2-21C3-5C55-AC13-89C7153EA83B"><p>Pin user memory accessed
+from DFCs </p><p>Do not allocate on the kernel heap while handling page out
+requests.</p> <p>The paging algorithm can be over ridden and pages of memory
+can be kept in memory (pinned). This situation can be reversed by 'unpinning'
+the page. The TClientBufferRequest API provides this functionality. </p> </li>
+<li id="GUID-67DB522A-DEB2-5FEA-ACA4-D80D09D80926"><p>Re-write the driver
+to use shared chunks </p> </li>
+<li id="GUID-A298C045-2260-55B5-89B9-595E3AF5472F"><p>No fast mutex may be
+held when calling APIs that access user memory </p> </li>
+<li id="GUID-F9F79078-0CBC-5E8F-899F-117D148C605A"><p>No kernel mutex may
+be held </p> </li>
+<li id="GUID-D378D276-CAF0-5B8B-BDA2-4D18EB87F96A"><p>Use the new APIs, (See
+the <xref href="GUID-592B6D20-4ABA-5C79-9734-D18E2CE4A86C.dita">Writable Data Paging
+Overview</xref> ). </p> </li>
+</ul> </section>
+<section id="GUID-32E564F3-D66A-472B-A3C1-D2D61807A5F2"><title>See
+also</title> <ul>
+<li id="GUID-77417650-C1F4-5ABC-9E75-54D274556FCD"><p> <xref href="GUID-E7C55048-5B7A-5BF2-B7F4-4D731659B88C.dita">Device
+Driver Writing and Migration Guide</xref>  </p> <p>This document explains
+techniques for writing device drivers on data paged systems and migrating
+device drivers to data paged systems. </p> </li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-FCCF9634-0610-5199-A37A-CF2EC9B73261.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,112 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-FCCF9634-0610-5199-A37A-CF2EC9B73261" xml:lang="en"><title>Adaptation Quick Start</title><shortdesc>Adaptation involves extending software on the device to
+support a given hardware component. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<section id="GUID-BC149020-EE8D-55ED-8254-75B70A4A1D3E"><title>Adaptation
+environment</title> <p>The functionality of a particular hardware
+technology is enabled when an interface to the standard for that technology
+is defined. </p> <p>The hardware is enabled when the following exist: </p> <ul>
+<li id="GUID-70F0057C-32FA-5AC5-922B-9FA853950490"><p>LDD – Logical
+Device Driver </p> </li>
+<li id="GUID-554F5C6F-F718-5FFA-8685-31D8322A513C"><p>PDD – Physical
+Device Driver </p> </li>
+</ul> </section>
+<section id="GUID-8298F0E2-1811-5C08-8C08-F6A5754EA678"><title>Kernel
+extensions</title> <p>Kernel extensions provide additional functionality
+in the kernel and run with the same access rights and permissions
+as the rest of the kernel. </p> <p>Adaptation device drivers (LDD/PDD)
+require low-level access to the device and implementing them as a
+kernel extension gives them this access. </p> <p><b>LDD</b> </p> <p>Each LDD has the following features: </p> <ul>
+<li id="GUID-7549B5B5-7E7C-5F7C-9A2F-81EB8FB7F9E7"><p>the LDD is a
+packaged DLL </p> </li>
+<li id="GUID-5A57648F-9657-5261-8068-4D7F946F1C04"><p>provides user
+side functionality </p> </li>
+<li id="GUID-740E0B4E-A993-577E-ACF4-2EDC8E8DE834"><p>loaded into
+the kernel </p> </li>
+<li id="GUID-0991A098-C7DC-5335-8AF1-567BD9C0EEF8"><p>calls a function
+that opens a <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita"><apiname>DLogicalChannel</apiname></xref>  </p> </li>
+<li id="GUID-5BA91833-A9DC-5C07-B3CB-769FD2B4758C"><p>opens an <xref href="GUID-6FBFA078-8253-3E24-B1F8-5F75E86C3066.dita"><apiname>RBusLogicalChannel</apiname></xref>  </p> </li>
+<li id="GUID-0BB01A79-8D94-5BDB-BE4C-7B1A015950EE"><p>allows user
+code to communicate with the hardware and send commands to control
+the hardware </p> </li>
+<li id="GUID-9A42F726-DBF3-5559-A2D9-867B293D7A44"><p>defines an abstract
+class that must be implemented in the PDD </p> </li>
+</ul> <p>Mandatory – there must be one LDD for each hardware component. </p> <p id="GUID-1097C454-8236-5291-88FB-92F979FB3B78"><b>PDD</b> </p> <p>PDDs have the following features: </p> <ul>
+<li id="GUID-83481281-B6B0-50D2-A8B0-EDF6FDF7632B"><p>the PDD is a
+packaged DLL </p> </li>
+<li id="GUID-3B0AAFEC-786C-5003-B71A-B686C49034B4"><p>provides access
+to hardware </p> </li>
+<li id="GUID-E23527A0-4082-51E3-A3B1-200952C7B071"><p>loaded into
+the kernel </p> </li>
+<li id="GUID-9436F11E-6E53-5990-A2D5-625AFA815FD9"><p>calls a function
+that opens a physical channel </p> </li>
+<li id="GUID-285B2015-34B2-5BC5-8903-2BBE47E35CF3"><p>receives control
+commands and other communications through its interface with the LDD </p> </li>
+<li id="GUID-E3BA0A9E-4856-5831-86E3-6BC7702C7CC7"><p>may be an extension
+to an existing device driver </p> </li>
+</ul> <p>Mandatory – there must be one PDD for each hardware platform
+for each hardware component. </p> </section>
+<section id="GUID-A20284FD-D793-5650-94DF-D4DCB6BC0CC2"><title>Using
+Kernel extensions</title> <p>A Kernel Extension is additional functionality
+that runs as part of the kernel. </p> <p>For example, access to the
+SD Card is provided through a kernel extension. </p> <p><b>Adaptation ready architecture</b> </p> <p>Adaptation ready architecture
+means the following have been created: </p> <ul>
+<li id="GUID-90B150BC-C18A-5578-AC86-54D4525D28E4"><p>The LDD </p> </li>
+<li id="GUID-73DF2D9B-E53A-51C8-93C5-60AC883DDE18"><p>The abstract
+class that must be implemented in the PDD </p> </li>
+<li id="GUID-82E50357-5AB6-5975-9630-A9C7382F2FBB"><p>The interface
+to the user code </p> </li>
+<li id="GUID-CBA9DF88-CF53-519D-A792-3DBD3B548F25"><p>Any optional
+kernel extension DLLs </p> </li>
+<li id="GUID-D887C2E9-04FC-504F-A09A-5D9227AD4AEC"><p>Optional reference
+implementation PDD </p> </li>
+</ul> <p id="GUID-C10B0527-A1E1-54B0-A4B6-E4E991FD24B8"><b>Adaptation options</b> </p> <p>There are broadly two types of hardware adaptation: </p> <ul>
+<li id="GUID-716ACF8A-278F-5FDA-A27A-2634EB6F24E5"><p>New hardware </p> </li>
+<li id="GUID-6E1419FA-99EB-5183-A1E3-5F998995D96E"><p>Updated hardware </p> </li>
+</ul> <p> <i>New hardware</i>  </p> <p>The entire adaptation architecture,
+as described above, must be defined. This includes: </p> <ul>
+<li id="GUID-12A35E7B-3F03-5D4D-83C9-EA61BAD0D193"><p>Defining an
+abstract class that the PDD creators are required to implement, creating
+an LDD and so on. </p> </li>
+<li id="GUID-EA64CF53-61C4-531D-89C2-6B580A6E75C4"><p>The architecture
+enables the new hardware. </p> </li>
+<li id="GUID-0AA5340B-647E-535C-B183-D0E886017093"><p>The architecture
+allows hardware manufacturers to create their own implementation (PDD). </p> </li>
+</ul> <p>New hardware adaptation will be supported with a reference
+implementation, which will go a long way towards guiding the device
+developer’s efforts. </p> <p> <i>Updated hardware</i>  </p> <p>Updated
+hardware which provides new or modified functionality requires a new
+PDD to be created to either extend the functionality of the existing
+PDD or to replace the existing PDD. </p> <p>In most cases the new
+functionality of the hardware will be enabled by extending the architecture
+with a new extension PDD or be writing a new PDD that incorporates
+all the existing and new functionality. </p> <p>There are situations
+where the entire adaptation architecture needs to be extended or redesigned,
+such as when a hardware component is extended in a way that was not
+expected. The Bluetooth baseband radio being extended to provide Bluetooth,
+802.11, and FM radio from the same hardware component, for example,
+will require a redesign of the adaptation architecture so the LDD
+knows about 802.11 and FM as well as Bluetooth. Such a redesign should
+ensure older Bluetooth PDDs will still work while extending the possible
+PDDs that will work with the LDD to include Bluetooth, 802.11, FM
+radio, and a combination of the above. </p> </section>
+<section id="GUID-AC29A1E3-4FAF-41EC-A08A-CCCE8B28AB02"><title>Where
+to go next</title> <p>Adaptation is described in more detail in these
+documents:</p><ul>
+<li><xref href="GUID-D5EE0A17-2246-4CB3-9CE5-538F1E01F8D4.dita">What is
+Adaptation?</xref></li>
+<li><xref href="GUID-95BD3650-08CB-407D-969E-DFDB39B2FEFC.dita">What is
+a Platform Service?</xref></li>
+<li><xref href="GUID-C9923DF3-8425-4EB4-8066-FB5A92A85F5B.dita">Adaptation
+Process Guide</xref></li>
+</ul> </section>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-FD8634B8-E522-4AC4-8129-ED807A7754A2-GENID-1-2-1-9-1-5-1-6-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-FD8634B8-E522-4AC4-8129-ED807A7754A2-GENID-1-2-1-9-1-5-1-6-1" xml:lang="en"><title>Kernel-side
+Implementation</title><shortdesc>This document describes kernel-side implementation of requests
+to device drivers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Requests from the user-side are initially handled by the driver
+in the context of the client user-side thread. All requests are passed to
+the "gateway" function: <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita#GUID-E7550422-5121-3393-A85E-BB797969CD2A/GUID-FD4DA73F-45E7-37BE-9380-1D8ED36114F7"><apiname>DLogicalChannelBase::Request()</apiname></xref>.
+This is defined as pure virtual in <codeph>DLogicalChannelBase</codeph>, and
+needs to be implemented in a derived class as part of your logical channel
+implementation. </p>
+<fig id="GUID-0DEEF003-53B6-5892-8FF2-6684BC424E27-GENID-1-2-1-9-1-5-1-6-1-3-2">
+<title>                 Device driver logical channel communication      
+        </title>
+<image href="GUID-4A2E212E-BC1B-5965-9A62-6309CC7CAAAB_d0e61647_href.png" placement="inline"/>
+</fig>
+<p>There are two options for implementing this: </p>
+<ol id="GUID-F9FDC221-82F8-569E-B12A-969194137E24-GENID-1-2-1-9-1-5-1-6-1-3-4">
+<li id="GUID-A58B2511-6058-5DE6-8407-0ED4EB7A0112-GENID-1-2-1-9-1-5-1-6-1-3-4-1"><p>Use the ready-made framework
+provided by the <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita"><apiname>DLogicalChannel</apiname></xref> class, which handles a
+request in the context of a single kernel-side thread. This framework uses
+the kernel-side messaging mechanism for queuing requests on a DFC that runs
+in that single kernel-side thread. </p> <p>In practice, this model makes the
+writing of device drivers easier because the same kernel thread can be used
+to process requests from (potentially multiple) user-side clients and DFCs,
+thus in effect serialising access to the device driver, and eliminating thread-related
+issues, such as the need to know about mutexes, pre-emption, etc. Several
+drivers can use the same request/DFC kernel thread to reduce resource usage. </p> </li>
+<li id="GUID-DE277962-5BDC-5CD7-9868-65FA576E11AD-GENID-1-2-1-9-1-5-1-6-1-3-4-2"><p>Derive your own logical
+channel class from <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita"><apiname>DLogicalChannelBase</apiname></xref> to handle requests.
+This allows you to build your own thread model for running DFCs to handle
+requests and to handle request completion. This requires that you manage inter-thread
+conflicts. However, your design may give you the chance to do some optimisation
+by handling some requests in the context of the user-side thread, minimising
+context-switching overhead. </p> </li>
+</ol>
+<p>Option 1 lets you get a new driver up and running quickly. Option 2 gives
+you greater flexibility if the requirements of your driver demand it. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-FD8634B8-E522-4AC4-8129-ED807A7754A2-GENID-1-2-1-9-1-6-1-9-1-8-1.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-FD8634B8-E522-4AC4-8129-ED807A7754A2-GENID-1-2-1-9-1-6-1-9-1-8-1" xml:lang="en"><title>Kernel-side
+Implementation</title><shortdesc>This document describes kernel-side implementation of requests
+to device drivers.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>Requests from the user-side are initially handled by the driver
+in the context of the client user-side thread. All requests are passed to
+the "gateway" function: <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita#GUID-E7550422-5121-3393-A85E-BB797969CD2A/GUID-FD4DA73F-45E7-37BE-9380-1D8ED36114F7"><apiname>DLogicalChannelBase::Request()</apiname></xref>.
+This is defined as pure virtual in <codeph>DLogicalChannelBase</codeph>, and
+needs to be implemented in a derived class as part of your logical channel
+implementation. </p>
+<fig id="GUID-0DEEF003-53B6-5892-8FF2-6684BC424E27-GENID-1-2-1-9-1-6-1-9-1-8-1-3-2">
+<title>                 Device driver logical channel communication      
+        </title>
+<image href="GUID-4A2E212E-BC1B-5965-9A62-6309CC7CAAAB_d0e65116_href.png" placement="inline"/>
+</fig>
+<p>There are two options for implementing this: </p>
+<ol id="GUID-F9FDC221-82F8-569E-B12A-969194137E24-GENID-1-2-1-9-1-6-1-9-1-8-1-3-4">
+<li id="GUID-A58B2511-6058-5DE6-8407-0ED4EB7A0112-GENID-1-2-1-9-1-6-1-9-1-8-1-3-4-1"><p>Use the ready-made framework
+provided by the <xref href="GUID-A3CC1D95-4681-3349-A67C-F113A614041D.dita"><apiname>DLogicalChannel</apiname></xref> class, which handles a
+request in the context of a single kernel-side thread. This framework uses
+the kernel-side messaging mechanism for queuing requests on a DFC that runs
+in that single kernel-side thread. </p> <p>In practice, this model makes the
+writing of device drivers easier because the same kernel thread can be used
+to process requests from (potentially multiple) user-side clients and DFCs,
+thus in effect serialising access to the device driver, and eliminating thread-related
+issues, such as the need to know about mutexes, pre-emption, etc. Several
+drivers can use the same request/DFC kernel thread to reduce resource usage. </p> </li>
+<li id="GUID-DE277962-5BDC-5CD7-9868-65FA576E11AD-GENID-1-2-1-9-1-6-1-9-1-8-1-3-4-2"><p>Derive your own logical
+channel class from <xref href="GUID-E7550422-5121-3393-A85E-BB797969CD2A.dita"><apiname>DLogicalChannelBase</apiname></xref> to handle requests.
+This allows you to build your own thread model for running DFCs to handle
+requests and to handle request completion. This requires that you manage inter-thread
+conflicts. However, your design may give you the chance to do some optimisation
+by handling some requests in the context of the user-side thread, minimising
+context-switching overhead. </p> </li>
+</ol>
+<p>Option 1 lets you get a new driver up and running quickly. Option 2 gives
+you greater flexibility if the requirements of your driver demand it. </p>
+</conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-FDAED7A7-3D93-5B57-9879-DF8BDBE8A9BD.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept xml:lang="en" id="GUID-FDAED7A7-3D93-5B57-9879-DF8BDBE8A9BD"><title>Load and Open a USB Channel </title><shortdesc>Before configuration the Logical Device Driver (LDD) must be loaded and opened. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody><section><title>Load the USB LDD</title> <p>Before a channel can be opened the Logical Device Driver (LDD) must be loaded. Load a logical device using <xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-AE0D51B7-7ADC-3C9F-ACAA-8F6D9EA0AEFA"><apiname>User::LoadLogicalDevice()</apiname></xref> passing it the file name of the LDD you wish to load. </p> <codeblock id="GUID-E7E137E3-3E68-5545-9100-A327EEC9092A" xml:space="preserve">_LIT(KLddName, "eusbcsc.ldd");
+TInt r = User::LoadLogicalDevice(KLddName);</codeblock> </section> <section><title>Open a USB Channel</title> <p>Open your USB channel using the LDD open function <xref href="GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA.dita#GUID-4D1AE286-41EE-3361-948A-3E8634D81DBA/GUID-F4611D22-8893-3A1D-8B76-18045707DF63"><apiname>RDevUsbcScClient::Open()</apiname></xref>. </p> <codeblock id="GUID-EB86689D-EB77-53CE-84AE-E7AE3AE2E7CB" xml:space="preserve">RDevUsbcScClient gPort;
+TInt r = gPort.Open(0);</codeblock> </section> <section><p>After you have loaded and opened the USB LDD you should <xref href="GUID-18DD4FE5-6641-5A0E-A00E-DC0C00639CE4.dita">Set the Configuration Descriptors</xref>. </p> </section> </conbody></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-FE36E7DE-7C2C-415B-BB2F-22D9E2BE49A6.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-FE36E7DE-7C2C-415B-BB2F-22D9E2BE49A6" xml:lang="en"><title>Configuration Storage</title><shortdesc>The Hardware Configuration Repository (HCR) can be used
+to hold configuration information for DMA.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>There are two places where you may want to consider using a registry
+to hold information for DMA.<ol>
+<li id="GUID-6316ABED-967B-453F-BBB9-8F6C346C3D9F"><p>Chipset configuration </p></li>
+<li id="GUID-02513035-3A91-455A-8EEB-F7F914844734"><p>Channel configuration
+and information.</p></li>
+</ol></p>
+<section id="GUID-85868C4A-83CA-4FEE-B35E-5C168819B03D"><title>Chipset
+configuration</title><p>On initialization of the chipset you can store
+and retrieve settings in the HCR. </p><p>In the <xref href="GUID-95A33491-17AC-4F12-948E-A1352ADDA483.dita">DMA Implementation
+Guide</xref> there are links to a sample implementation in which no
+chipset configuration is required or specified.</p></section>
+<section id="GUID-D59E35D2-3198-43BA-91F9-153F7DCAA78A"><title>Channel
+configuration and information</title><p>When a client opens a channel,
+it specifies a cookie parameter in the <xref href="GUID-176B8E0D-0422-341B-A134-7C85432E1303.dita#GUID-176B8E0D-0422-341B-A134-7C85432E1303/GUID-934F46B3-1DF9-3870-87EE-A8E2DEF82810"><apiname>DmaChannelMgr::Open()</apiname></xref> function. This cookie is used by the DMA implementation to identify
+a specific channel on a specific DMA controller. This is entirely
+chipset and implementation specific and the client will need to know
+what cookie values can be used to request a channel.</p><p>One way
+that the implementation can communicate this information to the client
+is by using the Central Repository to hold a table of cookie values
+and matching channel identification. An alternative approach may be
+to use a Central Repository entry to specify the number of channels
+available and then the client knows the highest channel number it
+can request.</p><p>Again this is entirely implementation specific.
+In the implementation mentioned above, the repository is not used.</p></section>
+</conbody><related-links>
+<link href="GUID-14F5433A-16F4-4F01-8A7B-C8E26F46C98B.dita"><linktext>HCR
+Platform Service</linktext></link>
+</related-links></concept>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Adaptation/GUID-FE77CDFC-B66B-485B-A94D-F646894FD330.dita	Fri Oct 15 14:32:18 2010 +0100
@@ -0,0 +1,102 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-FE77CDFC-B66B-485B-A94D-F646894FD330" xml:lang="en"><title>Time Interface Guide</title><shortdesc>Provides a summary of Time platform service interface.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>The Time platform service interface is provided by the <xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita"><apiname>MRtcAdaptation</apiname></xref> class. The class is defined in the <filepath>os/devicesrv/sysstatemgmt/systemstatemgr/inc/ssmadaptation.h</filepath> header file.</p>
+<section id="GUID-47171771-F8A3-46C4-8EC1-4817BE037634">         
+   <title>Interface classes</title>             <table id="GUID-111B0F19-7C0C-48FD-90BE-4AF2C1B3D81C">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">Class </entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita"><apiname>MRtcAdaptation</apiname></xref></entry>
+<entry>Provides the interface between the Real Time Clock (RTC) and
+the upper layers of the operating system.</entry>
+</row>
+<row>
+<entry><xref href="GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9.dita"><apiname>ASIC</apiname></xref></entry>
+<entry>Provides an interface to the Application Specific Integrated
+Circuit (ASIC) that is being used.</entry>
+</row>
+</tbody>
+</tgroup>
+</table>      </section>
+<section id="GUID-956B0961-1F18-43AD-89EF-EBB5966DC3A2"><title>Time
+adaptation functions</title><p>The following functions should be implemented
+to provide the Time platform service functionality.</p><table id="GUID-A3E87FE5-5000-477F-8DE1-EE587B58B054">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita#GUID-CC79A63E-15DF-3437-983B-9A90966B3004/GUID-949F292B-90FE-3412-9529-E63503669758"><apiname>MRtcAdaptation::ValidateRtc(TDesc8&amp; aValidityPckg,
+TRequestStatus aStatus)</apiname></xref></entry>
+<entry>Check the real time clock implementation is valid. </entry>
+</row>
+<row>
+<entry><xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita#GUID-CC79A63E-15DF-3437-983B-9A90966B3004/GUID-C9CA1DF9-786F-39D3-B661-2F082C164BC6"><apiname>MRtcAdaptation::SetWakeupAlarm(TDesC8&amp; aAlarmTimePckg,
+TRequestStatus&amp; aStat)</apiname></xref></entry>
+<entry>Set a device wakeup alarm time in UTC. </entry>
+</row>
+<row>
+<entry><xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita#GUID-CC79A63E-15DF-3437-983B-9A90966B3004/GUID-77E1ECE3-06C1-3C61-9756-C1C83A14DDA5"><apiname>MRtcAdaptation::UnsetWakeupAlarm(TRequestStatus&amp;
+aStatus)</apiname></xref></entry>
+<entry>Delete the device wakeup alarm.</entry>
+</row>
+<row>
+<entry><xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita#GUID-CC79A63E-15DF-3437-983B-9A90966B3004/GUID-ADC7041A-23F0-319F-A163-29E8BB261D0B"><apiname>MRtcAdaptation::Cancel()</apiname></xref></entry>
+<entry>Cancel any outstanding request to the real time clock.</entry>
+</row>
+<row>
+<entry><xref href="GUID-CC79A63E-15DF-3437-983B-9A90966B3004.dita#GUID-CC79A63E-15DF-3437-983B-9A90966B3004/GUID-C44E98E9-6568-3628-9A7E-85379C4298FD"><apiname>MRtcAdaptation::Release()</apiname></xref></entry>
+<entry>Deletes and release the allocated memory.</entry>
+</row>
+</tbody>
+</tgroup>
+</table><p><note>The above function calls will return <codeph>KErrNotSuported
+in an emulator.</codeph></note></p></section>
+<section id="GUID-514CDC5A-D8CF-436D-B155-B3176BAAC6E6"><title>ASIC
+functions</title><p>The functions related to the Time platform service
+in the ASIC class.</p><table id="GUID-C31721D2-CB8A-42CE-AB88-19B81E43FF0E">
+<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
+<thead>
+<row>
+<entry valign="top">API</entry>
+<entry valign="top">Description</entry>
+</row>
+</thead>
+<tbody>
+<row>
+<entry><xref href="GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9.dita#GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9/GUID-2D7976BE-F6D5-3FC4-8253-C34A592A63D3"><apiname>ASIC::SetSystemTimeCalibration()</apiname></xref></entry>
+<entry>Set the real time clock by specifying the time calibration
+in parts per million.</entry>
+</row>
+<row>
+<entry><xref href="GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9.dita#GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9/GUID-DE2DBFE9-9B9E-3C30-9435-5EA8A12C54E6"><apiname>ASIC::SystemTimeInSecondsFrom2000(TInt)</apiname></xref></entry>
+<entry>Get the system time in seconds from the year 2000.</entry>
+</row>
+<row>
+<entry><xref href="GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9.dita#GUID-69C70CA3-1121-3C5B-AEA4-B2E0245539B9/GUID-B210267E-2378-331C-8B4E-AF7E0FA0258B"><apiname>ASIC::SetSystemTimeInSecondsFrom2000(TInt)</apiname></xref></entry>
+<entry>Set the system time to 0 from the start the year 2000.</entry>
+</row>
+</tbody>
+</tgroup>
+</table><p>The header file for the Time platform service can be found <xref href="http://developer.symbian.org/xref/oss/xref/MCL/sf/os/devicesrv/sysstatemgmt/systemstatemgr/inc/ssmadaptation.h.dita#http://developer.symbian.org/xref/oss/xref/MCL/sf/os/devicesrv/sysstatemgmt/systemstatemgr/inc/ssmadaptation.h/MRtcAdaptation">here</xref>.</p></section>
+</conbody></concept>
\ No newline at end of file
Binary file Adaptation/GUID-FF2ABA1D-1F71-5A9C-AFD5-A0CED39BFD86-master.png has changed
Binary file Adaptation/GUID-FF2ABA1D-1F71-5A9C-AFD5-A0CED39BFD86_d0e39571_href.png has changed