If dev_get_platdata has failed pd is null. Do not dereference a null pointer. Signed-off-by: Heinrich Schuchardt <[email protected]> Signed-off-by: David S. Miller <[email protected]>