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

Commit c88e40e0 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull mfd bugfix from Lee Jones.

Fix stmfx type confusion between regmap_read() (which takes an "u32")
and the bitmap operations (which take an "unsigned long" array).

* tag 'mfd-fixes-5.2-1' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd:
  mfd: stmfx: Fix an endian bug in stmfx_irq_handler()
  mfd: stmfx: Uninitialized variable in stmfx_irq_handler()
parents 39071cf8 63b2de12
Loading
Loading
Loading
Loading
+6 −6
Original line number Diff line number Diff line
@@ -204,12 +204,11 @@ static struct irq_chip stmfx_irq_chip = {
static irqreturn_t stmfx_irq_handler(int irq, void *data)
{
	struct stmfx *stmfx = data;
	unsigned long n, pending;
	u32 ack;
	int ret;
	unsigned long bits;
	u32 pending, ack;
	int n, ret;

	ret = regmap_read(stmfx->map, STMFX_REG_IRQ_PENDING,
			  (u32 *)&pending);
	ret = regmap_read(stmfx->map, STMFX_REG_IRQ_PENDING, &pending);
	if (ret)
		return IRQ_NONE;

@@ -224,7 +223,8 @@ static irqreturn_t stmfx_irq_handler(int irq, void *data)
			return IRQ_NONE;
	}

	for_each_set_bit(n, &pending, STMFX_REG_IRQ_SRC_MAX)
	bits = pending;
	for_each_set_bit(n, &bits, STMFX_REG_IRQ_SRC_MAX)
		handle_nested_irq(irq_find_mapping(stmfx->irq_domain, n));

	return IRQ_HANDLED;