]> www.infradead.org Git - users/hch/misc.git/commitdiff
HID: intel-thc-hid: intel-quicki2c: Fix wrong type casting
authorXinpeng Sun <xinpeng.sun@intel.com>
Thu, 9 Oct 2025 03:31:08 +0000 (11:31 +0800)
committerJiri Kosina <jkosina@suse.com>
Tue, 14 Oct 2025 09:27:01 +0000 (11:27 +0200)
The type definition of qcdev->i2c_max_frame_size is already
u32, so remove the unnecessary type casting le16_to_cpu.

Signed-off-by: Xinpeng Sun <xinpeng.sun@intel.com>
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202509280841.pxmgBzKW-lkp@intel.com/
Signed-off-by: Jiri Kosina <jkosina@suse.com>
drivers/hid/intel-thc-hid/intel-quicki2c/pci-quicki2c.c

index 8433a991e7f49245bb1406f77cd550de583a858e..0156ab3917789e3a0d8be1631608895239dff4b2 100644 (file)
@@ -466,7 +466,7 @@ static void quicki2c_dma_adv_enable(struct quicki2c_device *qcdev)
                        dev_warn(qcdev->dev,
                                 "Max frame size is smaller than hid max input length!");
                        thc_i2c_set_rx_max_size(qcdev->thc_hw,
-                                               le16_to_cpu(qcdev->i2c_max_frame_size));
+                                               qcdev->i2c_max_frame_size);
                }
                thc_i2c_rx_max_size_enable(qcdev->thc_hw, true);
        }