How to control the gpio in orin nx(jetpack6.x)

Hi,
Please use libgpiod as suggested in:
40hdr - SPI1 gpio padctl register bit[10] effect by gpiod tools in JP6 - #14 by lhoang

And there is a known issue. Please apply this fix and rebuild kernel:
Jetson AGX Orin FAQ