sgw: extract appending a sgw HNA into its own function