mirror-linux/drivers/net/ethernet/pensando/ionic
Shannon Nelson 4a54903ff6 ionic: catch failure from devlink_alloc
Add a check for NULL on the alloc return.  If devlink_alloc() fails and
we try to use devlink_priv() on the NULL return, the kernel gets very
unhappy and panics. With this fix, the driver load will still fail,
but at least it won't panic the kernel.

Fixes: df69ba4321 ("ionic: Add basic framework for IONIC Network device driver")
Signed-off-by: Shannon Nelson <shannon.nelson@amd.com>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
Reviewed-by: Jiri Pirko <jiri@nvidia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2023-05-03 09:14:47 +01:00
..
Makefile
ionic.h
ionic_bus.h
ionic_bus_pci.c ionic: Remove redundant pci_clear_master 2023-03-24 09:09:28 +00:00
ionic_debugfs.c
ionic_debugfs.h
ionic_dev.c ionic: add tx/rx-push support with device Component Memory Buffers 2023-02-13 11:05:12 +00:00
ionic_dev.h ionic: add tx/rx-push support with device Component Memory Buffers 2023-02-13 11:05:12 +00:00
ionic_devlink.c ionic: catch failure from devlink_alloc 2023-05-03 09:14:47 +01:00
ionic_devlink.h
ionic_ethtool.c ionic: remove noise from ethtool rxnfc error msg 2023-05-03 09:08:02 +01:00
ionic_ethtool.h
ionic_fw.c
ionic_if.h ionic: add tx/rx-push support with device Component Memory Buffers 2023-02-13 11:05:12 +00:00
ionic_lif.c ionic: add tx/rx-push support with device Component Memory Buffers 2023-02-13 11:05:12 +00:00
ionic_lif.h ionic: add tx/rx-push support with device Component Memory Buffers 2023-02-13 11:05:12 +00:00
ionic_main.c ionic: remove unnecessary void casts 2023-02-13 11:05:11 +00:00
ionic_phc.c ionic: Don't overwrite the cyclecounter bitmask 2023-04-12 09:36:25 +01:00
ionic_regs.h
ionic_rx_filter.c ionic: remove unnecessary void casts 2023-02-13 11:05:11 +00:00
ionic_rx_filter.h
ionic_stats.c
ionic_stats.h
ionic_txrx.c ionic: add tx/rx-push support with device Component Memory Buffers 2023-02-13 11:05:12 +00:00
ionic_txrx.h