Lines Matching refs:mask
794 #define ES1688_SINGLE(xname, xindex, reg, shift, mask, invert) \ argument
798 .private_value = reg | (shift << 8) | (mask << 16) | (invert << 24) }
802 int mask = (kcontrol->private_value >> 16) & 0xff; in snd_es1688_info_single() local
804 uinfo->type = mask == 1 ? SNDRV_CTL_ELEM_TYPE_BOOLEAN : SNDRV_CTL_ELEM_TYPE_INTEGER; in snd_es1688_info_single()
807 uinfo->value.integer.max = mask; in snd_es1688_info_single()
817 int mask = (kcontrol->private_value >> 16) & 0xff; in snd_es1688_get_single() local
821 ucontrol->value.integer.value[0] = (snd_es1688_mixer_read(chip, reg) >> shift) & mask; in snd_es1688_get_single()
824 ucontrol->value.integer.value[0] = mask - ucontrol->value.integer.value[0]; in snd_es1688_get_single()
834 int mask = (kcontrol->private_value >> 16) & 0xff; in snd_es1688_put_single() local
839 nval = (ucontrol->value.integer.value[0] & mask); in snd_es1688_put_single()
841 nval = mask - nval; in snd_es1688_put_single()
845 nval = (oval & ~(mask << shift)) | nval; in snd_es1688_put_single()
853 #define ES1688_DOUBLE(xname, xindex, left_reg, right_reg, shift_left, shift_right, mask, invert) \ argument
857 ….private_value = left_reg | (right_reg << 8) | (shift_left << 16) | (shift_right << 19) | (mask <<…
861 int mask = (kcontrol->private_value >> 24) & 0xff; in snd_es1688_info_double() local
863 uinfo->type = mask == 1 ? SNDRV_CTL_ELEM_TYPE_BOOLEAN : SNDRV_CTL_ELEM_TYPE_INTEGER; in snd_es1688_info_double()
866 uinfo->value.integer.max = mask; in snd_es1688_info_double()
878 int mask = (kcontrol->private_value >> 24) & 0xff; in snd_es1688_get_double() local
895 ucontrol->value.integer.value[0] = (left >> shift_left) & mask; in snd_es1688_get_double()
896 ucontrol->value.integer.value[1] = (right >> shift_right) & mask; in snd_es1688_get_double()
898 ucontrol->value.integer.value[0] = mask - ucontrol->value.integer.value[0]; in snd_es1688_get_double()
899 ucontrol->value.integer.value[1] = mask - ucontrol->value.integer.value[1]; in snd_es1688_get_double()
912 int mask = (kcontrol->private_value >> 24) & 0xff; in snd_es1688_put_double() local
917 val1 = ucontrol->value.integer.value[0] & mask; in snd_es1688_put_double()
918 val2 = ucontrol->value.integer.value[1] & mask; in snd_es1688_put_double()
920 val1 = mask - val1; in snd_es1688_put_double()
921 val2 = mask - val2; in snd_es1688_put_double()
935 val1 = (oval1 & ~(mask << shift_left)) | val1; in snd_es1688_put_double()
936 val2 = (oval2 & ~(mask << shift_right)) | val2; in snd_es1688_put_double()
953 val1 = (oval1 & ~((mask << shift_left) | (mask << shift_right))) | val1 | val2; in snd_es1688_put_double()