Re: [PATCH v6 2/7] kbuild: implement and use depcheck to check dependency timestamps

From: Miguel Ojeda

Date: Wed Nov 25 2026 - 10:34:06 EST


On Tue, Nov 24, 2026 at 1:20 PM Lorenzo Stoakes (ARM) <ljs@xxxxxxxxxx> wrote:
>
> A dependency that is also a target of the same directory (e.g. header
> generated by an if_changed rule) may get remade later in the same make run,
> so do not treat a target as fresh.

One more thing I noticed: a header generated with `filechk` does not
have a `.cmd` file, so it is not covered by this.

It matters for targets that reach such a header through their `.cmd`
file alone, e.g. single targets like `.s`. For instance, after
building `arch/x86/kvm/`:

make arch/x86/kvm/vmx/vmenter.s
# Change an offset in `kvm-asm-offsets.c`.
make arch/x86/kvm/vmx/vmenter.s

In mainline, the second one regenerates `kvm-asm-offsets.h` and then
`vmenter.s`. With this patch, nothing is rebuilt.

Cheers,
Miguel