Commit 2bb596a
platform/x86: x86-android-tablets: Simplify node-group [un]registration
software_node_register_node_group() / software_node_unregister_node_group()
both accept a NULL node-group as argument.
So there is no need to check for the node-group being NULL before calling
these functions, remove the checks to simplify the code.
Note the "if (gpio_button_swnodes)" check for registering is kept because
that also guards the creation of a gpio-button platform-device.
Suggested-by: Andy Shevchenko <andy@kernel.org>
Signed-off-by: Hans de Goede <hansg@kernel.org>
Reviewed-by: Andy Shevchenko <andy@kernel.org>
Link: https://patch.msgid.link/20250920200713.20193-15-hansg@kernel.org
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>1 parent 936ddb5 commit 2bb596a
1 file changed
Lines changed: 11 additions & 20 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
387 | 387 | | |
388 | 388 | | |
389 | 389 | | |
390 | | - | |
391 | | - | |
392 | | - | |
393 | | - | |
394 | | - | |
395 | | - | |
396 | | - | |
397 | | - | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
398 | 393 | | |
399 | 394 | | |
400 | 395 | | |
| |||
430 | 425 | | |
431 | 426 | | |
432 | 427 | | |
433 | | - | |
434 | | - | |
435 | | - | |
436 | | - | |
437 | | - | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
438 | 431 | | |
439 | | - | |
440 | | - | |
441 | | - | |
442 | | - | |
443 | | - | |
444 | | - | |
445 | | - | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
446 | 436 | | |
| 437 | + | |
447 | 438 | | |
448 | 439 | | |
449 | 440 | | |
| |||
0 commit comments