summaryrefslogtreecommitdiffstats
path: root/drivers/pinctrl
diff options
context:
space:
mode:
authorRaag Jadav <raag.jadav@intel.com>2023-06-17 02:03:56 +0530
committerAndy Shevchenko <andriy.shevchenko@linux.intel.com>2023-06-19 13:53:26 +0300
commit605ba2564437b088243b5f5cdf65b182a10220a1 (patch)
tree4f6aec88fe8c394deb17860ce981b4be487c16c0 /drivers/pinctrl
parent9d49882e439efde737dbd65d6319123dbf91d42d (diff)
downloadlinux-stable-605ba2564437b088243b5f5cdf65b182a10220a1.tar.gz
linux-stable-605ba2564437b088243b5f5cdf65b182a10220a1.tar.bz2
linux-stable-605ba2564437b088243b5f5cdf65b182a10220a1.zip
pinctrl: baytrail: invert if condition
Invert if condition and get rid of redundant else. Signed-off-by: Raag Jadav <raag.jadav@intel.com> Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com> Link: https://lore.kernel.org/r/20230616203356.27343-4-raag.jadav@intel.com Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Diffstat (limited to 'drivers/pinctrl')
-rw-r--r--drivers/pinctrl/intel/pinctrl-baytrail.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/pinctrl/intel/pinctrl-baytrail.c b/drivers/pinctrl/intel/pinctrl-baytrail.c
index 97ead2c58b66..27aef62fc7c0 100644
--- a/drivers/pinctrl/intel/pinctrl-baytrail.c
+++ b/drivers/pinctrl/intel/pinctrl-baytrail.c
@@ -753,9 +753,7 @@ static void byt_gpio_clear_triggering(struct intel_pinctrl *vg, unsigned int off
value = readl(reg);
/* Do not clear direct-irq enabled IRQs (from gpio_disable_free) */
- if (value & BYT_DIRECT_IRQ_EN)
- /* nothing to do */ ;
- else
+ if (!(value & BYT_DIRECT_IRQ_EN))
value &= ~(BYT_TRIG_POS | BYT_TRIG_NEG | BYT_TRIG_LVL);
writel(value, reg);