Loading Documentation/devicetree/bindings/wcnss/wcnss-wlan.txt +0 −3 Original line number Original line Diff line number Diff line Loading @@ -66,8 +66,6 @@ to use for VBATT feature. register is available or not. register is available or not. - qcom,wcn-external-gpio-support: boolean flag to determine 3.3v gpio support - qcom,wcn-external-gpio-support: boolean flag to determine 3.3v gpio support for pronto hardware for a target. for pronto hardware for a target. - qcom,wcn-external-gpio: The wcnss wlan module 3.3v external GPIO for the pronto hardware. Example: Example: Loading @@ -89,7 +87,6 @@ Example: gpios = <&msmgpio 36 0>, <&msmgpio 37 0>, <&msmgpio 38 0>, gpios = <&msmgpio 36 0>, <&msmgpio 37 0>, <&msmgpio 38 0>, <&msmgpio 39 0>, <&msmgpio 40 0>; <&msmgpio 39 0>, <&msmgpio 40 0>; qcom,wcn-external-gpio = <&msmgpio 64 0>; qcom,wcn-external-gpio-support; qcom,wcn-external-gpio-support; qcom,has-48mhz-xo; qcom,has-48mhz-xo; qcom,is-pronto-vt; qcom,is-pronto-vt; Loading arch/arm/boot/dts/qcom/msm8909w-pm660-mtp.dtsi +0 −1 Original line number Original line Diff line number Diff line Loading @@ -39,7 +39,6 @@ qcom,iris-vddxo-supply = <&pm660_l12>; qcom,iris-vddxo-supply = <&pm660_l12>; qcom,iris-vddrfa-supply = <&pm660_l6>; qcom,iris-vddrfa-supply = <&pm660_l6>; qcom,iris-vdddig-supply = <&pm660_l13>; qcom,iris-vdddig-supply = <&pm660_l13>; qcom,wcn-external-gpio = <&msm_gpio 64 0>; qcom,wcn-external-gpio-support; qcom,wcn-external-gpio-support; }; }; Loading drivers/net/wireless/wcnss/wcnss_vreg.c +2 −53 Original line number Original line Diff line number Diff line Loading @@ -102,45 +102,6 @@ enum { IRIS_3610 IRIS_3610 }; }; static int wcnss_external_gpio_set_state(bool state) { int ret; struct wcnss_wlan_config *cfg = wcnss_get_wlan_config(); if (!cfg) return -EINVAL; if (state) { ret = gpio_request(cfg->wcn_external_gpio, WCNSS_EXTERNAL_GPIO_NAME); if (ret) { pr_err("%s: Can't get GPIO %s, ret = %d\n", __func__, WCNSS_EXTERNAL_GPIO_NAME, ret); return ret; } ret = gpio_direction_output(cfg->wcn_external_gpio, WCNSS_EXTERNAL_GPIO_DIR_OUT); if (ret) { pr_err("%s: Can't set GPIO %s direction, ret = %d\n", __func__, WCNSS_EXTERNAL_GPIO_NAME, ret); gpio_free(cfg->wcn_external_gpio); return ret; } gpio_set_value(cfg->wcn_external_gpio, WCNSS_EXTERNAL_GPIO_HIGH); } else { gpio_set_value(cfg->wcn_external_gpio, WCNSS_EXTERNAL_GPIO_LOW); gpio_free(cfg->wcn_external_gpio); } pr_debug("%s: %d gpio is now %s\n", __func__, cfg->wcn_external_gpio, state ? "enabled" : "disabled"); return 0; } int xo_auto_detect(u32 reg) int xo_auto_detect(u32 reg) { { Loading Loading @@ -459,8 +420,7 @@ static void wcnss_vregs_off(struct vregs_info regulators[], uint size, continue; continue; if (cfg->wcn_external_gpio_support) { if (cfg->wcn_external_gpio_support) { if (!memcmp(regulators[i].name, VDD_PA, if (!memcmp(regulators[i].name, VDD_PA, sizeof(VDD_PA))) sizeof(VDD_PA))) continue; continue; } } Loading Loading @@ -526,8 +486,7 @@ static int wcnss_vregs_on(struct device *dev, for (i = 0; i < size; i++) { for (i = 0; i < size; i++) { if (cfg->wcn_external_gpio_support) { if (cfg->wcn_external_gpio_support) { if (!memcmp(regulators[i].name, VDD_PA, if (!memcmp(regulators[i].name, VDD_PA, sizeof(VDD_PA))) sizeof(VDD_PA))) continue; continue; } } Loading Loading @@ -675,12 +634,6 @@ int wcnss_wlan_power(struct device *dev, down(&wcnss_power_on_lock); down(&wcnss_power_on_lock); if (on) { if (on) { if (cfg->wcn_external_gpio_support) { rc = wcnss_external_gpio_set_state(true); if (rc) return rc; } /* RIVA regulator settings */ /* RIVA regulator settings */ rc = wcnss_core_vregs_on(dev, hw_type, rc = wcnss_core_vregs_on(dev, hw_type, cfg); cfg); Loading @@ -703,8 +656,6 @@ int wcnss_wlan_power(struct device *dev, } else if (is_power_on) { } else if (is_power_on) { is_power_on = false; is_power_on = false; if (cfg->wcn_external_gpio_support) wcnss_external_gpio_set_state(false); configure_iris_xo(dev, cfg, configure_iris_xo(dev, cfg, WCNSS_WLAN_SWITCH_OFF, NULL); WCNSS_WLAN_SWITCH_OFF, NULL); wcnss_iris_vregs_off(hw_type, cfg); wcnss_iris_vregs_off(hw_type, cfg); Loading @@ -721,8 +672,6 @@ fail_iris_on: wcnss_core_vregs_off(hw_type, cfg); wcnss_core_vregs_off(hw_type, cfg); fail_wcnss_on: fail_wcnss_on: if (cfg->wcn_external_gpio_support) wcnss_external_gpio_set_state(false); up(&wcnss_power_on_lock); up(&wcnss_power_on_lock); return rc; return rc; } } Loading drivers/net/wireless/wcnss/wcnss_wlan.c +0 −19 Original line number Original line Diff line number Diff line Loading @@ -2810,25 +2810,6 @@ wcnss_trigger_config(struct platform_device *pdev) wlan_cfg->wcn_external_gpio_support = wlan_cfg->wcn_external_gpio_support = of_property_read_bool(node, "qcom,wcn-external-gpio-support"); of_property_read_bool(node, "qcom,wcn-external-gpio-support"); if (wlan_cfg->wcn_external_gpio_support) { if (of_find_property(node, WCNSS_EXTERNAL_GPIO_NAME, NULL)) { wlan_cfg->wcn_external_gpio = of_get_named_gpio( pdev->dev.of_node, WCNSS_EXTERNAL_GPIO_NAME, 0); if (!gpio_is_valid(wlan_cfg->wcn_external_gpio)) { pr_err("%s: Invalid %s num defined in DT\n", __func__, WCNSS_EXTERNAL_GPIO_NAME); ret = -EINVAL; goto fail; } } else { pr_err("%s: %s prop not defined in DT node\n", __func__, WCNSS_EXTERNAL_GPIO_NAME); goto fail; } } if (of_property_read_u32(node, "qcom,wlan-rx-buff-count", if (of_property_read_u32(node, "qcom,wlan-rx-buff-count", &penv->wlan_rx_buff_count)) { &penv->wlan_rx_buff_count)) { Loading include/linux/wcnss_wlan.h +0 −6 Original line number Original line Diff line number Diff line Loading @@ -20,11 +20,6 @@ #define IRIS_REGULATORS 4 #define IRIS_REGULATORS 4 #define PRONTO_REGULATORS 3 #define PRONTO_REGULATORS 3 #define WCNSS_EXTERNAL_GPIO_NAME "qcom,wcn-external-gpio" #define WCNSS_EXTERNAL_GPIO_HIGH 1 #define WCNSS_EXTERNAL_GPIO_LOW 0 #define WCNSS_EXTERNAL_GPIO_DIR_OUT 1 enum wcnss_opcode { enum wcnss_opcode { WCNSS_WLAN_SWITCH_OFF = 0, WCNSS_WLAN_SWITCH_OFF = 0, WCNSS_WLAN_SWITCH_ON, WCNSS_WLAN_SWITCH_ON, Loading @@ -44,7 +39,6 @@ struct vregs_level { struct wcnss_wlan_config { struct wcnss_wlan_config { bool wcn_external_gpio_support; bool wcn_external_gpio_support; int wcn_external_gpio; int use_48mhz_xo; int use_48mhz_xo; int is_pronto_vadc; int is_pronto_vadc; int is_pronto_v3; int is_pronto_v3; Loading Loading
Documentation/devicetree/bindings/wcnss/wcnss-wlan.txt +0 −3 Original line number Original line Diff line number Diff line Loading @@ -66,8 +66,6 @@ to use for VBATT feature. register is available or not. register is available or not. - qcom,wcn-external-gpio-support: boolean flag to determine 3.3v gpio support - qcom,wcn-external-gpio-support: boolean flag to determine 3.3v gpio support for pronto hardware for a target. for pronto hardware for a target. - qcom,wcn-external-gpio: The wcnss wlan module 3.3v external GPIO for the pronto hardware. Example: Example: Loading @@ -89,7 +87,6 @@ Example: gpios = <&msmgpio 36 0>, <&msmgpio 37 0>, <&msmgpio 38 0>, gpios = <&msmgpio 36 0>, <&msmgpio 37 0>, <&msmgpio 38 0>, <&msmgpio 39 0>, <&msmgpio 40 0>; <&msmgpio 39 0>, <&msmgpio 40 0>; qcom,wcn-external-gpio = <&msmgpio 64 0>; qcom,wcn-external-gpio-support; qcom,wcn-external-gpio-support; qcom,has-48mhz-xo; qcom,has-48mhz-xo; qcom,is-pronto-vt; qcom,is-pronto-vt; Loading
arch/arm/boot/dts/qcom/msm8909w-pm660-mtp.dtsi +0 −1 Original line number Original line Diff line number Diff line Loading @@ -39,7 +39,6 @@ qcom,iris-vddxo-supply = <&pm660_l12>; qcom,iris-vddxo-supply = <&pm660_l12>; qcom,iris-vddrfa-supply = <&pm660_l6>; qcom,iris-vddrfa-supply = <&pm660_l6>; qcom,iris-vdddig-supply = <&pm660_l13>; qcom,iris-vdddig-supply = <&pm660_l13>; qcom,wcn-external-gpio = <&msm_gpio 64 0>; qcom,wcn-external-gpio-support; qcom,wcn-external-gpio-support; }; }; Loading
drivers/net/wireless/wcnss/wcnss_vreg.c +2 −53 Original line number Original line Diff line number Diff line Loading @@ -102,45 +102,6 @@ enum { IRIS_3610 IRIS_3610 }; }; static int wcnss_external_gpio_set_state(bool state) { int ret; struct wcnss_wlan_config *cfg = wcnss_get_wlan_config(); if (!cfg) return -EINVAL; if (state) { ret = gpio_request(cfg->wcn_external_gpio, WCNSS_EXTERNAL_GPIO_NAME); if (ret) { pr_err("%s: Can't get GPIO %s, ret = %d\n", __func__, WCNSS_EXTERNAL_GPIO_NAME, ret); return ret; } ret = gpio_direction_output(cfg->wcn_external_gpio, WCNSS_EXTERNAL_GPIO_DIR_OUT); if (ret) { pr_err("%s: Can't set GPIO %s direction, ret = %d\n", __func__, WCNSS_EXTERNAL_GPIO_NAME, ret); gpio_free(cfg->wcn_external_gpio); return ret; } gpio_set_value(cfg->wcn_external_gpio, WCNSS_EXTERNAL_GPIO_HIGH); } else { gpio_set_value(cfg->wcn_external_gpio, WCNSS_EXTERNAL_GPIO_LOW); gpio_free(cfg->wcn_external_gpio); } pr_debug("%s: %d gpio is now %s\n", __func__, cfg->wcn_external_gpio, state ? "enabled" : "disabled"); return 0; } int xo_auto_detect(u32 reg) int xo_auto_detect(u32 reg) { { Loading Loading @@ -459,8 +420,7 @@ static void wcnss_vregs_off(struct vregs_info regulators[], uint size, continue; continue; if (cfg->wcn_external_gpio_support) { if (cfg->wcn_external_gpio_support) { if (!memcmp(regulators[i].name, VDD_PA, if (!memcmp(regulators[i].name, VDD_PA, sizeof(VDD_PA))) sizeof(VDD_PA))) continue; continue; } } Loading Loading @@ -526,8 +486,7 @@ static int wcnss_vregs_on(struct device *dev, for (i = 0; i < size; i++) { for (i = 0; i < size; i++) { if (cfg->wcn_external_gpio_support) { if (cfg->wcn_external_gpio_support) { if (!memcmp(regulators[i].name, VDD_PA, if (!memcmp(regulators[i].name, VDD_PA, sizeof(VDD_PA))) sizeof(VDD_PA))) continue; continue; } } Loading Loading @@ -675,12 +634,6 @@ int wcnss_wlan_power(struct device *dev, down(&wcnss_power_on_lock); down(&wcnss_power_on_lock); if (on) { if (on) { if (cfg->wcn_external_gpio_support) { rc = wcnss_external_gpio_set_state(true); if (rc) return rc; } /* RIVA regulator settings */ /* RIVA regulator settings */ rc = wcnss_core_vregs_on(dev, hw_type, rc = wcnss_core_vregs_on(dev, hw_type, cfg); cfg); Loading @@ -703,8 +656,6 @@ int wcnss_wlan_power(struct device *dev, } else if (is_power_on) { } else if (is_power_on) { is_power_on = false; is_power_on = false; if (cfg->wcn_external_gpio_support) wcnss_external_gpio_set_state(false); configure_iris_xo(dev, cfg, configure_iris_xo(dev, cfg, WCNSS_WLAN_SWITCH_OFF, NULL); WCNSS_WLAN_SWITCH_OFF, NULL); wcnss_iris_vregs_off(hw_type, cfg); wcnss_iris_vregs_off(hw_type, cfg); Loading @@ -721,8 +672,6 @@ fail_iris_on: wcnss_core_vregs_off(hw_type, cfg); wcnss_core_vregs_off(hw_type, cfg); fail_wcnss_on: fail_wcnss_on: if (cfg->wcn_external_gpio_support) wcnss_external_gpio_set_state(false); up(&wcnss_power_on_lock); up(&wcnss_power_on_lock); return rc; return rc; } } Loading
drivers/net/wireless/wcnss/wcnss_wlan.c +0 −19 Original line number Original line Diff line number Diff line Loading @@ -2810,25 +2810,6 @@ wcnss_trigger_config(struct platform_device *pdev) wlan_cfg->wcn_external_gpio_support = wlan_cfg->wcn_external_gpio_support = of_property_read_bool(node, "qcom,wcn-external-gpio-support"); of_property_read_bool(node, "qcom,wcn-external-gpio-support"); if (wlan_cfg->wcn_external_gpio_support) { if (of_find_property(node, WCNSS_EXTERNAL_GPIO_NAME, NULL)) { wlan_cfg->wcn_external_gpio = of_get_named_gpio( pdev->dev.of_node, WCNSS_EXTERNAL_GPIO_NAME, 0); if (!gpio_is_valid(wlan_cfg->wcn_external_gpio)) { pr_err("%s: Invalid %s num defined in DT\n", __func__, WCNSS_EXTERNAL_GPIO_NAME); ret = -EINVAL; goto fail; } } else { pr_err("%s: %s prop not defined in DT node\n", __func__, WCNSS_EXTERNAL_GPIO_NAME); goto fail; } } if (of_property_read_u32(node, "qcom,wlan-rx-buff-count", if (of_property_read_u32(node, "qcom,wlan-rx-buff-count", &penv->wlan_rx_buff_count)) { &penv->wlan_rx_buff_count)) { Loading
include/linux/wcnss_wlan.h +0 −6 Original line number Original line Diff line number Diff line Loading @@ -20,11 +20,6 @@ #define IRIS_REGULATORS 4 #define IRIS_REGULATORS 4 #define PRONTO_REGULATORS 3 #define PRONTO_REGULATORS 3 #define WCNSS_EXTERNAL_GPIO_NAME "qcom,wcn-external-gpio" #define WCNSS_EXTERNAL_GPIO_HIGH 1 #define WCNSS_EXTERNAL_GPIO_LOW 0 #define WCNSS_EXTERNAL_GPIO_DIR_OUT 1 enum wcnss_opcode { enum wcnss_opcode { WCNSS_WLAN_SWITCH_OFF = 0, WCNSS_WLAN_SWITCH_OFF = 0, WCNSS_WLAN_SWITCH_ON, WCNSS_WLAN_SWITCH_ON, Loading @@ -44,7 +39,6 @@ struct vregs_level { struct wcnss_wlan_config { struct wcnss_wlan_config { bool wcn_external_gpio_support; bool wcn_external_gpio_support; int wcn_external_gpio; int use_48mhz_xo; int use_48mhz_xo; int is_pronto_vadc; int is_pronto_vadc; int is_pronto_v3; int is_pronto_v3; Loading