Commit a94a59f
committed
mmc: sdio: Fix several potential memory leaks in mmc_sdio_init_card()
Over the years, the code in mmc_sdio_init_card() has grown to become quite
messy. Unfortunate this has also lead to that several paths are leaking
memory in form of an allocated struct mmc_card, which includes additional
data, such as initialized struct device for example.
Unfortunate, it's a too complex task find each offending commit. Therefore,
this change fixes all memory leaks at once.
Cc: <stable@vger.kernel.org>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Link: https://lore.kernel.org/r/20200430091640.455-3-ulf.hansson@linaro.org1 parent f04086c commit a94a59f
1 file changed
+27
-31
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
584 | 584 | | |
585 | 585 | | |
586 | 586 | | |
587 | | - | |
| 587 | + | |
588 | 588 | | |
589 | 589 | | |
590 | 590 | | |
591 | 591 | | |
592 | 592 | | |
593 | 593 | | |
594 | 594 | | |
595 | | - | |
| 595 | + | |
596 | 596 | | |
597 | 597 | | |
598 | 598 | | |
599 | 599 | | |
600 | 600 | | |
601 | 601 | | |
602 | | - | |
603 | | - | |
604 | | - | |
605 | | - | |
| 602 | + | |
| 603 | + | |
606 | 604 | | |
607 | 605 | | |
608 | 606 | | |
609 | 607 | | |
610 | 608 | | |
611 | 609 | | |
612 | 610 | | |
613 | | - | |
614 | | - | |
615 | | - | |
616 | | - | |
| 611 | + | |
| 612 | + | |
617 | 613 | | |
618 | 614 | | |
619 | 615 | | |
620 | 616 | | |
621 | 617 | | |
622 | | - | |
623 | | - | |
624 | | - | |
625 | | - | |
| 618 | + | |
| 619 | + | |
626 | 620 | | |
627 | 621 | | |
628 | 622 | | |
| |||
677 | 671 | | |
678 | 672 | | |
679 | 673 | | |
680 | | - | |
| 674 | + | |
681 | 675 | | |
682 | 676 | | |
683 | 677 | | |
| |||
704 | 698 | | |
705 | 699 | | |
706 | 700 | | |
707 | | - | |
| 701 | + | |
| 702 | + | |
| 703 | + | |
| 704 | + | |
| 705 | + | |
| 706 | + | |
708 | 707 | | |
709 | 708 | | |
710 | 709 | | |
| |||
730 | 729 | | |
731 | 730 | | |
732 | 731 | | |
733 | | - | |
734 | | - | |
735 | | - | |
736 | | - | |
737 | | - | |
738 | | - | |
739 | | - | |
| 732 | + | |
| 733 | + | |
| 734 | + | |
| 735 | + | |
| 736 | + | |
| 737 | + | |
| 738 | + | |
740 | 739 | | |
741 | | - | |
742 | | - | |
743 | 740 | | |
744 | 741 | | |
745 | 742 | | |
| |||
800 | 797 | | |
801 | 798 | | |
802 | 799 | | |
803 | | - | |
804 | | - | |
805 | | - | |
| 800 | + | |
| 801 | + | |
806 | 802 | | |
807 | 803 | | |
| 804 | + | |
| 805 | + | |
808 | 806 | | |
809 | | - | |
| 807 | + | |
810 | 808 | | |
811 | | - | |
812 | | - | |
813 | 809 | | |
814 | 810 | | |
815 | 811 | | |
| |||
0 commit comments