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

Commit 2dbef210 authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "pci: msm: Fix out of bound error with find_next_bit()"

parents 5474ca56 b62866e6
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1395,7 +1395,7 @@ static void msm_pcie_write_reg(void __iomem *base, u32 offset, u32 value)
static void msm_pcie_write_reg_field(void __iomem *base, u32 offset,
	const u32 mask, u32 val)
{
	u32 shift = find_first_bit((void *)&mask, 32);
	u32 shift = __ffs(mask);
	u32 tmp = readl_relaxed(base + offset);

	tmp &= ~mask; /* clear written bits */