Variables to define targets and subtargets for Makefile building

I need to define different conditions in a Makefile depending on the target and/or subtarget that is getting cross compiled. I know this works to select x86_64:

ifdef CONFIG_TARGET_x86_64
        ...
endif

Where can I find a list of valid values for others?

Do I simply use the dir names under target/linux/xxx/yyy where xxx represents an entire target and where yyy are the subtargets?

For example, Raspberry Pi4/5 drawing from my yyy analogy:

ifdef CONFIG_TARGET_bcm2711||CONFIG_TARGET_bcm2712
      ...
endif

If I wanted to expand it all of the bcm devices would I draw from the xxx analogy and simply do:

ifdef CONFIG_TARGET_bcm27xx
      ...
endif

Hey John,

I think they are all listed at the top of .config (some of the items listed aren't targets, but the first 50 or so are...

Eric

$  grep CONFIG_TARGET_ .config
# CONFIG_TARGET_airoha is not set
# CONFIG_TARGET_d1 is not set
# CONFIG_TARGET_sunxi is not set
# CONFIG_TARGET_apm821xx is not set
# CONFIG_TARGET_armsr is not set
# CONFIG_TARGET_ath79 is not set
# CONFIG_TARGET_bcm27xx is not set
# CONFIG_TARGET_bcm53xx is not set
# CONFIG_TARGET_bcm47xx is not set
...