pib.h.html 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836
  1. <?xml version='1.0' encoding='iso-8859-1'?>
  2. <!doctype html public '-//W3C//DTD XHTML 1.0 Strict//EN' 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd'>
  3. <html xmlns='http://www.w3c.org/1999/xhtml' lang='en-us'>
  4. <head>
  5. <title>
  6. pib.h
  7. </title>
  8. <meta http-equiv='content-type' content='text/html;iso-8859-1'/>
  9. <meta name='generator' content='motley-tools 1.9.4 13:40:33 Feb 18 2015'/>
  10. <meta name='author' content='cmaier@cmassoc.net'/>
  11. <meta name='robots' content='noindex,nofollow'/>
  12. <link href='toolkit.css' rel='stylesheet' type='text/css'/>
  13. </head>
  14. <body>
  15. <div class='headerlink'>
  16. [<a href='pcap-stdinc.h.html' title=' pcap-stdinc.h '>PREV</a>]
  17. [<a href='toolkit.html' title=' Index '>HOME</a>]
  18. [<a href='plc.h.html' title=' plc.h '>NEXT</a>]
  19. </div>
  20. <pre>
  21. /*====================================================================*
  22. *
  23. * Copyright (c) 2013 Qualcomm Atheros, Inc.
  24. *
  25. * All rights reserved.
  26. *
  27. * Redistribution and use in source and binary forms, with or
  28. * without modification, are permitted (subject to the limitations
  29. * in the disclaimer below) provided that the following conditions
  30. * are met:
  31. *
  32. * * Redistributions of source code must retain the above copyright
  33. * notice, this list of conditions and the following disclaimer.
  34. *
  35. * * Redistributions in binary form must reproduce the above
  36. * copyright notice, this list of conditions and the following
  37. * disclaimer in the documentation and/or other materials
  38. * provided with the distribution.
  39. *
  40. * * Neither the name of Qualcomm Atheros nor the names of
  41. * its contributors may be used to endorse or promote products
  42. * derived from this software without specific prior written
  43. * permission.
  44. *
  45. * NO EXPRESS OR IMPLIED LICENSES TO ANY PARTY'S PATENT RIGHTS ARE
  46. * GRANTED BY THIS LICENSE. THIS SOFTWARE IS PROVIDED BY THE
  47. * COPYRIGHT HOLDERS AND CONTRIBUTORS &quot;AS IS&quot; AND ANY EXPRESS OR
  48. * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
  49. * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  50. * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER
  51. * OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  52. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  53. * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  54. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  55. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  56. * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
  57. * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
  58. * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  59. *
  60. *--------------------------------------------------------------------*/
  61. /*====================================================================*
  62. *
  63. * pib.h - PIB version definitions and declarations;
  64. *
  65. * The PIB undergoes periodic revision as new features are added;
  66. * versions are distiguished from one another by the first two bytes;
  67. *
  68. * this file declares PIB header structure for PIBs released to
  69. * date; it does not define the position of all PIB information
  70. * because there must be some mystery to life;
  71. *
  72. * call function pibpeek() to display a buffer holding an unkown
  73. * PIB structure;
  74. *
  75. *. Qualcomm Atheros HomePlug AV Powerline Toolkit;
  76. *: Copyright (c) 2006-2010 by Intellon Corporation; ALL RIGHTS RESERVED;
  77. *; For demonstration and evaluation only; Not for production use.
  78. *
  79. * Contributor(s):
  80. * Charles Maier &lt;cmaier@qca.qualcomm.com&gt;
  81. *
  82. *--------------------------------------------------------------------*/
  83. #ifndef PIB_HEADER
  84. #define PIB_HEADER
  85. /*====================================================================*
  86. * system header files;
  87. *--------------------------------------------------------------------*/
  88. #include &lt;stdio.h&gt;
  89. #include &lt;stdint.h&gt;
  90. #include &lt;errno.h&gt;
  91. #ifndef ETHER_ADDR_LEN
  92. #define ETHER_ADDR_LEN 6 /* normally defined in ethernet.h or if_ether.h */
  93. #endif
  94. /*====================================================================*
  95. * custom header files;
  96. *--------------------------------------------------------------------*/
  97. #include &quot;../tools/types.h&quot;
  98. #include &quot;../tools/memory.h&quot;
  99. #include &quot;../key/HPAVKey.h&quot;
  100. /*====================================================================*
  101. * constants;
  102. *--------------------------------------------------------------------*/
  103. #define PIB_NAME_LEN 32
  104. #define PIB_HFID_LEN 64
  105. #define PIB_TEXT_LEN 256
  106. #define PIB_KEY_LEN 16
  107. #define PIB_SILENCE (1 &lt;&lt; 0)
  108. #define PIB_VERBOSE (1 &lt;&lt; 1)
  109. #define PIB_MANIFEST (1 &lt;&lt; 2)
  110. #define PIB_MAC (1 &lt;&lt; 3)
  111. #define PIB_MACINC (1 &lt;&lt; 4)
  112. #define PIB_NMK (1 &lt;&lt; 5)
  113. #define PIB_DAK (1 &lt;&lt; 6)
  114. #define PIB_MFGSTRING (1 &lt;&lt; 7)
  115. #define PIB_USER (1 &lt;&lt; 8)
  116. #define PIB_NETWORK (1 &lt;&lt; 9)
  117. #define PIB_CCO_MODE (1 &lt;&lt; 10)
  118. #define PIB_NID (1 &lt;&lt; 11)
  119. #define PIB_CHECKED (1 &lt;&lt; 12)
  120. #define INT_PRESCALER_OFFSET 0x0A10
  121. #define INT_PRESCALER_LENGTH (1155 * sizeof (uint32_t))
  122. #define AMP_PRESCALER_OFFSET 0x0A30
  123. #define AMP_PRESCALER_LENGTH ((2880 * 5) / sizeof (uint32_t))
  124. #define PLC_PRESCALER_OFFSET 0x0F2B
  125. #define PLC_PRESCALER_LENGTH (1345 / sizeof (uint32_t))
  126. #define QCA_PRESCALER_OFFSET 0x12E8
  127. #define QCA_PRESCALER_LENGTH 1345
  128. #define INDEX_TO_FREQ(index) ((float)((index)+74)/40.96)
  129. #define FREQ_TO_INDEX(freq) ((unsigned)(40.96*(freq))-74)
  130. /*====================================================================*
  131. * standard PIB message formats;
  132. *--------------------------------------------------------------------*/
  133. #define PIB_BADVERSION &quot;%s found bad PIB version in %s&quot;, __func__
  134. #define PIB_BADCONTENT &quot;%s found wrong PIB content in %s&quot;, __func__
  135. #define PIB_BADLENGTH &quot;%s found wrong PIB image length in %s&quot;, __func__
  136. #define PIB_BADCHECKSUM &quot;%s found wrong PIB image checksum in %s&quot;, __func__
  137. #define PIB_BADNID &quot;%s found wrong Preferred NID in %s&quot;, __func__
  138. /*====================================================================*
  139. * Basic PIB header;
  140. *--------------------------------------------------------------------*/
  141. #ifndef __GNUC__
  142. #pragma pack (push, 1)
  143. #endif
  144. typedef struct __packed pib_header
  145. {
  146. uint8_t FWVERSION;
  147. uint8_t PIBVERSION;
  148. uint16_t RESERVED1;
  149. uint16_t PIBLENGTH;
  150. uint16_t RESERVED2;
  151. uint32_t CHECKSUM;
  152. }
  153. pib_header;
  154. #ifndef __GNUC__
  155. #pragma pack (pop)
  156. #endif
  157. /*====================================================================*
  158. * As of PIB 1.4 a generic structure evolved; this is the start;
  159. *--------------------------------------------------------------------*/
  160. #ifndef __GNUC__
  161. #pragma pack (push, 1)
  162. #endif
  163. typedef struct __packed simple_pib
  164. {
  165. uint16_t PIBVERSION;
  166. uint16_t RESERVED1;
  167. uint16_t PIBLENGTH;
  168. uint16_t RESERVED2;
  169. uint32_t CHECKSUM;
  170. uint8_t MAC [ETHER_ADDR_LEN];
  171. uint8_t DAK [HPAVKEY_DAK_LEN];
  172. uint16_t RESERVED3;
  173. uint8_t MFG [PIB_HFID_LEN];
  174. uint8_t NMK [HPAVKEY_NMK_LEN];
  175. uint8_t USR [PIB_HFID_LEN];
  176. uint8_t NET [PIB_HFID_LEN];
  177. uint8_t CCoSelection;
  178. uint8_t CexistModeSelect;
  179. uint8_t PLFreqSelect;
  180. uint8_t RESERVED4;
  181. uint8_t PreferredNID [HPAVKEY_NID_LEN];
  182. uint8_t AutoFWUpgradeable;
  183. uint8_t MDUConfiguration;
  184. uint8_t MDURole;
  185. uint8_t RESERVED5 [10];
  186. uint8_t StaticNetworkConfiguration [128];
  187. uint8_t InterfaceConfiguration [64];
  188. }
  189. simple_pib;
  190. #ifndef __GNUC__
  191. #pragma pack (pop)
  192. #endif
  193. /*====================================================================*
  194. *
  195. *--------------------------------------------------------------------*/
  196. #ifndef __GNUC__
  197. #pragma pack (push, 1)
  198. #endif
  199. typedef struct __packed PIB1
  200. {
  201. uint8_t FWVersion;
  202. uint8_t PIBVersion;
  203. uint16_t Reserved1;
  204. uint16_t PIBLength;
  205. }
  206. PIB1;
  207. #ifndef __GNUC__
  208. #pragma pack (pop)
  209. #endif
  210. /*====================================================================*
  211. * PIB structure as of v1.2; this is deprecated;
  212. *--------------------------------------------------------------------*/
  213. #ifndef __GNUC__
  214. #pragma pack (push, 1)
  215. #endif
  216. typedef struct __packed PIB1_2
  217. {
  218. uint8_t FWVersion;
  219. uint8_t PIBVersion;
  220. uint16_t Reserved1;
  221. uint8_t DAK [HPAVKEY_DAK_LEN];
  222. uint8_t NMK [HPAVKEY_NMK_LEN];
  223. uint8_t MAC [ETHER_ADDR_LEN];
  224. uint32_t FLG;
  225. }
  226. PIB1_2;
  227. #ifndef __GNUC__
  228. #pragma pack (pop)
  229. #endif
  230. /*====================================================================*
  231. * PIB Structure as of v1.3; this is deprecated;
  232. *--------------------------------------------------------------------*/
  233. #ifndef __GNUC__
  234. #pragma pack (push, 1)
  235. #endif
  236. typedef struct __packed PIB1_3
  237. {
  238. uint8_t FWVersion;
  239. uint8_t PIBVersion;
  240. uint16_t Reserved1;
  241. uint8_t MAC [ETHER_ADDR_LEN];
  242. uint8_t DAK [HPAVKEY_DAK_LEN];
  243. uint16_t Reserved2;
  244. uint8_t MFG [PIB_HFID_LEN];
  245. uint8_t NMK [HPAVKEY_NMK_LEN];
  246. uint8_t USR [PIB_HFID_LEN];
  247. uint8_t NET [PIB_HFID_LEN];
  248. }
  249. PIB1_3;
  250. #ifndef __GNUC__
  251. #pragma pack (pop)
  252. #endif
  253. /*====================================================================*
  254. * PIB sub-structure introduced as of v1.4
  255. *--------------------------------------------------------------------*/
  256. #ifndef __GNUC__
  257. #pragma pack (push, 1)
  258. #endif
  259. typedef struct __packed VersionHeader
  260. {
  261. uint8_t FWVersion;
  262. uint8_t PIBVersion;
  263. uint16_t Reserved1;
  264. uint16_t PIBLength;
  265. uint16_t Reserved2;
  266. uint32_t Checksum;
  267. }
  268. VersionHeader;
  269. #ifndef __GNUC__
  270. #pragma pack (pop)
  271. #endif
  272. /*====================================================================*
  273. * PIB Structure as of v1.4
  274. *--------------------------------------------------------------------*/
  275. #ifndef __GNUC__
  276. #pragma pack (push, 1)
  277. #endif
  278. typedef struct __packed PIB1_4
  279. {
  280. struct VersionHeader VersionHeader;
  281. struct __packed
  282. {
  283. uint8_t MAC [ETHER_ADDR_LEN];
  284. uint8_t DAK [HPAVKEY_DAK_LEN];
  285. uint16_t Reserved1;
  286. uint8_t MFG [PIB_HFID_LEN];
  287. uint8_t NMK [HPAVKEY_NMK_LEN];
  288. uint8_t USR [PIB_HFID_LEN];
  289. uint8_t NET [PIB_HFID_LEN];
  290. uint8_t CCoSelection;
  291. uint8_t CoexistModeSelection;
  292. uint8_t FreqSelection;
  293. uint8_t Reserved2;
  294. }
  295. LocalDeviceConfig;
  296. }
  297. PIB1_4;
  298. #ifndef __GNUC__
  299. #pragma pack (pop)
  300. #endif
  301. /*====================================================================*
  302. * PIB sub-structures introduced as of v1.5;
  303. *--------------------------------------------------------------------*/
  304. #ifndef __GNUC__
  305. #pragma pack (push, 1)
  306. #endif
  307. typedef struct __packed LocalDeviceConfig
  308. {
  309. uint8_t MAC [ETHER_ADDR_LEN];
  310. uint8_t DAK [HPAVKEY_DAK_LEN];
  311. uint16_t Reserved1;
  312. uint8_t MFG [PIB_HFID_LEN];
  313. uint8_t NMK [HPAVKEY_NMK_LEN];
  314. uint8_t USR [PIB_HFID_LEN];
  315. uint8_t NET [PIB_HFID_LEN];
  316. uint8_t CCoSelection;
  317. uint8_t CoexistModeSelect;
  318. uint8_t PLFreqSelection;
  319. uint8_t Reserved2;
  320. uint8_t PreferredNID [HPAVKEY_NID_LEN];
  321. uint8_t AutoFWUpgradeable;
  322. uint8_t MDUConfiguration;
  323. uint8_t MDURole;
  324. uint8_t Reserved3 [10];
  325. }
  326. LocalDeviceConfig;
  327. typedef struct __packed StaticNetworkConfig
  328. {
  329. uint8_t Reserved [128];
  330. }
  331. StaticNetworkConfig;
  332. typedef struct __packed InterfaceConfig
  333. {
  334. uint8_t Reserved [96];
  335. }
  336. InterfaceConfig;
  337. typedef struct __packed IGMPConfig
  338. {
  339. uint8_t Reserved [32];
  340. }
  341. IGMPConfig;
  342. typedef struct __packed QoSParameters
  343. {
  344. uint8_t UnicastPriority;
  345. uint8_t McastPriority;
  346. uint8_t IGMPPriority;
  347. uint8_t AVStreamPriority;
  348. uint32_t PriorityTTL [4];
  349. uint8_t EnableVLANOver;
  350. uint8_t EnableTOSOver;
  351. uint16_t Reserved1;
  352. uint32_t VLANPrioTOSPrecMatrix;
  353. uint8_t Reserved2 [2020];
  354. }
  355. QoSParameters;
  356. typedef struct __packed ToneNotchParameters
  357. {
  358. uint8_t Reserved [5120];
  359. }
  360. ToneNotchParameters;
  361. #ifndef __GNUC__
  362. #pragma pack (pop)
  363. #endif
  364. /*====================================================================*
  365. * PIB structure as of v1.5
  366. *--------------------------------------------------------------------*/
  367. #ifndef __GNUC__
  368. #pragma pack (push, 1)
  369. #endif
  370. typedef struct __packed PIB1_5
  371. {
  372. struct VersionHeader VersionHeader;
  373. struct LocalDeviceConfig LocalDeviceConfig;
  374. struct StaticNetworkConfig StaticNetworkConfig;
  375. struct InterfaceConfig InterfaceConfig;
  376. struct IGMPConfig IGMPConfig;
  377. struct QoSParameters QoSParameters;
  378. struct ToneNotchParameters ToneNotchParameters;
  379. }
  380. PIB1_5;
  381. #ifndef __GNUC__
  382. #pragma pack (pop)
  383. #endif
  384. /*====================================================================*
  385. * PIB sub-structures introduced as of v2.0
  386. *--------------------------------------------------------------------*/
  387. #ifndef __GNUC__
  388. #pragma pack (push, 1)
  389. #endif
  390. typedef struct __packed FeatureConfiguration
  391. {
  392. uint8_t Reserved [128];
  393. }
  394. FeatureConfiguration;
  395. #ifndef __GNUC__
  396. #pragma pack (pop)
  397. #endif
  398. /*====================================================================*
  399. * PIB structure as of v2.0
  400. *--------------------------------------------------------------------*/
  401. #ifndef __GNUC__
  402. #pragma pack (push, 1)
  403. #endif
  404. typedef struct __packed PIB2_0
  405. {
  406. struct VersionHeader VersionHeader;
  407. struct LocalDeviceConfig LocalDeviceConfig;
  408. struct StaticNetworkConfig StaticNetworkConfig;
  409. struct InterfaceConfig InterfaceConfig;
  410. struct IGMPConfig IGMPConfig;
  411. struct QoSParameters QoSParameters;
  412. struct ToneNotchParameters ToneNotchParameters;
  413. struct FeatureConfiguration FeatureConfiguration;
  414. }
  415. PIB2_0;
  416. #ifndef __GNUC__
  417. #pragma pack (pop)
  418. #endif
  419. /*====================================================================*
  420. * PIB sub-structures introduced as of v3.0;
  421. *--------------------------------------------------------------------*/
  422. #ifndef __GNUC__
  423. #pragma pack (push, 1)
  424. #endif
  425. typedef struct __packed V3_0Configuration
  426. {
  427. uint32_t AVLNMembership;
  428. uint32_t SimpleConnectTimeout;
  429. uint8_t EnableLEDThroughputIndicate;
  430. uint8_t MidLEDThroughputThreshold;
  431. uint8_t HighLEDThroughputThreshold;
  432. uint8_t Reserved1;
  433. uint32_t EnableUnicastQueriesToMembers;
  434. uint32_t DisableExpireGroupMulticastInterval;
  435. uint32_t DisableLEDTestLights;
  436. uint8_t GPIOMap [12];
  437. uint8_t Reserved [8];
  438. }
  439. V3_0Configuration;
  440. #ifndef __GNUC__
  441. #pragma pack (pop)
  442. #endif
  443. /*====================================================================*
  444. * PIB structure as of v3.0;
  445. *--------------------------------------------------------------------*/
  446. #ifndef __GNUC__
  447. #pragma pack (push, 1)
  448. #endif
  449. typedef struct __packed PIB3_0
  450. {
  451. struct VersionHeader VersionHeader;
  452. struct LocalDeviceConfig LocalDeviceConfig;
  453. struct StaticNetworkConfig StaticNetworkConfig;
  454. struct InterfaceConfig InterfaceConfig;
  455. struct IGMPConfig IGMPConfig;
  456. struct QoSParameters QoSParameters;
  457. struct ToneNotchParameters ToneNotchParameters;
  458. struct FeatureConfiguration FeatureConfiguration;
  459. struct V3_0Configuration V3_0Configuration;
  460. }
  461. PIB3_0;
  462. #ifndef __GNUC__
  463. #pragma pack (pop)
  464. #endif
  465. /*====================================================================*
  466. * PIB sub-structures introduced as of v3.1;
  467. *--------------------------------------------------------------------*/
  468. #ifndef __GNUC__
  469. #pragma pack (push, 1)
  470. #endif
  471. typedef struct __packed V3_1Configuration
  472. {
  473. uint8_t Reserved [128];
  474. }
  475. V3_1Configuration;
  476. #ifndef __GNUC__
  477. #pragma pack (pop)
  478. #endif
  479. /*====================================================================*
  480. * PIB structure as of v3.1;
  481. *--------------------------------------------------------------------*/
  482. #ifndef __GNUC__
  483. #pragma pack (push, 1)
  484. #endif
  485. typedef struct __packed PIB3_1
  486. {
  487. struct VersionHeader VersionHeader;
  488. struct LocalDeviceConfig LocalDeviceConfig;
  489. struct StaticNetworkConfig StaticNetworkConfig;
  490. struct InterfaceConfig InterfaceConfig;
  491. struct IGMPConfig IGMPConfig;
  492. struct QoSParameters QoSParameters;
  493. struct ToneNotchParameters ToneNotchParameters;
  494. struct FeatureConfiguration FeatureConfiguration;
  495. struct V3_0Configuration V3_0Configuration;
  496. struct V3_1Configuration V3_1Configuration;
  497. }
  498. PIB3_1;
  499. #ifndef __GNUC__
  500. #pragma pack (pop)
  501. #endif
  502. /*====================================================================*
  503. * PIB structure as of v3.2
  504. *--------------------------------------------------------------------*/
  505. #ifndef __GNUC__
  506. #pragma pack (push, 1)
  507. #endif
  508. typedef struct __packed PIB3_2
  509. {
  510. struct VersionHeader VersionHeader;
  511. struct LocalDeviceConfig LocalDeviceConfig;
  512. struct StaticNetworkConfig StaticNetworkConfig;
  513. struct InterfaceConfig InterfaceConfig;
  514. struct IGMPConfig IGMPConfig;
  515. struct QoSParameters QoSParameters;
  516. struct ToneNotchParameters ToneNotchParameters;
  517. struct FeatureConfiguration FeatureConfiguration;
  518. struct V3_0Configuration V3_0Configuration;
  519. struct V3_1Configuration V3_1Configuration;
  520. }
  521. PIB3_2;
  522. #ifndef __GNUC__
  523. #pragma pack (pop)
  524. #endif
  525. /*====================================================================*
  526. * PIB sub-structure introduced as of v3.3;
  527. *--------------------------------------------------------------------*/
  528. #ifndef __GNUC__
  529. #pragma pack (push, 1)
  530. #endif
  531. typedef struct __packed V3_3Configuration
  532. {
  533. uint8_t Reserved [64];
  534. }
  535. V3_3Configuration;
  536. #ifndef __GNUC__
  537. #pragma pack (pop)
  538. #endif
  539. /*====================================================================*
  540. * PIB structure as of v3.3
  541. *--------------------------------------------------------------------*/
  542. #ifndef __GNUC__
  543. #pragma pack (push, 1)
  544. #endif
  545. typedef struct __packed PIB3_3
  546. {
  547. struct VersionHeader VersionHeader;
  548. struct LocalDeviceConfig LocalDeviceConfig;
  549. struct StaticNetworkConfig StaticNetworkConfig;
  550. struct InterfaceConfig InterfaceConfig;
  551. struct IGMPConfig IGMPConfig;
  552. struct QoSParameters QoSParameters;
  553. struct ToneNotchParameters ToneNotchParameters;
  554. struct FeatureConfiguration FeatureConfiguration;
  555. struct V3_0Configuration V3_0Configuration;
  556. struct V3_1Configuration V3_1Configuration;
  557. struct V3_3Configuration V3_3Configuration;
  558. }
  559. PIB3_3;
  560. #ifndef __GNUC__
  561. #pragma pack (pop)
  562. #endif
  563. /*====================================================================*
  564. * PIB structure as of v3.4
  565. *--------------------------------------------------------------------*/
  566. #ifndef __GNUC__
  567. #pragma pack (push, 1)
  568. #endif
  569. typedef struct __packed PIB3_4
  570. {
  571. struct VersionHeader VersionHeader;
  572. struct LocalDeviceConfig LocalDeviceConfig;
  573. struct StaticNetworkConfig StaticNetworkConfig;
  574. struct InterfaceConfig InterfaceConfig;
  575. struct IGMPConfig IGMPConfig;
  576. struct QoSParameters QoSParameters;
  577. struct ToneNotchParameters ToneNotchParameters;
  578. struct FeatureConfiguration FeatureConfiguration;
  579. struct V3_0Configuration V3_0Configuration;
  580. struct V3_1Configuration V3_1Configuration;
  581. struct V3_3Configuration V3_3Configuration;
  582. }
  583. PIB3_4;
  584. #ifndef __GNUC__
  585. #pragma pack (pop)
  586. #endif
  587. /*====================================================================*
  588. * PIB sub-structure introduced as of v3.5
  589. *--------------------------------------------------------------------*/
  590. #ifndef __GNUC__
  591. #pragma pack (push, 1)
  592. #endif
  593. typedef struct __packed FeatureGroupEnablement
  594. {
  595. uint8_t Reserved [16];
  596. }
  597. FeatureGroupEnablement;
  598. #ifndef __GNUC__
  599. #pragma pack (pop)
  600. #endif
  601. /*====================================================================*
  602. * PIB structure as of v3.5
  603. *--------------------------------------------------------------------*/
  604. #ifndef __GNUC__
  605. #pragma pack (push, 1)
  606. #endif
  607. typedef struct __packed PIB3_5
  608. {
  609. struct VersionHeader VersionHeader;
  610. struct LocalDeviceConfig LocalDeviceConfig;
  611. struct StaticNetworkConfig StaticNetworkConfig;
  612. struct InterfaceConfig InterfaceConfig;
  613. struct IGMPConfig IGMPConfig;
  614. struct QoSParameters QoSParameters;
  615. struct ToneNotchParameters ToneNotchParameters;
  616. struct FeatureConfiguration FeatureConfiguration;
  617. struct V3_0Configuration V3_0Configuration;
  618. struct V3_1Configuration V3_1Configuration;
  619. struct V3_3Configuration V3_3Configuration;
  620. struct FeatureGroupEnablement FeatureGroupEnablement;
  621. }
  622. PIB3_5;
  623. #ifndef __GNUC__
  624. #pragma pack (pop)
  625. #endif
  626. /*====================================================================*
  627. * PIB structure as of v3.6
  628. *--------------------------------------------------------------------*/
  629. #ifndef __GNUC__
  630. #pragma pack (push, 1)
  631. #endif
  632. typedef struct __packed PIB3_6
  633. {
  634. struct VersionHeader VersionHeader;
  635. struct LocalDeviceConfig LocalDeviceConfig;
  636. struct StaticNetworkConfig StaticNetworkConfig;
  637. struct InterfaceConfig InterfaceConfig;
  638. struct IGMPConfig IGMPConfig;
  639. struct QoSParameters QoSParameters;
  640. struct ToneNotchParameters ToneNotchParameters;
  641. struct FeatureConfiguration FeatureConfiguration;
  642. struct V3_0Configuration V3_0Configuration;
  643. struct V3_1Configuration V3_1Configuration;
  644. struct V3_3Configuration V3_3Configuration;
  645. struct FeatureGroupEnablement FeatureGroupEnablement;
  646. }
  647. PIB3_6;
  648. #ifndef __GNUC__
  649. #pragma pack (pop)
  650. #endif
  651. /*====================================================================*
  652. * functions;
  653. *--------------------------------------------------------------------*/
  654. signed pibseek (signed fd, char const * filename, flag_t flags);
  655. signed pibfile (struct _file_ const * pib);
  656. signed pibfile1 (struct _file_ const * pib);
  657. signed pibfile2 (struct _file_ const * pib);
  658. signed piblock (struct _file_ const * pib);
  659. signed pibpeek1 (void const * memory);
  660. signed pibpeek2 (void const * memory);
  661. uint16_t pibscalers (struct _file_ * pib);
  662. uint16_t psread (uint16_t values [], uint16_t limit, FILE * fp);
  663. /*====================================================================*
  664. *
  665. *--------------------------------------------------------------------*/
  666. #endif
  667. </pre>
  668. <div class='footerlink'>
  669. [<a href='pcap-stdinc.h.html' title=' pcap-stdinc.h '>PREV</a>]
  670. [<a href='toolkit.html' title=' Index '>HOME</a>]
  671. [<a href='plc.h.html' title=' plc.h '>NEXT</a>]
  672. </div>
  673. </body>
  674. </html>