File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
drivers/platform/mellanox Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -1198,15 +1198,18 @@ static int nvsw_sn2201_config_pre_init(struct nvsw_sn2201 *nvsw_sn2201)
1198
1198
static int nvsw_sn2201_probe (struct platform_device * pdev )
1199
1199
{
1200
1200
struct nvsw_sn2201 * nvsw_sn2201 ;
1201
+ int ret ;
1201
1202
1202
1203
nvsw_sn2201 = devm_kzalloc (& pdev -> dev , sizeof (* nvsw_sn2201 ), GFP_KERNEL );
1203
1204
if (!nvsw_sn2201 )
1204
1205
return - ENOMEM ;
1205
1206
1206
1207
nvsw_sn2201 -> dev = & pdev -> dev ;
1207
1208
platform_set_drvdata (pdev , nvsw_sn2201 );
1208
- platform_device_add_resources (pdev , nvsw_sn2201_lpc_io_resources ,
1209
+ ret = platform_device_add_resources (pdev , nvsw_sn2201_lpc_io_resources ,
1209
1210
ARRAY_SIZE (nvsw_sn2201_lpc_io_resources ));
1211
+ if (ret )
1212
+ return ret ;
1210
1213
1211
1214
nvsw_sn2201 -> main_mux_deferred_nr = NVSW_SN2201_MAIN_MUX_DEFER_NR ;
1212
1215
nvsw_sn2201 -> main_mux_devs = nvsw_sn2201_main_mux_brdinfo ;
You can’t perform that action at this time.
0 commit comments