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

Commit 40bd5203 authored by Rafał Miłecki's avatar Rafał Miłecki Committed by John W. Linville
Browse files

b43: N-PHY: handle allocation fail in samples generation

parent 5f6393ec
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -1069,6 +1069,10 @@ static u16 b43_nphy_gen_load_samples(struct b43_wldev *dev, u32 freq, u16 max,
	}

	samples = kzalloc(len * sizeof(struct b43_c32), GFP_KERNEL);
	if (!samples) {
		b43err(dev->wl, "allocation for samples generation failed\n");
		return 0;
	}
	rot = (((freq * 36) / bw) << 16) / 100;
	angle = 0;