[PATCH] fm10k_main.c: fix missing return value check of alloc_skb()

2018-08-17 Thread Jiecheng Wu
Function fm10k_init_module() defined in drivers/net/ethernet/intel/fm10k/fm10k_main.c calls alloc_workqueue() to allocate memory for struct workqueue_struct which is dereferenced immediately. As alloc_workqueue() may return NULL on failure, this code piece may cause NULL pointer dereference

Re: [PATCH] fm10k_main.c: fix missing return value check of alloc_skb()

2018-08-17 Thread Andrew Lunn
On Sat, Aug 18, 2018 at 10:00:58AM +0800, Jiecheng Wu wrote: > Function fm10k_init_module() defined in > drivers/net/ethernet/intel/fm10k/fm10k_main.c calls alloc_workqueue() to > allocate memory for struct workqueue_struct which is dereferenced > immediately. As alloc_workqueue() may return NUL

[PATCH] fm10k_main.c: fix missing return value check of alloc_skb()

2018-08-17 Thread Jiecheng Wu
Function fm10k_init_module() defined in drivers/net/ethernet/intel/fm10k/fm10k_main.c calls alloc_workqueue() to allocate memory for struct workqueue_struct which is dereferenced immediately. As alloc_workqueue() may return NULL on failure, this code piece may cause NULL pointer dereference bug