title: PREEMPT_RT Kernel Jetson TX-NX
body: <p>Hi,
  I need to compile an RT kernel for a Jetson TX2-NX, I followed the explanations <a href="https://docs.nvidia.com/jetson/archives/l4t-archived/l4t-3261/index.html#page/Tegra%20Linux%20Driver%20Package%20Development%20Guide/kernel_custom.html#" rel="nofollow noreferrer">here</a> to apply the patch and re-compile the kernel.</p>
  <p>However, this error appears</p>
  <pre><code>/path/to/kernel/kernel-4.9/arch/arm64/boot/dts/Makefile:119: target 'arch/arm64/boot/_ddot_'  given more than once in the same rule
  ...
  make[2]: ***  No rules for making the target arch/arm64/boot/dts/..//hardware/nvidia/platform/t19x/mccoy/kernel-dts/tegra194-p2888-0004-e3900-0000.dts, necessary for  arch/arm64/boot/dts/_ddot_//hardware/nvidia/platform/t19x/mccoy/kernel-dts/tegra194-p2888-0004-e3900-0000.dtb . Stop.
  </code></pre>
  <blockquote>
  <p>the first error appears 465 times</p>
  </blockquote>
  <p>After going through several forums and tutorials I broke down my compilation.</p>
  <pre><code>make -C kernel/kernel-4.9/ ARCH=arm64 O=$KERNEL_OUT tegra_defconfig 
  make -C kernel/kernel-4.9/ ARCH=arm64 O=$KERNEL_OUT CROSS_COMPILE=${CROSS_COMPILE} -j$N_CORE Image
  make -C kernel/kernel-4.9/ ARCH=arm64 O=$KERNEL_OUT CROSS_COMPILE=${CROSS_COMPILE} -j$N_CORE dtbs 
  make -C kernel/kernel-4.9/ ARCH=arm64 O=$KERNEL_OUT CROSS_COMPILE=${CROSS_COMPILE} -j$N_CORE modules 
  make -C kernel/kernel-4.9/ ARCH=arm64 O=$KERNEL_OUT modules_install INSTALL_MOD_PATH=$KERNEL_MODULES_OUT
  </code></pre>
  <p>Thanks to this I realised that this error came from the compilation of the <code>dtbs</code></p>
  <p>I found a forum talking about this error <a href="https://forums.developer.nvidia.com/t/failed-to-make-l4t-kernel-dts/116399" rel="nofollow noreferrer">here</a> but the solution found there is not feasible in my case.</p>
  <p>Does anyone know how to solve this problem?</p>