It is not the expected result to use the pin as GPIO.
Do you run gpioget before gpioset command?
Please apply the patch from 40hdr - SPI1 gpio padctl register bit[10] effect by gpiod tools in JP6 - #20 by KevinFFF to check if it could help in your case.