Holger Hildebrandt | fa07499 | 2020-03-27 15:42:06 +0000 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2018 - present. Boling Consulting Solutions (bcsw.net) |
| 3 | * Copyright 2020-present Open Networking Foundation |
| 4 | |
| 5 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | * you may not use this file except in compliance with the License. |
| 7 | * You may obtain a copy of the License at |
| 8 | |
| 9 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | |
| 11 | * Unless required by applicable law or agreed to in writing, software |
| 12 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | * See the License for the specific language governing permissions and |
| 15 | * limitations under the License. |
| 16 | */ |
David K. Bainbridge | d80007b | 2021-04-12 12:22:29 +0000 | [diff] [blame] | 17 | /* |
Holger Hildebrandt | fa07499 | 2020-03-27 15:42:06 +0000 | [diff] [blame] | 18 | * NOTE: This file was generated, manual edits will be overwritten! |
| 19 | * |
| 20 | * Generated by 'goCodeGenerator.py': |
| 21 | * https://github.com/cboling/OMCI-parser/README.md |
| 22 | */ |
| 23 | |
| 24 | package generated |
| 25 | |
| 26 | import "github.com/deckarep/golang-set" |
| 27 | |
| 28 | // MacBridgePortFilterPreAssignTableClassID is the 16-bit ID for the OMCI |
| 29 | // Managed entity MAC bridge port filter pre-assign table |
mpagenko | 836a1fd | 2021-11-01 16:12:42 +0000 | [diff] [blame] | 30 | const MacBridgePortFilterPreAssignTableClassID = ClassID(79) // 0x004f |
Holger Hildebrandt | fa07499 | 2020-03-27 15:42:06 +0000 | [diff] [blame] | 31 | |
| 32 | var macbridgeportfilterpreassigntableBME *ManagedEntityDefinition |
| 33 | |
mpagenko | 836a1fd | 2021-11-01 16:12:42 +0000 | [diff] [blame] | 34 | // MacBridgePortFilterPreAssignTable (Class ID: #79 / 0x004f) |
Holger Hildebrandt | fa07499 | 2020-03-27 15:42:06 +0000 | [diff] [blame] | 35 | // This ME provides an alternate approach to DA filtering from that supported through the MAC |
| 36 | // bridge port filter table data ME. This alternate approach is useful when all groups of addresses |
| 37 | // are stored beforehand in the ONU, and the MAC bridge port filter pre-assign table ME designates |
| 38 | // which groups are valid or invalid for filtering. On a circuit pack in which all groups of |
| 39 | // addresses are pre-assigned and stored locally, the ONU creates or deletes an instance of this ME |
| 40 | // automatically upon creation or deletion of a MAC bridge port configuration data ME. |
| 41 | // |
| 42 | // Relationships |
| 43 | // An instance of this ME is associated with an instance of a MAC bridge port configuration data |
| 44 | // ME. |
| 45 | // |
| 46 | // Attributes |
| 47 | // Managed Entity Id |
mpagenko | 836a1fd | 2021-11-01 16:12:42 +0000 | [diff] [blame] | 48 | // The following 10 attributes have similar definitions. Each permits the OLT to specify whether |
| 49 | // MAC DAs or Ethertypes of the named type are forwarded (0) or filtered (1). In each case, the |
| 50 | // initial value of the attribute is 0. |
| 51 | // |
| 52 | // This attribute uniquely identifies each instance of this ME. Through an identical ID, this ME is |
| 53 | // implicitly linked to an instance of the MAC bridge port configuration data ME. (R) (mandatory) |
| 54 | // (2-bytes) |
Holger Hildebrandt | fa07499 | 2020-03-27 15:42:06 +0000 | [diff] [blame] | 55 | // |
| 56 | // Ipv4 Multicast Filtering |
mpagenko | 836a1fd | 2021-11-01 16:12:42 +0000 | [diff] [blame] | 57 | // (R,-W) (mandatory) (1-byte) |
Holger Hildebrandt | fa07499 | 2020-03-27 15:42:06 +0000 | [diff] [blame] | 58 | // |
| 59 | // Ipv6 Multicast Filtering |
mpagenko | 836a1fd | 2021-11-01 16:12:42 +0000 | [diff] [blame] | 60 | // (R,-W) (mandatory) (1-byte) |
Holger Hildebrandt | fa07499 | 2020-03-27 15:42:06 +0000 | [diff] [blame] | 61 | // |
| 62 | // Ipv4 Broadcast Filtering |
mpagenko | 836a1fd | 2021-11-01 16:12:42 +0000 | [diff] [blame] | 63 | // (R,-W) (mandatory) (1-byte) |
Holger Hildebrandt | fa07499 | 2020-03-27 15:42:06 +0000 | [diff] [blame] | 64 | // |
| 65 | // Rarp Filtering |
mpagenko | 836a1fd | 2021-11-01 16:12:42 +0000 | [diff] [blame] | 66 | // (R,-W) (mandatory) (1-byte) |
Holger Hildebrandt | fa07499 | 2020-03-27 15:42:06 +0000 | [diff] [blame] | 67 | // |
| 68 | // Ipx Filtering |
mpagenko | 836a1fd | 2021-11-01 16:12:42 +0000 | [diff] [blame] | 69 | // (R,-W) (mandatory) (1-byte) |
Holger Hildebrandt | fa07499 | 2020-03-27 15:42:06 +0000 | [diff] [blame] | 70 | // |
| 71 | // Netbeui Filtering |
mpagenko | 836a1fd | 2021-11-01 16:12:42 +0000 | [diff] [blame] | 72 | // (R,-W) (mandatory) (1-byte) |
Holger Hildebrandt | fa07499 | 2020-03-27 15:42:06 +0000 | [diff] [blame] | 73 | // |
| 74 | // Appletalk Filtering |
mpagenko | 836a1fd | 2021-11-01 16:12:42 +0000 | [diff] [blame] | 75 | // (R,-W) (mandatory) (1-byte) |
Holger Hildebrandt | fa07499 | 2020-03-27 15:42:06 +0000 | [diff] [blame] | 76 | // |
| 77 | // Bridge Management Information Filtering |
mpagenko | 836a1fd | 2021-11-01 16:12:42 +0000 | [diff] [blame] | 78 | // (R,-W) (mandatory) (1-byte) |
| 79 | // |
| 80 | // Note that some destination MAC addresses should never be forwarded, considering the following |
| 81 | // rules of [IEEE 802.1D]. |
| 82 | // |
| 83 | // 1 Addresses from 01.80.C2.00.00.00 to 01.80.C2.00.00.0F are reserved. |
| 84 | // |
Holger Hildebrandt | fa07499 | 2020-03-27 15:42:06 +0000 | [diff] [blame] | 85 | // 2 Addresses from 01.80.C2.00.00.20 to 01.80.C2.00.00.2F are used for generic attribute |
| 86 | // registration protocol (GARP) applications. |
| 87 | // |
| 88 | // Arp Filtering |
mpagenko | 836a1fd | 2021-11-01 16:12:42 +0000 | [diff] [blame] | 89 | // (R,-W) (mandatory) (1-byte) |
Holger Hildebrandt | fa07499 | 2020-03-27 15:42:06 +0000 | [diff] [blame] | 90 | // |
| 91 | // Point_To_Point Protocol Over Ethernet Pppoe Broadcast Filtering |
| 92 | // Point-to-point protocol over Ethernet (PPPoE) broadcast filtering: (R,-W) (mandatory) (1-byte) |
| 93 | // |
| 94 | type MacBridgePortFilterPreAssignTable struct { |
| 95 | ManagedEntityDefinition |
| 96 | Attributes AttributeValueMap |
| 97 | } |
| 98 | |
| 99 | func init() { |
| 100 | macbridgeportfilterpreassigntableBME = &ManagedEntityDefinition{ |
| 101 | Name: "MacBridgePortFilterPreAssignTable", |
| 102 | ClassID: 79, |
| 103 | MessageTypes: mapset.NewSetWith( |
| 104 | Get, |
| 105 | Set, |
| 106 | ), |
| 107 | AllowedAttributeMask: 0xffc0, |
| 108 | AttributeDefinitions: AttributeDefinitionMap{ |
| 109 | 0: Uint16Field("ManagedEntityId", PointerAttributeType, 0x0000, 0, mapset.NewSetWith(Read), false, false, false, 0), |
| 110 | 1: ByteField("Ipv4MulticastFiltering", UnsignedIntegerAttributeType, 0x8000, 0, mapset.NewSetWith(Read, Write), false, false, false, 1), |
| 111 | 2: ByteField("Ipv6MulticastFiltering", UnsignedIntegerAttributeType, 0x4000, 0, mapset.NewSetWith(Read, Write), false, false, false, 2), |
| 112 | 3: ByteField("Ipv4BroadcastFiltering", UnsignedIntegerAttributeType, 0x2000, 0, mapset.NewSetWith(Read, Write), false, false, false, 3), |
| 113 | 4: ByteField("RarpFiltering", UnsignedIntegerAttributeType, 0x1000, 0, mapset.NewSetWith(Read, Write), false, false, false, 4), |
| 114 | 5: ByteField("IpxFiltering", UnsignedIntegerAttributeType, 0x0800, 0, mapset.NewSetWith(Read, Write), false, false, false, 5), |
| 115 | 6: ByteField("NetbeuiFiltering", UnsignedIntegerAttributeType, 0x0400, 0, mapset.NewSetWith(Read, Write), false, false, false, 6), |
| 116 | 7: ByteField("AppletalkFiltering", UnsignedIntegerAttributeType, 0x0200, 0, mapset.NewSetWith(Read, Write), false, false, false, 7), |
| 117 | 8: ByteField("BridgeManagementInformationFiltering", UnsignedIntegerAttributeType, 0x0100, 0, mapset.NewSetWith(Read, Write), false, false, false, 8), |
| 118 | 9: ByteField("ArpFiltering", UnsignedIntegerAttributeType, 0x0080, 0, mapset.NewSetWith(Read, Write), false, false, false, 9), |
| 119 | 10: ByteField("PointToPointProtocolOverEthernetPppoeBroadcastFiltering", UnsignedIntegerAttributeType, 0x0040, 0, mapset.NewSetWith(Read, Write), false, false, false, 10), |
| 120 | }, |
| 121 | Access: CreatedByOnu, |
| 122 | Support: UnknownSupport, |
| 123 | } |
| 124 | } |
| 125 | |
| 126 | // NewMacBridgePortFilterPreAssignTable (class ID 79) creates the basic |
| 127 | // Managed Entity definition that is used to validate an ME of this type that |
| 128 | // is received from or transmitted to the OMCC. |
| 129 | func NewMacBridgePortFilterPreAssignTable(params ...ParamData) (*ManagedEntity, OmciErrors) { |
| 130 | return NewManagedEntity(*macbridgeportfilterpreassigntableBME, params...) |
| 131 | } |