Lines Matching refs:pin_conf
167 struct ns2_pinconf pin_conf; member
174 .pin_conf = { \
670 val = readl(base_address + pin_data->pin_conf.offset); in ns2_pin_set_enable()
671 val &= ~(NS2_PIN_SRC_MASK << pin_data->pin_conf.input_en); in ns2_pin_set_enable()
674 val |= NS2_PIN_INPUT_EN_MASK << pin_data->pin_conf.input_en; in ns2_pin_set_enable()
676 writel(val, (base_address + pin_data->pin_conf.offset)); in ns2_pin_set_enable()
691 enable = readl(pinctrl->pinconf_base + pin_data->pin_conf.offset); in ns2_pin_get_enable()
692 enable = (enable >> pin_data->pin_conf.input_en) & in ns2_pin_get_enable()
716 val = readl(base_address + pin_data->pin_conf.offset); in ns2_pin_set_slew()
717 val &= ~(NS2_PIN_SRC_MASK << pin_data->pin_conf.src_shift); in ns2_pin_set_slew()
720 val |= NS2_PIN_SRC_MASK << pin_data->pin_conf.src_shift; in ns2_pin_set_slew()
722 writel(val, (base_address + pin_data->pin_conf.offset)); in ns2_pin_set_slew()
738 val = readl(pinctrl->pinconf_base + pin_data->pin_conf.offset); in ns2_pin_get_slew()
739 *slew = (val >> pin_data->pin_conf.src_shift) & NS2_PIN_SRC_MASK; in ns2_pin_get_slew()
757 val = readl(base_address + pin_data->pin_conf.offset); in ns2_pin_set_pull()
758 val &= ~(NS2_PIN_PULL_MASK << pin_data->pin_conf.pull_shift); in ns2_pin_set_pull()
761 val |= NS2_PIN_PULL_UP << pin_data->pin_conf.pull_shift; in ns2_pin_set_pull()
763 val |= NS2_PIN_PULL_DOWN << pin_data->pin_conf.pull_shift; in ns2_pin_set_pull()
764 writel(val, (base_address + pin_data->pin_conf.offset)); in ns2_pin_set_pull()
782 val = readl(pinctrl->pinconf_base + pin_data->pin_conf.offset); in ns2_pin_get_pull()
783 val = (val >> pin_data->pin_conf.pull_shift) & NS2_PIN_PULL_MASK; in ns2_pin_get_pull()
810 val = readl(base_address + pin_data->pin_conf.offset); in ns2_pin_set_strength()
811 val &= ~(NS2_PIN_DRIVE_STRENGTH_MASK << pin_data->pin_conf.drive_shift); in ns2_pin_set_strength()
812 val |= ((strength / 2) - 1) << pin_data->pin_conf.drive_shift; in ns2_pin_set_strength()
813 writel(val, (base_address + pin_data->pin_conf.offset)); in ns2_pin_set_strength()
830 val = readl(pinctrl->pinconf_base + pin_data->pin_conf.offset); in ns2_pin_get_strength()
831 *strength = (val >> pin_data->pin_conf.drive_shift) & in ns2_pin_get_strength()
850 if (pin_data->pin_conf.base == -1) in ns2_pin_config_get()
910 if (pin_data->pin_conf.base == -1) in ns2_pin_config_set()