Input: twl6040-vibra - use cleanup facility for device_node
authorJavier Carrasco <javier.carrasco.cruz@gmail.com>
Sun, 20 Oct 2024 04:07:19 +0000 (21:07 -0700)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Sun, 20 Oct 2024 04:21:39 +0000 (21:21 -0700)
commit0ba9d3a597c4446072f2a4326689b8858761c8f7
tree9c502760c15a35b8971c3564c3fb95ef00b4216e
parent0ec6f58b63ae17774b10aa41ee86b6a387b60038
Input: twl6040-vibra - use cleanup facility for device_node

Use the '__free(device_node)' macro to simplify the code and error
handling. This makes the error handling more robust by ensuring that the
device node is always freed.

Signed-off-by: Javier Carrasco <javier.carrasco.cruz@gmail.com>
Link: https://lore.kernel.org/r/20241010-input_automate_of_node_put-v1-4-ebc62138fbf8@gmail.com
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
drivers/input/misc/twl6040-vibra.c