Commit 2b6bfd4d4af86310903804b35183e3b50b469591
Committed by
Lee Jones
1 parent
a30fffb060
mfd: twl-core: Clean up module by removing twl603x pdata handling
Since currently nobody uses TWL603x platform data and all new users will supply it through device tree, handling of these data within twl-core will never be used, so remove it. Signed-off-by: Ruslan Ruslichenko <ruslan.ruslichenko@globallogic.com> Signed-off-by: Lee Jones <lee.jones@linaro.org>
Showing 1 changed file with 0 additions and 198 deletions Side-by-side Diff
drivers/mfd/twl-core.c
... | ... | @@ -701,63 +701,7 @@ |
701 | 701 | usb3v1[0].dev_name = dev_name(child); |
702 | 702 | } |
703 | 703 | } |
704 | - if (IS_ENABLED(CONFIG_TWL6030_USB) && pdata->usb && | |
705 | - twl_class_is_6030()) { | |
706 | 704 | |
707 | - static struct regulator_consumer_supply usb3v3; | |
708 | - int regulator; | |
709 | - | |
710 | - if (IS_ENABLED(CONFIG_REGULATOR_TWL4030)) { | |
711 | - /* this is a template that gets copied */ | |
712 | - struct regulator_init_data usb_fixed = { | |
713 | - .constraints.valid_modes_mask = | |
714 | - REGULATOR_MODE_NORMAL | |
715 | - | REGULATOR_MODE_STANDBY, | |
716 | - .constraints.valid_ops_mask = | |
717 | - REGULATOR_CHANGE_MODE | |
718 | - | REGULATOR_CHANGE_STATUS, | |
719 | - }; | |
720 | - | |
721 | - if (features & TWL6032_SUBCLASS) { | |
722 | - usb3v3.supply = "ldousb"; | |
723 | - regulator = TWL6032_REG_LDOUSB; | |
724 | - } else { | |
725 | - usb3v3.supply = "vusb"; | |
726 | - regulator = TWL6030_REG_VUSB; | |
727 | - } | |
728 | - child = add_regulator_linked(regulator, &usb_fixed, | |
729 | - &usb3v3, 1, | |
730 | - features); | |
731 | - if (IS_ERR(child)) | |
732 | - return PTR_ERR(child); | |
733 | - } | |
734 | - | |
735 | - pdata->usb->features = features; | |
736 | - | |
737 | - child = add_child(TWL_MODULE_USB, "twl6030_usb", | |
738 | - pdata->usb, sizeof(*pdata->usb), true, | |
739 | - /* irq1 = VBUS_PRES, irq0 = USB ID */ | |
740 | - irq_base + USBOTG_INTR_OFFSET, | |
741 | - irq_base + USB_PRES_INTR_OFFSET); | |
742 | - | |
743 | - if (IS_ERR(child)) | |
744 | - return PTR_ERR(child); | |
745 | - /* we need to connect regulators to this transceiver */ | |
746 | - if (IS_ENABLED(CONFIG_REGULATOR_TWL4030) && child) | |
747 | - usb3v3.dev_name = dev_name(child); | |
748 | - } else if (IS_ENABLED(CONFIG_REGULATOR_TWL4030) && | |
749 | - twl_class_is_6030()) { | |
750 | - if (features & TWL6032_SUBCLASS) | |
751 | - child = add_regulator(TWL6032_REG_LDOUSB, | |
752 | - pdata->ldousb, features); | |
753 | - else | |
754 | - child = add_regulator(TWL6030_REG_VUSB, | |
755 | - pdata->vusb, features); | |
756 | - | |
757 | - if (IS_ERR(child)) | |
758 | - return PTR_ERR(child); | |
759 | - } | |
760 | - | |
761 | 705 | if (IS_ENABLED(CONFIG_TWL4030_WATCHDOG) && twl_class_is_4030()) { |
762 | 706 | child = add_child(TWL_MODULE_PM_RECEIVER, "twl4030_wdt", NULL, |
763 | 707 | 0, false, 0, 0); |
... | ... | @@ -868,148 +812,6 @@ |
868 | 812 | features); |
869 | 813 | if (IS_ERR(child)) |
870 | 814 | return PTR_ERR(child); |
871 | - } | |
872 | - | |
873 | - /* twl6030 regulators */ | |
874 | - if (IS_ENABLED(CONFIG_REGULATOR_TWL4030) && twl_class_is_6030() && | |
875 | - !(features & TWL6032_SUBCLASS)) { | |
876 | - child = add_regulator(TWL6030_REG_VDD1, pdata->vdd1, | |
877 | - features); | |
878 | - if (IS_ERR(child)) | |
879 | - return PTR_ERR(child); | |
880 | - | |
881 | - child = add_regulator(TWL6030_REG_VDD2, pdata->vdd2, | |
882 | - features); | |
883 | - if (IS_ERR(child)) | |
884 | - return PTR_ERR(child); | |
885 | - | |
886 | - child = add_regulator(TWL6030_REG_VDD3, pdata->vdd3, | |
887 | - features); | |
888 | - if (IS_ERR(child)) | |
889 | - return PTR_ERR(child); | |
890 | - | |
891 | - child = add_regulator(TWL6030_REG_V1V8, pdata->v1v8, | |
892 | - features); | |
893 | - if (IS_ERR(child)) | |
894 | - return PTR_ERR(child); | |
895 | - | |
896 | - child = add_regulator(TWL6030_REG_V2V1, pdata->v2v1, | |
897 | - features); | |
898 | - if (IS_ERR(child)) | |
899 | - return PTR_ERR(child); | |
900 | - | |
901 | - child = add_regulator(TWL6030_REG_VMMC, pdata->vmmc, | |
902 | - features); | |
903 | - if (IS_ERR(child)) | |
904 | - return PTR_ERR(child); | |
905 | - | |
906 | - child = add_regulator(TWL6030_REG_VPP, pdata->vpp, | |
907 | - features); | |
908 | - if (IS_ERR(child)) | |
909 | - return PTR_ERR(child); | |
910 | - | |
911 | - child = add_regulator(TWL6030_REG_VUSIM, pdata->vusim, | |
912 | - features); | |
913 | - if (IS_ERR(child)) | |
914 | - return PTR_ERR(child); | |
915 | - | |
916 | - child = add_regulator(TWL6030_REG_VCXIO, pdata->vcxio, | |
917 | - features); | |
918 | - if (IS_ERR(child)) | |
919 | - return PTR_ERR(child); | |
920 | - | |
921 | - child = add_regulator(TWL6030_REG_VDAC, pdata->vdac, | |
922 | - features); | |
923 | - if (IS_ERR(child)) | |
924 | - return PTR_ERR(child); | |
925 | - | |
926 | - child = add_regulator(TWL6030_REG_VAUX1_6030, pdata->vaux1, | |
927 | - features); | |
928 | - if (IS_ERR(child)) | |
929 | - return PTR_ERR(child); | |
930 | - | |
931 | - child = add_regulator(TWL6030_REG_VAUX2_6030, pdata->vaux2, | |
932 | - features); | |
933 | - if (IS_ERR(child)) | |
934 | - return PTR_ERR(child); | |
935 | - | |
936 | - child = add_regulator(TWL6030_REG_VAUX3_6030, pdata->vaux3, | |
937 | - features); | |
938 | - if (IS_ERR(child)) | |
939 | - return PTR_ERR(child); | |
940 | - | |
941 | - child = add_regulator(TWL6030_REG_CLK32KG, pdata->clk32kg, | |
942 | - features); | |
943 | - if (IS_ERR(child)) | |
944 | - return PTR_ERR(child); | |
945 | - } | |
946 | - | |
947 | - /* 6030 and 6025 share this regulator */ | |
948 | - if (IS_ENABLED(CONFIG_REGULATOR_TWL4030) && twl_class_is_6030()) { | |
949 | - child = add_regulator(TWL6030_REG_VANA, pdata->vana, | |
950 | - features); | |
951 | - if (IS_ERR(child)) | |
952 | - return PTR_ERR(child); | |
953 | - } | |
954 | - | |
955 | - /* twl6032 regulators */ | |
956 | - if (IS_ENABLED(CONFIG_REGULATOR_TWL4030) && twl_class_is_6030() && | |
957 | - (features & TWL6032_SUBCLASS)) { | |
958 | - child = add_regulator(TWL6032_REG_LDO5, pdata->ldo5, | |
959 | - features); | |
960 | - if (IS_ERR(child)) | |
961 | - return PTR_ERR(child); | |
962 | - | |
963 | - child = add_regulator(TWL6032_REG_LDO1, pdata->ldo1, | |
964 | - features); | |
965 | - if (IS_ERR(child)) | |
966 | - return PTR_ERR(child); | |
967 | - | |
968 | - child = add_regulator(TWL6032_REG_LDO7, pdata->ldo7, | |
969 | - features); | |
970 | - if (IS_ERR(child)) | |
971 | - return PTR_ERR(child); | |
972 | - | |
973 | - child = add_regulator(TWL6032_REG_LDO6, pdata->ldo6, | |
974 | - features); | |
975 | - if (IS_ERR(child)) | |
976 | - return PTR_ERR(child); | |
977 | - | |
978 | - child = add_regulator(TWL6032_REG_LDOLN, pdata->ldoln, | |
979 | - features); | |
980 | - if (IS_ERR(child)) | |
981 | - return PTR_ERR(child); | |
982 | - | |
983 | - child = add_regulator(TWL6032_REG_LDO2, pdata->ldo2, | |
984 | - features); | |
985 | - if (IS_ERR(child)) | |
986 | - return PTR_ERR(child); | |
987 | - | |
988 | - child = add_regulator(TWL6032_REG_LDO4, pdata->ldo4, | |
989 | - features); | |
990 | - if (IS_ERR(child)) | |
991 | - return PTR_ERR(child); | |
992 | - | |
993 | - child = add_regulator(TWL6032_REG_LDO3, pdata->ldo3, | |
994 | - features); | |
995 | - if (IS_ERR(child)) | |
996 | - return PTR_ERR(child); | |
997 | - | |
998 | - child = add_regulator(TWL6032_REG_SMPS3, pdata->smps3, | |
999 | - features); | |
1000 | - if (IS_ERR(child)) | |
1001 | - return PTR_ERR(child); | |
1002 | - | |
1003 | - child = add_regulator(TWL6032_REG_SMPS4, pdata->smps4, | |
1004 | - features); | |
1005 | - if (IS_ERR(child)) | |
1006 | - return PTR_ERR(child); | |
1007 | - | |
1008 | - child = add_regulator(TWL6032_REG_VIO, pdata->vio6025, | |
1009 | - features); | |
1010 | - if (IS_ERR(child)) | |
1011 | - return PTR_ERR(child); | |
1012 | - | |
1013 | 815 | } |
1014 | 816 | |
1015 | 817 | if (IS_ENABLED(CONFIG_CHARGER_TWL4030) && pdata->bci && |