Download linux kernel source for grinch 23.1 on jetson /usr/src

I need some help to download the linux kernel source for the grinch 23.1
I need to compile CAN-USB2 driver from CANESD and it appears that I need to customize and compile the kernel source code to install it’s driver.

My jetson board has following kernel and kernel source

ubuntu@tegra-ubuntu:~$ uname -r
3.10.40-grinch-21.3.4

ubuntu@tegra-ubuntu:/usr/src$ ls
gtest linux-headers-3.10.40-gdacac96

How do I get linux-headers-3.10.40-grinch-21.3.4 inside /usr/src?

I tried following instructions here https://wiki.ubuntu.com/Kernel/SourceCode

But the instructions to download the kernel source does not work as the kernel version name is atypical to what we see in Ubuntu generic headers.

Any pointers would be a great help.

Thanks in advance for your time.
Bikram

This is an old thread which had Grinch source for R21.x:
https://devtalk.nvidia.com/default/topic/883595/embedded-systems/attempting-to-compile-kernel-sources-as-described-make-j4-fails-/post/4691280/#4691280

Basically download all of that, and then from main source you apply each patch (I think it was "patch -p 1 ", but might need different "-p " like “0”). That’s the source…you won’t fid it on git repositories so far as I know.

I’ve never checked how to manually separate out headers, but this is probably just the “include” directory within the source. Source is of course everything, and header packages have the “include” files as a subset of the source. If you have the full source, you have the headers, but might need to name the directory of the headers within the full source.