rtcan_flexcan: fix devtype_data initialization
PATCH 1/1 rtcan_flexcan: fix devtype_data initialization
fix devtype_data initialization when using CONFIG_OF and dtb file
--- ksrc/drivers/can/rtcan_flexcan.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
ksrc/drivers/can/rtcan_flexcan.c +4 -2
@@ -1055,8 +1055,10 @@ static int flexcan_probe(struct platform_device *pdev) devtype_data = (struct flexcan_devtype_data *) pdev->id_entry->driver_data; }else { - err = -ENODEV ; - goto out_error; +if (!devtype_data){ + err = -ENODEV ; + goto out_error; + } }if (!clock_freq) {
Signature · 1 line
1.7.9.5
Gilles Chanteperdrix
AppliedQuoted 1 line · Alexandre Coffignal
fix
devtype_datainitialization when usingCONFIG_OFand dtb file
Merged, thanks.
Signature · 1 line
Gilles.