Skip to contentSkip to conversation

HID: intel-thc-hid: intel-thc: Fix the return value in thc_dev_init() kernel-doc

PATCH New Karl Mehltretter 1 participant 1 message Sep 12

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 HID: intel-thc-hid: intel-thc: Fix the return value in thc_dev_init() kernel-doc

thc_dev_init() returns an ERR_PTR() on failure, never NULL, but its kernel-doc says "NULL on failed". Say ERR_PTR().

Fixes 1b2d05384c29 ("HID: intel-thc-hid: Add basic THC driver skeleton")
Assisted-by LLM
---
 drivers/hid/intel-thc-hid/intel-thc/intel-thc-dev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/hid/intel-thc-hid/intel-thc/intel-thc-dev.c +1 -1
index 7b4a58e1416d685186ef4bb222b882fab130a4e2..02ec5db9ad26977e72a7c8026b1796bc5d83bd6c 100644
@@ -190,7 +190,7 @@ static void thc_clear_state(const struct thc_device *dev)
  * @device: The pointer of device structure
  * @mem_addr: The pointer of MMIO memory address
  *
- * Return: The thc_device pointer on success, NULL on failed.
+ * Return: The thc_device pointer on success, an ERR_PTR() on failure.
  */
 struct thc_device *thc_dev_init(struct device *device, void __iomem *mem_addr)
 {
Signature · 1 line
2.39.5 (Apple Git-154)