Skip to content

feat: add NRNTN-TAI-Information protocol IE/extension ID#87

Merged
gab-arrobo merged 3 commits into
omec-project:mainfrom
donivtech:feat/nrntn-tai-information-id
Apr 30, 2026
Merged

feat: add NRNTN-TAI-Information protocol IE/extension ID#87
gab-arrobo merged 3 commits into
omec-project:mainfrom
donivtech:feat/nrntn-tai-information-id

Conversation

@donivtech
Copy link
Copy Markdown
Contributor

@donivtech donivtech commented Apr 29, 2026

Adds NGAP support consumed by omec-project/amf#684 (NR NTN access detection).

Changes

  • ngapType/ProtocolIEID.go: add the protocol IE/extension identifier 287 assigned to NRNTN-TAI-Information per 3GPP TS 38.413. Follows the existing repo convention where ProtocolIEID* constants are the sole declaration for an NGAP identifier regardless of whether it is used as a ProtocolIE-ID, a ProtocolExtensionID, or both — NGAP's ASN.1 reuses one integer numbering space across both kinds (e.g. id-PSCellInformation = 149).
  • extensions.go (new): add HasUserLocationInformationNRExtension(*ngapType.UserLocationInformationNR, id int64) bool, a generic helper that reports whether a protocol extension with the supplied identifier is present in UserLocationInformationNR.IEExtensions. Generic over the ID so any future protocol-extension presence check can compose with the ProtocolIEID* constants.
  • extensions_test.go (new): 6 table-driven cases covering nil location, nil extensions, empty list, unrelated ID, matching ID, and matching ID among several.
  • VERSION: drop -dev to cut release v1.9.1 so omec-project/amf#684 can pick these additions up via a go.mod bump (per maintainer request in the review thread).

Out of scope

The full Rel-17 IE type (NRNTNTAIInformation SEQUENCE) and the rest of the Rel-16/17/18 IE IDs are expected to land as part of the broader NGAP release uplift.

Test plan

  • go build ./... clean
  • go vet ./... clean
  • go test ./... all pass
  • golangci-lint run (v2.6.1) — 0 issues

@donivtech donivtech requested a review from a team April 29, 2026 07:23
Add the NGAP protocol IE/extension identifier 287 assigned to
NRNTN-TAI-Information per 3GPP TS 38.413. This IE-extension is
optionally carried inside UserLocationInformationNR.IEExtensions
and indicates that the UE is being served over NR Non-Terrestrial
Network access.

The full Rel-17 IE type (NRNTNTAIInformation SEQUENCE) is not yet
defined here; this commit only adds the bare ID so that callers
checking presence of the extension can reference a canonical
constant rather than hard-coding 287. The type definition and the
remaining Rel-16/17/18 IE IDs are expected to land as part of the
broader NGAP release uplift.

Used by omec-project/amf#684 (NTN access detection).

Signed-off-by: Vinod Patmanathan <vinod.patmanathan@forsway.com>
@gab-arrobo
Copy link
Copy Markdown
Contributor

@donivtech, please also remove "-dev" from VERSION file (as part of this PR) such that a new release is automatically created when this PR is merged. Thanks!

@donivtech
Copy link
Copy Markdown
Contributor Author

Done. Added "Create patch release" commit dropping -dev from VERSION. Thanks!

@gab-arrobo
Copy link
Copy Markdown
Contributor

Is there anything else from your AMF PR that should go in this NGAP PR?

@donivtech
Copy link
Copy Markdown
Contributor Author

The constant was the only AMF ngap-side dependency. Though there's a small AMF-internal helper nrLocationHasNtnExt(*ngapType.UserLocationInformationNR) bool that traverses IEExtensions for the ID, but it's 8 lines, called from a single site, that could be moved to ngap. But there are no similar helper functions in ngap. Otherwise nothing else.

@gab-arrobo
Copy link
Copy Markdown
Contributor

The constant was the only AMF ngap-side dependency. Though there's a small AMF-internal helper nrLocationHasNtnExt(*ngapType.UserLocationInformationNR) bool that traverses IEExtensions for the ID, but it's 8 lines, called from a single site, that could be moved to ngap. But there are no similar helper functions in ngap. Otherwise nothing else.

Would it make sense to move it here? I am asking this because it would be good to keep NGAP related stuff in it own repo such that when time comes to upgrade N2 release, we know it is there and not "hidden" in some other repo.. what so you think?

@donivtech
Copy link
Copy Markdown
Contributor Author

Yes sound good. Will move it as HasUserLocationInformationNRExtension(*ngapType.UserLocationInformationNR, id int64) bool (top-level ngap package, alongside the existing Decoder/Encoder). Generic over the ID instead of ntn-specific so the helper is reusable for any future protocol-extension presence check. Will push shortly

@donivtech donivtech force-pushed the feat/nrntn-tai-information-id branch from ee6591b to 880d765 Compare April 29, 2026 17:05
@gab-arrobo gab-arrobo requested a review from Copilot April 29, 2026 17:29
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds support for the NRNTN-TAI-Information identifier so downstream components (e.g., AMF) can reference a canonical NGAP constant when handling NR NTN-related location extensions.

Changes:

  • Add ProtocolIEIDNRNTNTAIInformation constant with value 287.
  • Introduce HasUserLocationInformationNRExtension helper for checking presence of an NR UserLocationInformation extension ID.
  • Add unit tests for the new helper and update VERSION from 1.9.1-dev to 1.9.1.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 5 comments.

File Description
ngapType/ProtocolIEID.go Adds the new NRNTN-TAI-Information identifier constant (287).
extensions.go Adds an exported helper to detect a specific extension ID in UserLocationInformationNR.IEExtensions.
extensions_test.go Adds coverage for the new helper across nil/empty/matching/non-matching cases.
VERSION Switches from a -dev version to a release version, which can trigger release automation.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread VERSION
Comment thread ngapType/ProtocolIEID.go
Comment thread extensions.go Outdated
Comment thread extensions_test.go
Comment thread extensions.go
@donivtech
Copy link
Copy Markdown
Contributor Author

Addressing review comments:
1 , 5 (PR scope and description): The description is stale. Will update with correct scope.
3 (doc comment): Will tighten to refer to "ID" / "ProtocolExtensionID" and explicitly note the shared NGAP IE/extension numbering space.
2, 4 (naming): The repo's existing convention follows shared numbering space between ProtocolIE-ID and ProtocolExtensionID e.g id-PSCellInformation = 149 is the same number used in both contexts. Adding a ProtocolExtensionIDNRNTNTAIInformation alias just for our one constant would be inconsistent with the rest.

Vinod Patmanathan added 2 commits April 30, 2026 09:45
Add a small NGAP-aware helper that reports whether a given
UserLocationInformationNR carries a protocol extension with the
specified ProtocolIE-ID inside its IEExtensions container.

Generic over the extension ID, so callers can compose it with any
existing or future ProtocolIEID* constant (NRNTN-TAI-Information being
the immediate use case from omec-project/amf#684).

Keeping NGAP-aware inspection helpers in this repo makes the eventual
N2 release uplift easier to scope: all NGAP-touching code lives here.

Signed-off-by: Vinod Patmanathan <vinod.patmanathan@forsway.com>
Signed-off-by: Vinod Patmanathan <vinod.patmanathan@forsway.com>
@donivtech donivtech force-pushed the feat/nrntn-tai-information-id branch from 880d765 to 51fab30 Compare April 30, 2026 07:45
Copy link
Copy Markdown
Contributor

@gab-arrobo gab-arrobo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

@gab-arrobo gab-arrobo merged commit 0126dda into omec-project:main Apr 30, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants