| /linux/drivers/char/tpm/ |
| H A D | tpm-chip.c | 40 static int tpm_request_locality(struct tpm_chip *chip) in tpm_request_locality() argument 44 if (!chip->ops->request_locality) in tpm_request_locality() 47 rc = chip->ops->request_locality(chip, 0); in tpm_request_locality() 51 chip->locality = rc; in tpm_request_locality() 55 static void tpm_relinquish_locality(struct tpm_chip *chip) in tpm_relinquish_locality() argument 59 if (!chip->ops->relinquish_locality) in tpm_relinquish_locality() 62 rc = chip->ops->relinquish_locality(chip, chip->locality); in tpm_relinquish_locality() 64 dev_err(&chip->dev, "%s: : error %d\n", __func__, rc); in tpm_relinquish_locality() 66 chip->locality = -1; in tpm_relinquish_locality() 69 static int tpm_cmd_ready(struct tpm_chip *chip) in tpm_cmd_ready() argument [all …]
|
| H A D | tpm-interface.c | 52 unsigned long tpm_calc_ordinal_duration(struct tpm_chip *chip, u32 ordinal) in tpm_calc_ordinal_duration() argument 54 if (chip->flags & TPM_CHIP_FLAG_TPM2) in tpm_calc_ordinal_duration() 57 return tpm1_calc_ordinal_duration(chip, ordinal); in tpm_calc_ordinal_duration() 61 static void tpm_chip_cancel(struct tpm_chip *chip) in tpm_chip_cancel() argument 63 if (!chip->ops->cancel) in tpm_chip_cancel() 66 chip->ops->cancel(chip); in tpm_chip_cancel() 69 static u8 tpm_chip_status(struct tpm_chip *chip) in tpm_chip_status() argument 71 if (!chip->ops->status) in tpm_chip_status() 74 return chip->ops->status(chip); in tpm_chip_status() 77 static bool tpm_chip_req_canceled(struct tpm_chip *chip, u8 status) in tpm_chip_req_canceled() argument [all …]
|
| /linux/sound/pci/echoaudio/ |
| H A D | echoaudio_dsp.c | 35 static int restore_dsp_settings(struct echoaudio *chip); 42 static int wait_handshake(struct echoaudio *chip) in wait_handshake() argument 50 if (chip->comm_page->handshake) { in wait_handshake() 56 dev_err(chip->card->dev, "wait_handshake(): Timeout waiting for DSP\n"); in wait_handshake() 66 static int send_vector(struct echoaudio *chip, u32 command) in send_vector() argument 74 if (!(get_dsp_register(chip, CHI32_VECTOR_REG) & in send_vector() 76 set_dsp_register(chip, CHI32_VECTOR_REG, command); in send_vector() 83 dev_err(chip->card->dev, "timeout on send_vector\n"); in send_vector() 91 static int write_dsp(struct echoaudio *chip, u32 data) in write_dsp() argument 96 status = get_dsp_register(chip, CHI32_STATUS_RE in write_dsp() 115 read_dsp(struct echoaudio * chip,u32 * data) read_dsp() argument 145 read_sn(struct echoaudio * chip) read_sn() argument 167 check_asic_status(struct echoaudio * chip) check_asic_status() argument 180 load_asic_generic(struct echoaudio * chip,u32 cmd,short asic) load_asic_generic() argument 227 install_resident_loader(struct echoaudio * chip) install_resident_loader() argument 335 load_dsp(struct echoaudio * chip,u16 * code) load_dsp() argument 489 load_firmware(struct echoaudio * chip) load_firmware() argument 531 set_nominal_level(struct echoaudio * chip,u16 index,char consumer) set_nominal_level() argument 555 set_output_gain(struct echoaudio * chip,u16 channel,s8 gain) set_output_gain() argument 573 set_monitor_gain(struct echoaudio * chip,u16 output,u16 input,s8 gain) set_monitor_gain() argument 591 update_output_line_level(struct echoaudio * chip) update_output_line_level() argument 602 update_input_line_level(struct echoaudio * chip) update_input_line_level() argument 614 set_meters_on(struct echoaudio * chip,char on) set_meters_on() argument 639 get_audio_meters(struct echoaudio * chip,long * meters) get_audio_meters() argument 669 restore_dsp_rettings(struct echoaudio * chip) restore_dsp_rettings() argument 781 set_audio_format(struct echoaudio * chip,u16 pipe_index,const struct audioformat * format) set_audio_format() argument 859 start_transport(struct echoaudio * chip,u32 channel_mask,u32 cyclic_mask) start_transport() argument 885 pause_transport(struct echoaudio * chip,u32 channel_mask) pause_transport() argument 911 stop_transport(struct echoaudio * chip,u32 channel_mask) stop_transport() argument 937 is_pipe_allocated(struct echoaudio * chip,u16 pipe_index) is_pipe_allocated() argument 946 rest_in_peace(struct echoaudio * chip) rest_in_peace() argument 971 init_dsp_comm_page(struct echoaudio * chip) init_dsp_comm_page() argument 1008 init_line_levels(struct echoaudio * chip) init_line_levels() argument 1025 service_irq(struct echoaudio * chip) service_irq() argument 1054 allocate_pipes(struct echoaudio * chip,struct audiopipe * pipe,int pipe_index,int interleave) allocate_pipes() argument 1092 free_pipes(struct echoaudio * chip,struct audiopipe * pipe) free_pipes() argument 1116 sglist_init(struct echoaudio * chip,struct audiopipe * pipe) sglist_init() argument 1127 sglist_add_mapping(struct echoaudio * chip,struct audiopipe * pipe,dma_addr_t address,size_t length) sglist_add_mapping() argument 1146 sglist_add_irq(struct echoaudio * chip,struct audiopipe * pipe) sglist_add_irq() argument 1153 sglist_wrap(struct echoaudio * chip,struct audiopipe * pipe) sglist_wrap() argument [all...] |
| H A D | layla20_dsp.c | 32 static int read_dsp(struct echoaudio *chip, u32 *data); 33 static int set_professional_spdif(struct echoaudio *chip, char prof); 34 static int load_asic_generic(struct echoaudio *chip, u32 cmd, short asic); 35 static int check_asic_status(struct echoaudio *chip); 36 static int update_flags(struct echoaudio *chip); 39 static int init_hw(struct echoaudio *chip, u16 device_id, u16 subdevice_id) in init_hw() argument 46 err = init_dsp_comm_page(chip); in init_hw() 48 dev_err(chip->card->dev, in init_hw() 53 chip->device_id = device_id; in init_hw() 54 chip->subdevice_id = subdevice_id; in init_hw() [all …]
|
| H A D | echo3g_dsp.c | 31 static int load_asic(struct echoaudio *chip); 32 static int dsp_set_digital_mode(struct echoaudio *chip, u8 mode); 33 static int set_digital_mode(struct echoaudio *chip, u8 mode); 34 static int check_asic_status(struct echoaudio *chip); 35 static int set_sample_rate(struct echoaudio *chip, u32 rate); 36 static int set_input_clock(struct echoaudio *chip, u16 clock); 37 static int set_professional_spdif(struct echoaudio *chip, char prof); 38 static int set_phantom_power(struct echoaudio *chip, char on); 39 static int write_control_reg(struct echoaudio *chip, u32 ctl, u32 frq, 44 static int init_hw(struct echoaudio *chip, u16 device_id, u16 subdevice_id) in init_hw() argument [all …]
|
| H A D | gina20_dsp.c | 32 static int set_professional_spdif(struct echoaudio *chip, char prof); 33 static int update_flags(struct echoaudio *chip); 36 static int init_hw(struct echoaudio *chip, u16 device_id, u16 subdevice_id) in init_hw() argument 43 err = init_dsp_comm_page(chip); in init_hw() 45 dev_err(chip->card->dev, in init_hw() 50 chip->device_id = device_id; in init_hw() 51 chip->subdevice_id = subdevice_id; in init_hw() 52 chip->bad_board = true; in init_hw() 53 chip->dsp_code_to_load = FW_GINA20_DSP; in init_hw() 54 chip->spdif_status = GD_SPDIF_STATUS_UNDEF; in init_hw() [all …]
|
| H A D | mia_dsp.c | 32 static int set_input_clock(struct echoaudio *chip, u16 clock); 33 static int set_professional_spdif(struct echoaudio *chip, char prof); 34 static int update_flags(struct echoaudio *chip); 35 static int set_vmixer_gain(struct echoaudio *chip, u16 output, u16 pipe, 37 static int update_vmixer_level(struct echoaudio *chip); 40 static int init_hw(struct echoaudio *chip, u16 device_id, u16 subdevice_id) in init_hw() argument 47 err = init_dsp_comm_page(chip); in init_hw() 49 dev_err(chip->card->dev, in init_hw() 54 chip->device_id = device_id; in init_hw() 55 chip->subdevice_id = subdevice_id; in init_hw() [all …]
|
| /linux/drivers/mtd/nand/raw/ |
| H A D | nand_legacy.c | 28 static uint8_t nand_read_byte(struct nand_chip *chip) in nand_read_byte() argument 30 return readb(chip->legacy.IO_ADDR_R); in nand_read_byte() 40 static uint8_t nand_read_byte16(struct nand_chip *chip) in nand_read_byte16() argument 42 return (uint8_t) cpu_to_le16(readw(chip->legacy.IO_ADDR_R)); in nand_read_byte16() 52 static void nand_select_chip(struct nand_chip *chip, int chipnr) in nand_select_chip() argument 56 chip->legacy.cmd_ctrl(chip, NAND_CMD_NONE, in nand_select_chip() 74 static void nand_write_byte(struct nand_chip *chip, uint8_t byte) in nand_write_byte() argument 76 chip->legacy.write_buf(chip, &byte, 1); in nand_write_byte() 86 static void nand_write_byte16(struct nand_chip *chip, uint8_t byte) in nand_write_byte16() argument 106 chip->legacy.write_buf(chip, (uint8_t *)&word, 2); in nand_write_byte16() [all …]
|
| H A D | nand_base.c | 99 static int check_offs_len(struct nand_chip *chip, loff_t ofs, uint64_t len) in check_offs_len() argument 104 if (ofs & ((1ULL << chip->phys_erase_shift) - 1)) { in check_offs_len() 110 if (len & ((1ULL << chip->phys_erase_shift) - 1)) { in check_offs_len() 171 void nand_select_target(struct nand_chip *chip, unsigned int cs) in nand_select_target() argument 177 if (WARN_ON(cs > nanddev_ntargets(&chip->base))) in nand_select_target() 180 chip->cur_cs = cs; in nand_select_target() 182 if (chip->legacy.select_chip) in nand_select_target() 183 chip->legacy.select_chip(chip, cs); in nand_select_target() 194 void nand_deselect_target(struct nand_chip *chip) in nand_deselect_target() argument 196 if (chip->legacy.select_chip) in nand_deselect_target() [all …]
|
| /linux/drivers/usb/typec/tcpm/ |
| H A D | fusb302.c | 39 * for the current capability offered by the SRC. As FUSB302 chip fires 93 /* lock for sharing chip states */ 96 /* chip status */ 129 static bool fusb302_log_full(struct fusb302_chip *chip) in fusb302_log_full() argument 131 return chip->logbuffer_tail == in fusb302_log_full() 132 (chip->logbuffer_head + 1) % LOG_BUFFER_ENTRIES; in fusb302_log_full() 136 static void _fusb302_log(struct fusb302_chip *chip, const char *fmt, in _fusb302_log() argument 143 if (!chip->logbuffer[chip->logbuffer_head]) { in _fusb302_log() 144 chip in _fusb302_log() 184 fusb302_log(struct fusb302_chip * chip,const char * fmt,...) fusb302_log() argument 195 struct fusb302_chip *chip = s->private; fusb302_debug_show() local 212 fusb302_debugfs_init(struct fusb302_chip * chip) fusb302_debugfs_init() argument 223 fusb302_debugfs_exit(struct fusb302_chip * chip) fusb302_debugfs_exit() argument 230 fusb302_log(const struct fusb302_chip * chip,const char * fmt,...) fusb302_log() argument 232 fusb302_debugfs_init(const struct fusb302_chip * chip) fusb302_debugfs_init() argument 233 fusb302_debugfs_exit(const struct fusb302_chip * chip) fusb302_debugfs_exit() argument 237 fusb302_i2c_write(struct fusb302_chip * chip,u8 address,u8 data) fusb302_i2c_write() argument 250 fusb302_i2c_block_write(struct fusb302_chip * chip,u8 address,u8 length,const u8 * data) fusb302_i2c_block_write() argument 267 fusb302_i2c_read(struct fusb302_chip * chip,u8 address,u8 * data) fusb302_i2c_read() argument 280 fusb302_i2c_block_read(struct fusb302_chip * chip,u8 address,u8 length,u8 * data) fusb302_i2c_block_read() argument 305 fusb302_i2c_mask_write(struct fusb302_chip * chip,u8 address,u8 mask,u8 value) fusb302_i2c_mask_write() argument 323 fusb302_i2c_set_bits(struct fusb302_chip * chip,u8 address,u8 set_bits) fusb302_i2c_set_bits() argument 329 fusb302_i2c_clear_bits(struct fusb302_chip * chip,u8 address,u8 clear_bits) fusb302_i2c_clear_bits() argument 335 fusb302_sw_reset(struct fusb302_chip * chip) fusb302_sw_reset() argument 349 fusb302_enable_tx_auto_retries(struct fusb302_chip * chip,u8 retry_count) fusb302_enable_tx_auto_retries() argument 363 fusb302_init_interrupt(struct fusb302_chip * chip) fusb302_init_interrupt() argument 385 fusb302_set_power_mode(struct fusb302_chip * chip,u8 power_mode) fusb302_set_power_mode() argument 396 struct fusb302_chip *chip = container_of(dev, struct fusb302_chip, tcpm_init() local 427 struct fusb302_chip *chip = container_of(dev, struct fusb302_chip, tcpm_get_vbus() local 440 struct fusb302_chip *chip = container_of(dev, struct fusb302_chip, tcpm_get_current_limit() local 470 fusb302_set_src_current(struct fusb302_chip * chip,enum src_current_status status) fusb302_set_src_current() argument 499 fusb302_set_toggling(struct fusb302_chip * chip,enum toggling_mode mode) fusb302_set_toggling() argument 601 struct fusb302_chip *chip = container_of(dev, struct fusb302_chip, tcpm_set_cc() local 708 struct fusb302_chip *chip = container_of(dev, struct fusb302_chip, tcpm_get_cc() local 729 struct fusb302_chip *chip = container_of(dev, struct fusb302_chip, tcpm_set_vconn() local 760 struct fusb302_chip *chip = container_of(dev, struct fusb302_chip, tcpm_set_vbus() local 791 fusb302_pd_tx_flush(struct fusb302_chip * chip) fusb302_pd_tx_flush() argument 797 fusb302_pd_rx_flush(struct fusb302_chip * chip) fusb302_pd_rx_flush() argument 803 fusb302_pd_set_auto_goodcrc(struct fusb302_chip * chip,bool on) fusb302_pd_set_auto_goodcrc() argument 812 fusb302_pd_set_interrupts(struct fusb302_chip * chip,bool on) fusb302_pd_set_interrupts() argument 840 struct fusb302_chip *chip = container_of(dev, struct fusb302_chip, tcpm_set_pd_rx() local 894 struct fusb302_chip *chip = container_of(dev, struct fusb302_chip, tcpm_set_roles() local 926 struct fusb302_chip *chip = container_of(dev, struct fusb302_chip, tcpm_start_toggling() local 963 fusb302_pd_send_message(struct fusb302_chip * chip,const struct pd_message * msg) fusb302_pd_send_message() argument 1012 fusb302_pd_send_hardreset(struct fusb302_chip * chip) fusb302_pd_send_hardreset() argument 1032 struct fusb302_chip *chip = container_of(dev, struct fusb302_chip, tcpm_pd_transmit() local 1080 struct fusb302_chip *chip = container_of(work, struct fusb302_chip, fusb302_bc_lvl_handler_work() local 1147 fusb302_set_cc_polarity_and_pull(struct fusb302_chip * chip,enum typec_cc_polarity cc_polarity,bool pull_up,bool pull_down) fusb302_set_cc_polarity_and_pull() argument 1188 fusb302_handle_togdone_snk(struct fusb302_chip * chip,u8 togdone_result) fusb302_handle_togdone_snk() argument 1251 fusb302_get_src_cc_status(struct fusb302_chip * chip,enum typec_cc_polarity cc_polarity,enum typec_cc_status * cc) fusb302_get_src_cc_status() argument 1306 fusb302_handle_togdone_src(struct fusb302_chip * chip,u8 togdone_result) fusb302_handle_togdone_src() argument 1392 fusb302_handle_togdone(struct fusb302_chip * chip) fusb302_handle_togdone() argument 1424 fusb302_pd_reset(struct fusb302_chip * chip) fusb302_pd_reset() argument 1430 fusb302_pd_read_message(struct fusb302_chip * chip,struct pd_message * msg) fusb302_pd_read_message() argument 1485 struct fusb302_chip *chip = dev_id; fusb302_irq_intn() local 1503 struct fusb302_chip *chip = container_of(work, struct fusb302_chip, fusb302_irq_work() local 1636 init_gpio(struct fusb302_chip * chip) init_gpio() argument 1690 struct fusb302_chip *chip; fusb302_probe() local 1782 struct fusb302_chip *chip = i2c_get_clientdata(client); fusb302_remove() local 1796 struct fusb302_chip *chip = dev->driver_data; fusb302_pm_suspend() local 1810 struct fusb302_chip *chip = dev->driver_data; fusb302_pm_resume() local [all...] |
| /linux/tools/testing/selftests/gpio/ |
| H A D | gpio-sim.sh | 128 $BASE_DIR/gpio-chip-info /dev/`configfs_chip_name $CHIP $BANK` num-lines || \ 136 $BASE_DIR/gpio-chip-info /dev/`configfs_chip_name $CHIP $BANK` label || \ 181 create_chip chip 182 create_bank chip bank 183 enable_chip chip 184 test -n `cat $CONFIGFS_DIR/chip/bank/chip_name` || fail "chip_name doesn't work" 185 disable_chip chip 186 remove_chip chip 189 create_chip chip 190 create_bank chip bank [all …]
|
| /linux/sound/sh/ |
| H A D | sh_dac_audio.c | 53 static void dac_audio_start_timer(struct snd_sh_dac *chip) in dac_audio_start_timer() argument 55 hrtimer_start(&chip->hrtimer, chip->wakeups_per_second, in dac_audio_start_timer() 59 static void dac_audio_stop_timer(struct snd_sh_dac *chip) in dac_audio_stop_timer() argument 61 hrtimer_cancel(&chip->hrtimer); in dac_audio_stop_timer() 64 static void dac_audio_reset(struct snd_sh_dac *chip) in dac_audio_reset() argument 66 dac_audio_stop_timer(chip); in dac_audio_reset() 67 chip->buffer_begin = chip->buffer_end = chip->data_buffer; in dac_audio_reset() 68 chip->processed = 0; in dac_audio_reset() 69 chip->empty = 1; in dac_audio_reset() 72 static void dac_audio_set_rate(struct snd_sh_dac *chip) in dac_audio_set_rate() argument [all …]
|
| /linux/drivers/input/misc/ |
| H A D | max8997_haptic.c | 56 static void max8997_haptic_set_internal_duty_cycle(struct max8997_haptic *chip) in max8997_haptic_set_internal_duty_cycle() argument 58 u8 duty_index = DIV_ROUND_UP(chip->level * 64, 100); in max8997_haptic_set_internal_duty_cycle() 60 switch (chip->internal_mode_pattern) { in max8997_haptic_set_internal_duty_cycle() 62 max8997_write_reg(chip->client, in max8997_haptic_set_internal_duty_cycle() 66 max8997_write_reg(chip->client, in max8997_haptic_set_internal_duty_cycle() 70 max8997_write_reg(chip->client, in max8997_haptic_set_internal_duty_cycle() 74 max8997_write_reg(chip->client, in max8997_haptic_set_internal_duty_cycle() 82 static void max8997_haptic_configure(struct max8997_haptic *chip) in max8997_haptic_configure() argument 86 value = chip->type << MAX8997_MOTOR_TYPE_SHIFT | in max8997_haptic_configure() 87 chip->enabled << MAX8997_ENABLE_SHIFT | in max8997_haptic_configure() [all …]
|
| /linux/drivers/net/dsa/mv88e6xxx/ |
| H A D | global2.c | 19 int mv88e6xxx_g2_read(struct mv88e6xxx_chip *chip, int reg, u16 *val) in mv88e6xxx_g2_read() argument 21 return mv88e6xxx_read(chip, chip->info->global2_addr, reg, val); in mv88e6xxx_g2_read() 24 int mv88e6xxx_g2_write(struct mv88e6xxx_chip *chip, int reg, u16 val) in mv88e6xxx_g2_write() argument 26 return mv88e6xxx_write(chip, chip->info->global2_addr, reg, val); in mv88e6xxx_g2_write() 29 int mv88e6xxx_g2_wait_bit(struct mv88e6xxx_chip *chip, int reg, int in mv88e6xxx_g2_wait_bit() argument 32 return mv88e6xxx_wait_bit(chip, chip->info->global2_addr, reg, in mv88e6xxx_g2_wait_bit() 38 static int mv88e6xxx_g2_int_source(struct mv88e6xxx_chip *chip, u16 *src) in mv88e6xxx_g2_int_source() argument 41 return mv88e6xxx_g2_read(chip, MV88E6XXX_G2_INT_SRC, src); in mv88e6xxx_g2_int_source() 46 static int mv88e6xxx_g2_int_mask(struct mv88e6xxx_chip *chip, u16 mask) in mv88e6xxx_g2_int_mask() argument 48 return mv88e6xxx_g2_write(chip, MV88E6XXX_G2_INT_MASK, mask); in mv88e6xxx_g2_int_mask() [all …]
|
| H A D | phy.c | 16 int mv88e6165_phy_read(struct mv88e6xxx_chip *chip, struct mii_bus *bus, in mv88e6165_phy_read() argument 19 return mv88e6xxx_read(chip, addr, reg, val); in mv88e6165_phy_read() 22 int mv88e6165_phy_write(struct mv88e6xxx_chip *chip, struct mii_bus *bus, in mv88e6165_phy_write() argument 25 return mv88e6xxx_write(chip, addr, reg, val); in mv88e6165_phy_write() 28 int mv88e6xxx_phy_read(struct mv88e6xxx_chip *chip, int phy, int reg, u16 *val) in mv88e6xxx_phy_read() argument 33 bus = mv88e6xxx_default_mdio_bus(chip); in mv88e6xxx_phy_read() 37 if (!chip->info->ops->phy_read) in mv88e6xxx_phy_read() 40 return chip->info->ops->phy_read(chip, bus, addr, reg, val); in mv88e6xxx_phy_read() 43 int mv88e6xxx_phy_write(struct mv88e6xxx_chip *chip, int phy, int reg, u16 val) in mv88e6xxx_phy_write() argument 48 bus = mv88e6xxx_default_mdio_bus(chip); in mv88e6xxx_phy_write() [all …]
|
| H A D | global1.c | 16 int mv88e6xxx_g1_read(struct mv88e6xxx_chip *chip, int reg, u16 *val) in mv88e6xxx_g1_read() argument 18 int addr = chip->info->global1_addr; in mv88e6xxx_g1_read() 20 return mv88e6xxx_read(chip, addr, reg, val); in mv88e6xxx_g1_read() 23 int mv88e6xxx_g1_write(struct mv88e6xxx_chip *chip, int reg, u16 val) in mv88e6xxx_g1_write() argument 25 int addr = chip->info->global1_addr; in mv88e6xxx_g1_write() 27 return mv88e6xxx_write(chip, addr, reg, val); in mv88e6xxx_g1_write() 30 int mv88e6xxx_g1_wait_bit(struct mv88e6xxx_chip *chip, int reg, int in mv88e6xxx_g1_wait_bit() argument 33 return mv88e6xxx_wait_bit(chip, chip->info->global1_addr, reg, in mv88e6xxx_g1_wait_bit() 37 int mv88e6xxx_g1_wait_mask(struct mv88e6xxx_chip *chip, int reg, in mv88e6xxx_g1_wait_mask() argument 40 return mv88e6xxx_wait_mask(chip, chip->info->global1_addr, reg, in mv88e6xxx_g1_wait_mask() [all …]
|
| H A D | global1_atu.c | 20 static int mv88e6xxx_g1_atu_fid_write(struct mv88e6xxx_chip *chip, u16 fid) in mv88e6xxx_g1_atu_fid_write() argument 22 return mv88e6xxx_g1_write(chip, MV88E6352_G1_ATU_FID, fid & 0xfff); in mv88e6xxx_g1_atu_fid_write() 27 int mv88e6xxx_g1_atu_set_learn2all(struct mv88e6xxx_chip *chip, bool learn2all) in mv88e6xxx_g1_atu_set_learn2all() argument 32 err = mv88e6xxx_g1_read(chip, MV88E6XXX_G1_ATU_CTL, &val); in mv88e6xxx_g1_atu_set_learn2all() 41 return mv88e6xxx_g1_write(chip, MV88E6XXX_G1_ATU_CTL, val); in mv88e6xxx_g1_atu_set_learn2all() 44 int mv88e6xxx_g1_atu_set_age_time(struct mv88e6xxx_chip *chip, in mv88e6xxx_g1_atu_set_age_time() argument 47 const unsigned int coeff = chip->info->age_time_coeff; in mv88e6xxx_g1_atu_set_age_time() 60 err = mv88e6xxx_g1_read(chip, MV88E6XXX_G1_ATU_CTL, &val); in mv88e6xxx_g1_atu_set_age_time() 68 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_ATU_CTL, val); in mv88e6xxx_g1_atu_set_age_time() 72 dev_dbg(chip->dev, "AgeTime set to 0x%02x (%d ms)\n", age_time, in mv88e6xxx_g1_atu_set_age_time() [all …]
|
| /linux/drivers/misc/ |
| H A D | bh1770glc.c | 179 static inline int bh1770_lux_interrupt_control(struct bh1770_chip *chip, in bh1770_lux_interrupt_control() argument 182 chip->int_mode_lux = lux; in bh1770_lux_interrupt_control() 184 return i2c_smbus_write_byte_data(chip->client, in bh1770_lux_interrupt_control() 186 (lux << 1) | chip->int_mode_prox); in bh1770_lux_interrupt_control() 189 static inline int bh1770_prox_interrupt_control(struct bh1770_chip *chip, in bh1770_prox_interrupt_control() argument 192 chip->int_mode_prox = ps; in bh1770_prox_interrupt_control() 193 return i2c_smbus_write_byte_data(chip->client, in bh1770_prox_interrupt_control() 195 (chip->int_mode_lux << 1) | (ps << 0)); in bh1770_prox_interrupt_control() 199 static int bh1770_lux_rate(struct bh1770_chip *chip, int rate_index) in bh1770_lux_rate() argument 202 if (pm_runtime_suspended(&chip->client->dev)) in bh1770_lux_rate() [all …]
|
| H A D | pch_phub.c | 139 * @chip: Pointer to the PHUB register structure 144 static void pch_phub_read_modify_write_reg(struct pch_phub_reg *chip, in pch_phub_read_modify_write_reg() 148 void __iomem *reg_addr = chip->pch_phub_base_address + reg_addr_offset; in pch_phub_read_modify_write_reg() 156 struct pch_phub_reg *chip = pci_get_drvdata(pdev); in pch_phub_save_reg_conf() 158 void __iomem *p = chip->pch_phub_base_address; in pch_phub_save_reg_conf() 160 chip->phub_id_reg = ioread32(p + PCH_PHUB_ID_REG); in pch_phub_save_reg_conf() 161 chip->q_pri_val_reg = ioread32(p + PCH_PHUB_QUEUE_PRI_VAL_REG); in pch_phub_save_reg_conf() 162 chip->rc_q_maxsize_reg = ioread32(p + PCH_PHUB_RC_QUEUE_MAXSIZE_REG); in pch_phub_save_reg_conf() 163 chip->bri_q_maxsize_reg = ioread32(p + PCH_PHUB_BRI_QUEUE_MAXSIZE_REG); in pch_phub_save_reg_conf() 164 chip in pch_phub_save_reg_conf() 143 pch_phub_read_modify_write_reg(struct pch_phub_reg * chip,unsigned int reg_addr_offset,unsigned int data,unsigned int mask) pch_phub_read_modify_write_reg() argument 155 struct pch_phub_reg *chip = pci_get_drvdata(pdev); pch_phub_save_reg_conf() local 216 struct pch_phub_reg *chip = pci_get_drvdata(pdev); pch_phub_restore_reg_conf() local 280 pch_phub_read_serial_rom(struct pch_phub_reg * chip,unsigned int offset_address,u8 * data) pch_phub_read_serial_rom() argument 295 pch_phub_write_serial_rom(struct pch_phub_reg * chip,unsigned int offset_address,u8 data) pch_phub_write_serial_rom() argument 334 pch_phub_read_serial_rom_val(struct pch_phub_reg * chip,unsigned int offset_address,u8 * data) pch_phub_read_serial_rom_val() argument 351 pch_phub_write_serial_rom_val(struct pch_phub_reg * chip,unsigned int offset_address,u8 data) pch_phub_write_serial_rom_val() argument 368 pch_phub_gbe_serial_rom_conf(struct pch_phub_reg * chip) pch_phub_gbe_serial_rom_conf() argument 408 pch_phub_gbe_serial_rom_conf_mp(struct pch_phub_reg * chip) pch_phub_gbe_serial_rom_conf_mp() argument 452 pch_phub_read_gbe_mac_addr(struct pch_phub_reg * chip,u8 * data) pch_phub_read_gbe_mac_addr() argument 464 pch_phub_write_gbe_mac_addr(struct pch_phub_reg * chip,u8 * data) pch_phub_write_gbe_mac_addr() argument 498 struct pch_phub_reg *chip = dev_get_drvdata(kobj_to_dev(kobj)); pch_phub_bin_read() local 563 struct pch_phub_reg *chip = dev_get_drvdata(kobj_to_dev(kobj)); pch_phub_bin_write() local 614 struct pch_phub_reg *chip = dev_get_drvdata(dev); show_pch_mac() local 632 struct pch_phub_reg *chip = dev_get_drvdata(dev); store_pch_mac() local 666 struct pch_phub_reg *chip; pch_phub_probe() local 831 struct pch_phub_reg *chip = pci_get_drvdata(pdev); pch_phub_remove() local [all...] |
| /linux/drivers/net/wireless/zydas/zd1211rw/ |
| H A D | zd_chip.c | 22 void zd_chip_init(struct zd_chip *chip, in zd_chip_init() argument 26 memset(chip, 0, sizeof(*chip)); in zd_chip_init() 27 mutex_init(&chip->mutex); in zd_chip_init() 28 zd_usb_init(&chip->usb, hw, intf); in zd_chip_init() 29 zd_rf_init(&chip->rf); in zd_chip_init() 32 void zd_chip_clear(struct zd_chip *chip) in zd_chip_clear() argument 34 ZD_ASSERT(!mutex_is_locked(&chip->mutex)); in zd_chip_clear() 35 zd_usb_clear(&chip->usb); in zd_chip_clear() 36 zd_rf_clear(&chip->rf); in zd_chip_clear() 37 mutex_destroy(&chip->mutex); in zd_chip_clear() [all …]
|
| /linux/drivers/video/fbdev/riva/ |
| H A D | riva_hw.c | 62 RIVA_HW_INST *chip in nv3Busy() argument 65 return ((NV_RD32(&chip->Rop->FifoFree, 0) < chip->FifoEmptyCount) || in nv3Busy() 66 NV_RD32(&chip->PGRAPH[0x000006B0/4], 0) & 0x01); in nv3Busy() 70 RIVA_HW_INST *chip in nv4Busy() argument 73 return ((NV_RD32(&chip->Rop->FifoFree, 0) < chip->FifoEmptyCount) || in nv4Busy() 74 NV_RD32(&chip->PGRAPH[0x00000700/4], 0) & 0x01); in nv4Busy() 78 RIVA_HW_INST *chip in nv10Busy() argument 81 return ((NV_RD32(&chip in nv10Busy() 87 vgaLockUnlock(RIVA_HW_INST * chip,int Lock) vgaLockUnlock() argument 100 nv3LockUnlock(RIVA_HW_INST * chip,int Lock) nv3LockUnlock() argument 110 nv4LockUnlock(RIVA_HW_INST * chip,int Lock) nv4LockUnlock() argument 121 ShowHideCursor(RIVA_HW_INST * chip,int ShowHide) ShowHideCursor() argument 613 nv3UpdateArbitrationSettings(unsigned VClk,unsigned pixelDepth,unsigned * burst,unsigned * lwm,RIVA_HW_INST * chip) nv3UpdateArbitrationSettings() argument 797 nv4UpdateArbitrationSettings(unsigned VClk,unsigned pixelDepth,unsigned * burst,unsigned * lwm,RIVA_HW_INST * chip) nv4UpdateArbitrationSettings() argument 1046 nv10UpdateArbitrationSettings(unsigned VClk,unsigned pixelDepth,unsigned * burst,unsigned * lwm,RIVA_HW_INST * chip) nv10UpdateArbitrationSettings() argument 1091 nForceUpdateArbitrationSettings(unsigned VClk,unsigned pixelDepth,unsigned * burst,unsigned * lwm,RIVA_HW_INST * chip,struct pci_dev * pdev) nForceUpdateArbitrationSettings() argument 1157 CalcVClock(int clockIn,int * clockOut,int * mOut,int * nOut,int * pOut,RIVA_HW_INST * chip) CalcVClock() argument 1217 CalcStateExt(RIVA_HW_INST * chip,RIVA_HW_STATE * state,struct pci_dev * pdev,int bpp,int width,int hDisplaySize,int height,int dotClock) CalcStateExt() argument 1343 UpdateFifoState(RIVA_HW_INST * chip) UpdateFifoState() argument 1370 LoadStateExt(RIVA_HW_INST * chip,RIVA_HW_STATE * state) LoadStateExt() argument 1705 UnloadStateExt(RIVA_HW_INST * chip,RIVA_HW_STATE * state) UnloadStateExt() argument 1794 SetStartAddress(RIVA_HW_INST * chip,unsigned start) SetStartAddress() argument 1803 SetStartAddress3(RIVA_HW_INST * chip,unsigned start) SetStartAddress3() argument 1835 nv3SetSurfaces2D(RIVA_HW_INST * chip,unsigned surf0,unsigned surf1) nv3SetSurfaces2D() argument 1852 nv4SetSurfaces2D(RIVA_HW_INST * chip,unsigned surf0,unsigned surf1) nv4SetSurfaces2D() argument 1868 nv10SetSurfaces2D(RIVA_HW_INST * chip,unsigned surf0,unsigned surf1) nv10SetSurfaces2D() argument 1884 nv3SetSurfaces3D(RIVA_HW_INST * chip,unsigned surf0,unsigned surf1) nv3SetSurfaces3D() argument 1901 nv4SetSurfaces3D(RIVA_HW_INST * chip,unsigned surf0,unsigned surf1) nv4SetSurfaces3D() argument 1917 nv10SetSurfaces3D(RIVA_HW_INST * chip,unsigned surf0,unsigned surf1) nv10SetSurfaces3D() argument 1940 nv3GetConfig(RIVA_HW_INST * chip) nv3GetConfig() argument 2011 nv4GetConfig(RIVA_HW_INST * chip) nv4GetConfig() argument 2068 nv10GetConfig(RIVA_HW_INST * chip,struct pci_dev * pdev,unsigned int chipset) nv10GetConfig() argument 2192 RivaGetConfig(RIVA_HW_INST * chip,struct pci_dev * pdev,unsigned int chipset) RivaGetConfig() argument [all...] |
| /linux/sound/drivers/pcsp/ |
| H A D | pcsp_lib.c | 45 static u64 pcsp_timer_update(struct snd_pcsp *chip) in pcsp_timer_update() argument 53 if (chip->thalf) { in pcsp_timer_update() 54 outb(chip->val61, 0x61); in pcsp_timer_update() 55 chip->thalf = 0; in pcsp_timer_update() 56 return chip->ns_rem; in pcsp_timer_update() 59 substream = chip->playback_substream; in pcsp_timer_update() 65 val = runtime->dma_area[chip->playback_ptr + chip->fmt_size - 1]; in pcsp_timer_update() 66 if (chip->is_signed) in pcsp_timer_update() 70 if (timer_cnt && chip->enable) { in pcsp_timer_update() 73 outb_p(chip->val61, 0x61); in pcsp_timer_update() [all …]
|
| /linux/drivers/thermal/qcom/ |
| H A D | qcom-spmi-temp-alarm.c | 128 int (*sync_thresholds)(struct qpnp_tm_chip *chip); 129 int (*get_temp_stage)(struct qpnp_tm_chip *chip); 130 int (*configure_trip_temps)(struct qpnp_tm_chip *chip); 155 static int qpnp_tm_read(struct qpnp_tm_chip *chip, u16 addr, u8 *data) in qpnp_tm_read() argument 160 ret = regmap_read(chip->map, chip->base + addr, &val); in qpnp_tm_read() 168 static int qpnp_tm_write(struct qpnp_tm_chip *chip, u16 addr, u8 data) in qpnp_tm_write() argument 170 return regmap_write(chip->map, chip->base + addr, data); in qpnp_tm_write() 181 static long qpnp_tm_decode_temp(struct qpnp_tm_chip *chip, unsigned int stage) in qpnp_tm_decode_temp() argument 186 return chip->temp_thresh_map[stage - 1]; in qpnp_tm_decode_temp() 195 static int qpnp_tm_gen1_get_temp_stage(struct qpnp_tm_chip *chip) in qpnp_tm_gen1_get_temp_stage() argument [all …]
|
| /linux/sound/soc/amd/acp/ |
| H A D | acp-pci.c | 31 struct acp_chip_info *chip = data; in irq_handler() local 33 if (chip && chip->acp_hw_ops && chip->acp_hw_ops->irq) in irq_handler() 34 return chip->acp_hw_ops->irq(irq, chip); in irq_handler() 57 static int create_acp_platform_devs(struct pci_dev *pci, struct acp_chip_info *chip, u32 addr) in create_acp_platform_devs() argument 65 if (chip->is_i2s_config || chip->is_pdm_dev) { in create_acp_platform_devs() 66 chip->res = devm_kzalloc(&pci->dev, sizeof(struct resource), GFP_KERNEL); in create_acp_platform_devs() 67 if (!chip->res) { in create_acp_platform_devs() 71 chip->res->flags = IORESOURCE_MEM; in create_acp_platform_devs() 72 chip->res->start = addr; in create_acp_platform_devs() 73 chip->res->end = addr + (ACP3x_REG_END - ACP3x_REG_START); in create_acp_platform_devs() [all …]
|
| /linux/drivers/gpio/ |
| H A D | gpio-pca953x.c | 193 #define NBANK(chip) DIV_ROUND_UP(chip->gpio_chip.ngpio, BANK_SZ) 246 u8 (*recalc_addr)(struct pca953x_chip *chip, int reg, int off); 247 bool (*check_reg)(struct pca953x_chip *chip, unsigned int reg, 251 static int pca953x_bank_shift(struct pca953x_chip *chip) in pca953x_bank_shift() 253 return fls((chip->gpio_chip.ngpio - 1) / BANK_SZ); 257 * Helper function to get the correct bit mask for a given offset and chip type. 261 static inline u8 pca953x_get_bit_mask(struct pca953x_chip *chip, unsigned int offset) in pca953x_get_bit_mask() 266 if (PCA_CHIP_TYPE(chip->driver_data) == TCA6418_TYPE && offset <= msb) in pca953x_get_bit_mask() 304 * - Extended set, above 0x40, often chip specifi 190 NBANK(chip) global() argument 248 pca953x_bank_shift(struct pca953x_chip * chip) pca953x_bank_shift() argument 258 pca953x_get_bit_mask(struct pca953x_chip * chip,unsigned int offset) pca953x_get_bit_mask() argument 314 pca953x_check_register(struct pca953x_chip * chip,unsigned int reg,u32 checkbank) pca953x_check_register() argument 346 pcal6534_check_register(struct pca953x_chip * chip,unsigned int reg,u32 checkbank) pcal6534_check_register() argument 386 tca6418_check_register(struct pca953x_chip * chip,unsigned int reg,u32 access_type_mask) tca6418_check_register() argument 406 struct pca953x_chip *chip = dev_get_drvdata(dev); pca953x_readable_register() local 435 struct pca953x_chip *chip = dev_get_drvdata(dev); pca953x_writeable_register() local 461 struct pca953x_chip *chip = dev_get_drvdata(dev); pca953x_volatile_register() local 514 pca953x_recalc_addr(struct pca953x_chip * chip,int reg,int off) pca953x_recalc_addr() argument 528 pcal6534_recalc_addr(struct pca953x_chip * chip,int reg,int off) pcal6534_recalc_addr() argument 559 tca6418_recalc_addr(struct pca953x_chip * chip,int reg_base,int offset) tca6418_recalc_addr() argument 569 pca953x_write_regs(struct pca953x_chip * chip,int reg,unsigned long * val) pca953x_write_regs() argument 587 pca953x_read_regs(struct pca953x_chip * chip,int reg,unsigned long * val) pca953x_read_regs() argument 607 struct pca953x_chip *chip = gpiochip_get_data(gc); pca953x_gpio_direction_input() local 622 struct pca953x_chip *chip = gpiochip_get_data(gc); pca953x_gpio_direction_output() local 647 struct pca953x_chip *chip = gpiochip_get_data(gc); pca953x_gpio_get_value() local 664 struct pca953x_chip *chip = gpiochip_get_data(gc); pca953x_gpio_set_value() local 675 struct pca953x_chip *chip = gpiochip_get_data(gc); pca953x_gpio_get_direction() local 702 struct pca953x_chip *chip = gpiochip_get_data(gc); pca953x_gpio_get_multiple() local 718 struct pca953x_chip *chip = gpiochip_get_data(gc); pca953x_gpio_set_multiple() local 733 pca953x_gpio_set_pull_up_down(struct pca953x_chip * chip,unsigned int offset,unsigned long config) pca953x_gpio_set_pull_up_down() argument 772 struct pca953x_chip *chip = gpiochip_get_data(gc); pca953x_gpio_set_config() local 785 pca953x_setup_gpio(struct pca953x_chip * chip,int gpios) pca953x_setup_gpio() argument 810 struct pca953x_chip *chip = gpiochip_get_data(gc); pca953x_irq_mask() local 820 struct pca953x_chip *chip = gpiochip_get_data(gc); pca953x_irq_unmask() local 830 struct pca953x_chip *chip = gpiochip_get_data(gc); pca953x_irq_set_wake() local 843 struct pca953x_chip *chip = gpiochip_get_data(gc); pca953x_irq_bus_lock() local 851 struct pca953x_chip *chip = gpiochip_get_data(gc); pca953x_irq_bus_sync_unlock() local 890 struct pca953x_chip *chip = gpiochip_get_data(gc); pca953x_irq_set_type() local 910 struct pca953x_chip *chip = gpiochip_get_data(gc); pca953x_irq_shutdown() local 941 pca953x_irq_pending(struct pca953x_chip * chip,unsigned long * pending) pca953x_irq_pending() argument 1016 struct pca953x_chip *chip = devid; pca953x_irq_handler() local 1045 pca953x_irq_setup(struct pca953x_chip * chip,int irq_base) pca953x_irq_setup() argument 1104 pca953x_irq_setup(struct pca953x_chip * chip,int irq_base) pca953x_irq_setup() argument 1116 device_pca95xx_init(struct pca953x_chip * chip) device_pca95xx_init() argument 1140 device_pca957x_init(struct pca953x_chip * chip) device_pca957x_init() argument 1162 pca953x_get_and_enable_regulator(struct pca953x_chip * chip) pca953x_get_and_enable_regulator() argument 1188 struct pca953x_chip *chip; pca953x_probe() local 1312 pca953x_regcache_sync(struct pca953x_chip * chip) pca953x_regcache_sync() argument 1361 pca953x_restore_context(struct pca953x_chip * chip) pca953x_restore_context() argument 1378 pca953x_save_context(struct pca953x_chip * chip) pca953x_save_context() argument 1390 struct pca953x_chip *chip = dev_get_drvdata(dev); pca953x_suspend() local 1404 struct pca953x_chip *chip = dev_get_drvdata(dev); pca953x_resume() local [all...] |