
Unmanaged Switch
API Document
Ver 1.4.3
29
th
April, 2022
Realtek Semiconductor Corp.
No. 2, Innovation Road II, Hsinchu Science Park,
Hsinchu 300, Taiwan
Tel: +886-3-578-0211 Fax: +886-3-577-6047
www.realtek.com

Unmanaged Switch API Document
Realtek confidential documentation Rev 1.4.3
COPYRIGHT
© 2020-2022 Realtek Semiconductor Corp. All rights reserved. No part of this document
may be reproduced, transmitted, transcribed, stored in a retrieval system, or translated into
any language in any form or by any means without the written permission of Realtek
Semiconductor Corp.
TRADEMARKS
Realtek is a trademark of Realtek Semiconductor Corporation. Other names mentioned in
this document are trademarks/registered trademarks of their respective owners.
DISCLAIMER
Realtek provides this document “as is”, without warranty of any kind, neither expressed nor
implied, including, but not limited to, the particular purpose. Realtek may make
improvements and/or changes in this document or in the product described in this document
at any time. This document could include technical inaccuracies or typographical errors.
USING THIS DOCUMENT
This document is intended for use by the system engineer when integrating with Realtek
Switch Software SDK. Though every effort has been made to assure that this document is
current and accurate, more information may have become available subsequent to the
production of this guide. In that event, please contact your Realtek representative for
additional information that may help in the development process.

Unmanaged Switch API Document
Realtek confidential documentation Rev 1.4.3
REVISION HISTORY
Revision
Date
Description
Author
1.4.0
2020/06/11
First Release
Realtek
1.4.1
2021/08/11
Add API rtk_port_fiberAbility_set
Add API rtk_port_fiberAbility_get
Realtek
1.4.2
2021/11/30
Add API rtk_port_phyMdx_set
Add API rtk_port_phyMdx_get
Add API rtk_port_phyMdxStatus_get
Add API rtk_gpio_input_get
Add API rtk_gpio_output_set
Add API rtk_gpio_output_get
Add API rtk_gpio_state_set
Add API rtk_gpio_state_get
Add API rtk_gpio_mode_set
Add API rtk_gpio_mode_get
Add API rtk_gpio_aclEnClear_set
Add API rtk_gpio_aclEnClear_get
Add API rtk_port_phyTestMode_set
Add API rtk_port_phyTestMode_get
Realtek
1.4.3
Add API rtk_port_maxPacketLength_set
Add API rtk_port_maxPacketLength_get
Add API rtk_port_phyGreenEthernet_set
Add API rtk_port_phyGreenEthernet_get
Add API rtk_port_phyLinkDownPowerSaving_set
Add API rtk_port_phyLinkDownPowerSaving_get
Realtek


Unmanaged Switch API Document
Realtek confidential documentation Rev 1.4.3
i
1. Module acl.h - Unmanaged switch high-level API .............................................................................. 20
1.1. rtk_filter_igrAcl_init ................................................................................................................. 21
1.2. rtk_filter_igrAcl_field_add ....................................................................................................... 21
1.3. rtk_filter_igrAcl_cfg_add .......................................................................................................... 22
1.4. rtk_filter_igrAcl_cfg_del ........................................................................................................... 23
1.5. rtk_filter_igrAcl_cfg_delAll ..................................................................................................... 23
1.6. rtk_filter_igrAcl_cfg_get ........................................................................................................... 23
1.7. rtk_filter_igrAcl_unmatchAction_set ....................................................................................... 24
1.8. rtk_filter_igrAcl_unmatchAction_get ....................................................................................... 25
1.9. rtk_filter_igrAcl_state_set ......................................................................................................... 25
1.10. rtk_filter_igrAcl_state_get ........................................................................................................ 26
1.11. rtk_filter_igrAcl_template_set .................................................................................................. 26
1.12. rtk_filter_igrAcl_template_get .................................................................................................. 27
1.13. rtk_filter_igrAcl_field_sel_set .................................................................................................. 27
1.14. rtk_filter_igrAcl_field_sel_get .................................................................................................. 28
1.15. rtk_filter_iprange_set ................................................................................................................ 28
1.16. rtk_filter_iprange_get ................................................................................................................ 29
1.17. rtk_filter_vidrange_set .............................................................................................................. 30
1.18. rtk_filter_vidrange_get .............................................................................................................. 30
1.19. rtk_filter_portrange_set ............................................................................................................. 31
1.20. rtk_filter_portrange_get ............................................................................................................. 32
1.21. rtk_filter_igrAclPolarity_set ..................................................................................................... 32
1.22. rtk_filter_igrAclPolarity_get ..................................................................................................... 33
2. Module cpu.h - Unmanaged switch high-level API ............................................................................. 33
2.1. rtk_cpu_enable_set .................................................................................................................... 34
2.2. rtk_cpu_enable_get .................................................................................................................... 34
2.3. rtk_cpu_tagPort_set ................................................................................................................... 35
2.4. rtk_cpu_tagPort_get .................................................................................................................. 35