Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4f64a1e9 authored by Luciano Coelho's avatar Luciano Coelho
Browse files

wlcore: add space for private area when allocating fw_status



When allocating the fw_status structure, the space for the
lower-driver private area was missing.  This was causing an illegal
write outside the allocated area, which was causing random oopses
around the kernel.

Signed-off-by: default avatarLuciano Coelho <coelho@ti.com>
Signed-off-by: default avatarArik Nemtsov <arik@wizery.com>
parent 4b9d2365
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -904,7 +904,8 @@ static void wl1271_fw_wakeup(struct wl1271 *wl)
static int wl1271_setup(struct wl1271 *wl)
{
	wl->fw_status_1 = kmalloc(WLCORE_FW_STATUS_1_LEN(wl->num_rx_desc) +
				  sizeof(*wl->fw_status_2), GFP_KERNEL);
				  sizeof(*wl->fw_status_2) +
				  wl->fw_status_priv_len, GFP_KERNEL);
	if (!wl->fw_status_1)
		return -ENOMEM;