Lines Matching refs:pin_data

657 	struct ns2_pin *pin_data = pctrldev->desc->pins[pin].drv_data;  in ns2_pin_set_enable()  local
664 val = readl(base_address + pin_data->pin_conf.offset); in ns2_pin_set_enable()
665 val &= ~(NS2_PIN_SRC_MASK << pin_data->pin_conf.input_en); in ns2_pin_set_enable()
668 val |= NS2_PIN_INPUT_EN_MASK << pin_data->pin_conf.input_en; in ns2_pin_set_enable()
670 writel(val, (base_address + pin_data->pin_conf.offset)); in ns2_pin_set_enable()
680 struct ns2_pin *pin_data = pctrldev->desc->pins[pin].drv_data; in ns2_pin_get_enable() local
685 enable = readl(pinctrl->pinconf_base + pin_data->pin_conf.offset); in ns2_pin_get_enable()
686 enable = (enable >> pin_data->pin_conf.input_en) & in ns2_pin_get_enable()
703 struct ns2_pin *pin_data = pctrldev->desc->pins[pin].drv_data; in ns2_pin_set_slew() local
710 val = readl(base_address + pin_data->pin_conf.offset); in ns2_pin_set_slew()
711 val &= ~(NS2_PIN_SRC_MASK << pin_data->pin_conf.src_shift); in ns2_pin_set_slew()
714 val |= NS2_PIN_SRC_MASK << pin_data->pin_conf.src_shift; in ns2_pin_set_slew()
716 writel(val, (base_address + pin_data->pin_conf.offset)); in ns2_pin_set_slew()
727 struct ns2_pin *pin_data = pctrldev->desc->pins[pin].drv_data; in ns2_pin_get_slew() local
732 val = readl(pinctrl->pinconf_base + pin_data->pin_conf.offset); in ns2_pin_get_slew()
733 *slew = (val >> pin_data->pin_conf.src_shift) & NS2_PIN_SRC_MASK; in ns2_pin_get_slew()
744 struct ns2_pin *pin_data = pctrldev->desc->pins[pin].drv_data; in ns2_pin_set_pull() local
751 val = readl(base_address + pin_data->pin_conf.offset); in ns2_pin_set_pull()
752 val &= ~(NS2_PIN_PULL_MASK << pin_data->pin_conf.pull_shift); in ns2_pin_set_pull()
755 val |= NS2_PIN_PULL_UP << pin_data->pin_conf.pull_shift; in ns2_pin_set_pull()
757 val |= NS2_PIN_PULL_DOWN << pin_data->pin_conf.pull_shift; in ns2_pin_set_pull()
758 writel(val, (base_address + pin_data->pin_conf.offset)); in ns2_pin_set_pull()
771 struct ns2_pin *pin_data = pctrldev->desc->pins[pin].drv_data; in ns2_pin_get_pull() local
776 val = readl(pinctrl->pinconf_base + pin_data->pin_conf.offset); in ns2_pin_get_pull()
777 val = (val >> pin_data->pin_conf.pull_shift) & NS2_PIN_PULL_MASK; in ns2_pin_get_pull()
793 struct ns2_pin *pin_data = pctrldev->desc->pins[pin].drv_data; in ns2_pin_set_strength() local
804 val = readl(base_address + pin_data->pin_conf.offset); in ns2_pin_set_strength()
805 val &= ~(NS2_PIN_DRIVE_STRENGTH_MASK << pin_data->pin_conf.drive_shift); in ns2_pin_set_strength()
806 val |= ((strength / 2) - 1) << pin_data->pin_conf.drive_shift; in ns2_pin_set_strength()
807 writel(val, (base_address + pin_data->pin_conf.offset)); in ns2_pin_set_strength()
819 struct ns2_pin *pin_data = pctrldev->desc->pins[pin].drv_data; in ns2_pin_get_strength() local
824 val = readl(pinctrl->pinconf_base + pin_data->pin_conf.offset); in ns2_pin_get_strength()
825 *strength = (val >> pin_data->pin_conf.drive_shift) & in ns2_pin_get_strength()
838 struct ns2_pin *pin_data = pctldev->desc->pins[pin].drv_data; in ns2_pin_config_get() local
844 if (pin_data->pin_conf.base == -1) in ns2_pin_config_get()
898 struct ns2_pin *pin_data = pctrldev->desc->pins[pin].drv_data; in ns2_pin_config_set() local
904 if (pin_data->pin_conf.base == -1) in ns2_pin_config_set()