[Skiboot] [PATCH] occ: Fix potential race when clearing occ interrupt status

Benjamin Herrenschmidt benh at kernel.crashing.org
Tue Feb 17 13:25:10 AEDT 2015


On Tue, 2015-02-17 at 10:07 +0800, Jeremy Kerr wrote:
> +       rc = xscom_read(chip_id, OCB_OCI_OCCMISC, &ireg);
> +       if (!rc && ireg & OCB_OCI_OCIMISC_MASK)
> +               xscom_write(chip_id, OCB_OCI_OCCMISC_OR, OCB_OCI_OCIMISC_IRQ);
>  }

I prefer if you used () above, ie

	if (!rc && (ireg & OCB_OCI...))


I realize that && has the lowest precedence above but still ...

Cheers,
Ben.




More information about the Skiboot mailing list