Home
last modified time | relevance | path

Searched refs:master (Results 1 – 25 of 385) sorted by relevance

12345678910>>...16

/drivers/fsi/
Dfsi-master-gpio.c54 struct fsi_master master; member
67 #define to_fsi_master_gpio(m) container_of(m, struct fsi_master_gpio, master)
74 static void clock_toggle(struct fsi_master_gpio *master, int count) in clock_toggle() argument
80 gpiod_set_value(master->gpio_clk, 0); in clock_toggle()
82 gpiod_set_value(master->gpio_clk, 1); in clock_toggle()
86 static int sda_in(struct fsi_master_gpio *master) in sda_in() argument
91 in = gpiod_get_value(master->gpio_data); in sda_in()
95 static void sda_out(struct fsi_master_gpio *master, int value) in sda_out() argument
97 gpiod_set_value(master->gpio_data, value); in sda_out()
100 static void set_sda_input(struct fsi_master_gpio *master) in set_sda_input() argument
[all …]
Dfsi-core.c79 struct fsi_master *master; member
91 static int fsi_master_read(struct fsi_master *master, int link,
93 static int fsi_master_write(struct fsi_master *master, int link,
95 static int fsi_master_break(struct fsi_master *master, int link);
190 struct fsi_master *master = slave->master; in fsi_slave_report_and_clear_errors() local
198 rc = fsi_master_read(master, link, id, FSI_SLAVE_BASE + FSI_SISC, in fsi_slave_report_and_clear_errors()
203 rc = fsi_master_read(master, link, id, FSI_SLAVE_BASE + FSI_SSTAT, in fsi_slave_report_and_clear_errors()
212 return fsi_master_write(master, link, id, FSI_SLAVE_BASE + FSI_SISC, in fsi_slave_report_and_clear_errors()
216 static int fsi_slave_set_smode(struct fsi_master *master, int link, int id);
221 struct fsi_master *master = slave->master; in fsi_slave_handle_error() local
[all …]
/drivers/base/
Dcomponent.c37 struct master { struct
48 struct master *master; argument
59 static struct master *__master_find(struct device *dev, in __master_find()
62 struct master *m; in __master_find()
71 static struct component *find_component(struct master *master, in find_component() argument
77 if (c->master && c->master != master) in find_component()
87 static int find_components(struct master *master) in find_components() argument
89 struct component_match *match = master->match; in find_components()
101 dev_dbg(master->dev, "Looking for component %zu\n", i); in find_components()
106 c = find_component(master, mc->compare, mc->data); in find_components()
[all …]
/drivers/gpu/drm/
Ddrm_auth.c64 ret = idr_alloc(&file_priv->master->magic_map, file_priv, in drm_getmagic()
86 file = idr_find(&file_priv->master->magic_map, auth->magic); in drm_authmagic()
89 idr_replace(&file_priv->master->magic_map, NULL, auth->magic); in drm_authmagic()
98 struct drm_master *master; in drm_master_create() local
100 master = kzalloc(sizeof(*master), GFP_KERNEL); in drm_master_create()
101 if (!master) in drm_master_create()
104 kref_init(&master->refcount); in drm_master_create()
105 spin_lock_init(&master->lock.spinlock); in drm_master_create()
106 init_waitqueue_head(&master->lock.lock_queue); in drm_master_create()
107 idr_init(&master->magic_map); in drm_master_create()
[all …]
Ddrm_lock.c165 struct drm_master *master = file_priv->master; in drm_legacy_lock() local
181 master->lock.hw_lock ? master->lock.hw_lock->lock : -1, in drm_legacy_lock()
184 add_wait_queue(&master->lock.lock_queue, &entry); in drm_legacy_lock()
185 spin_lock_bh(&master->lock.spinlock); in drm_legacy_lock()
186 master->lock.user_waiters++; in drm_legacy_lock()
187 spin_unlock_bh(&master->lock.spinlock); in drm_legacy_lock()
191 if (!master->lock.hw_lock) { in drm_legacy_lock()
197 if (drm_lock_take(&master->lock, lock->context)) { in drm_legacy_lock()
198 master->lock.file_priv = file_priv; in drm_legacy_lock()
199 master->lock.lock_time = jiffies; in drm_legacy_lock()
[all …]
/drivers/spi/
Dspi-bcm2835.c129 static void bcm2835_spi_reset_hw(struct spi_master *master) in bcm2835_spi_reset_hw() argument
131 struct bcm2835_spi *bs = spi_master_get_devdata(master); in bcm2835_spi_reset_hw()
150 struct spi_master *master = dev_id; in bcm2835_spi_interrupt() local
151 struct bcm2835_spi *bs = spi_master_get_devdata(master); in bcm2835_spi_interrupt()
160 bcm2835_spi_reset_hw(master); in bcm2835_spi_interrupt()
162 complete(&master->xfer_completion); in bcm2835_spi_interrupt()
168 static int bcm2835_spi_transfer_one_irq(struct spi_master *master, in bcm2835_spi_transfer_one_irq() argument
173 struct bcm2835_spi *bs = spi_master_get_devdata(master); in bcm2835_spi_transfer_one_irq()
224 struct spi_master *master = data; in bcm2835_spi_dma_done() local
225 struct bcm2835_spi *bs = spi_master_get_devdata(master); in bcm2835_spi_dma_done()
[all …]
Dspi-ep93xx.c115 static int ep93xx_spi_calc_divisors(struct spi_master *master, in ep93xx_spi_calc_divisors() argument
118 struct ep93xx_spi *espi = spi_master_get_devdata(master); in ep93xx_spi_calc_divisors()
126 rate = clamp(rate, master->min_speed_hz, master->max_speed_hz); in ep93xx_spi_calc_divisors()
149 static int ep93xx_spi_chip_setup(struct spi_master *master, in ep93xx_spi_chip_setup() argument
153 struct ep93xx_spi *espi = spi_master_get_devdata(master); in ep93xx_spi_chip_setup()
160 err = ep93xx_spi_calc_divisors(master, xfer->speed_hz, in ep93xx_spi_chip_setup()
169 dev_dbg(&master->dev, "setup: mode %d, cpsr %d, scr %d, dss %d\n", in ep93xx_spi_chip_setup()
171 dev_dbg(&master->dev, "setup: cr0 %#x\n", cr0); in ep93xx_spi_chip_setup()
179 static void ep93xx_do_write(struct spi_master *master) in ep93xx_do_write() argument
181 struct ep93xx_spi *espi = spi_master_get_devdata(master); in ep93xx_do_write()
[all …]
Dspi-omap-100k.c90 static void spi100k_enable_clock(struct spi_master *master) in spi100k_enable_clock() argument
93 struct omap1_spi100k *spi100k = spi_master_get_devdata(master); in spi100k_enable_clock()
101 static void spi100k_disable_clock(struct spi_master *master) in spi100k_disable_clock() argument
104 struct omap1_spi100k *spi100k = spi_master_get_devdata(master); in spi100k_disable_clock()
112 static void spi100k_write_data(struct spi_master *master, int len, int data) in spi100k_write_data() argument
114 struct omap1_spi100k *spi100k = spi_master_get_devdata(master); in spi100k_write_data()
122 spi100k_enable_clock(master); in spi100k_write_data()
135 spi100k_disable_clock(master); in spi100k_write_data()
138 static int spi100k_read_data(struct spi_master *master, int len) in spi100k_read_data() argument
141 struct omap1_spi100k *spi100k = spi_master_get_devdata(master); in spi100k_read_data()
[all …]
Dspi-mt65xx.c171 static int mtk_spi_prepare_message(struct spi_master *master, in mtk_spi_prepare_message() argument
178 struct mtk_spi *mdata = spi_master_get_devdata(master); in mtk_spi_prepare_message()
245 struct mtk_spi *mdata = spi_master_get_devdata(spi->master); in mtk_spi_set_cs()
259 static void mtk_spi_prepare_transfer(struct spi_master *master, in mtk_spi_prepare_transfer() argument
263 struct mtk_spi *mdata = spi_master_get_devdata(master); in mtk_spi_prepare_transfer()
300 static void mtk_spi_setup_packet(struct spi_master *master) in mtk_spi_setup_packet() argument
303 struct mtk_spi *mdata = spi_master_get_devdata(master); in mtk_spi_setup_packet()
315 static void mtk_spi_enable_transfer(struct spi_master *master) in mtk_spi_enable_transfer() argument
318 struct mtk_spi *mdata = spi_master_get_devdata(master); in mtk_spi_enable_transfer()
340 static void mtk_spi_update_mdata_len(struct spi_master *master) in mtk_spi_update_mdata_len() argument
[all …]
Dspi-pic32.c111 struct spi_master *master; member
235 dev_err(&pic32s->master->dev, "%s\n", msg); in pic32_err_stop()
236 if (pic32s->master->cur_msg) in pic32_err_stop()
237 pic32s->master->cur_msg->status = -EIO; in pic32_err_stop()
261 if (!pic32s->master->cur_msg) { in pic32_spi_fault_irq()
311 struct spi_master *master = pic32s->master; in pic32_spi_dma_transfer() local
317 if (!master->dma_rx || !master->dma_tx) in pic32_spi_dma_transfer()
320 desc_rx = dmaengine_prep_slave_sg(master->dma_rx, in pic32_spi_dma_transfer()
330 desc_tx = dmaengine_prep_slave_sg(master->dma_tx, in pic32_spi_dma_transfer()
354 dma_async_issue_pending(master->dma_rx); in pic32_spi_dma_transfer()
[all …]
Dspi-atmel.c384 for (i = 0; i < spi->master->num_chipselect; i++) { in cs_activate()
444 static bool atmel_spi_can_dma(struct spi_master *master, in atmel_spi_can_dma() argument
448 struct atmel_spi *as = spi_master_get_devdata(master); in atmel_spi_can_dma()
457 struct spi_master *master = platform_get_drvdata(as->pdev); in atmel_spi_dma_slave_config() local
489 if (dmaengine_slave_config(master->dma_tx, slave_config)) { in atmel_spi_dma_slave_config()
504 if (dmaengine_slave_config(master->dma_rx, slave_config)) { in atmel_spi_dma_slave_config()
513 static int atmel_spi_configure_dma(struct spi_master *master, in atmel_spi_configure_dma() argument
524 master->dma_tx = dma_request_slave_channel_reason(dev, "tx"); in atmel_spi_configure_dma()
525 if (IS_ERR(master->dma_tx)) { in atmel_spi_configure_dma()
526 err = PTR_ERR(master->dma_tx); in atmel_spi_configure_dma()
[all …]
Dspi-cadence.c183 struct cdns_spi *xspi = spi_master_get_devdata(spi->master); in cdns_spi_chipselect()
214 struct cdns_spi *xspi = spi_master_get_devdata(spi->master); in cdns_spi_config_clock_mode()
257 struct cdns_spi *xspi = spi_master_get_devdata(spi->master); in cdns_spi_config_clock_freq()
295 struct cdns_spi *xspi = spi_master_get_devdata(spi->master); in cdns_spi_setup_transfer()
350 struct spi_master *master = dev_id; in cdns_spi_irq() local
351 struct cdns_spi *xspi = spi_master_get_devdata(master); in cdns_spi_irq()
364 spi_finalize_current_transfer(master); in cdns_spi_irq()
390 spi_finalize_current_transfer(master); in cdns_spi_irq()
398 static int cdns_prepare_message(struct spi_master *master, in cdns_prepare_message() argument
417 static int cdns_transfer_one(struct spi_master *master, in cdns_transfer_one() argument
[all …]
Dspi-pxa2xx-dma.c26 struct spi_message *msg = drv_data->master->cur_msg; in pxa2xx_spi_dma_transfer_complete()
80 spi_get_ctldata(drv_data->master->cur_msg->spi); in pxa2xx_spi_dma_prepare_one()
109 chan = drv_data->master->dma_tx; in pxa2xx_spi_dma_prepare_one()
116 chan = drv_data->master->dma_rx; in pxa2xx_spi_dma_prepare_one()
137 dmaengine_terminate_async(drv_data->master->dma_rx); in pxa2xx_spi_dma_transfer()
138 dmaengine_terminate_async(drv_data->master->dma_tx); in pxa2xx_spi_dma_transfer()
177 dmaengine_terminate_async(drv_data->master->dma_tx); in pxa2xx_spi_dma_prepare()
184 dma_async_issue_pending(drv_data->master->dma_rx); in pxa2xx_spi_dma_start()
185 dma_async_issue_pending(drv_data->master->dma_tx); in pxa2xx_spi_dma_start()
194 struct spi_master *master = drv_data->master; in pxa2xx_spi_dma_setup() local
[all …]
Dspi-bcm2835aux.c201 struct spi_master *master = dev_id; in bcm2835aux_spi_interrupt() local
202 struct bcm2835aux_spi *bs = spi_master_get_devdata(master); in bcm2835aux_spi_interrupt()
221 complete(&master->xfer_completion); in bcm2835aux_spi_interrupt()
227 static int __bcm2835aux_spi_transfer_one_irq(struct spi_master *master, in __bcm2835aux_spi_transfer_one_irq() argument
231 struct bcm2835aux_spi *bs = spi_master_get_devdata(master); in __bcm2835aux_spi_transfer_one_irq()
242 static int bcm2835aux_spi_transfer_one_irq(struct spi_master *master, in bcm2835aux_spi_transfer_one_irq() argument
246 struct bcm2835aux_spi *bs = spi_master_get_devdata(master); in bcm2835aux_spi_transfer_one_irq()
261 return __bcm2835aux_spi_transfer_one_irq(master, spi, tfr); in bcm2835aux_spi_transfer_one_irq()
264 static int bcm2835aux_spi_transfer_one_poll(struct spi_master *master, in bcm2835aux_spi_transfer_one_poll() argument
268 struct bcm2835aux_spi *bs = spi_master_get_devdata(master); in bcm2835aux_spi_transfer_one_poll()
[all …]
Dspi-clps711x.c44 ret = devm_gpio_request(&spi->master->dev, spi->cs_gpio, in spi_clps711x_setup()
45 dev_name(&spi->master->dev)); in spi_clps711x_setup()
58 static int spi_clps711x_prepare_message(struct spi_master *master, in spi_clps711x_prepare_message() argument
61 struct spi_clps711x_data *hw = spi_master_get_devdata(master); in spi_clps711x_prepare_message()
70 static int spi_clps711x_transfer_one(struct spi_master *master, in spi_clps711x_transfer_one() argument
74 struct spi_clps711x_data *hw = spi_master_get_devdata(master); in spi_clps711x_transfer_one()
93 struct spi_master *master = dev_id; in spi_clps711x_isr() local
94 struct spi_clps711x_data *hw = spi_master_get_devdata(master); in spi_clps711x_isr()
108 spi_finalize_current_transfer(master); in spi_clps711x_isr()
116 struct spi_master *master; in spi_clps711x_probe() local
[all …]
Dspi-img-spfi.c93 struct spi_master *master; member
232 static int img_spfi_start_pio(struct spi_master *master, in img_spfi_start_pio() argument
236 struct img_spfi *spfi = spi_master_get_devdata(spi->master); in img_spfi_start_pio()
296 spi_finalize_current_transfer(spfi->master); in img_spfi_dma_rx_cb()
310 spi_finalize_current_transfer(spfi->master); in img_spfi_dma_tx_cb()
314 static int img_spfi_start_dma(struct spi_master *master, in img_spfi_start_dma() argument
318 struct img_spfi *spfi = spi_master_get_devdata(spi->master); in img_spfi_start_dma()
395 static void img_spfi_handle_err(struct spi_master *master, in img_spfi_handle_err() argument
398 struct img_spfi *spfi = spi_master_get_devdata(master); in img_spfi_handle_err()
416 static int img_spfi_prepare(struct spi_master *master, struct spi_message *msg) in img_spfi_prepare() argument
[all …]
Dspi-qup.c388 static int spi_qup_prep_sg(struct spi_master *master, struct scatterlist *sgl, in spi_qup_prep_sg() argument
392 struct spi_qup *qup = spi_master_get_devdata(master); in spi_qup_prep_sg()
399 chan = master->dma_tx; in spi_qup_prep_sg()
401 chan = master->dma_rx; in spi_qup_prep_sg()
415 static void spi_qup_dma_terminate(struct spi_master *master, in spi_qup_dma_terminate() argument
419 dmaengine_terminate_all(master->dma_tx); in spi_qup_dma_terminate()
421 dmaengine_terminate_all(master->dma_rx); in spi_qup_dma_terminate()
448 struct spi_master *master = spi->master; in spi_qup_do_dma() local
449 struct spi_qup *qup = spi_master_get_devdata(master); in spi_qup_do_dma()
484 ret = spi_qup_prep_sg(master, rx_sgl, rx_nents, in spi_qup_do_dma()
[all …]
Dspi-jcore.c35 struct spi_master *master; member
61 dev_err(hw->master->dev.parent, in jcore_spi_program()
69 struct jcore_spi *hw = spi_master_get_devdata(spi->master); in jcore_spi_chipsel()
72 dev_dbg(hw->master->dev.parent, "chipselect %d\n", spi->chip_select); in jcore_spi_chipsel()
91 dev_dbg(hw->master->dev.parent, "speed=%d reg=0x%x\n", in jcore_spi_baudrate()
95 static int jcore_spi_txrx(struct spi_master *master, struct spi_device *spi, in jcore_spi_txrx() argument
98 struct jcore_spi *hw = spi_master_get_devdata(master); in jcore_spi_txrx()
131 spi_finalize_current_transfer(master); in jcore_spi_txrx()
143 struct spi_master *master; in jcore_spi_probe() local
149 master = spi_alloc_master(&pdev->dev, sizeof(struct jcore_spi)); in jcore_spi_probe()
[all …]
Dspi-cavium-octeon.c23 struct spi_master *master; in octeon_spi_probe() local
27 master = spi_alloc_master(&pdev->dev, sizeof(struct octeon_spi)); in octeon_spi_probe()
28 if (!master) in octeon_spi_probe()
30 p = spi_master_get_devdata(master); in octeon_spi_probe()
31 platform_set_drvdata(pdev, master); in octeon_spi_probe()
48 master->num_chipselect = 4; in octeon_spi_probe()
49 master->mode_bits = SPI_CPHA | in octeon_spi_probe()
55 master->transfer_one_message = octeon_spi_transfer_one_message; in octeon_spi_probe()
56 master->bits_per_word_mask = SPI_BPW_MASK(8); in octeon_spi_probe()
57 master->max_speed_hz = OCTEON_SPI_MAX_CLOCK_HZ; in octeon_spi_probe()
[all …]
Dspi-dw.c60 "%s registers:\n", dev_name(&dws->master->dev)); in dw_spi_show_regs()
112 snprintf(name, 32, "dw_spi%d", dws->master->bus_num); in dw_spi_debugfs_init()
140 struct dw_spi *dws = spi_master_get_devdata(spi->master); in dw_spi_set_cs()
227 dev_err(&dws->master->dev, "%s\n", msg); in int_error_stop()
228 dws->master->cur_msg->status = -EIO; in int_error_stop()
229 spi_finalize_current_transfer(dws->master); in int_error_stop()
246 spi_finalize_current_transfer(dws->master); in interrupt_transfer()
261 struct spi_master *master = dev_id; in dw_spi_irq() local
262 struct dw_spi *dws = spi_master_get_devdata(master); in dw_spi_irq()
268 if (!master->cur_msg) { in dw_spi_irq()
[all …]
Dspi-meson-spifc.c82 struct spi_master *master; member
251 static int meson_spifc_transfer_one(struct spi_master *master, in meson_spifc_transfer_one() argument
255 struct meson_spifc *spifc = spi_master_get_devdata(master); in meson_spifc_transfer_one()
265 spi_transfer_is_last(master, xfer), in meson_spifc_transfer_one()
293 struct spi_master *master; in meson_spifc_probe() local
300 master = spi_alloc_master(&pdev->dev, sizeof(struct meson_spifc)); in meson_spifc_probe()
301 if (!master) in meson_spifc_probe()
304 platform_set_drvdata(pdev, master); in meson_spifc_probe()
306 spifc = spi_master_get_devdata(master); in meson_spifc_probe()
338 master->num_chipselect = 1; in meson_spifc_probe()
[all …]
/drivers/base/regmap/
Dregmap-w1.c34 mutex_lock(&sl->master->bus_mutex); in w1_reg_a8_v8_read()
36 w1_write_8(sl->master, W1_CMD_READ_DATA); in w1_reg_a8_v8_read()
37 w1_write_8(sl->master, reg); in w1_reg_a8_v8_read()
38 *val = w1_read_8(sl->master); in w1_reg_a8_v8_read()
42 mutex_unlock(&sl->master->bus_mutex); in w1_reg_a8_v8_read()
56 mutex_lock(&sl->master->bus_mutex); in w1_reg_a8_v8_write()
58 w1_write_8(sl->master, W1_CMD_WRITE_DATA); in w1_reg_a8_v8_write()
59 w1_write_8(sl->master, reg); in w1_reg_a8_v8_write()
60 w1_write_8(sl->master, val); in w1_reg_a8_v8_write()
64 mutex_unlock(&sl->master->bus_mutex); in w1_reg_a8_v8_write()
[all …]
/drivers/w1/slaves/
Dw1_ds2408.c50 mutex_lock(&sl->master->bus_mutex); in _read_reg()
54 mutex_unlock(&sl->master->bus_mutex); in _read_reg()
61 w1_write_block(sl->master, wrbuf, 3); in _read_reg()
62 *buf = w1_read_8(sl->master); in _read_reg()
64 mutex_unlock(&sl->master->bus_mutex); in _read_reg()
154 mutex_lock(&sl->master->bus_mutex); in output_write()
164 w1_write_block(sl->master, w1_buf, 3); in output_write()
166 readBack = w1_read_8(sl->master); in output_write()
169 if (w1_reset_resume_command(sl->master)) in output_write()
181 if (w1_reset_resume_command(sl->master)) in output_write()
[all …]
/drivers/clk/at91/
Dclk-master.c58 struct clk_master *master = to_clk_master(hw); in clk_master_prepare() local
60 while (!clk_master_ready(master->regmap)) in clk_master_prepare()
68 struct clk_master *master = to_clk_master(hw); in clk_master_is_prepared() local
70 return clk_master_ready(master->regmap); in clk_master_is_prepared()
79 struct clk_master *master = to_clk_master(hw); in clk_master_recalc_rate() local
80 const struct clk_master_layout *layout = master->layout; in clk_master_recalc_rate()
82 master->characteristics; in clk_master_recalc_rate()
85 regmap_read(master->regmap, AT91_PMC_MCKR, &mckr); in clk_master_recalc_rate()
108 struct clk_master *master = to_clk_master(hw); in clk_master_get_parent() local
111 regmap_read(master->regmap, AT91_PMC_MCKR, &mckr); in clk_master_get_parent()
[all …]
/drivers/mtd/
Dar7part.c45 static int create_mtd_partitions(struct mtd_info *master, in create_mtd_partitions() argument
52 unsigned int pre_size = master->erasesize, post_size = 0; in create_mtd_partitions()
63 ar7_parts[0].size = master->erasesize; in create_mtd_partitions()
68 ar7_parts[1].size = master->erasesize; in create_mtd_partitions()
73 mtd_read(master, offset, sizeof(header), &len, in create_mtd_partitions()
81 pre_size += master->erasesize; in create_mtd_partitions()
87 ar7_parts[1].offset = master->size - master->erasesize; in create_mtd_partitions()
88 post_size = master->erasesize; in create_mtd_partitions()
95 mtd_read(master, offset, sizeof(header), &len, in create_mtd_partitions()
103 mtd_read(master, offset, sizeof(header), &len, in create_mtd_partitions()
[all …]

12345678910>>...16