Date: Wed, 4 Feb 2015 18:35:50 +0000 (UTC) From: Luiz Otavio O Souza <loos@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r278216 - head/sys/arm/ti Message-ID: <201502041835.t14IZoFh085770@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: loos Date: Wed Feb 4 18:35:49 2015 New Revision: 278216 URL: https://svnweb.freebsd.org/changeset/base/278216 Log: Fix a bug where an interrupt could be masked unintentionally when bus_config_intr() is called with the same interrupt type and polarity that is already set. Pointy hat: loos Modified: head/sys/arm/ti/ti_gpio.c Modified: head/sys/arm/ti/ti_gpio.c ============================================================================== --- head/sys/arm/ti/ti_gpio.c Wed Feb 4 18:15:28 2015 (r278215) +++ head/sys/arm/ti/ti_gpio.c Wed Feb 4 18:35:49 2015 (r278216) @@ -1004,7 +1004,7 @@ ti_gpio_config_intr(device_t dev, int ir val |= TI_GPIO_MASK(irq); ti_gpio_write_4(sc, TI_GPIO_BANK(irq), reg, val); } - if (oldreg != 0) { + if (reg != oldreg && oldreg != 0) { /* Remove the old settings. */ val = ti_gpio_read_4(sc, TI_GPIO_BANK(irq), oldreg); val &= ~TI_GPIO_MASK(irq);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201502041835.t14IZoFh085770>