Commit b22bb0d
pwm: atmel: Simplify using devm functions
For all resources used by the driver there is a devm variant to allocate
these. This simplifies the error path in the probe callback and allows
to drop the remove callback.
While at it also use dev_err_probe() to compact returning an error.
With the remove callback gone, there is no user of driver data left, so
the call to platform_set_drvdata() can also be dropped.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Thierry Reding <thierry.reding@gmail.com>1 parent 8b9d91d commit b22bb0d
1 file changed
Lines changed: 7 additions & 26 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
517 | 517 | | |
518 | 518 | | |
519 | 519 | | |
520 | | - | |
| 520 | + | |
521 | 521 | | |
522 | | - | |
523 | | - | |
524 | | - | |
525 | | - | |
526 | | - | |
527 | | - | |
528 | | - | |
| 522 | + | |
| 523 | + | |
529 | 524 | | |
530 | 525 | | |
531 | 526 | | |
532 | 527 | | |
533 | 528 | | |
534 | 529 | | |
535 | 530 | | |
536 | | - | |
| 531 | + | |
537 | 532 | | |
538 | | - | |
| 533 | + | |
539 | 534 | | |
540 | | - | |
| 535 | + | |
541 | 536 | | |
542 | 537 | | |
543 | 538 | | |
544 | | - | |
545 | | - | |
546 | | - | |
| 539 | + | |
547 | 540 | | |
548 | 541 | | |
549 | 542 | | |
550 | 543 | | |
551 | | - | |
552 | | - | |
553 | 544 | | |
554 | 545 | | |
555 | 546 | | |
556 | | - | |
557 | | - | |
558 | | - | |
559 | | - | |
560 | | - | |
561 | | - | |
562 | | - | |
563 | | - | |
564 | | - | |
565 | 547 | | |
566 | 548 | | |
567 | 549 | | |
568 | 550 | | |
569 | 551 | | |
570 | 552 | | |
571 | | - | |
572 | 553 | | |
573 | 554 | | |
574 | 555 | | |
| |||
0 commit comments