On Mon, Mar 06, 2017 at 09:03:56PM +0100, Niklas Söderlund wrote: > If the memory resource for a TSC is unviable probe should fail not try > to go ahead with the remaining TSC. This fix is aligned with other > checks in probe where probe fails if they are unavailable. > > Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@xxxxxxxxxxxx> I disagree. There are likely SoCs in the future which have less than TSC_MAX_NUM sensors (V3M shall have only 1 according to chapter 10C in v0.52 documentation). So, the code exits the loop for this case. We should move it before the devm_kzalloc(), however. That also means that you can't really iterate over TSC_MAX_NUM in later patches, but rather store the amount of instances in the main struct and iterate over that value.