drivers/char/hpet.c ACPI parsing

From: Tomas Winkler
Date: Tue Sep 03 2013 - 20:35:57 EST


In hpet_resources function

Can anybody explain why we check fixmem32 for NULL, looks strange as
it derreferences a member address

I'm asking since a static analyzer is complaining about it.

} else if (res->id == ACPI_RSTYPE_FIXED_MEM32) {
struct acpi_resource_fixed_mem32 *fixmem32;

fixmem32 = &res->data.fixed_memory32;
if (!fixmem32)
^^^^^^
return -EINVAL;

Thanks
Tomas
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/