Lines Matching refs:data
56 static void ewx_i2c_setlines(struct snd_i2c_bus *bus, int clk, int data) in ewx_i2c_setlines() argument
62 if (data) in ewx_i2c_setlines()
116 static void ewx_i2c_direction(struct snd_i2c_bus *bus, int clock, int data) in ewx_i2c_direction() argument
123 if (data) in ewx_i2c_direction()
149 unsigned char data, ndata; in snd_ice1712_ews88mt_chip_select() local
154 if (snd_i2c_readbytes(spec->i2cdevs[EWS_I2C_PCF2], &data, 1) != 1) in snd_ice1712_ews88mt_chip_select()
156 ndata = (data & 0xf0) | chip_mask; in snd_ice1712_ews88mt_chip_select()
157 if (ndata != data) in snd_ice1712_ews88mt_chip_select()
420 …ic int snd_ice1712_6fire_write_pca(struct snd_ice1712 *ice, unsigned char reg, unsigned char data);
646 unsigned char data; in snd_ice1712_ews88mt_output_sense_get() local
649 if (snd_i2c_readbytes(spec->i2cdevs[EWS_I2C_PCF2], &data, 1) != 1) { in snd_ice1712_ews88mt_output_sense_get()
654 …ucontrol->value.enumerated.item[0] = data & ICE1712_EWS88MT_OUTPUT_SENSE ? 1 : 0; /* high = -10dBV… in snd_ice1712_ews88mt_output_sense_get()
663 unsigned char data, ndata; in snd_ice1712_ews88mt_output_sense_put() local
666 if (snd_i2c_readbytes(spec->i2cdevs[EWS_I2C_PCF2], &data, 1) != 1) { in snd_ice1712_ews88mt_output_sense_put()
670 …ndata = (data & ~ICE1712_EWS88MT_OUTPUT_SENSE) | (ucontrol->value.enumerated.item[0] ? ICE1712_EWS… in snd_ice1712_ews88mt_output_sense_put()
671 if (ndata != data && snd_i2c_sendbytes(spec->i2cdevs[EWS_I2C_PCF2], in snd_ice1712_ews88mt_output_sense_put()
677 return ndata != data; in snd_ice1712_ews88mt_output_sense_put()
686 unsigned char data; in snd_ice1712_ews88mt_input_sense_get() local
691 if (snd_i2c_readbytes(spec->i2cdevs[EWS_I2C_PCF1], &data, 1) != 1) { in snd_ice1712_ews88mt_input_sense_get()
696 ucontrol->value.enumerated.item[0] = data & (1 << channel) ? 0 : 1; in snd_ice1712_ews88mt_input_sense_get()
707 unsigned char data, ndata; in snd_ice1712_ews88mt_input_sense_put() local
712 if (snd_i2c_readbytes(spec->i2cdevs[EWS_I2C_PCF1], &data, 1) != 1) { in snd_ice1712_ews88mt_input_sense_put()
716 ndata = (data & ~(1 << channel)) | (ucontrol->value.enumerated.item[0] ? 0 : (1 << channel)); in snd_ice1712_ews88mt_input_sense_put()
717 if (ndata != data && snd_i2c_sendbytes(spec->i2cdevs[EWS_I2C_PCF1], in snd_ice1712_ews88mt_input_sense_put()
723 return ndata != data; in snd_ice1712_ews88mt_input_sense_put()
756 unsigned char data[2]; in snd_ice1712_ews88d_control_get() local
759 if (snd_i2c_readbytes(spec->i2cdevs[EWS_I2C_88D], data, 2) != 2) { in snd_ice1712_ews88d_control_get()
764 data[0] = (data[shift >> 3] >> (shift & 7)) & 0x01; in snd_ice1712_ews88d_control_get()
766 data[0] ^= 0x01; in snd_ice1712_ews88d_control_get()
767 ucontrol->value.integer.value[0] = data[0]; in snd_ice1712_ews88d_control_get()
777 unsigned char data[2], ndata[2]; in snd_ice1712_ews88d_control_put() local
781 if (snd_i2c_readbytes(spec->i2cdevs[EWS_I2C_88D], data, 2) != 2) { in snd_ice1712_ews88d_control_put()
785 ndata[shift >> 3] = data[shift >> 3] & ~(1 << (shift & 7)); in snd_ice1712_ews88d_control_put()
793 change = (data[shift >> 3] != ndata[shift >> 3]); in snd_ice1712_ews88d_control_put()
795 snd_i2c_sendbytes(spec->i2cdevs[EWS_I2C_88D], data, 2) != 2) { in snd_ice1712_ews88d_control_put()
844 …tic int snd_ice1712_6fire_write_pca(struct snd_ice1712 *ice, unsigned char reg, unsigned char data) in snd_ice1712_6fire_write_pca() argument
851 bytes[1] = data; in snd_ice1712_6fire_write_pca()
867 int data; in snd_ice1712_6fire_control_get() local
869 if ((data = snd_ice1712_6fire_read_pca(ice, PCF9554_REG_OUTPUT)) < 0) in snd_ice1712_6fire_control_get()
870 return data; in snd_ice1712_6fire_control_get()
871 data = (data >> shift) & 1; in snd_ice1712_6fire_control_get()
873 data ^= 1; in snd_ice1712_6fire_control_get()
874 ucontrol->value.integer.value[0] = data; in snd_ice1712_6fire_control_get()
883 int data, ndata; in snd_ice1712_6fire_control_put() local
885 if ((data = snd_ice1712_6fire_read_pca(ice, PCF9554_REG_OUTPUT)) < 0) in snd_ice1712_6fire_control_put()
886 return data; in snd_ice1712_6fire_control_put()
887 ndata = data & ~(1 << shift); in snd_ice1712_6fire_control_put()
892 if (data != ndata) { in snd_ice1712_6fire_control_put()
916 int data; in snd_ice1712_6fire_select_input_get() local
918 if ((data = snd_ice1712_6fire_read_pca(ice, PCF9554_REG_OUTPUT)) < 0) in snd_ice1712_6fire_select_input_get()
919 return data; in snd_ice1712_6fire_select_input_get()
920 ucontrol->value.integer.value[0] = data & 3; in snd_ice1712_6fire_select_input_get()
927 int data, ndata; in snd_ice1712_6fire_select_input_put() local
929 if ((data = snd_ice1712_6fire_read_pca(ice, PCF9554_REG_OUTPUT)) < 0) in snd_ice1712_6fire_select_input_put()
930 return data; in snd_ice1712_6fire_select_input_put()
931 ndata = data & ~3; in snd_ice1712_6fire_select_input_put()
933 if (data != ndata) { in snd_ice1712_6fire_select_input_put()