[PATCH AUTOSEL for 4.9 090/190] mt7601u: check return value of alloc_skb

2018-03-07 Thread Sasha Levin
From: Pan Bian [ Upstream commit 5fb01e91daf84ad1e50edfcf63116ecbe31e7ba7 ] Function alloc_skb() will return a NULL pointer if there is no enough memory. However, in function mt7601u_mcu_msg_alloc(), its return value is not validated before it is used. This patch fixes it.

[PATCH AUTOSEL for 4.9 090/190] mt7601u: check return value of alloc_skb

2018-03-07 Thread Sasha Levin
From: Pan Bian [ Upstream commit 5fb01e91daf84ad1e50edfcf63116ecbe31e7ba7 ] Function alloc_skb() will return a NULL pointer if there is no enough memory. However, in function mt7601u_mcu_msg_alloc(), its return value is not validated before it is used. This patch fixes it. Signed-off-by: Pan