]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
Hid: Intel-thc-hid: Intel-thc: Fix "dubious: !x | !y" issue
authorEven Xu <even.xu@intel.com>
Thu, 13 Feb 2025 02:40:21 +0000 (10:40 +0800)
committerJiri Kosina <jkosina@suse.com>
Tue, 18 Feb 2025 21:09:49 +0000 (22:09 +0100)
Change to use "||" to make it more readable and avoid miss
understanding.

Signed-off-by: Even Xu <even.xu@intel.com>
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202501292144.eFDq4ovr-lkp@intel.com
Signed-off-by: Jiri Kosina <jkosina@suse.com>
drivers/hid/intel-thc-hid/intel-thc/intel-thc-dma.c

index eb23bea776864566d94419e1a5553544c8d9ef02..8f97e71df7f41041c86a964e6eadc63dc44f0c8a 100644 (file)
@@ -295,7 +295,7 @@ static void release_dma_buffers(struct thc_device *dev,
                return;
 
        for (i = 0; i < config->prd_tbl_num; i++) {
-               if (!config->sgls[i] | !config->sgls_nent[i])
+               if (!config->sgls[i] || !config->sgls_nent[i])
                        continue;
 
                dma_unmap_sg(dev->dev, config->sgls[i],