Symbol: attach
drivers/accel/amdxdna/aie2_ctx.c
786
bool attach)
drivers/accel/amdxdna/aie2_ctx.c
801
if (attach) {
drivers/accel/amdxdna/aie2_ctx.c
828
if (attach)
drivers/accel/amdxdna/amdxdna_gem.c
383
.attach = drm_gem_map_attach,
drivers/accel/amdxdna/amdxdna_gem.c
443
dma_buf_unmap_attachment_unlocked(abo->attach, abo->base.sgt, DMA_BIDIRECTIONAL);
drivers/accel/amdxdna/amdxdna_gem.c
444
dma_buf_detach(abo->dma_buf, abo->attach);
drivers/accel/amdxdna/amdxdna_gem.c
595
struct dma_buf_attachment *attach;
drivers/accel/amdxdna/amdxdna_gem.c
603
attach = dma_buf_attach(dma_buf, dev->dev);
drivers/accel/amdxdna/amdxdna_gem.c
604
if (IS_ERR(attach)) {
drivers/accel/amdxdna/amdxdna_gem.c
605
ret = PTR_ERR(attach);
drivers/accel/amdxdna/amdxdna_gem.c
609
sgt = dma_buf_map_attachment_unlocked(attach, DMA_BIDIRECTIONAL);
drivers/accel/amdxdna/amdxdna_gem.c
615
gobj = drm_gem_shmem_prime_import_sg_table(dev, attach, sgt);
drivers/accel/amdxdna/amdxdna_gem.c
622
abo->attach = attach;
drivers/accel/amdxdna/amdxdna_gem.c
628
dma_buf_unmap_attachment_unlocked(attach, sgt, DMA_BIDIRECTIONAL);
drivers/accel/amdxdna/amdxdna_gem.c
630
dma_buf_detach(dma_buf, attach);
drivers/accel/amdxdna/amdxdna_gem.h
48
struct dma_buf_attachment *attach;
drivers/accel/amdxdna/amdxdna_gem.h
52
#define is_import_bo(obj) ((obj)->attach)
drivers/accel/amdxdna/amdxdna_ubuf.c
24
static struct sg_table *amdxdna_ubuf_map(struct dma_buf_attachment *attach,
drivers/accel/amdxdna/amdxdna_ubuf.c
27
struct amdxdna_ubuf_priv *ubuf = attach->dmabuf->priv;
drivers/accel/amdxdna/amdxdna_ubuf.c
41
ret = dma_map_sgtable(attach->dev, sg, direction, 0);
drivers/accel/amdxdna/amdxdna_ubuf.c
55
static void amdxdna_ubuf_unmap(struct dma_buf_attachment *attach,
drivers/accel/amdxdna/amdxdna_ubuf.c
59
struct amdxdna_ubuf_priv *ubuf = attach->dmabuf->priv;
drivers/accel/amdxdna/amdxdna_ubuf.c
62
dma_unmap_sgtable(attach->dev, sg, direction, 0);
drivers/accel/habanalabs/common/memory.c
1852
.attach = hl_dmabuf_attach,
drivers/accel/ivpu/ivpu_gem.c
215
struct dma_buf_attachment *attach;
drivers/accel/ivpu/ivpu_gem.c
220
attach = dma_buf_attach(dma_buf, attach_dev);
drivers/accel/ivpu/ivpu_gem.c
221
if (IS_ERR(attach))
drivers/accel/ivpu/ivpu_gem.c
222
return ERR_CAST(attach);
drivers/accel/ivpu/ivpu_gem.c
226
obj = drm_gem_shmem_prime_import_sg_table(dev, attach, NULL);
drivers/accel/ivpu/ivpu_gem.c
232
obj->import_attach = attach;
drivers/accel/ivpu/ivpu_gem.c
246
dma_buf_detach(dma_buf, attach);
drivers/accel/qaic/qaic_data.c
820
struct dma_buf_attachment *attach;
drivers/accel/qaic/qaic_data.c
834
attach = dma_buf_attach(dma_buf, dev->dev);
drivers/accel/qaic/qaic_data.c
835
if (IS_ERR(attach)) {
drivers/accel/qaic/qaic_data.c
836
ret = PTR_ERR(attach);
drivers/accel/qaic/qaic_data.c
840
if (!attach->dmabuf->size) {
drivers/accel/qaic/qaic_data.c
845
drm_gem_private_object_init(dev, obj, attach->dmabuf->size);
drivers/accel/qaic/qaic_data.c
853
obj->import_attach = attach;
drivers/accel/qaic/qaic_data.c
859
dma_buf_detach(dma_buf, attach);
drivers/acpi/acpi_apd.c
261
.attach = acpi_apd_create_device,
drivers/acpi/acpi_memhotplug.c
346
memory_device_handler.attach = NULL;
drivers/acpi/acpi_memhotplug.c
38
.attach = acpi_memory_device_add,
drivers/acpi/acpi_pnp.c
355
.attach = acpi_pnp_attach,
drivers/acpi/acpi_processor.c
647
.attach = acpi_processor_add,
drivers/acpi/acpi_processor.c
669
.attach = acpi_processor_container_attach,
drivers/acpi/arm64/amba.c
110
.attach = amba_handler_attach,
drivers/acpi/container.c
92
.attach = container_device_attach,
drivers/acpi/pci_link.c
47
.attach = acpi_pci_link_add,
drivers/acpi/pci_root.c
51
.attach = acpi_pci_root_add,
drivers/acpi/scan.c
2304
.attach = acpi_generic_device_attach,
drivers/acpi/scan.c
2318
if (!handler->attach) {
drivers/acpi/scan.c
2323
ret = handler->attach(device, devid);
drivers/acpi/x86/cmos_rtc.c
91
.attach = acpi_cmos_rtc_attach_handler,
drivers/acpi/x86/lpss.c
1319
.attach = acpi_lpss_create_device,
drivers/acpi/x86/s2idle.c
515
.attach = lps0_device_attach,
drivers/bluetooth/btrsi.c
175
.attach = rsi_hci_attach,
drivers/comedi/drivers.c
1057
if (!driv->attach) {
drivers/comedi/drivers.c
1077
ret = driv->attach(dev, it);
drivers/comedi/drivers/8255.c
115
.attach = dev_8255_attach,
drivers/comedi/drivers/adl_pci9118.c
1701
.attach = pci9118_attach,
drivers/comedi/drivers/adq12b.c
235
.attach = adq12b_attach,
drivers/comedi/drivers/aio_aio12_8.c
266
.attach = aio_aio12_8_attach,
drivers/comedi/drivers/aio_iiro_16.c
228
.attach = aio_iiro_16_attach,
drivers/comedi/drivers/amplc_dio200.c
255
.attach = dio200_attach,
drivers/comedi/drivers/amplc_pc236.c
64
.attach = pc236_attach,
drivers/comedi/drivers/amplc_pc263.c
91
.attach = pc263_attach,
drivers/comedi/drivers/c6xdigio.c
281
.attach = c6xdigio_attach,
drivers/comedi/drivers/comedi_bond.c
340
.attach = bonding_attach,
drivers/comedi/drivers/comedi_parport.c
298
.attach = parport_attach,
drivers/comedi/drivers/comedi_test.c
852
.attach = waveform_attach,
drivers/comedi/drivers/dac02.c
129
.attach = dac02_attach,
drivers/comedi/drivers/das08_isa.c
180
.attach = das08_isa_attach,
drivers/comedi/drivers/das16.c
1189
.attach = das16_attach,
drivers/comedi/drivers/das16m1.c
617
.attach = das16m1_attach,
drivers/comedi/drivers/das1800.c
1352
.attach = das1800_attach,
drivers/comedi/drivers/das6402.c
658
.attach = das6402_attach,
drivers/comedi/drivers/das800.c
732
.attach = das800_attach,
drivers/comedi/drivers/dmm32at.c
637
.attach = dmm32at_attach,
drivers/comedi/drivers/dt2801.c
638
.attach = dt2801_attach,
drivers/comedi/drivers/dt2811.c
634
.attach = dt2811_attach,
drivers/comedi/drivers/dt2814.c
364
.attach = dt2814_attach,
drivers/comedi/drivers/dt2815.c
221
.attach = dt2815_attach,
drivers/comedi/drivers/dt2817.c
133
.attach = dt2817_attach,
drivers/comedi/drivers/dt282x.c
1160
.attach = dt282x_attach,
drivers/comedi/drivers/fl512.c
135
.attach = fl512_attach,
drivers/comedi/drivers/ii_pci20kc.c
517
.attach = ii20k_attach,
drivers/comedi/drivers/mpc624.c
303
.attach = mpc624_attach,
drivers/comedi/drivers/multiq3.c
333
.attach = multiq3_attach,
drivers/comedi/drivers/ni_at_a2150.c
773
.attach = a2150_attach,
drivers/comedi/drivers/ni_at_ao.c
362
.attach = atao_attach,
drivers/comedi/drivers/ni_atmio.c
360
.attach = ni_atmio_attach,
drivers/comedi/drivers/ni_atmio16d.c
719
.attach = atmio16d_attach,
drivers/comedi/drivers/ni_labpc.c
105
.attach = labpc_attach,
drivers/comedi/drivers/pcl711.c
501
.attach = pcl711_attach,
drivers/comedi/drivers/pcl724.c
142
.attach = pcl724_attach,
drivers/comedi/drivers/pcl726.c
415
.attach = pcl726_attach,
drivers/comedi/drivers/pcl730.c
340
.attach = pcl730_attach,
drivers/comedi/drivers/pcl812.c
1325
.attach = pcl812_attach,
drivers/comedi/drivers/pcl816.c
684
.attach = pcl816_attach,
drivers/comedi/drivers/pcl818.c
1124
.attach = pcl818_attach,
drivers/comedi/drivers/pcm3724.c
218
.attach = pcm3724_attach,
drivers/comedi/drivers/pcmad.c
139
.attach = pcmad_attach,
drivers/comedi/drivers/pcmda12.c
158
.attach = pcmda12_attach,
drivers/comedi/drivers/pcmmio.c
769
.attach = pcmmio_attach,
drivers/comedi/drivers/pcmuio.c
613
.attach = pcmuio_attach,
drivers/comedi/drivers/rti800.c
347
.attach = rti800_attach,
drivers/comedi/drivers/rti802.c
113
.attach = rti802_attach,
drivers/comedi/drivers/s526.c
622
.attach = s526_attach,
drivers/comedi/drivers/ssv_dnp.c
173
.attach = dnp_attach,
drivers/cxl/core/memdev.c
1101
return (cxlmd->attach && !cxlmd->dev.driver);
drivers/cxl/core/memdev.c
1126
const struct cxl_memdev_attach *attach)
drivers/cxl/core/memdev.c
1132
cxl_memdev_alloc(cxlds, &cxl_memdev_fops, attach);
drivers/cxl/core/memdev.c
650
if (cxlmd->attach)
drivers/cxl/core/memdev.c
661
const struct cxl_memdev_attach *attach)
drivers/cxl/core/memdev.c
677
cxlmd->attach = attach;
drivers/cxl/core/region.c
3945
bool attach = false;
drivers/cxl/core/region.c
3981
attach = p->state == CXL_CONFIG_COMMIT;
drivers/cxl/core/region.c
3984
if (attach) {
drivers/cxl/cxlmem.h
105
const struct cxl_memdev_attach *attach);
drivers/cxl/cxlmem.h
107
const struct cxl_memdev_attach *attach);
drivers/cxl/cxlmem.h
67
const struct cxl_memdev_attach *attach;
drivers/cxl/mem.c
143
if (cxlmd->attach) {
drivers/cxl/mem.c
144
rc = cxlmd->attach->probe(cxlmd);
drivers/cxl/mem.c
187
const struct cxl_memdev_attach *attach)
drivers/cxl/mem.c
189
return __devm_cxl_add_memdev(cxlds, attach);
drivers/dma-buf/dma-buf-mapping.c
105
dma_resv_assert_held(attach->dmabuf->resv);
drivers/dma-buf/dma-buf-mapping.c
107
if (WARN_ON(!attach || !attach->dmabuf || !provider))
drivers/dma-buf/dma-buf-mapping.c
115
switch (pci_p2pdma_map_type(provider, attach->dev)) {
drivers/dma-buf/dma-buf-mapping.c
128
dma_iova_try_alloc(attach->dev, dma->state, 0, size);
drivers/dma-buf/dma-buf-mapping.c
147
ret = dma_iova_link(attach->dev, dma->state,
drivers/dma-buf/dma-buf-mapping.c
156
addr = dma_map_phys(attach->dev, phys_vec[i].paddr,
drivers/dma-buf/dma-buf-mapping.c
159
ret = dma_mapping_error(attach->dev, addr);
drivers/dma-buf/dma-buf-mapping.c
170
ret = dma_iova_sync(attach->dev, dma->state, 0, mapped_len);
drivers/dma-buf/dma-buf-mapping.c
197
dma_iova_destroy(attach->dev, dma->state, mapped_len, dir,
drivers/dma-buf/dma-buf-mapping.c
201
dma_unmap_phys(attach->dev, sg_dma_address(sgl),
drivers/dma-buf/dma-buf-mapping.c
222
void dma_buf_free_sgt(struct dma_buf_attachment *attach, struct sg_table *sgt,
drivers/dma-buf/dma-buf-mapping.c
228
dma_resv_assert_held(attach->dmabuf->resv);
drivers/dma-buf/dma-buf-mapping.c
233
dma_iova_destroy(attach->dev, dma->state, dma->size, dir,
drivers/dma-buf/dma-buf-mapping.c
239
dma_unmap_phys(attach->dev, sg_dma_address(sgl),
drivers/dma-buf/dma-buf-mapping.c
92
struct sg_table *dma_buf_phys_vec_to_sgt(struct dma_buf_attachment *attach,
drivers/dma-buf/dma-buf.c
1014
struct dma_buf_attachment *attach;
drivers/dma-buf/dma-buf.c
1023
attach = kzalloc_obj(*attach);
drivers/dma-buf/dma-buf.c
1024
if (!attach)
drivers/dma-buf/dma-buf.c
1027
attach->dev = dev;
drivers/dma-buf/dma-buf.c
1028
attach->dmabuf = dmabuf;
drivers/dma-buf/dma-buf.c
1030
attach->peer2peer = importer_ops->allow_peer2peer;
drivers/dma-buf/dma-buf.c
1031
attach->importer_ops = importer_ops;
drivers/dma-buf/dma-buf.c
1032
attach->importer_priv = importer_priv;
drivers/dma-buf/dma-buf.c
1034
if (dmabuf->ops->attach) {
drivers/dma-buf/dma-buf.c
1035
ret = dmabuf->ops->attach(dmabuf, attach);
drivers/dma-buf/dma-buf.c
1040
list_add(&attach->node, &dmabuf->attachments);
drivers/dma-buf/dma-buf.c
1043
DMA_BUF_TRACE(trace_dma_buf_dynamic_attach, dmabuf, attach,
drivers/dma-buf/dma-buf.c
1044
dma_buf_attachment_is_dynamic(attach), dev);
drivers/dma-buf/dma-buf.c
1046
return attach;
drivers/dma-buf/dma-buf.c
1049
kfree(attach);
drivers/dma-buf/dma-buf.c
1078
void dma_buf_detach(struct dma_buf *dmabuf, struct dma_buf_attachment *attach)
drivers/dma-buf/dma-buf.c
1080
if (WARN_ON(!dmabuf || !attach || dmabuf != attach->dmabuf))
drivers/dma-buf/dma-buf.c
1084
list_del(&attach->node);
drivers/dma-buf/dma-buf.c
1088
dmabuf->ops->detach(dmabuf, attach);
drivers/dma-buf/dma-buf.c
1090
DMA_BUF_TRACE(trace_dma_buf_detach, dmabuf, attach,
drivers/dma-buf/dma-buf.c
1091
dma_buf_attachment_is_dynamic(attach), attach->dev);
drivers/dma-buf/dma-buf.c
1093
kfree(attach);
drivers/dma-buf/dma-buf.c
1111
int dma_buf_pin(struct dma_buf_attachment *attach)
drivers/dma-buf/dma-buf.c
1113
struct dma_buf *dmabuf = attach->dmabuf;
drivers/dma-buf/dma-buf.c
1116
WARN_ON(!attach->importer_ops);
drivers/dma-buf/dma-buf.c
1121
ret = dmabuf->ops->pin(attach);
drivers/dma-buf/dma-buf.c
1135
void dma_buf_unpin(struct dma_buf_attachment *attach)
drivers/dma-buf/dma-buf.c
1137
struct dma_buf *dmabuf = attach->dmabuf;
drivers/dma-buf/dma-buf.c
1139
WARN_ON(!attach->importer_ops);
drivers/dma-buf/dma-buf.c
1144
dmabuf->ops->unpin(attach);
drivers/dma-buf/dma-buf.c
1169
struct sg_table *dma_buf_map_attachment(struct dma_buf_attachment *attach,
drivers/dma-buf/dma-buf.c
1177
if (WARN_ON(!attach || !attach->dmabuf))
drivers/dma-buf/dma-buf.c
1180
dma_resv_assert_held(attach->dmabuf->resv);
drivers/dma-buf/dma-buf.c
1182
if (dma_buf_pin_on_map(attach)) {
drivers/dma-buf/dma-buf.c
1183
ret = attach->dmabuf->ops->pin(attach);
drivers/dma-buf/dma-buf.c
1193
sg_table = attach->dmabuf->ops->map_dma_buf(attach, direction);
drivers/dma-buf/dma-buf.c
1202
if (!dma_buf_attachment_is_dynamic(attach)) {
drivers/dma-buf/dma-buf.c
1203
ret = dma_resv_wait_timeout(attach->dmabuf->resv,
drivers/dma-buf/dma-buf.c
1232
attach->dmabuf->ops->unmap_dma_buf(attach, sg_table, direction);
drivers/dma-buf/dma-buf.c
1236
if (dma_buf_pin_on_map(attach))
drivers/dma-buf/dma-buf.c
1237
attach->dmabuf->ops->unpin(attach);
drivers/dma-buf/dma-buf.c
1253
dma_buf_map_attachment_unlocked(struct dma_buf_attachment *attach,
drivers/dma-buf/dma-buf.c
1260
if (WARN_ON(!attach || !attach->dmabuf))
drivers/dma-buf/dma-buf.c
1263
dma_resv_lock(attach->dmabuf->resv, NULL);
drivers/dma-buf/dma-buf.c
1264
sg_table = dma_buf_map_attachment(attach, direction);
drivers/dma-buf/dma-buf.c
1265
dma_resv_unlock(attach->dmabuf->resv);
drivers/dma-buf/dma-buf.c
1281
void dma_buf_unmap_attachment(struct dma_buf_attachment *attach,
drivers/dma-buf/dma-buf.c
1287
if (WARN_ON(!attach || !attach->dmabuf || !sg_table))
drivers/dma-buf/dma-buf.c
1290
dma_resv_assert_held(attach->dmabuf->resv);
drivers/dma-buf/dma-buf.c
1293
attach->dmabuf->ops->unmap_dma_buf(attach, sg_table, direction);
drivers/dma-buf/dma-buf.c
1295
if (dma_buf_pin_on_map(attach))
drivers/dma-buf/dma-buf.c
1296
attach->dmabuf->ops->unpin(attach);
drivers/dma-buf/dma-buf.c
1310
void dma_buf_unmap_attachment_unlocked(struct dma_buf_attachment *attach,
drivers/dma-buf/dma-buf.c
1316
if (WARN_ON(!attach || !attach->dmabuf || !sg_table))
drivers/dma-buf/dma-buf.c
1319
dma_resv_lock(attach->dmabuf->resv, NULL);
drivers/dma-buf/dma-buf.c
1320
dma_buf_unmap_attachment(attach, sg_table, direction);
drivers/dma-buf/dma-buf.c
1321
dma_resv_unlock(attach->dmabuf->resv);
drivers/dma-buf/dma-buf.c
1335
struct dma_buf_attachment *attach;
drivers/dma-buf/dma-buf.c
1339
list_for_each_entry(attach, &dmabuf->attachments, node)
drivers/dma-buf/dma-buf.c
1340
if (attach->importer_ops)
drivers/dma-buf/dma-buf.c
1341
attach->importer_ops->move_notify(attach);
drivers/dma-buf/dma-buf.c
910
dma_buf_attachment_is_dynamic(struct dma_buf_attachment *attach)
drivers/dma-buf/dma-buf.c
912
return !!attach->importer_ops;
drivers/dma-buf/dma-buf.c
916
dma_buf_pin_on_map(struct dma_buf_attachment *attach)
drivers/dma-buf/dma-buf.c
918
return attach->dmabuf->ops->pin &&
drivers/dma-buf/dma-buf.c
919
(!dma_buf_attachment_is_dynamic(attach) ||
drivers/dma-buf/heaps/cma_heap.c
283
.attach = cma_heap_attach,
drivers/dma-buf/heaps/system_heap.c
306
.attach = system_heap_attach,
drivers/dma/dmaengine.c
1511
if (!desc->metadata_ops || !desc->metadata_ops->attach)
drivers/dma/dmaengine.c
1514
return desc->metadata_ops->attach(desc, data, len);
drivers/dma/ti/k3-udma.c
3412
.attach = udma_attach_metadata,
drivers/gpib/agilent_82350b/agilent_82350b.c
781
.attach = agilent_82350b_unaccel_attach,
drivers/gpib/agilent_82350b/agilent_82350b.c
809
.attach = agilent_82350b_accel_attach,
drivers/gpib/agilent_82357a/agilent_82357a.c
1436
.attach = agilent_82357a_attach,
drivers/gpib/cb7210/cb7210.c
1330
.attach = cb_pcmcia_attach,
drivers/gpib/cb7210/cb7210.c
1358
.attach = cb_pcmcia_attach,
drivers/gpib/cb7210/cb7210.c
1386
.attach = cb_pcmcia_attach,
drivers/gpib/cb7210/cb7210.c
691
.attach = cb_pci_attach,
drivers/gpib/cb7210/cb7210.c
719
.attach = cb_pci_attach,
drivers/gpib/cb7210/cb7210.c
747
.attach = cb_pci_attach,
drivers/gpib/cb7210/cb7210.c
774
.attach = cb_isa_attach,
drivers/gpib/cb7210/cb7210.c
802
.attach = cb_isa_attach,
drivers/gpib/cb7210/cb7210.c
829
.attach = cb_isa_attach,
drivers/gpib/cec/cec_gpib.c
193
.attach = cec_pci_attach,
drivers/gpib/common/iblib.c
218
retval = board->interface->attach(board, &board->config);
drivers/gpib/eastwood/fluke_gpib.c
717
.attach = fluke_attach_holdoff_all,
drivers/gpib/eastwood/fluke_gpib.c
753
.attach = fluke_attach_holdoff_all,
drivers/gpib/eastwood/fluke_gpib.c
780
.attach = fluke_attach_holdoff_end,
drivers/gpib/fmh_gpib/fmh_gpib.c
1036
.attach = fmh_gpib_attach_holdoff_all,
drivers/gpib/fmh_gpib/fmh_gpib.c
1064
.attach = fmh_gpib_attach_holdoff_end,
drivers/gpib/fmh_gpib/fmh_gpib.c
1092
.attach = fmh_gpib_pci_attach_holdoff_end,
drivers/gpib/fmh_gpib/fmh_gpib.c
1120
.attach = fmh_gpib_pci_attach_holdoff_all,
drivers/gpib/gpio/gpib_bitbang.c
1310
.attach = bb_attach,
drivers/gpib/hp_82335/hp82335.c
185
.attach = hp82335_attach,
drivers/gpib/hp_82341/hp_82341.c
410
.attach = hp_82341_attach,
drivers/gpib/hp_82341/hp_82341.c
438
.attach = hp_82341_attach,
drivers/gpib/include/gpib_types.h
60
int (*attach)(struct gpib_board *board, const struct gpib_board_config *config);
drivers/gpib/ines/ines_gpib.c
1222
.attach = ines_pcmcia_attach,
drivers/gpib/ines/ines_gpib.c
1250
.attach = ines_pcmcia_accel_attach,
drivers/gpib/ines/ines_gpib.c
1278
.attach = ines_pcmcia_accel_attach,
drivers/gpib/ines/ines_gpib.c
546
.attach = ines_pci_attach,
drivers/gpib/ines/ines_gpib.c
574
.attach = ines_pci_accel_attach,
drivers/gpib/ines/ines_gpib.c
602
.attach = ines_pci_accel_attach,
drivers/gpib/ines/ines_gpib.c
630
.attach = ines_isa_attach,
drivers/gpib/lpvo_usb_gpib/lpvo_usb_gpib.c
1058
.attach = usb_gpib_attach,
drivers/gpib/ni_usb/ni_usb_gpib.c
2387
.attach = ni_usb_attach,
drivers/gpib/pc2/pc2_gpib.c
525
.attach = pc2_attach,
drivers/gpib/pc2/pc2_gpib.c
553
.attach = pc2a_attach,
drivers/gpib/pc2/pc2_gpib.c
581
.attach = pc2a_cb7210_attach,
drivers/gpib/pc2/pc2_gpib.c
609
.attach = pc2_2a_attach,
drivers/gpib/tnt4882/tnt4882_gpib.c
1130
.attach = ni_pci_attach,
drivers/gpib/tnt4882/tnt4882_gpib.c
1158
.attach = ni_pci_attach,
drivers/gpib/tnt4882/tnt4882_gpib.c
1186
.attach = ni_tnt_isa_attach,
drivers/gpib/tnt4882/tnt4882_gpib.c
1214
.attach = ni_nat4882_isa_attach,
drivers/gpib/tnt4882/tnt4882_gpib.c
1242
.attach = ni_nec_isa_attach,
drivers/gpib/tnt4882/tnt4882_gpib.c
1270
.attach = ni_tnt_isa_attach,
drivers/gpib/tnt4882/tnt4882_gpib.c
1298
.attach = ni_nat4882_isa_attach,
drivers/gpib/tnt4882/tnt4882_gpib.c
1326
.attach = ni_nec_isa_attach,
drivers/gpib/tnt4882/tnt4882_gpib.c
1783
.attach = ni_pcmcia_attach,
drivers/gpib/tnt4882/tnt4882_gpib.c
1811
.attach = ni_pcmcia_attach,
drivers/gpu/drm/adp/adp-mipi.c
210
.attach = adp_dsi_host_attach,
drivers/gpu/drm/adp/adp-mipi.c
225
.attach = adp_dsi_bridge_attach,
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
100
pci_p2pdma_distance(adev->pdev, attach->dev, false) < 0)
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
101
attach->peer2peer = false;
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
121
static int amdgpu_dma_buf_pin(struct dma_buf_attachment *attach)
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
123
struct dma_buf *dmabuf = attach->dmabuf;
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
140
list_for_each_entry(attach, &dmabuf->attachments, node)
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
141
if (!attach->peer2peer)
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
161
static void amdgpu_dma_buf_unpin(struct dma_buf_attachment *attach)
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
163
struct drm_gem_object *obj = attach->dmabuf->priv;
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
182
static struct sg_table *amdgpu_dma_buf_map(struct dma_buf_attachment *attach,
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
185
struct dma_buf *dma_buf = attach->dmabuf;
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
198
attach->peer2peer) {
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
216
if (dma_map_sgtable(attach->dev, sgt, dir,
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
224
dma_buf_attach_adev(attach), bo)))
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
228
bo->tbo.base.size, attach->dev,
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
236
attach->dev, dir, &sgt);
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
262
static void amdgpu_dma_buf_unmap(struct dma_buf_attachment *attach,
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
266
struct drm_gem_object *obj = attach->dmabuf->priv;
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
271
amdgpu_ttm_mmio_remap_free_sgt(attach->dev, dir, sgt);
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
276
dma_unmap_sgtable(attach->dev, sgt, dir, 0);
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
280
amdgpu_vram_mgr_free_sgt(attach->dev, dir, sgt);
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
356
.attach = amdgpu_dma_buf_attach,
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
467
amdgpu_dma_buf_move_notify(struct dma_buf_attachment *attach)
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
469
struct drm_gem_object *obj = attach->importer_priv;
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
553
struct dma_buf_attachment *attach;
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
572
attach = dma_buf_dynamic_attach(dma_buf, dev->dev,
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
574
if (IS_ERR(attach)) {
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
576
return ERR_CAST(attach);
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
58
static struct amdgpu_device *dma_buf_attach_adev(struct dma_buf_attachment *attach)
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
580
obj->import_attach = attach;
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
60
if (attach->importer_ops == &amdgpu_dma_buf_attach_ops) {
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
61
struct drm_gem_object *obj = attach->importer_priv;
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
79
struct dma_buf_attachment *attach)
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
81
struct amdgpu_device *attach_adev = dma_buf_attach_adev(attach);
drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
97
attach->peer2peer = false;
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
1039
struct dma_buf_attachment *attach;
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
1041
attach = gtt->gobj->import_attach;
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
1042
dma_buf_unmap_attachment(attach, ttm->sg, DMA_BIDIRECTIONAL);
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
917
struct dma_buf_attachment *attach;
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
920
attach = gtt->gobj->import_attach;
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
921
sgt = dma_buf_map_attachment(attach, DMA_BIDIRECTIONAL);
drivers/gpu/drm/armada/armada_gem.c
387
armada_gem_prime_map_dma_buf(struct dma_buf_attachment *attach,
drivers/gpu/drm/armada/armada_gem.c
390
struct drm_gem_object *obj = attach->dmabuf->priv;
drivers/gpu/drm/armada/armada_gem.c
420
if (dma_map_sgtable(attach->dev, sgt, dir, 0))
drivers/gpu/drm/armada/armada_gem.c
429
if (dma_map_sgtable(attach->dev, sgt, dir, 0))
drivers/gpu/drm/armada/armada_gem.c
453
static void armada_gem_prime_unmap_dma_buf(struct dma_buf_attachment *attach,
drivers/gpu/drm/armada/armada_gem.c
456
struct drm_gem_object *obj = attach->dmabuf->priv;
drivers/gpu/drm/armada/armada_gem.c
461
dma_unmap_sgtable(attach->dev, sgt, dir, 0);
drivers/gpu/drm/armada/armada_gem.c
503
struct dma_buf_attachment *attach;
drivers/gpu/drm/armada/armada_gem.c
518
attach = dma_buf_attach(buf, dev->dev);
drivers/gpu/drm/armada/armada_gem.c
519
if (IS_ERR(attach))
drivers/gpu/drm/armada/armada_gem.c
520
return ERR_CAST(attach);
drivers/gpu/drm/armada/armada_gem.c
524
dma_buf_detach(buf, attach);
drivers/gpu/drm/armada/armada_gem.c
528
dobj->obj.import_attach = attach;
drivers/gpu/drm/bridge/adv7511/adv7511_drv.c
1001
.attach = adv7511_bridge_attach,
drivers/gpu/drm/bridge/analogix/analogix-anx6345.c
603
.attach = anx6345_bridge_attach,
drivers/gpu/drm/bridge/analogix/analogix-anx78xx.c
995
.attach = anx78xx_bridge_attach,
drivers/gpu/drm/bridge/analogix/analogix_dp_core.c
1076
if (dp->plat_data->attach) {
drivers/gpu/drm/bridge/analogix/analogix_dp_core.c
1077
ret = dp->plat_data->attach(dp->plat_data, bridge, connector);
drivers/gpu/drm/bridge/analogix/analogix_dp_core.c
1385
.attach = analogix_dp_bridge_attach,
drivers/gpu/drm/bridge/analogix/anx7625.c
2492
.attach = anx7625_bridge_attach,
drivers/gpu/drm/bridge/aux-bridge.c
107
.attach = drm_aux_bridge_attach,
drivers/gpu/drm/bridge/aux-hpd-bridge.c
168
.attach = drm_aux_hpd_bridge_attach,
drivers/gpu/drm/bridge/cadence/cdns-dsi-core.c
1027
.attach = cdns_dsi_bridge_attach,
drivers/gpu/drm/bridge/cadence/cdns-dsi-core.c
1228
.attach = cdns_dsi_attach,
drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-core.c
2168
.attach = cdns_mhdp_attach,
drivers/gpu/drm/bridge/chipone-icn6211.c
626
.attach = chipone_attach,
drivers/gpu/drm/bridge/chrontel-ch7033.c
518
.attach = ch7033_bridge_attach,
drivers/gpu/drm/bridge/display-connector.c
179
.attach = display_connector_attach,
drivers/gpu/drm/bridge/fsl-ldb.c
282
.attach = fsl_ldb_attach,
drivers/gpu/drm/bridge/imx/imx-legacy-bridge.c
53
.attach = imx_legacy_bridge_attach,
drivers/gpu/drm/bridge/imx/imx8mp-hdmi-pvi.c
128
.attach = imx8mp_hdmi_pvi_bridge_attach,
drivers/gpu/drm/bridge/imx/imx8qm-ldb.c
394
.attach = ldb_bridge_attach_helper,
drivers/gpu/drm/bridge/imx/imx8qxp-ldb.c
409
.attach = ldb_bridge_attach_helper,
drivers/gpu/drm/bridge/imx/imx8qxp-pixel-combiner.c
256
.attach = imx8qxp_pc_bridge_attach,
drivers/gpu/drm/bridge/imx/imx8qxp-pixel-link.c
234
.attach = imx8qxp_pixel_link_bridge_attach,
drivers/gpu/drm/bridge/imx/imx8qxp-pxl2dpi.c
214
.attach = imx8qxp_pxl2dpi_bridge_attach,
drivers/gpu/drm/bridge/imx/imx93-mipi-dsi.c
827
.attach = imx93_dsi_host_attach,
drivers/gpu/drm/bridge/ite-it6263.c
826
.attach = it6263_bridge_attach,
drivers/gpu/drm/bridge/ite-it6505.c
3243
.attach = it6505_bridge_attach,
drivers/gpu/drm/bridge/ite-it66121.c
909
.attach = it66121_bridge_attach,
drivers/gpu/drm/bridge/lontium-lt8912b.c
636
.attach = lt8912_bridge_attach,
drivers/gpu/drm/bridge/lontium-lt9211.c
615
.attach = lt9211_attach,
drivers/gpu/drm/bridge/lontium-lt9611.c
1002
.attach = lt9611_bridge_attach,
drivers/gpu/drm/bridge/lontium-lt9611uxc.c
469
.attach = lt9611uxc_bridge_attach,
drivers/gpu/drm/bridge/lvds-codec.c
102
.attach = lvds_codec_attach,
drivers/gpu/drm/bridge/megachips-stdpxxxx-ge-b850v3-fw.c
217
.attach = ge_b850v3_lvds_attach,
drivers/gpu/drm/bridge/microchip-lvds.c
145
.attach = mchp_lvds_attach,
drivers/gpu/drm/bridge/nwl-dsi.c
627
.attach = nwl_dsi_host_attach,
drivers/gpu/drm/bridge/nwl-dsi.c
970
.attach = nwl_dsi_bridge_attach,
drivers/gpu/drm/bridge/nxp-ptn3460.c
253
.attach = ptn3460_bridge_attach,
drivers/gpu/drm/bridge/panel.c
209
.attach = panel_bridge_attach,
drivers/gpu/drm/bridge/parade-ps8622.c
434
.attach = ps8622_attach,
drivers/gpu/drm/bridge/parade-ps8640.c
553
.attach = ps8640_bridge_attach,
drivers/gpu/drm/bridge/samsung-dsim.c
1846
.attach = samsung_dsim_attach,
drivers/gpu/drm/bridge/samsung-dsim.c
1978
if (pdata->host_ops && pdata->host_ops->attach) {
drivers/gpu/drm/bridge/samsung-dsim.c
1979
ret = pdata->host_ops->attach(dsi, device);
drivers/gpu/drm/bridge/samsung-dsim.c
2047
.attach = samsung_dsim_host_attach,
drivers/gpu/drm/bridge/sii902x.c
541
.attach = sii902x_bridge_attach,
drivers/gpu/drm/bridge/sil-sii8620.c
2282
.attach = sii8620_attach,
drivers/gpu/drm/bridge/simple-bridge.c
160
.attach = simple_bridge_attach,
drivers/gpu/drm/bridge/ssd2825.c
396
.attach = ssd2825_dsi_host_attach,
drivers/gpu/drm/bridge/ssd2825.c
675
.attach = ssd2825_bridge_attach,
drivers/gpu/drm/bridge/synopsys/dw-hdmi.c
3016
.attach = dw_hdmi_bridge_attach,
drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
1100
.attach = dw_mipi_dsi_bridge_attach,
drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
345
if (pdata->host_ops && pdata->host_ops->attach) {
drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
346
ret = pdata->host_ops->attach(pdata->priv_data, device);
drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
540
.attach = dw_mipi_dsi_host_attach,
drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi2.c
540
if (pdata->host_ops && pdata->host_ops->attach) {
drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi2.c
541
ret = pdata->host_ops->attach(pdata->priv_data, device);
drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi2.c
690
.attach = dw_mipi_dsi2_host_attach,
drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi2.c
898
.attach = dw_mipi_dsi2_bridge_attach,
drivers/gpu/drm/bridge/tc358762.c
230
.attach = tc358762_attach,
drivers/gpu/drm/bridge/tc358764.c
309
.attach = tc358764_attach,
drivers/gpu/drm/bridge/tc358767.c
1928
.attach = tc_dpi_bridge_attach,
drivers/gpu/drm/bridge/tc358767.c
1941
.attach = tc_edp_bridge_attach,
drivers/gpu/drm/bridge/tc358768.c
1171
.attach = tc358768_bridge_attach,
drivers/gpu/drm/bridge/tc358768.c
551
.attach = tc358768_dsi_host_attach,
drivers/gpu/drm/bridge/tc358775.c
596
.attach = tc_bridge_attach,
drivers/gpu/drm/bridge/tda998x_drv.c
1687
.attach = tda998x_bridge_attach,
drivers/gpu/drm/bridge/thc63lvd1024.c
115
.attach = thc63_attach,
drivers/gpu/drm/bridge/ti-dlpc3433.c
262
.attach = dlpc_attach,
drivers/gpu/drm/bridge/ti-sn65dsi83.c
785
.attach = sn65dsi83_attach,
drivers/gpu/drm/bridge/ti-sn65dsi86.c
1298
.attach = ti_sn_bridge_attach,
drivers/gpu/drm/bridge/ti-tdp158.c
58
.attach = tdp158_attach,
drivers/gpu/drm/bridge/ti-tfp410.c
243
.attach = tfp410_attach,
drivers/gpu/drm/bridge/ti-tpd12s015.c
99
.attach = tpd12s015_attach,
drivers/gpu/drm/bridge/waveshare-dsi.c
112
.attach = ws_bridge_bridge_attach,
drivers/gpu/drm/drm_bridge.c
534
if (bridge->funcs->attach) {
drivers/gpu/drm/drm_bridge.c
535
ret = bridge->funcs->attach(bridge, encoder, flags);
drivers/gpu/drm/drm_gem_dma_helper.c
467
struct dma_buf_attachment *attach,
drivers/gpu/drm/drm_gem_dma_helper.c
473
if (drm_prime_get_contiguous_size(sgt) < attach->dmabuf->size)
drivers/gpu/drm/drm_gem_dma_helper.c
477
dma_obj = __drm_gem_dma_create(dev, attach->dmabuf->size, true);
drivers/gpu/drm/drm_gem_dma_helper.c
485
attach->dmabuf->size);
drivers/gpu/drm/drm_gem_dma_helper.c
579
struct dma_buf_attachment *attach,
drivers/gpu/drm/drm_gem_dma_helper.c
587
ret = dma_buf_vmap_unlocked(attach->dmabuf, &map);
drivers/gpu/drm/drm_gem_dma_helper.c
593
obj = drm_gem_dma_prime_import_sg_table(dev, attach, sgt);
drivers/gpu/drm/drm_gem_dma_helper.c
595
dma_buf_vunmap_unlocked(attach->dmabuf, &map);
drivers/gpu/drm/drm_gem_shmem_helper.c
837
struct dma_buf_attachment *attach,
drivers/gpu/drm/drm_gem_shmem_helper.c
840
size_t size = PAGE_ALIGN(attach->dmabuf->size);
drivers/gpu/drm/drm_gem_shmem_helper.c
867
struct dma_buf_attachment *attach;
drivers/gpu/drm/drm_gem_shmem_helper.c
883
attach = dma_buf_attach(dma_buf, dev->dev);
drivers/gpu/drm/drm_gem_shmem_helper.c
884
if (IS_ERR(attach))
drivers/gpu/drm/drm_gem_shmem_helper.c
885
return ERR_CAST(attach);
drivers/gpu/drm/drm_gem_shmem_helper.c
889
size = PAGE_ALIGN(attach->dmabuf->size);
drivers/gpu/drm/drm_gem_shmem_helper.c
899
shmem->base.import_attach = attach;
drivers/gpu/drm/drm_gem_shmem_helper.c
905
dma_buf_detach(dma_buf, attach);
drivers/gpu/drm/drm_mipi_dsi.c
380
if (!ops || !ops->attach)
drivers/gpu/drm/drm_mipi_dsi.c
383
ret = ops->attach(dsi->host, dsi);
drivers/gpu/drm/drm_prime.c
1002
obj = dev->driver->gem_prime_import_sg_table(dev, attach, sgt);
drivers/gpu/drm/drm_prime.c
1008
obj->import_attach = attach;
drivers/gpu/drm/drm_prime.c
1014
dma_buf_unmap_attachment_unlocked(attach, sgt, DMA_BIDIRECTIONAL);
drivers/gpu/drm/drm_prime.c
1016
dma_buf_detach(dma_buf, attach);
drivers/gpu/drm/drm_prime.c
1107
struct dma_buf_attachment *attach;
drivers/gpu/drm/drm_prime.c
1110
attach = obj->import_attach;
drivers/gpu/drm/drm_prime.c
1112
dma_buf_unmap_attachment_unlocked(attach, sg, DMA_BIDIRECTIONAL);
drivers/gpu/drm/drm_prime.c
1113
dma_buf = attach->dmabuf;
drivers/gpu/drm/drm_prime.c
1114
dma_buf_detach(attach->dmabuf, attach);
drivers/gpu/drm/drm_prime.c
602
struct dma_buf_attachment *attach)
drivers/gpu/drm/drm_prime.c
638
struct dma_buf_attachment *attach)
drivers/gpu/drm/drm_prime.c
666
struct sg_table *drm_gem_map_dma_buf(struct dma_buf_attachment *attach,
drivers/gpu/drm/drm_prime.c
669
struct drm_gem_object *obj = attach->dmabuf->priv;
drivers/gpu/drm/drm_prime.c
683
ret = dma_map_sgtable(attach->dev, sgt, dir,
drivers/gpu/drm/drm_prime.c
703
void drm_gem_unmap_dma_buf(struct dma_buf_attachment *attach,
drivers/gpu/drm/drm_prime.c
710
dma_unmap_sgtable(attach->dev, sgt, dir, DMA_ATTR_SKIP_CPU_SYNC);
drivers/gpu/drm/drm_prime.c
828
.attach = drm_gem_map_attach,
drivers/gpu/drm/drm_prime.c
972
struct dma_buf_attachment *attach;
drivers/gpu/drm/drm_prime.c
990
attach = dma_buf_attach(dma_buf, attach_dev);
drivers/gpu/drm/drm_prime.c
991
if (IS_ERR(attach))
drivers/gpu/drm/drm_prime.c
992
return ERR_CAST(attach);
drivers/gpu/drm/drm_prime.c
996
sgt = dma_buf_map_attachment_unlocked(attach, DMA_BIDIRECTIONAL);
drivers/gpu/drm/etnaviv/etnaviv_drv.h
63
struct dma_buf_attachment *attach, struct sg_table *sg);
drivers/gpu/drm/etnaviv/etnaviv_gem_prime.c
113
struct dma_buf_attachment *attach, struct sg_table *sgt)
drivers/gpu/drm/etnaviv/etnaviv_gem_prime.c
116
size_t size = PAGE_ALIGN(attach->dmabuf->size);
drivers/gpu/drm/exynos/exynos_dp.c
238
dp->plat_data.attach = exynos_dp_bridge_attach;
drivers/gpu/drm/exynos/exynos_drm_dsi.c
127
.attach = exynos_dsi_host_attach,
drivers/gpu/drm/exynos/exynos_drm_gem.c
432
struct dma_buf_attachment *attach,
drivers/gpu/drm/exynos/exynos_drm_gem.c
438
if (drm_prime_get_contiguous_size(sgt) < attach->dmabuf->size) {
drivers/gpu/drm/exynos/exynos_drm_gem.c
443
exynos_gem = exynos_drm_gem_init(dev, attach->dmabuf->size);
drivers/gpu/drm/exynos/exynos_drm_gem.h
105
struct dma_buf_attachment *attach,
drivers/gpu/drm/hisilicon/kirin/dw_drm_dsi.c
758
.attach = dsi_host_attach,
drivers/gpu/drm/i915/display/icl_dsi.c
1852
.attach = gen11_dsi_host_attach,
drivers/gpu/drm/i915/display/vlv_dsi.c
216
.attach = intel_dsi_host_attach,
drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
167
struct dma_buf_attachment *attach)
drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
196
struct dma_buf_attachment *attach)
drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
204
.attach = i915_gem_dmabuf_attach,
drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
27
static struct sg_table *i915_gem_map_dma_buf(struct dma_buf_attachment *attach,
drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
285
struct dma_buf_attachment *attach;
drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
30
struct drm_i915_gem_object *obj = dma_buf_to_obj(attach->dmabuf);
drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
307
attach = dma_buf_attach(dma_buf, dev->dev);
drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
308
if (IS_ERR(attach))
drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
309
return ERR_CAST(attach);
drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
322
obj->base.import_attach = attach;
drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
338
dma_buf_detach(dma_buf, attach);
drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
55
ret = dma_map_sgtable(attach->dev, sgt, dir, DMA_ATTR_SKIP_CPU_SYNC);
drivers/gpu/drm/imx/ipuv3/parallel-display.c
173
.attach = imx_pd_bridge_attach,
drivers/gpu/drm/ingenic/ingenic-drm-drv.c
1016
.attach = ingenic_drm_bridge_attach,
drivers/gpu/drm/kmb/kmb_dsi.c
212
.attach = kmb_dsi_host_attach,
drivers/gpu/drm/loongson/lsdc_gem.c
178
struct dma_buf_attachment *attach,
drivers/gpu/drm/loongson/lsdc_gem.c
181
struct dma_resv *resv = attach->dmabuf->resv;
drivers/gpu/drm/loongson/lsdc_gem.c
182
u64 size = attach->dmabuf->size;
drivers/gpu/drm/loongson/lsdc_gem.h
14
struct dma_buf_attachment *attach,
drivers/gpu/drm/mcde/mcde_dsi.c
1067
.attach = mcde_dsi_bridge_attach,
drivers/gpu/drm/mcde/mcde_dsi.c
384
.attach = mcde_dsi_host_attach,
drivers/gpu/drm/mediatek/mtk_dp.c
2582
.attach = mtk_dp_bridge_attach,
drivers/gpu/drm/mediatek/mtk_dpi.c
982
.attach = mtk_dpi_bridge_attach,
drivers/gpu/drm/mediatek/mtk_dsi.c
1191
.attach = mtk_dsi_host_attach,
drivers/gpu/drm/mediatek/mtk_dsi.c
887
.attach = mtk_dsi_bridge_attach,
drivers/gpu/drm/mediatek/mtk_gem.c
213
struct dma_buf_attachment *attach, struct sg_table *sgt)
drivers/gpu/drm/mediatek/mtk_gem.c
218
if (drm_prime_get_contiguous_size(sgt) < attach->dmabuf->size) {
drivers/gpu/drm/mediatek/mtk_gem.c
223
dma_obj = mtk_gem_init(dev, attach->dmabuf->size, true);
drivers/gpu/drm/mediatek/mtk_gem.h
15
struct dma_buf_attachment *attach, struct sg_table *sg);
drivers/gpu/drm/mediatek/mtk_hdmi.c
1076
.attach = mtk_hdmi_bridge_attach,
drivers/gpu/drm/mediatek/mtk_hdmi_v2.c
1319
.attach = mtk_hdmi_v2_bridge_attach,
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c
264
.attach = meson_dw_mipi_dsi_host_attach,
drivers/gpu/drm/meson/meson_encoder_cvbs.c
210
.attach = meson_encoder_cvbs_attach,
drivers/gpu/drm/meson/meson_encoder_dsi.c
94
.attach = meson_encoder_dsi_attach,
drivers/gpu/drm/meson/meson_encoder_hdmi.c
359
.attach = meson_encoder_hdmi_attach,
drivers/gpu/drm/msm/dsi/dsi_host.c
1746
.attach = dsi_host_attach,
drivers/gpu/drm/msm/dsi/dsi_manager.c
448
.attach = dsi_mgr_bridge_attach,
drivers/gpu/drm/msm/msm_drv.h
252
struct dma_buf_attachment *attach, struct sg_table *sg);
drivers/gpu/drm/msm/msm_gem_prime.c
55
.attach = drm_gem_map_attach,
drivers/gpu/drm/msm/msm_gem_prime.c
84
struct dma_buf_attachment *attach, struct sg_table *sg)
drivers/gpu/drm/msm/msm_gem_prime.c
86
return msm_gem_import(dev, attach->dmabuf, sg);
drivers/gpu/drm/nouveau/nouveau_prime.c
40
struct dma_buf_attachment *attach,
drivers/gpu/drm/nouveau/nouveau_prime.c
46
struct dma_resv *robj = attach->dmabuf->resv;
drivers/gpu/drm/nouveau/nouveau_prime.c
47
u64 size = attach->dmabuf->size;
drivers/gpu/drm/omapdrm/dss/dpi.c
555
.attach = dpi_bridge_attach,
drivers/gpu/drm/omapdrm/dss/dsi.c
4432
.attach = omap_dsi_host_attach,
drivers/gpu/drm/omapdrm/dss/dsi.c
4695
.attach = dsi_bridge_attach,
drivers/gpu/drm/omapdrm/dss/hdmi4.c
496
.attach = hdmi4_bridge_attach,
drivers/gpu/drm/omapdrm/dss/hdmi5.c
471
.attach = hdmi5_bridge_attach,
drivers/gpu/drm/omapdrm/dss/sdi.c
277
.attach = sdi_bridge_attach,
drivers/gpu/drm/omapdrm/dss/venc.c
656
.attach = venc_bridge_attach,
drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c
100
struct dma_buf_attachment *attach;
drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c
117
attach = dma_buf_attach(dma_buf, dev->dev);
drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c
118
if (IS_ERR(attach))
drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c
119
return ERR_CAST(attach);
drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c
123
sgt = dma_buf_map_attachment_unlocked(attach, DMA_TO_DEVICE);
drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c
135
obj->import_attach = attach;
drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c
140
dma_buf_unmap_attachment_unlocked(attach, sgt, DMA_TO_DEVICE);
drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c
142
dma_buf_detach(dma_buf, attach);
drivers/gpu/drm/panfrost/panfrost_gem.c
281
panfrost_gem_prime_map_dma_buf(struct dma_buf_attachment *attach,
drivers/gpu/drm/panfrost/panfrost_gem.c
284
struct sg_table *sgt = drm_gem_map_dma_buf(attach, dir);
drivers/gpu/drm/panfrost/panfrost_gem.c
287
attach->priv = sgt;
drivers/gpu/drm/panfrost/panfrost_gem.c
293
panfrost_gem_prime_unmap_dma_buf(struct dma_buf_attachment *attach,
drivers/gpu/drm/panfrost/panfrost_gem.c
297
attach->priv = NULL;
drivers/gpu/drm/panfrost/panfrost_gem.c
298
drm_gem_unmap_dma_buf(attach, sgt, dir);
drivers/gpu/drm/panfrost/panfrost_gem.c
308
struct dma_buf_attachment *attach;
drivers/gpu/drm/panfrost/panfrost_gem.c
317
list_for_each_entry(attach, &dma_buf->attachments, node) {
drivers/gpu/drm/panfrost/panfrost_gem.c
318
struct sg_table *sgt = attach->priv;
drivers/gpu/drm/panfrost/panfrost_gem.c
321
dma_sync_sgtable_for_cpu(attach->dev, sgt, dir);
drivers/gpu/drm/panfrost/panfrost_gem.c
335
struct dma_buf_attachment *attach;
drivers/gpu/drm/panfrost/panfrost_gem.c
338
list_for_each_entry(attach, &dma_buf->attachments, node) {
drivers/gpu/drm/panfrost/panfrost_gem.c
339
struct sg_table *sgt = attach->priv;
drivers/gpu/drm/panfrost/panfrost_gem.c
342
dma_sync_sgtable_for_device(attach->dev, sgt, dir);
drivers/gpu/drm/panfrost/panfrost_gem.c
356
.attach = drm_gem_map_attach,
drivers/gpu/drm/panfrost/panfrost_gem.c
502
struct dma_buf_attachment *attach,
drivers/gpu/drm/panfrost/panfrost_gem.c
508
obj = drm_gem_shmem_prime_import_sg_table(dev, attach, sgt);
drivers/gpu/drm/panfrost/panfrost_gem.h
138
struct dma_buf_attachment *attach,
drivers/gpu/drm/panthor/panthor_gem.c
240
panthor_gem_prime_map_dma_buf(struct dma_buf_attachment *attach,
drivers/gpu/drm/panthor/panthor_gem.c
243
struct sg_table *sgt = drm_gem_map_dma_buf(attach, dir);
drivers/gpu/drm/panthor/panthor_gem.c
246
attach->priv = sgt;
drivers/gpu/drm/panthor/panthor_gem.c
252
panthor_gem_prime_unmap_dma_buf(struct dma_buf_attachment *attach,
drivers/gpu/drm/panthor/panthor_gem.c
256
attach->priv = NULL;
drivers/gpu/drm/panthor/panthor_gem.c
257
drm_gem_unmap_dma_buf(attach, sgt, dir);
drivers/gpu/drm/panthor/panthor_gem.c
267
struct dma_buf_attachment *attach;
drivers/gpu/drm/panthor/panthor_gem.c
276
list_for_each_entry(attach, &dma_buf->attachments, node) {
drivers/gpu/drm/panthor/panthor_gem.c
277
struct sg_table *sgt = attach->priv;
drivers/gpu/drm/panthor/panthor_gem.c
280
dma_sync_sgtable_for_cpu(attach->dev, sgt, dir);
drivers/gpu/drm/panthor/panthor_gem.c
294
struct dma_buf_attachment *attach;
drivers/gpu/drm/panthor/panthor_gem.c
297
list_for_each_entry(attach, &dma_buf->attachments, node) {
drivers/gpu/drm/panthor/panthor_gem.c
298
struct sg_table *sgt = attach->priv;
drivers/gpu/drm/panthor/panthor_gem.c
301
dma_sync_sgtable_for_device(attach->dev, sgt, dir);
drivers/gpu/drm/panthor/panthor_gem.c
315
.attach = drm_gem_map_attach,
drivers/gpu/drm/pl111/pl111_drv.c
199
struct dma_buf_attachment *attach,
drivers/gpu/drm/pl111/pl111_drv.c
212
return drm_gem_dma_prime_import_sg_table(dev, attach, sgt);
drivers/gpu/drm/qxl/qxl_drv.h
419
struct drm_device *dev, struct dma_buf_attachment *attach,
drivers/gpu/drm/qxl/qxl_prime.c
51
struct drm_device *dev, struct dma_buf_attachment *attach,
drivers/gpu/drm/radeon/radeon_prime.c
46
struct dma_buf_attachment *attach,
drivers/gpu/drm/radeon/radeon_prime.c
49
struct dma_resv *resv = attach->dmabuf->resv;
drivers/gpu/drm/radeon/radeon_prime.c
55
ret = radeon_bo_create(rdev, attach->dmabuf->size, PAGE_SIZE, false,
drivers/gpu/drm/renesas/rcar-du/rcar_du_kms.c
372
struct dma_buf_attachment *attach,
drivers/gpu/drm/renesas/rcar-du/rcar_du_kms.c
381
return drm_gem_dma_prime_import_sg_table(dev, attach, sgt);
drivers/gpu/drm/renesas/rcar-du/rcar_du_kms.c
391
drm_gem_private_object_init(dev, gem_obj, attach->dmabuf->size);
drivers/gpu/drm/renesas/rcar-du/rcar_du_kms.h
41
struct dma_buf_attachment *attach,
drivers/gpu/drm/renesas/rcar-du/rcar_lvds.c
657
.attach = rcar_lvds_attach,
drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c
1183
.attach = rcar_mipi_dsi_host_attach,
drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c
907
.attach = rcar_mipi_dsi_attach,
drivers/gpu/drm/renesas/rz-du/rzg2l_du_kms.h
39
struct dma_buf_attachment *attach,
drivers/gpu/drm/renesas/rz-du/rzg2l_mipi_dsi.c
1106
.attach = rzg2l_mipi_dsi_attach,
drivers/gpu/drm/renesas/rz-du/rzg2l_mipi_dsi.c
1351
.attach = rzg2l_mipi_dsi_host_attach,
drivers/gpu/drm/rockchip/dw-mipi-dsi-rockchip.c
1111
.attach = dw_mipi_dsi_rockchip_host_attach,
drivers/gpu/drm/rockchip/dw-mipi-dsi2-rockchip.c
362
.attach = dw_mipi_dsi2_rockchip_host_attach,
drivers/gpu/drm/rockchip/rockchip_drm_gem.c
455
struct dma_buf_attachment *attach,
drivers/gpu/drm/rockchip/rockchip_drm_gem.c
465
struct dma_buf_attachment *attach,
drivers/gpu/drm/rockchip/rockchip_drm_gem.c
473
if (drm_prime_get_contiguous_size(sg) < attach->dmabuf->size) {
drivers/gpu/drm/rockchip/rockchip_drm_gem.c
486
struct dma_buf_attachment *attach,
drivers/gpu/drm/rockchip/rockchip_drm_gem.c
493
rk_obj = rockchip_gem_alloc_object(drm, attach->dmabuf->size);
drivers/gpu/drm/rockchip/rockchip_drm_gem.c
498
ret = rockchip_gem_iommu_map_sg(drm, attach, sg, rk_obj);
drivers/gpu/drm/rockchip/rockchip_drm_gem.c
500
ret = rockchip_gem_dma_map_sg(drm, attach, sg, rk_obj);
drivers/gpu/drm/rockchip/rockchip_drm_gem.h
32
struct dma_buf_attachment *attach,
drivers/gpu/drm/sprd/sprd_dsi.c
1020
.attach = sprd_dsi_host_attach,
drivers/gpu/drm/stm/lvds.c
1036
.attach = lvds_attach,
drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c
1037
.attach = sun6i_dsi_attach,
drivers/gpu/drm/tegra/dsi.c
1528
.attach = tegra_dsi_host_attach,
drivers/gpu/drm/tegra/gem.c
163
if (map->attach) {
drivers/gpu/drm/tegra/gem.c
164
dma_buf_unmap_attachment_unlocked(map->attach, map->sgt,
drivers/gpu/drm/tegra/gem.c
166
dma_buf_detach(map->attach->dmabuf, map->attach);
drivers/gpu/drm/tegra/gem.c
460
struct dma_buf_attachment *attach;
drivers/gpu/drm/tegra/gem.c
473
attach = dma_buf_attach(buf, drm->dev);
drivers/gpu/drm/tegra/gem.c
474
if (IS_ERR(attach)) {
drivers/gpu/drm/tegra/gem.c
475
err = PTR_ERR(attach);
drivers/gpu/drm/tegra/gem.c
479
bo->sgt = dma_buf_map_attachment_unlocked(attach, DMA_TO_DEVICE);
drivers/gpu/drm/tegra/gem.c
489
bo->gem.import_attach = attach;
drivers/gpu/drm/tegra/gem.c
499
dma_buf_unmap_attachment_unlocked(attach, bo->sgt, DMA_TO_DEVICE);
drivers/gpu/drm/tegra/gem.c
501
dma_buf_detach(buf, attach);
drivers/gpu/drm/tegra/gem.c
635
tegra_gem_prime_map_dma_buf(struct dma_buf_attachment *attach,
drivers/gpu/drm/tegra/gem.c
638
struct drm_gem_object *gem = attach->dmabuf->priv;
drivers/gpu/drm/tegra/gem.c
651
if (dma_get_sgtable(attach->dev, sgt, bo->vaddr, bo->iova,
drivers/gpu/drm/tegra/gem.c
656
if (dma_map_sgtable(attach->dev, sgt, dir, 0))
drivers/gpu/drm/tegra/gem.c
667
static void tegra_gem_prime_unmap_dma_buf(struct dma_buf_attachment *attach,
drivers/gpu/drm/tegra/gem.c
671
struct drm_gem_object *gem = attach->dmabuf->priv;
drivers/gpu/drm/tegra/gem.c
675
dma_unmap_sgtable(attach->dev, sgt, dir, 0);
drivers/gpu/drm/tegra/gem.c
82
map->attach = dma_buf_attach(buf, dev);
drivers/gpu/drm/tegra/gem.c
83
if (IS_ERR(map->attach)) {
drivers/gpu/drm/tegra/gem.c
84
err = PTR_ERR(map->attach);
drivers/gpu/drm/tegra/gem.c
88
map->sgt = dma_buf_map_attachment_unlocked(map->attach, direction);
drivers/gpu/drm/tegra/gem.c
90
dma_buf_detach(buf, map->attach);
drivers/gpu/drm/tidss/tidss_encoder.c
77
.attach = tidss_bridge_attach,
drivers/gpu/drm/tidss/tidss_oldi.c
332
.attach = tidss_oldi_bridge_attach,
drivers/gpu/drm/v3d/v3d_bo.c
175
struct dma_buf_attachment *attach,
drivers/gpu/drm/v3d/v3d_bo.c
181
obj = drm_gem_shmem_prime_import_sg_table(dev, attach, sgt);
drivers/gpu/drm/v3d/v3d_drv.h
552
struct dma_buf_attachment *attach,
drivers/gpu/drm/vc4/vc4_dsi.c
1406
.attach = vc4_dsi_host_attach,
drivers/gpu/drm/vc4/vc4_dsi.c
1419
.attach = vc4_dsi_bridge_attach,
drivers/gpu/drm/virtio/virtgpu_drv.h
489
struct drm_device *dev, struct dma_buf_attachment *attach,
drivers/gpu/drm/virtio/virtgpu_drv.h
494
struct dma_buf_attachment *attach);
drivers/gpu/drm/virtio/virtgpu_plane.c
314
struct dma_buf_attachment *attach = obj->import_attach;
drivers/gpu/drm/virtio/virtgpu_plane.c
315
struct dma_resv *resv = attach->dmabuf->resv;
drivers/gpu/drm/virtio/virtgpu_plane.c
322
ret = dma_buf_pin(attach);
drivers/gpu/drm/virtio/virtgpu_plane.c
330
bo, attach);
drivers/gpu/drm/virtio/virtgpu_plane.c
341
dma_buf_unpin(attach);
drivers/gpu/drm/virtio/virtgpu_plane.c
397
struct dma_buf_attachment *attach = obj->import_attach;
drivers/gpu/drm/virtio/virtgpu_plane.c
398
struct dma_resv *resv = attach->dmabuf->resv;
drivers/gpu/drm/virtio/virtgpu_plane.c
401
dma_buf_unpin(attach);
drivers/gpu/drm/virtio/virtgpu_prime.c
149
struct dma_buf_attachment *attach)
drivers/gpu/drm/virtio/virtgpu_prime.c
155
dma_resv_assert_held(attach->dmabuf->resv);
drivers/gpu/drm/virtio/virtgpu_prime.c
157
ret = dma_resv_wait_timeout(attach->dmabuf->resv,
drivers/gpu/drm/virtio/virtgpu_prime.c
163
sgt = dma_buf_map_attachment(attach, DMA_BIDIRECTIONAL);
drivers/gpu/drm/virtio/virtgpu_prime.c
169
dma_buf_unmap_attachment(attach, sgt, DMA_BIDIRECTIONAL);
drivers/gpu/drm/virtio/virtgpu_prime.c
186
struct dma_buf_attachment *attach = bo->base.base.import_attach;
drivers/gpu/drm/virtio/virtgpu_prime.c
188
dma_resv_assert_held(attach->dmabuf->resv);
drivers/gpu/drm/virtio/virtgpu_prime.c
194
dma_buf_unmap_attachment(attach, bo->sgt,
drivers/gpu/drm/virtio/virtgpu_prime.c
205
struct dma_buf_attachment *attach = obj->import_attach;
drivers/gpu/drm/virtio/virtgpu_prime.c
208
struct dma_buf *dmabuf = attach->dmabuf;
drivers/gpu/drm/virtio/virtgpu_prime.c
214
dma_buf_detach(dmabuf, attach);
drivers/gpu/drm/virtio/virtgpu_prime.c
228
struct dma_buf_attachment *attach)
drivers/gpu/drm/virtio/virtgpu_prime.c
232
struct dma_resv *resv = attach->dmabuf->resv;
drivers/gpu/drm/virtio/virtgpu_prime.c
245
ret = dma_buf_pin(attach);
drivers/gpu/drm/virtio/virtgpu_prime.c
249
ret = virtgpu_dma_buf_import_sgt(&ents, &nents, bo, attach);
drivers/gpu/drm/virtio/virtgpu_prime.c
256
params.size = attach->dmabuf->size;
drivers/gpu/drm/virtio/virtgpu_prime.c
262
dma_buf_unpin(attach);
drivers/gpu/drm/virtio/virtgpu_prime.c
268
dma_buf_unpin(attach);
drivers/gpu/drm/virtio/virtgpu_prime.c
279
static void virtgpu_dma_buf_move_notify(struct dma_buf_attachment *attach)
drivers/gpu/drm/virtio/virtgpu_prime.c
281
struct drm_gem_object *obj = attach->importer_priv;
drivers/gpu/drm/virtio/virtgpu_prime.c
296
struct dma_buf_attachment *attach;
drivers/gpu/drm/virtio/virtgpu_prime.c
325
attach = dma_buf_dynamic_attach(buf, dev->dev,
drivers/gpu/drm/virtio/virtgpu_prime.c
327
if (IS_ERR(attach)) {
drivers/gpu/drm/virtio/virtgpu_prime.c
329
return ERR_CAST(attach);
drivers/gpu/drm/virtio/virtgpu_prime.c
332
obj->import_attach = attach;
drivers/gpu/drm/virtio/virtgpu_prime.c
335
ret = virtgpu_dma_buf_init_obj(dev, bo, attach);
drivers/gpu/drm/virtio/virtgpu_prime.c
343
struct drm_device *dev, struct dma_buf_attachment *attach,
drivers/gpu/drm/virtio/virtgpu_prime.c
49
virtgpu_gem_map_dma_buf(struct dma_buf_attachment *attach,
drivers/gpu/drm/virtio/virtgpu_prime.c
52
struct drm_gem_object *obj = attach->dmabuf->priv;
drivers/gpu/drm/virtio/virtgpu_prime.c
56
return virtio_gpu_vram_map_dma_buf(bo, attach->dev, dir);
drivers/gpu/drm/virtio/virtgpu_prime.c
58
return drm_gem_map_dma_buf(attach, dir);
drivers/gpu/drm/virtio/virtgpu_prime.c
61
static void virtgpu_gem_unmap_dma_buf(struct dma_buf_attachment *attach,
drivers/gpu/drm/virtio/virtgpu_prime.c
65
struct drm_gem_object *obj = attach->dmabuf->priv;
drivers/gpu/drm/virtio/virtgpu_prime.c
69
virtio_gpu_vram_unmap_dma_buf(attach->dev, sgt, dir);
drivers/gpu/drm/virtio/virtgpu_prime.c
73
drm_gem_unmap_dma_buf(attach, sgt, dir);
drivers/gpu/drm/virtio/virtgpu_prime.c
78
.attach = virtio_dma_buf_attach,
drivers/gpu/drm/vmwgfx/vmwgfx_drv.h
1109
struct dma_buf_attachment *attach,
drivers/gpu/drm/vmwgfx/vmwgfx_gem.c
182
struct dma_buf_attachment *attach,
drivers/gpu/drm/vmwgfx/vmwgfx_gem.c
193
.size = attach->dmabuf->size,
drivers/gpu/drm/vmwgfx/vmwgfx_gem.c
196
.resv = attach->dmabuf->resv,
drivers/gpu/drm/vmwgfx/vmwgfx_prime.c
45
struct dma_buf_attachment *attach)
drivers/gpu/drm/vmwgfx/vmwgfx_prime.c
51
struct dma_buf_attachment *attach)
drivers/gpu/drm/vmwgfx/vmwgfx_prime.c
55
static struct sg_table *vmw_prime_map_dma_buf(struct dma_buf_attachment *attach,
drivers/gpu/drm/vmwgfx/vmwgfx_prime.c
61
static void vmw_prime_unmap_dma_buf(struct dma_buf_attachment *attach,
drivers/gpu/drm/vmwgfx/vmwgfx_prime.c
68
.attach = vmw_prime_map_attach,
drivers/gpu/drm/xe/tests/xe_dma_buf.c
34
struct dma_buf_attachment *attach;
drivers/gpu/drm/xe/tests/xe_dma_buf.c
93
attach = list_first_entry_or_null(&dmabuf->attachments, typeof(*attach), node);
drivers/gpu/drm/xe/tests/xe_dma_buf.c
94
if (attach) {
drivers/gpu/drm/xe/tests/xe_dma_buf.c
95
int err = dma_buf_pin(attach);
drivers/gpu/drm/xe/tests/xe_dma_buf.c
99
dma_buf_unpin(attach);
drivers/gpu/drm/xe/xe_bo.c
740
struct dma_buf_attachment *attach = ttm_bo->base.import_attach;
drivers/gpu/drm/xe/xe_bo.c
747
xe_assert(xe, attach);
drivers/gpu/drm/xe/xe_bo.c
754
dma_buf_unmap_attachment(attach, ttm_bo->sg, DMA_BIDIRECTIONAL);
drivers/gpu/drm/xe/xe_bo.c
762
dma_buf_unmap_attachment(attach, ttm_bo->sg, DMA_BIDIRECTIONAL);
drivers/gpu/drm/xe/xe_bo.c
766
sg = dma_buf_map_attachment(attach, DMA_BIDIRECTIONAL);
drivers/gpu/drm/xe/xe_dma_buf.c
101
static struct sg_table *xe_dma_buf_map(struct dma_buf_attachment *attach,
drivers/gpu/drm/xe/xe_dma_buf.c
104
struct dma_buf *dma_buf = attach->dmabuf;
drivers/gpu/drm/xe/xe_dma_buf.c
111
if (!attach->peer2peer && !xe_bo_can_migrate(bo, XE_PL_TT))
drivers/gpu/drm/xe/xe_dma_buf.c
115
if (!attach->peer2peer)
drivers/gpu/drm/xe/xe_dma_buf.c
131
if (dma_map_sgtable(attach->dev, sgt, dir,
drivers/gpu/drm/xe/xe_dma_buf.c
140
bo->ttm.base.size, attach->dev,
drivers/gpu/drm/xe/xe_dma_buf.c
157
static void xe_dma_buf_unmap(struct dma_buf_attachment *attach,
drivers/gpu/drm/xe/xe_dma_buf.c
162
dma_unmap_sgtable(attach->dev, sgt, dir, 0);
drivers/gpu/drm/xe/xe_dma_buf.c
166
xe_ttm_vram_mgr_free_sgt(attach->dev, dir, sgt);
drivers/gpu/drm/xe/xe_dma_buf.c
201
.attach = xe_dma_buf_attach,
drivers/gpu/drm/xe/xe_dma_buf.c
26
struct dma_buf_attachment *attach)
drivers/gpu/drm/xe/xe_dma_buf.c
279
static void xe_dma_buf_move_notify(struct dma_buf_attachment *attach)
drivers/gpu/drm/xe/xe_dma_buf.c
28
struct drm_gem_object *obj = attach->dmabuf->priv;
drivers/gpu/drm/xe/xe_dma_buf.c
281
struct drm_gem_object *obj = attach->importer_priv;
drivers/gpu/drm/xe/xe_dma_buf.c
30
if (attach->peer2peer &&
drivers/gpu/drm/xe/xe_dma_buf.c
31
pci_p2pdma_distance(to_pci_dev(obj->dev->dev), attach->dev, false) < 0)
drivers/gpu/drm/xe/xe_dma_buf.c
313
struct dma_buf_attachment *attach;
drivers/gpu/drm/xe/xe_dma_buf.c
32
attach->peer2peer = false;
drivers/gpu/drm/xe/xe_dma_buf.c
34
if (!attach->peer2peer && !xe_bo_can_migrate(gem_to_xe_bo(obj), XE_PL_TT))
drivers/gpu/drm/xe/xe_dma_buf.c
345
attach = dma_buf_dynamic_attach(dma_buf, dev->dev, attach_ops, &bo->ttm.base);
drivers/gpu/drm/xe/xe_dma_buf.c
346
if (IS_ERR(attach)) {
drivers/gpu/drm/xe/xe_dma_buf.c
347
obj = ERR_CAST(attach);
drivers/gpu/drm/xe/xe_dma_buf.c
358
obj->import_attach = attach;
drivers/gpu/drm/xe/xe_dma_buf.c
42
struct dma_buf_attachment *attach)
drivers/gpu/drm/xe/xe_dma_buf.c
44
struct drm_gem_object *obj = attach->dmabuf->priv;
drivers/gpu/drm/xe/xe_dma_buf.c
49
static int xe_dma_buf_pin(struct dma_buf_attachment *attach)
drivers/gpu/drm/xe/xe_dma_buf.c
51
struct dma_buf *dmabuf = attach->dmabuf;
drivers/gpu/drm/xe/xe_dma_buf.c
62
list_for_each_entry(attach, &dmabuf->attachments, node) {
drivers/gpu/drm/xe/xe_dma_buf.c
63
if (!attach->peer2peer) {
drivers/gpu/drm/xe/xe_dma_buf.c
93
static void xe_dma_buf_unpin(struct dma_buf_attachment *attach)
drivers/gpu/drm/xe/xe_dma_buf.c
95
struct drm_gem_object *obj = attach->dmabuf->priv;
drivers/gpu/drm/xen/xen_drm_front_gem.c
245
struct dma_buf_attachment *attach,
drivers/gpu/drm/xen/xen_drm_front_gem.c
253
size = attach->dmabuf->size;
drivers/gpu/drm/xen/xen_drm_front_gem.h
25
struct dma_buf_attachment *attach,
drivers/gpu/drm/xlnx/zynqmp_dp.c
2278
.attach = zynqmp_dp_bridge_attach,
drivers/iio/buffer/industrialio-buffer-dma.c
673
struct dma_buf_attachment *attach)
drivers/iio/buffer/industrialio-buffer-dma.c
687
block = iio_dma_buffer_alloc_block(queue, attach->dmabuf->size, false);
drivers/iio/industrialio-buffer.c
1564
struct dma_buf_attachment *attach = priv->attach;
drivers/iio/industrialio-buffer.c
1566
struct dma_buf *dmabuf = attach->dmabuf;
drivers/iio/industrialio-buffer.c
1568
dma_buf_unmap_attachment_unlocked(attach, priv->sgt, priv->dir);
drivers/iio/industrialio-buffer.c
1572
dma_buf_detach(attach->dmabuf, attach);
drivers/iio/industrialio-buffer.c
1577
static void iio_buffer_dmabuf_get(struct dma_buf_attachment *attach)
drivers/iio/industrialio-buffer.c
1579
struct iio_dmabuf_priv *priv = attach->importer_priv;
drivers/iio/industrialio-buffer.c
1584
static void iio_buffer_dmabuf_put(struct dma_buf_attachment *attach)
drivers/iio/industrialio-buffer.c
1586
struct iio_dmabuf_priv *priv = attach->importer_priv;
drivers/iio/industrialio-buffer.c
1605
iio_buffer_dmabuf_put(priv->attach);
drivers/iio/industrialio-buffer.c
1641
struct dma_buf_attachment *attach = NULL;
drivers/iio/industrialio-buffer.c
1647
if (priv->attach->dev == dma_dev
drivers/iio/industrialio-buffer.c
1648
&& priv->attach->dmabuf == dmabuf) {
drivers/iio/industrialio-buffer.c
1649
attach = priv->attach;
drivers/iio/industrialio-buffer.c
1654
if (attach)
drivers/iio/industrialio-buffer.c
1655
iio_buffer_dmabuf_get(attach);
drivers/iio/industrialio-buffer.c
1657
return attach ?: ERR_PTR(-EPERM);
drivers/iio/industrialio-buffer.c
1666
struct dma_buf_attachment *attach;
drivers/iio/industrialio-buffer.c
1692
attach = dma_buf_attach(dmabuf, dma_dev);
drivers/iio/industrialio-buffer.c
1693
if (IS_ERR(attach)) {
drivers/iio/industrialio-buffer.c
1694
err = PTR_ERR(attach);
drivers/iio/industrialio-buffer.c
1705
priv->sgt = dma_buf_map_attachment(attach, priv->dir);
drivers/iio/industrialio-buffer.c
1714
priv->attach = attach;
drivers/iio/industrialio-buffer.c
1715
attach->importer_priv = priv;
drivers/iio/industrialio-buffer.c
1717
priv->block = buffer->access->attach_dmabuf(buffer, attach);
drivers/iio/industrialio-buffer.c
1732
if (each->attach->dev == dma_dev
drivers/iio/industrialio-buffer.c
1733
&& each->attach->dmabuf == dmabuf) {
drivers/iio/industrialio-buffer.c
1741
iio_buffer_dmabuf_put(attach);
drivers/iio/industrialio-buffer.c
1753
dma_buf_unmap_attachment(attach, priv->sgt, priv->dir);
drivers/iio/industrialio-buffer.c
1757
dma_buf_detach(dmabuf, attach);
drivers/iio/industrialio-buffer.c
1786
if (priv->attach->dev == dma_dev
drivers/iio/industrialio-buffer.c
1787
&& priv->attach->dmabuf == dmabuf) {
drivers/iio/industrialio-buffer.c
1791
iio_buffer_dmabuf_put(priv->attach);
drivers/iio/industrialio-buffer.c
1828
struct dma_buf_attachment *attach;
drivers/iio/industrialio-buffer.c
1859
attach = iio_buffer_find_attachment(ib, dmabuf, nonblock);
drivers/iio/industrialio-buffer.c
1860
if (IS_ERR(attach)) {
drivers/iio/industrialio-buffer.c
1861
ret = PTR_ERR(attach);
drivers/iio/industrialio-buffer.c
1865
priv = attach->importer_priv;
drivers/iio/industrialio-buffer.c
1943
iio_buffer_dmabuf_put(attach);
drivers/iio/industrialio-buffer.c
1955
struct dma_buf_attachment *attach = priv->attach;
drivers/iio/industrialio-buffer.c
1958
iio_buffer_dmabuf_put(attach);
drivers/iio/industrialio-buffer.c
53
struct dma_buf_attachment *attach;
drivers/infiniband/core/umem_dmabuf.c
109
dma_buf_unmap_attachment(umem_dmabuf->attach, umem_dmabuf->sgt,
drivers/infiniband/core/umem_dmabuf.c
155
umem_dmabuf->attach = dma_buf_dynamic_attach(
drivers/infiniband/core/umem_dmabuf.c
160
if (IS_ERR(umem_dmabuf->attach)) {
drivers/infiniband/core/umem_dmabuf.c
161
ret = ERR_CAST(umem_dmabuf->attach);
drivers/infiniband/core/umem_dmabuf.c
185
ib_umem_dmabuf_unsupported_move_notify(struct dma_buf_attachment *attach)
drivers/infiniband/core/umem_dmabuf.c
187
struct ib_umem_dmabuf *umem_dmabuf = attach->importer_priv;
drivers/infiniband/core/umem_dmabuf.c
213
dma_resv_lock(umem_dmabuf->attach->dmabuf->resv, NULL);
drivers/infiniband/core/umem_dmabuf.c
214
err = dma_buf_pin(umem_dmabuf->attach);
drivers/infiniband/core/umem_dmabuf.c
222
dma_resv_unlock(umem_dmabuf->attach->dmabuf->resv);
drivers/infiniband/core/umem_dmabuf.c
227
dma_resv_unlock(umem_dmabuf->attach->dmabuf->resv);
drivers/infiniband/core/umem_dmabuf.c
24
dma_resv_assert_held(umem_dmabuf->attach->dmabuf->resv);
drivers/infiniband/core/umem_dmabuf.c
245
struct dma_buf *dmabuf = umem_dmabuf->attach->dmabuf;
drivers/infiniband/core/umem_dmabuf.c
252
dma_buf_unpin(umem_dmabuf->attach);
drivers/infiniband/core/umem_dmabuf.c
263
struct dma_buf *dmabuf = umem_dmabuf->attach->dmabuf;
drivers/infiniband/core/umem_dmabuf.c
267
dma_buf_detach(dmabuf, umem_dmabuf->attach);
drivers/infiniband/core/umem_dmabuf.c
32
sgt = dma_buf_map_attachment(umem_dmabuf->attach,
drivers/infiniband/core/umem_dmabuf.c
75
ret = dma_resv_wait_timeout(umem_dmabuf->attach->dmabuf->resv,
drivers/infiniband/core/umem_dmabuf.c
88
dma_resv_assert_held(umem_dmabuf->attach->dmabuf->resv);
drivers/infiniband/core/uverbs_std_types_dmabuf.c
57
static int uverbs_dmabuf_pin(struct dma_buf_attachment *attach)
drivers/infiniband/core/uverbs_std_types_dmabuf.c
62
static void uverbs_dmabuf_unpin(struct dma_buf_attachment *attach)
drivers/infiniband/core/uverbs_std_types_dmabuf.c
80
.attach = uverbs_dmabuf_attach,
drivers/infiniband/hw/mlx5/mr.c
1606
static void mlx5_ib_dmabuf_invalidate_cb(struct dma_buf_attachment *attach)
drivers/infiniband/hw/mlx5/mr.c
1608
struct ib_umem_dmabuf *umem_dmabuf = attach->importer_priv;
drivers/infiniband/hw/mlx5/mr.c
1611
dma_resv_assert_held(umem_dmabuf->attach->dmabuf->resv);
drivers/infiniband/hw/mlx5/mr.c
2108
dma_resv_lock(to_ib_umem_dmabuf(mr->umem)->attach->dmabuf->resv,
drivers/infiniband/hw/mlx5/mr.c
2123
to_ib_umem_dmabuf(mr->umem)->attach->dmabuf->resv);
drivers/infiniband/hw/mlx5/mr.c
2166
dma_resv_lock(to_ib_umem_dmabuf(mr->umem)->attach->dmabuf->resv,
drivers/infiniband/hw/mlx5/mr.c
2179
to_ib_umem_dmabuf(mr->umem)->attach->dmabuf->resv);
drivers/infiniband/hw/mlx5/odp.c
847
dma_resv_lock(umem_dmabuf->attach->dmabuf->resv, NULL);
drivers/infiniband/hw/mlx5/odp.c
850
dma_resv_unlock(umem_dmabuf->attach->dmabuf->resv);
drivers/infiniband/hw/mlx5/odp.c
873
dma_resv_unlock(umem_dmabuf->attach->dmabuf->resv);
drivers/iommu/iommufd/device.c
355
struct iommufd_attach *attach;
drivers/iommu/iommufd/device.c
362
attach = xa_load(&igroup->pasid_attach, pasid);
drivers/iommu/iommufd/device.c
363
if (attach)
drivers/iommu/iommufd/device.c
364
xa_for_each(&attach->device_array, index, idev)
drivers/iommu/iommufd/device.c
443
struct iommufd_attach *attach;
drivers/iommu/iommufd/device.c
445
attach = xa_load(&idev->igroup->pasid_attach, pasid);
drivers/iommu/iommufd/device.c
446
return xa_load(&attach->device_array, idev->obj.id);
drivers/iommu/iommufd/device.c
465
struct iommufd_attach *attach;
drivers/iommu/iommufd/device.c
470
attach = xa_load(&igroup->pasid_attach, IOMMU_NO_PASID);
drivers/iommu/iommufd/device.c
471
if (attach && attach->hwpt && !attach->hwpt->pasid_compat)
drivers/iommu/iommufd/device.c
609
struct iommufd_attach *attach;
drivers/iommu/iommufd/device.c
614
attach = xa_cmpxchg(&igroup->pasid_attach, pasid, NULL,
drivers/iommu/iommufd/device.c
616
if (xa_is_err(attach)) {
drivers/iommu/iommufd/device.c
617
rc = xa_err(attach);
drivers/iommu/iommufd/device.c
621
if (!attach) {
drivers/iommu/iommufd/device.c
622
attach = kzalloc_obj(*attach);
drivers/iommu/iommufd/device.c
623
if (!attach) {
drivers/iommu/iommufd/device.c
627
xa_init(&attach->device_array);
drivers/iommu/iommufd/device.c
630
old_hwpt = attach->hwpt;
drivers/iommu/iommufd/device.c
632
rc = xa_insert(&attach->device_array, idev->obj.id, XA_ZERO_ENTRY,
drivers/iommu/iommufd/device.c
661
attach->hwpt = hwpt;
drivers/iommu/iommufd/device.c
662
WARN_ON(xa_is_err(xa_store(&igroup->pasid_attach, pasid, attach,
drivers/iommu/iommufd/device.c
666
WARN_ON(xa_is_err(xa_store(&attach->device_array, idev->obj.id,
drivers/iommu/iommufd/device.c
674
xa_release(&attach->device_array, idev->obj.id);
drivers/iommu/iommufd/device.c
677
kfree(attach);
drivers/iommu/iommufd/device.c
692
struct iommufd_attach *attach;
drivers/iommu/iommufd/device.c
695
attach = xa_load(&igroup->pasid_attach, pasid);
drivers/iommu/iommufd/device.c
696
if (!attach) {
drivers/iommu/iommufd/device.c
701
hwpt = attach->hwpt;
drivers/iommu/iommufd/device.c
704
xa_erase(&attach->device_array, idev->obj.id);
drivers/iommu/iommufd/device.c
705
if (xa_empty(&attach->device_array)) {
drivers/iommu/iommufd/device.c
708
kfree(attach);
drivers/iommu/iommufd/device.c
736
struct iommufd_attach *attach;
drivers/iommu/iommufd/device.c
742
attach = xa_load(&igroup->pasid_attach, IOMMU_NO_PASID);
drivers/iommu/iommufd/device.c
743
xa_for_each(&attach->device_array, index, cur)
drivers/iommu/iommufd/device.c
752
struct iommufd_attach *attach;
drivers/iommu/iommufd/device.c
759
attach = xa_load(&igroup->pasid_attach, IOMMU_NO_PASID);
drivers/iommu/iommufd/device.c
760
old_hwpt_paging = find_hwpt_paging(attach->hwpt);
drivers/iommu/iommufd/device.c
762
xa_for_each(&attach->device_array, index, cur) {
drivers/iommu/iommufd/device.c
789
struct iommufd_attach *attach;
drivers/iommu/iommufd/device.c
795
attach = xa_load(&igroup->pasid_attach, pasid);
drivers/iommu/iommufd/device.c
796
if (!attach) {
drivers/iommu/iommufd/device.c
801
old_hwpt = attach->hwpt;
drivers/iommu/iommufd/device.c
803
WARN_ON(!old_hwpt || xa_empty(&attach->device_array));
drivers/iommu/iommufd/device.c
830
attach->hwpt = hwpt;
drivers/iommu/iommufd/io_pagetable.h
204
struct dma_buf_attachment *attach;
drivers/iommu/iommufd/pages.c
1434
static void iopt_revoke_notify(struct dma_buf_attachment *attach)
drivers/iommu/iommufd/pages.c
1436
struct iopt_pages *pages = attach->importer_priv;
drivers/iommu/iommufd/pages.c
1487
struct dma_buf_attachment *attach;
drivers/iommu/iommufd/pages.c
1490
attach = dma_buf_dynamic_attach(dmabuf, iommufd_global_device(),
drivers/iommu/iommufd/pages.c
1492
if (IS_ERR(attach))
drivers/iommu/iommufd/pages.c
1493
return PTR_ERR(attach);
drivers/iommu/iommufd/pages.c
1505
rc = sym_vfio_pci_dma_buf_iommufd_map(attach, &pages->dmabuf.phys);
drivers/iommu/iommufd/pages.c
1512
pages->dmabuf.attach = attach;
drivers/iommu/iommufd/pages.c
1517
dma_buf_detach(dmabuf, attach);
drivers/iommu/iommufd/pages.c
1657
if (iopt_is_dmabuf(pages) && pages->dmabuf.attach) {
drivers/iommu/iommufd/pages.c
1658
struct dma_buf *dmabuf = pages->dmabuf.attach->dmabuf;
drivers/iommu/iommufd/pages.c
1660
dma_buf_detach(dmabuf, pages->dmabuf.attach);
drivers/iommu/iommufd/selftest.c
1997
.attach = iommufd_test_dma_buf_attach,
drivers/md/bcache/sysfs.c
57
write_attribute(attach);
drivers/media/common/b2c2/flexcop-fe-tuner.c
666
int (*attach)(struct flexcop_device *, struct i2c_adapter *);
drivers/media/common/b2c2/flexcop-fe-tuner.c
685
if (!flexcop_frontends[i].attach)
drivers/media/common/b2c2/flexcop-fe-tuner.c
690
if (flexcop_frontends[i].attach(fc, &fc->fc_i2c_adap[0].i2c_adap))
drivers/media/common/saa7146/saa7146_core.c
448
if (ext->attach(dev, pci_ext)) {
drivers/media/common/videobuf2/videobuf2-dma-contig.c
321
struct vb2_dc_attachment *attach;
drivers/media/common/videobuf2/videobuf2-dma-contig.c
328
attach = kzalloc_obj(*attach);
drivers/media/common/videobuf2/videobuf2-dma-contig.c
329
if (!attach)
drivers/media/common/videobuf2/videobuf2-dma-contig.c
332
sgt = &attach->sgt;
drivers/media/common/videobuf2/videobuf2-dma-contig.c
338
kfree(attach);
drivers/media/common/videobuf2/videobuf2-dma-contig.c
350
attach->dma_dir = DMA_NONE;
drivers/media/common/videobuf2/videobuf2-dma-contig.c
351
dbuf_attach->priv = attach;
drivers/media/common/videobuf2/videobuf2-dma-contig.c
359
struct vb2_dc_attachment *attach = db_attach->priv;
drivers/media/common/videobuf2/videobuf2-dma-contig.c
362
if (!attach)
drivers/media/common/videobuf2/videobuf2-dma-contig.c
365
sgt = &attach->sgt;
drivers/media/common/videobuf2/videobuf2-dma-contig.c
368
if (attach->dma_dir != DMA_NONE)
drivers/media/common/videobuf2/videobuf2-dma-contig.c
375
dma_unmap_sgtable(db_attach->dev, sgt, attach->dma_dir,
drivers/media/common/videobuf2/videobuf2-dma-contig.c
378
kfree(attach);
drivers/media/common/videobuf2/videobuf2-dma-contig.c
385
struct vb2_dc_attachment *attach = db_attach->priv;
drivers/media/common/videobuf2/videobuf2-dma-contig.c
388
sgt = &attach->sgt;
drivers/media/common/videobuf2/videobuf2-dma-contig.c
390
if (attach->dma_dir == dma_dir)
drivers/media/common/videobuf2/videobuf2-dma-contig.c
394
if (attach->dma_dir != DMA_NONE) {
drivers/media/common/videobuf2/videobuf2-dma-contig.c
395
dma_unmap_sgtable(db_attach->dev, sgt, attach->dma_dir,
drivers/media/common/videobuf2/videobuf2-dma-contig.c
397
attach->dma_dir = DMA_NONE;
drivers/media/common/videobuf2/videobuf2-dma-contig.c
410
attach->dma_dir = dma_dir;
drivers/media/common/videobuf2/videobuf2-dma-contig.c
463
.attach = vb2_dc_dmabuf_ops_attach,
drivers/media/common/videobuf2/videobuf2-dma-sg.c
371
struct vb2_dma_sg_attachment *attach;
drivers/media/common/videobuf2/videobuf2-dma-sg.c
378
attach = kzalloc_obj(*attach);
drivers/media/common/videobuf2/videobuf2-dma-sg.c
379
if (!attach)
drivers/media/common/videobuf2/videobuf2-dma-sg.c
382
sgt = &attach->sgt;
drivers/media/common/videobuf2/videobuf2-dma-sg.c
388
kfree(attach);
drivers/media/common/videobuf2/videobuf2-dma-sg.c
400
attach->dma_dir = DMA_NONE;
drivers/media/common/videobuf2/videobuf2-dma-sg.c
401
dbuf_attach->priv = attach;
drivers/media/common/videobuf2/videobuf2-dma-sg.c
409
struct vb2_dma_sg_attachment *attach = db_attach->priv;
drivers/media/common/videobuf2/videobuf2-dma-sg.c
412
if (!attach)
drivers/media/common/videobuf2/videobuf2-dma-sg.c
415
sgt = &attach->sgt;
drivers/media/common/videobuf2/videobuf2-dma-sg.c
418
if (attach->dma_dir != DMA_NONE)
drivers/media/common/videobuf2/videobuf2-dma-sg.c
419
dma_unmap_sgtable(db_attach->dev, sgt, attach->dma_dir, 0);
drivers/media/common/videobuf2/videobuf2-dma-sg.c
421
kfree(attach);
drivers/media/common/videobuf2/videobuf2-dma-sg.c
428
struct vb2_dma_sg_attachment *attach = db_attach->priv;
drivers/media/common/videobuf2/videobuf2-dma-sg.c
431
sgt = &attach->sgt;
drivers/media/common/videobuf2/videobuf2-dma-sg.c
433
if (attach->dma_dir == dma_dir)
drivers/media/common/videobuf2/videobuf2-dma-sg.c
437
if (attach->dma_dir != DMA_NONE) {
drivers/media/common/videobuf2/videobuf2-dma-sg.c
438
dma_unmap_sgtable(db_attach->dev, sgt, attach->dma_dir, 0);
drivers/media/common/videobuf2/videobuf2-dma-sg.c
439
attach->dma_dir = DMA_NONE;
drivers/media/common/videobuf2/videobuf2-dma-sg.c
448
attach->dma_dir = dma_dir;
drivers/media/common/videobuf2/videobuf2-dma-sg.c
510
.attach = vb2_dma_sg_dmabuf_ops_attach,
drivers/media/common/videobuf2/videobuf2-vmalloc.c
215
struct vb2_vmalloc_attachment *attach;
drivers/media/common/videobuf2/videobuf2-vmalloc.c
224
attach = kzalloc_obj(*attach);
drivers/media/common/videobuf2/videobuf2-vmalloc.c
225
if (!attach)
drivers/media/common/videobuf2/videobuf2-vmalloc.c
228
sgt = &attach->sgt;
drivers/media/common/videobuf2/videobuf2-vmalloc.c
231
kfree(attach);
drivers/media/common/videobuf2/videobuf2-vmalloc.c
239
kfree(attach);
drivers/media/common/videobuf2/videobuf2-vmalloc.c
246
attach->dma_dir = DMA_NONE;
drivers/media/common/videobuf2/videobuf2-vmalloc.c
247
dbuf_attach->priv = attach;
drivers/media/common/videobuf2/videobuf2-vmalloc.c
254
struct vb2_vmalloc_attachment *attach = db_attach->priv;
drivers/media/common/videobuf2/videobuf2-vmalloc.c
257
if (!attach)
drivers/media/common/videobuf2/videobuf2-vmalloc.c
260
sgt = &attach->sgt;
drivers/media/common/videobuf2/videobuf2-vmalloc.c
263
if (attach->dma_dir != DMA_NONE)
drivers/media/common/videobuf2/videobuf2-vmalloc.c
264
dma_unmap_sgtable(db_attach->dev, sgt, attach->dma_dir, 0);
drivers/media/common/videobuf2/videobuf2-vmalloc.c
266
kfree(attach);
drivers/media/common/videobuf2/videobuf2-vmalloc.c
273
struct vb2_vmalloc_attachment *attach = db_attach->priv;
drivers/media/common/videobuf2/videobuf2-vmalloc.c
276
sgt = &attach->sgt;
drivers/media/common/videobuf2/videobuf2-vmalloc.c
278
if (attach->dma_dir == dma_dir)
drivers/media/common/videobuf2/videobuf2-vmalloc.c
282
if (attach->dma_dir != DMA_NONE) {
drivers/media/common/videobuf2/videobuf2-vmalloc.c
283
dma_unmap_sgtable(db_attach->dev, sgt, attach->dma_dir, 0);
drivers/media/common/videobuf2/videobuf2-vmalloc.c
284
attach->dma_dir = DMA_NONE;
drivers/media/common/videobuf2/videobuf2-vmalloc.c
293
attach->dma_dir = dma_dir;
drivers/media/common/videobuf2/videobuf2-vmalloc.c
327
.attach = vb2_vmalloc_dmabuf_ops_attach,
drivers/media/pci/saa7146/hexium_gemini.c
399
.attach = hexium_attach,
drivers/media/pci/saa7146/hexium_orion.c
471
.attach = hexium_attach,
drivers/media/pci/saa7146/mxb.c
851
.attach = mxb_attach,
drivers/media/pci/ttpci/budget-av.c
1603
.attach = budget_av_attach,
drivers/media/pci/ttpci/budget-ci.c
1552
.attach = budget_ci_attach,
drivers/media/pci/ttpci/budget.c
874
.attach = budget_attach,
drivers/misc/fastrpc.c
219
struct dma_buf_attachment *attach;
drivers/misc/fastrpc.c
357
dma_buf_unmap_attachment_unlocked(map->attach, map->table,
drivers/misc/fastrpc.c
359
dma_buf_detach(map->buf, map->attach);
drivers/misc/fastrpc.c
685
static void fastrpc_unmap_dma_buf(struct dma_buf_attachment *attach,
drivers/misc/fastrpc.c
689
dma_unmap_sgtable(attach->dev, table, dir, 0);
drivers/misc/fastrpc.c
765
.attach = fastrpc_dma_buf_attach,
drivers/misc/fastrpc.c
803
map->attach = dma_buf_attach(map->buf, sess->dev);
drivers/misc/fastrpc.c
804
if (IS_ERR(map->attach)) {
drivers/misc/fastrpc.c
806
err = PTR_ERR(map->attach);
drivers/misc/fastrpc.c
810
table = dma_buf_map_attachment_unlocked(map->attach, DMA_BIDIRECTIONAL);
drivers/misc/fastrpc.c
862
dma_buf_detach(map->buf, map->attach);
drivers/misc/vmw_vmci/vmci_queue_pair.c
1451
static int qp_notify_peer(bool attach,
drivers/misc/vmw_vmci/vmci_queue_pair.c
1476
ev.msg.event_data.event = attach ?
drivers/misc/vmw_vmci/vmci_queue_pair.c
1485
attach ? "ATTACH" : "DETACH", peer_id);
drivers/misc/vmw_vmci/vmci_queue_pair.c
852
static int qp_notify_peer_local(bool attach, struct vmci_handle handle)
drivers/misc/vmw_vmci/vmci_queue_pair.c
863
attach ? VMCI_EVENT_QP_PEER_ATTACH : VMCI_EVENT_QP_PEER_DETACH;
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1528
u16 pcifunc, struct rsrc_attach *attach)
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1537
if (attach->hdr.ver < RVU_MULTI_BLK_VER)
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1539
blkaddr = attach->cpt_blkaddr ? attach->cpt_blkaddr :
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1555
int num_lfs, struct rsrc_attach *attach)
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1567
blkaddr = rvu_get_attach_blkaddr(rvu, blktype, pcifunc, attach);
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1706
struct rsrc_attach *attach)
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1711
attach->hdr.pcifunc, attach);
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1715
num_lfs = rvu_get_rsrc_mapcount(rvu_get_pfvf(rvu, attach->hdr.pcifunc),
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1722
struct rsrc_attach *attach,
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1725
u16 pcifunc = attach->hdr.pcifunc;
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1729
if (!attach->modify) {
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1738
err = rvu_check_rsrc_availability(rvu, attach, pcifunc);
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1743
if (attach->npalf) {
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1744
err = rvu_attach_block(rvu, pcifunc, BLKTYPE_NPA, 1, attach);
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1749
if (attach->nixlf) {
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1750
err = rvu_attach_block(rvu, pcifunc, BLKTYPE_NIX, 1, attach);
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1755
if (attach->sso) {
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1761
if (attach->modify)
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1764
attach->sso, attach);
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1769
if (attach->ssow) {
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1770
if (attach->modify)
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1773
attach->ssow, attach);
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1778
if (attach->timlfs) {
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1779
if (attach->modify)
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1782
attach->timlfs, attach);
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1787
if (attach->cptlfs) {
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1788
if (attach->modify &&
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1789
rvu_attach_from_same_block(rvu, BLKTYPE_CPT, attach))
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1792
attach->cptlfs, attach);
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1801
if (attach->timlfs)
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1805
if (attach->ssow)
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1809
if (attach->sso)
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1813
if (attach->nixlf)
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
1817
if (attach->npalf)
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
343
u16 lf, bool attach)
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
365
block->fn_map[lf] = attach ? pcifunc : 0;
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
369
pfvf->npalf = attach ? true : false;
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
374
pfvf->nixlf = attach ? true : false;
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
378
attach ? pfvf->sso++ : pfvf->sso--;
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
382
attach ? pfvf->ssow++ : pfvf->ssow--;
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
386
attach ? pfvf->timlfs++ : pfvf->timlfs--;
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
390
attach ? pfvf->cptlfs++ : pfvf->cptlfs--;
drivers/net/ethernet/marvell/octeontx2/af/rvu.c
394
attach ? pfvf->cpt1_lfs++ : pfvf->cpt1_lfs--;
drivers/net/ethernet/marvell/octeontx2/nic/cn10k_ipsec.c
51
struct rsrc_attach *attach;
drivers/net/ethernet/marvell/octeontx2/nic/cn10k_ipsec.c
56
attach = otx2_mbox_alloc_msg_attach_resources(&pf->mbox);
drivers/net/ethernet/marvell/octeontx2/nic/cn10k_ipsec.c
57
if (!attach)
drivers/net/ethernet/marvell/octeontx2/nic/cn10k_ipsec.c
60
attach->cptlfs = true;
drivers/net/ethernet/marvell/octeontx2/nic/cn10k_ipsec.c
61
attach->modify = true;
drivers/net/ethernet/marvell/octeontx2/nic/otx2_common.c
1734
struct rsrc_attach *attach;
drivers/net/ethernet/marvell/octeontx2/nic/otx2_common.c
1740
attach = otx2_mbox_alloc_msg_attach_resources(&pfvf->mbox);
drivers/net/ethernet/marvell/octeontx2/nic/otx2_common.c
1741
if (!attach) {
drivers/net/ethernet/marvell/octeontx2/nic/otx2_common.c
1746
attach->npalf = true;
drivers/net/ethernet/marvell/octeontx2/nic/otx2_common.c
1747
attach->nixlf = true;
drivers/net/ethernet/mediatek/mtk_wed.c
2777
.attach = mtk_wed_attach,
drivers/net/ethernet/mellanox/mlx4/mcg.c
1336
u8 gid[16], u8 attach, u8 block_loopback,
drivers/net/ethernet/mellanox/mlx4/mcg.c
1353
if (attach && block_loopback)
drivers/net/ethernet/mellanox/mlx4/mcg.c
1356
err = mlx4_cmd(dev, mailbox->dma, qpn, attach,
drivers/net/ethernet/mellanox/mlx4/mcg.c
1361
if (err && !attach &&
drivers/net/ethernet/mellanox/mlx4/resource_tracker.c
4144
int attach = vhcr->op_modifier;
drivers/net/ethernet/mellanox/mlx4/resource_tracker.c
4155
if (attach) {
drivers/net/ethernet/mellanox/mlx5/core/en/mapping.c
56
goto attach;
drivers/net/ethernet/mellanox/mlx5/core/en/mapping.c
70
attach:
drivers/net/ethernet/qlogic/qlcnic/qlcnic_dcb.c
172
.attach = __qlcnic_dcb_attach,
drivers/net/ethernet/qlogic/qlcnic/qlcnic_dcb.c
185
.attach = __qlcnic_dcb_attach,
drivers/net/ethernet/qlogic/qlcnic/qlcnic_dcb.h
30
int (*attach) (struct qlcnic_dcb *);
drivers/net/ethernet/qlogic/qlcnic/qlcnic_dcb.h
60
if (dcb && dcb->ops->attach)
drivers/net/ethernet/qlogic/qlcnic/qlcnic_dcb.h
61
return dcb->ops->attach(dcb);
drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c
3610
goto attach;
drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c
3614
attach:
drivers/net/ethernet/ti/netcp.h
199
int (*attach)(void *inst_priv, struct net_device *ndev,
drivers/net/ethernet/ti/netcp_core.c
321
ret = module->attach(inst_modpriv->module_priv,
drivers/net/ethernet/ti/netcp_ethss.c
3824
.attach = gbe_attach,
drivers/net/ethernet/ti/netcp_ethss.c
3843
.attach = gbe_attach,
drivers/net/phy/phy_device.c
1613
.attach = phy_sfp_attach,
drivers/net/phy/phylink.c
3950
.attach = phylink_sfp_attach,
drivers/net/phy/sfp-bus.c
456
bus->socket_ops->attach(bus->sfp);
drivers/net/phy/sfp-bus.c
459
bus->upstream_ops->attach(bus->upstream, bus);
drivers/net/phy/sfp.c
2979
.attach = sfp_attach,
drivers/net/phy/sfp.h
18
void (*attach)(struct sfp *sfp);
drivers/net/wan/c101.c
367
hdlc->attach = sca_attach;
drivers/net/wan/farsync.c
2453
hdlc->attach = fst_attach;
drivers/net/wan/fsl_qmc_hdlc.c
760
hdlc->attach = qmc_hdlc_attach;
drivers/net/wan/fsl_ucc_hdlc.c
1226
hdlc->attach = ucc_hdlc_attach;
drivers/net/wan/hdlc_cisco.c
344
result = hdlc->attach(dev, ENCODING_NRZ,
drivers/net/wan/hdlc_fr.c
1233
result = hdlc->attach(dev, ENCODING_NRZ,
drivers/net/wan/hdlc_ppp.c
678
result = hdlc->attach(dev, ENCODING_NRZ,
drivers/net/wan/hdlc_raw.c
73
result = hdlc->attach(dev, new_settings.encoding,
drivers/net/wan/hdlc_raw_eth.c
89
result = hdlc->attach(dev, new_settings.encoding,
drivers/net/wan/hdlc_x25.c
335
result = hdlc->attach(dev, ENCODING_NRZ,
drivers/net/wan/ixp4xx_hss.c
1498
hdlc->attach = hss_hdlc_attach;
drivers/net/wan/n2.c
454
hdlc->attach = sca_attach;
drivers/net/wan/pc300too.c
441
hdlc->attach = sca_attach;
drivers/net/wan/pci200syn.c
380
hdlc->attach = sca_attach;
drivers/net/wan/wanxl.c
781
hdlc->attach = wanxl_attach;
drivers/net/wireless/rsi/rsi_91x_main.c
289
if (rsi_bt_ops.attach(common, &g_proto_ops))
drivers/nvdimm/claim.c
43
bool __nd_attach_ndns(struct device *dev, struct nd_namespace_common *attach,
drivers/nvdimm/claim.c
46
struct nvdimm_bus *nvdimm_bus = walk_to_nvdimm_bus(&attach->dev);
drivers/nvdimm/claim.c
48
if (attach->claim)
drivers/nvdimm/claim.c
52
attach->claim = dev;
drivers/nvdimm/claim.c
53
*_ndns = attach;
drivers/nvdimm/claim.c
54
get_device(&attach->dev);
drivers/nvdimm/nd-core.h
137
bool __nd_attach_ndns(struct device *dev, struct nd_namespace_common *attach,
drivers/platform/arm64/acer-aspire1-ec.c
396
.attach = aspire_ec_bridge_attach,
drivers/power/supply/mt6370-charger.c
100
int attach;
drivers/power/supply/mt6370-charger.c
260
unsigned int attach, usb_stat;
drivers/power/supply/mt6370-charger.c
263
attach = priv->attach;
drivers/power/supply/mt6370-charger.c
265
switch (attach) {
drivers/power/supply/mt6370-charger.c
270
ret = mt6370_chg_field_set(priv, F_USBCHGEN, attach);
drivers/power/supply/mt6370-charger.c
429
val->intval = !!priv->attach;
drivers/power/supply/mt6370-charger.c
515
if (pwr_rdy == !!priv->attach) {
drivers/power/supply/mt6370-charger.c
521
priv->attach = pwr_rdy;
drivers/power/supply/mt6370-charger.c
788
priv->attach = MT6370_ATTACH_STAT_ATTACH_BC12_DONE;
drivers/power/supply/mt6370-charger.c
894
priv->attach = MT6370_ATTACH_STAT_DETACH;
drivers/power/supply/rt9467-charger.c
1007
RT9467_IRQ_DESC(attach, usb_state, RT9467_IRQ_ATTACH),
drivers/remoteproc/imx_rproc.c
744
.attach = imx_rproc_attach,
drivers/remoteproc/remoteproc_core.c
2244
if (!rproc->ops->attach)
drivers/remoteproc/remoteproc_internal.h
143
if (rproc->ops->attach)
drivers/remoteproc/remoteproc_internal.h
144
return rproc->ops->attach(rproc);
drivers/remoteproc/stm32_rproc.c
659
.attach = stm32_rproc_attach,
drivers/remoteproc/ti_k3_dsp_remoteproc.c
62
.attach = k3_rproc_attach,
drivers/remoteproc/ti_k3_m4_remoteproc.c
29
.attach = k3_rproc_attach,
drivers/remoteproc/ti_k3_r5_remoteproc.c
890
kproc->rproc->ops->attach = k3_rproc_attach;
drivers/remoteproc/xlnx_r5_remoteproc.c
891
.attach = zynqmp_r5_attach,
drivers/scsi/device_handler/scsi_dh_alua.c
1290
.attach = alua_bus_attach,
drivers/scsi/device_handler/scsi_dh_emc.c
519
.attach = clariion_bus_attach,
drivers/scsi/device_handler/scsi_dh_hp_sw.c
264
.attach = hp_sw_bus_attach,
drivers/scsi/device_handler/scsi_dh_rdac.c
807
.attach = rdac_bus_attach,
drivers/scsi/scsi_dh.c
132
error = scsi_dh->attach(sdev);
drivers/scsi/scsi_dh.c
204
if (!scsi_dh->attach || !scsi_dh->detach)
drivers/staging/media/av7110/av7110.c
2873
.attach = av7110_attach,
drivers/target/iscsi/iscsi_target.c
2047
goto attach;
drivers/target/iscsi/iscsi_target.c
2055
goto attach;
drivers/target/iscsi/iscsi_target.c
2065
goto attach;
drivers/target/iscsi/iscsi_target.c
2071
goto attach;
drivers/target/iscsi/iscsi_target.c
2091
goto attach;
drivers/target/iscsi/iscsi_target.c
2097
attach:
drivers/tee/tee_heap.c
161
.attach = tee_heap_attach,
drivers/tty/synclink_gt.c
1720
hdlc->attach = hdlcdev_attach;
drivers/usb/gadget/function/f_fs.c
1327
struct dma_buf_attachment *attach = priv->attach;
drivers/usb/gadget/function/f_fs.c
1328
struct dma_buf *dmabuf = attach->dmabuf;
drivers/usb/gadget/function/f_fs.c
1331
dma_buf_unmap_attachment_unlocked(attach, priv->sgt, priv->dir);
drivers/usb/gadget/function/f_fs.c
1333
dma_buf_detach(attach->dmabuf, attach);
drivers/usb/gadget/function/f_fs.c
1338
static void ffs_dmabuf_get(struct dma_buf_attachment *attach)
drivers/usb/gadget/function/f_fs.c
1340
struct ffs_dmabuf_priv *priv = attach->importer_priv;
drivers/usb/gadget/function/f_fs.c
1345
static void ffs_dmabuf_put(struct dma_buf_attachment *attach)
drivers/usb/gadget/function/f_fs.c
1347
struct ffs_dmabuf_priv *priv = attach->importer_priv;
drivers/usb/gadget/function/f_fs.c
1370
ffs_dmabuf_put(priv->attach);
drivers/usb/gadget/function/f_fs.c
1386
struct dma_buf_attachment *attach = priv->attach;
drivers/usb/gadget/function/f_fs.c
1389
ffs_dmabuf_put(attach);
drivers/usb/gadget/function/f_fs.c
140
struct dma_buf_attachment *attach;
drivers/usb/gadget/function/f_fs.c
1460
struct dma_buf_attachment *attach = NULL;
drivers/usb/gadget/function/f_fs.c
1466
if (priv->attach->dev == dev
drivers/usb/gadget/function/f_fs.c
1467
&& priv->attach->dmabuf == dmabuf) {
drivers/usb/gadget/function/f_fs.c
1468
attach = priv->attach;
drivers/usb/gadget/function/f_fs.c
1473
if (attach)
drivers/usb/gadget/function/f_fs.c
1474
ffs_dmabuf_get(attach);
drivers/usb/gadget/function/f_fs.c
1478
return attach ?: ERR_PTR(-EPERM);
drivers/usb/gadget/function/f_fs.c
1486
struct dma_buf_attachment *attach;
drivers/usb/gadget/function/f_fs.c
1500
attach = dma_buf_attach(dmabuf, gadget->dev.parent);
drivers/usb/gadget/function/f_fs.c
1501
if (IS_ERR(attach)) {
drivers/usb/gadget/function/f_fs.c
1502
err = PTR_ERR(attach);
drivers/usb/gadget/function/f_fs.c
1518
sg_table = dma_buf_map_attachment(attach, dir);
drivers/usb/gadget/function/f_fs.c
1526
attach->importer_priv = priv;
drivers/usb/gadget/function/f_fs.c
1531
priv->attach = attach;
drivers/usb/gadget/function/f_fs.c
1545
dma_buf_detach(dmabuf, attach);
drivers/usb/gadget/function/f_fs.c
1568
if (priv->attach->dev == dev
drivers/usb/gadget/function/f_fs.c
1569
&& priv->attach->dmabuf == dmabuf) {
drivers/usb/gadget/function/f_fs.c
1579
ffs_dmabuf_put(priv->attach);
drivers/usb/gadget/function/f_fs.c
1596
struct dma_buf_attachment *attach;
drivers/usb/gadget/function/f_fs.c
1621
attach = ffs_dmabuf_find_attachment(epfile, dmabuf);
drivers/usb/gadget/function/f_fs.c
1622
if (IS_ERR(attach)) {
drivers/usb/gadget/function/f_fs.c
1623
ret = PTR_ERR(attach);
drivers/usb/gadget/function/f_fs.c
1627
priv = attach->importer_priv;
drivers/usb/gadget/function/f_fs.c
1725
ffs_dmabuf_put(attach);
drivers/usb/serial/cp210x.c
319
.attach = cp210x_attach,
drivers/usb/serial/digi_acceleport.c
286
.attach = digi_startup,
drivers/usb/serial/digi_acceleport.c
315
.attach = digi_startup,
drivers/usb/serial/empeg.c
53
.attach = empeg_startup,
drivers/usb/serial/io_edgeport.c
2996
.attach = edge_startup,
drivers/usb/serial/io_edgeport.c
3030
.attach = edge_startup,
drivers/usb/serial/io_edgeport.c
3064
.attach = edge_startup,
drivers/usb/serial/io_edgeport.c
3098
.attach = edge_startup,
drivers/usb/serial/io_ti.c
2682
.attach = edge_startup,
drivers/usb/serial/io_ti.c
2719
.attach = edge_startup,
drivers/usb/serial/ipaq.c
506
.attach = ipaq_startup,
drivers/usb/serial/ipw.c
295
.attach = ipw_attach,
drivers/usb/serial/ir-usb.c
82
.attach = ir_startup,
drivers/usb/serial/keyspan.c
3009
.attach = keyspan_fake_startup,
drivers/usb/serial/keyspan.c
3028
.attach = keyspan_startup,
drivers/usb/serial/keyspan.c
3051
.attach = keyspan_startup,
drivers/usb/serial/keyspan.c
3074
.attach = keyspan_startup,
drivers/usb/serial/keyspan_pda.c
684
.attach = keyspan_pda_fake_startup,
drivers/usb/serial/mos7720.c
1739
.attach = mos7720_startup,
drivers/usb/serial/mos7840.c
1785
.attach = mos7840_attach,
drivers/usb/serial/mxuport.c
1289
.attach = mxuport_attach,
drivers/usb/serial/option.c
2542
.attach = option_attach,
drivers/usb/serial/pl2303.c
1297
.attach = pl2303_startup,
drivers/usb/serial/qcserial.c
473
.attach = qc_attach,
drivers/usb/serial/quatech2.c
936
.attach = qt2_attach,
drivers/usb/serial/safe_serial.c
293
.attach = safe_startup,
drivers/usb/serial/sierra.c
1038
.attach = sierra_startup,
drivers/usb/serial/ssu100.c
509
.attach = ssu100_attach,
drivers/usb/serial/ti_usb_3410_5052.c
426
.attach = ti_startup,
drivers/usb/serial/ti_usb_3410_5052.c
458
.attach = ti_startup,
drivers/usb/serial/usb-serial.c
1122
if (type->attach) {
drivers/usb/serial/usb-serial.c
1123
retval = type->attach(serial);
drivers/usb/serial/visor.c
211
.attach = clie_3_5_startup,
drivers/usb/serial/whiteheat.c
100
.attach = whiteheat_firmware_attach,
drivers/usb/serial/whiteheat.c
112
.attach = whiteheat_attach,
drivers/usb/typec/class.c
1123
partner->attach = desc->attach;
drivers/usb/typec/class.c
2752
port->con.attach = typec_partner_attach;
drivers/usb/typec/class.c
902
if (partner->attach)
drivers/usb/typec/class.c
903
partner->attach(partner, dev);
drivers/usb/typec/class.h
45
void (*attach)(struct typec_partner *partner, struct device *dev);
drivers/usb/usbip/vhci_sysfs.c
449
static DEVICE_ATTR_WO(attach);
drivers/vfio/device_cdev.c
197
struct vfio_device_attach_iommufd_pt attach;
drivers/vfio/device_cdev.c
204
if (copy_from_user(&attach, arg, minsz))
drivers/vfio/device_cdev.c
207
if (attach.argsz < minsz)
drivers/vfio/device_cdev.c
210
if (attach.flags & ~VFIO_DEVICE_ATTACH_PASID)
drivers/vfio/device_cdev.c
213
if (attach.flags & VFIO_DEVICE_ATTACH_PASID) {
drivers/vfio/device_cdev.c
220
if (attach.argsz < xend)
drivers/vfio/device_cdev.c
223
if (copy_from_user((void *)&attach + minsz,
drivers/vfio/device_cdev.c
229
if (attach.flags & VFIO_DEVICE_ATTACH_PASID)
drivers/vfio/device_cdev.c
231
attach.pasid,
drivers/vfio/device_cdev.c
232
&attach.pt_id);
drivers/vfio/device_cdev.c
234
ret = device->ops->attach_ioas(device, &attach.pt_id);
drivers/vfio/device_cdev.c
238
if (copy_to_user(&arg->pt_id, &attach.pt_id, sizeof(attach.pt_id))) {
drivers/vfio/pci/vfio_pci_dmabuf.c
91
.attach = vfio_pci_dma_buf_attach,
drivers/vhost/vhost.c
649
struct vhost_attach_cgroups_struct attach;
drivers/vhost/vhost.c
652
attach.owner = current;
drivers/vhost/vhost.c
654
vhost_work_init(&attach.work, vhost_attach_cgroups_work);
drivers/vhost/vhost.c
655
vhost_worker_queue(worker, &attach.work);
drivers/vhost/vhost.c
670
return attach.ret;
drivers/virtio/virtio_dma_buf.c
28
exp_info->ops->attach != &virtio_dma_buf_attach ||
drivers/virtio/virtio_dma_buf.c
43
struct dma_buf_attachment *attach)
drivers/virtio/virtio_dma_buf.c
51
ret = ops->device_attach(dma_buf, attach);
drivers/virtio/virtio_dma_buf.c
65
return dma_buf->ops->attach == &virtio_dma_buf_attach;
drivers/w1/w1.c
865
void w1_reconnect_slaves(struct w1_family *f, int attach)
drivers/w1/w1.c
882
if ((attach && sl->family->fid == W1_FAMILY_DEFAULT
drivers/w1/w1.c
884
(!attach && sl->family->fid == f->fid)) {
drivers/w1/w1_internal.h
56
void w1_reconnect_slaves(struct w1_family *f, int attach);
drivers/xen/gntdev-dmabuf.c
221
struct dma_buf_attachment *attach)
drivers/xen/gntdev-dmabuf.c
230
attach->priv = gntdev_dmabuf_attach;
drivers/xen/gntdev-dmabuf.c
235
struct dma_buf_attachment *attach)
drivers/xen/gntdev-dmabuf.c
237
struct gntdev_dmabuf_attachment *gntdev_dmabuf_attach = attach->priv;
drivers/xen/gntdev-dmabuf.c
244
dma_unmap_sgtable(attach->dev, sgt,
drivers/xen/gntdev-dmabuf.c
252
attach->priv = NULL;
drivers/xen/gntdev-dmabuf.c
257
dmabuf_exp_ops_map_dma_buf(struct dma_buf_attachment *attach,
drivers/xen/gntdev-dmabuf.c
260
struct gntdev_dmabuf_attachment *gntdev_dmabuf_attach = attach->priv;
drivers/xen/gntdev-dmabuf.c
261
struct gntdev_dmabuf *gntdev_dmabuf = attach->dmabuf->priv;
drivers/xen/gntdev-dmabuf.c
265
attach->dev);
drivers/xen/gntdev-dmabuf.c
284
if (dma_map_sgtable(attach->dev, sgt, dir,
drivers/xen/gntdev-dmabuf.c
295
pr_debug("Failed to map sg table for dev %p\n", attach->dev);
drivers/xen/gntdev-dmabuf.c
299
static void dmabuf_exp_ops_unmap_dma_buf(struct dma_buf_attachment *attach,
drivers/xen/gntdev-dmabuf.c
339
.attach = dmabuf_exp_ops_attach,
drivers/xen/gntdev-dmabuf.c
48
struct dma_buf_attachment *attach;
drivers/xen/gntdev-dmabuf.c
561
struct dma_buf_attachment *attach;
drivers/xen/gntdev-dmabuf.c
580
attach = dma_buf_attach(dma_buf, dev);
drivers/xen/gntdev-dmabuf.c
581
if (IS_ERR(attach)) {
drivers/xen/gntdev-dmabuf.c
582
ret = ERR_CAST(attach);
drivers/xen/gntdev-dmabuf.c
586
gntdev_dmabuf->u.imp.attach = attach;
drivers/xen/gntdev-dmabuf.c
588
sgt = dma_buf_map_attachment_unlocked(attach, DMA_BIDIRECTIONAL);
drivers/xen/gntdev-dmabuf.c
603
if (attach->dmabuf->size != gntdev_dmabuf->nr_pages << PAGE_SHIFT) {
drivers/xen/gntdev-dmabuf.c
606
attach->dmabuf->size, gntdev_dmabuf->nr_pages);
drivers/xen/gntdev-dmabuf.c
651
dma_buf_unmap_attachment_unlocked(attach, sgt, DMA_BIDIRECTIONAL);
drivers/xen/gntdev-dmabuf.c
653
dma_buf_detach(dma_buf, attach);
drivers/xen/gntdev-dmabuf.c
686
struct dma_buf_attachment *attach;
drivers/xen/gntdev-dmabuf.c
698
attach = gntdev_dmabuf->u.imp.attach;
drivers/xen/gntdev-dmabuf.c
701
dma_buf_unmap_attachment_unlocked(attach, gntdev_dmabuf->u.imp.sgt,
drivers/xen/gntdev-dmabuf.c
703
dma_buf = attach->dmabuf;
drivers/xen/gntdev-dmabuf.c
704
dma_buf_detach(attach->dmabuf, attach);
include/acpi/acpi_bus.h
135
int (*attach)(struct acpi_device *dev, const struct acpi_device_id *id);
include/drm/bridge/analogix_dp.h
36
int (*attach)(struct analogix_dp_plat_data *, struct drm_bridge *,
include/drm/bridge/dw_mipi_dsi.h
47
int (*attach)(void *priv_data,
include/drm/bridge/dw_mipi_dsi2.h
57
int (*attach)(void *priv_data,
include/drm/bridge/samsung-dsim.h
90
int (*attach)(struct samsung_dsim *dsim, struct mipi_dsi_device *device);
include/drm/drm_bridge.h
78
int (*attach)(struct drm_bridge *bridge, struct drm_encoder *encoder,
include/drm/drm_drv.h
326
struct dma_buf_attachment *attach,
include/drm/drm_gem_dma_helper.h
152
struct dma_buf_attachment *attach,
include/drm/drm_gem_dma_helper.h
227
struct dma_buf_attachment *attach,
include/drm/drm_gem_shmem_helper.h
285
struct dma_buf_attachment *attach,
include/drm/drm_mipi_dsi.h
91
int (*attach)(struct mipi_dsi_host *host,
include/drm/drm_prime.h
81
struct dma_buf_attachment *attach);
include/drm/drm_prime.h
83
struct dma_buf_attachment *attach);
include/drm/drm_prime.h
84
struct sg_table *drm_gem_map_dma_buf(struct dma_buf_attachment *attach,
include/drm/drm_prime.h
86
void drm_gem_unmap_dma_buf(struct dma_buf_attachment *attach,
include/linux/atm_tcp.h
16
int (*attach)(struct atm_vcc *vcc,int itf);
include/linux/cgroup-defs.h
788
void (*attach)(struct cgroup_taskset *tset);
include/linux/comedi/comedidev.h
441
int (*attach)(struct comedi_device *dev, struct comedi_devconfig *it);
include/linux/dma-buf-mapping.h
10
struct sg_table *dma_buf_phys_vec_to_sgt(struct dma_buf_attachment *attach,
include/linux/dma-buf-mapping.h
15
void dma_buf_free_sgt(struct dma_buf_attachment *attach, struct sg_table *sgt,
include/linux/dma-buf.h
101
int (*pin)(struct dma_buf_attachment *attach);
include/linux/dma-buf.h
114
void (*unpin)(struct dma_buf_attachment *attach);
include/linux/dma-buf.h
466
void (*move_notify)(struct dma_buf_attachment *attach);
include/linux/dma-buf.h
567
struct dma_buf_attachment *attach);
include/linux/dma-buf.h
568
int dma_buf_pin(struct dma_buf_attachment *attach);
include/linux/dma-buf.h
569
void dma_buf_unpin(struct dma_buf_attachment *attach);
include/linux/dma-buf.h
587
dma_buf_map_attachment_unlocked(struct dma_buf_attachment *attach,
include/linux/dma-buf.h
589
void dma_buf_unmap_attachment_unlocked(struct dma_buf_attachment *attach,
include/linux/dma-buf.h
64
int (*attach)(struct dma_buf *, struct dma_buf_attachment *);
include/linux/dmaengine.h
578
int (*attach)(struct dma_async_tx_descriptor *desc, void *data,
include/linux/hdlc.h
37
int (*attach)(struct net_device *dev,
include/linux/host1x.h
127
struct dma_buf_attachment *attach;
include/linux/iio/buffer-dma.h
171
struct dma_buf_attachment *attach);
include/linux/iio/buffer_impl.h
88
struct dma_buf_attachment *attach);
include/linux/netfilter.h
474
void (*attach)(struct sk_buff *nskb, const struct sk_buff *skb);
include/linux/remoteproc.h
390
int (*attach)(struct rproc *rproc);
include/linux/sfp.h
566
void (*attach)(void *priv, struct sfp_bus *bus);
include/linux/soc/mediatek/mtk_wed.h
196
int (*attach)(struct mtk_wed_device *dev) __releases(RCU);
include/linux/soc/mediatek/mtk_wed.h
241
ret = dev->ops->attach(dev);
include/linux/usb/serial.h
253
int (*attach)(struct usb_serial *serial);
include/linux/usb/typec.h
249
void (*attach)(struct typec_partner *partner, struct device *dev);
include/linux/usb/typec.h
400
void (*attach)(struct typec_connector *con, struct device *dev);
include/linux/usb/typec.h
406
if (con && con->attach)
include/linux/usb/typec.h
407
con->attach(con, dev);
include/linux/virtio_dma_buf.h
25
struct dma_buf_attachment *attach);
include/linux/virtio_dma_buf.h
30
struct dma_buf_attachment *attach);
include/media/drv-intf/saa7146.h
104
int (*attach)(struct saa7146_dev *, struct saa7146_pci_extension_data *);
include/net/rsi_91x.h
50
int (*attach)(void *priv, struct rsi_proto_ops *ops);
include/net/sch_generic.h
324
void (*attach)(struct Qdisc *sch);
include/rdma/ib_umem.h
33
struct dma_buf_attachment *attach;
include/scsi/scsi_dh.h
57
int (*attach)(struct scsi_device *);
include/trace/events/dma_buf.h
126
TP_PROTO(struct dma_buf *dmabuf, struct dma_buf_attachment *attach,
include/trace/events/dma_buf.h
129
TP_ARGS(dmabuf, attach, is_dynamic, dev)
include/trace/events/dma_buf.h
134
TP_PROTO(struct dma_buf *dmabuf, struct dma_buf_attachment *attach,
include/trace/events/dma_buf.h
137
TP_ARGS(dmabuf, attach, is_dynamic, dev)
include/trace/events/dma_buf.h
37
TP_PROTO(struct dma_buf *dmabuf, struct dma_buf_attachment *attach,
include/trace/events/dma_buf.h
40
TP_ARGS(dmabuf, attach, is_dynamic, dev),
include/trace/events/dma_buf.h
47
__field( struct dma_buf_attachment *, attach)
include/trace/events/dma_buf.h
57
__entry->attach = attach;
include/trace/events/dma_buf.h
64
__entry->attach,
io_uring/zcrx.c
107
dma_buf_unmap_attachment_unlocked(mem->attach, mem->sgt,
io_uring/zcrx.c
109
if (mem->attach)
io_uring/zcrx.c
110
dma_buf_detach(mem->dmabuf, mem->attach);
io_uring/zcrx.c
115
mem->attach = NULL;
io_uring/zcrx.c
145
mem->attach = dma_buf_attach(mem->dmabuf, ifq->dev);
io_uring/zcrx.c
146
if (IS_ERR(mem->attach)) {
io_uring/zcrx.c
147
ret = PTR_ERR(mem->attach);
io_uring/zcrx.c
148
mem->attach = NULL;
io_uring/zcrx.c
152
mem->sgt = dma_buf_map_attachment_unlocked(mem->attach, DMA_FROM_DEVICE);
io_uring/zcrx.h
21
struct dma_buf_attachment *attach;
kernel/cgroup/cgroup.c
2751
if (ss->attach) {
kernel/cgroup/cgroup.c
2753
ss->attach(tset);
kernel/cgroup/cpuset.c
3655
.attach = cpuset_attach,
kernel/cgroup/legacy_freezer.c
471
.attach = freezer_attach,
kernel/events/core.c
15361
.attach = perf_cgroup_attach,
kernel/events/core.c
9230
goto attach;
kernel/events/core.c
9240
attach:
kernel/sched/core.c
10253
.attach = cpu_cgroup_attach,
mm/memcontrol.c
4706
.attach = mem_cgroup_attach,
net/core/netclassid_cgroup.c
152
.attach = cgrp_attach,
net/core/netprio_cgroup.c
260
.attach = net_prio_attach,
net/netfilter/core.c
703
ct_hook->attach(new, skb);
net/netfilter/nf_conntrack_core.c
2728
.attach = nf_conntrack_attach,
net/sched/sch_api.c
1127
if (new && new->ops->attach && !ingress)
net/sched/sch_api.c
1155
if (new && !new->ops->attach)
net/sched/sch_api.c
1161
if (new && new->ops->attach)
net/sched/sch_api.c
1162
new->ops->attach(new);
net/sched/sch_cake.c
3340
.attach = mq_attach,
net/sched/sch_generic.c
1198
qdisc->ops->attach(qdisc);
net/sched/sch_htb.c
2147
.attach = htb_attach,
net/sched/sch_mq.c
297
.attach = mq_attach,
net/sched/sch_mqprio.c
769
.attach = mqprio_attach,
net/sched/sch_taprio.c
2539
.attach = taprio_attach,
net/tipc/crypto.c
1168
goto attach;
net/tipc/crypto.c
1183
goto attach;
net/tipc/crypto.c
1187
goto attach;
net/tipc/crypto.c
1194
attach:
samples/bpf/xdp_fwd_user.c
129
int attach = 1;
samples/bpf/xdp_fwd_user.c
135
attach = 0;
samples/bpf/xdp_fwd_user.c
160
if (attach) {
samples/bpf/xdp_fwd_user.c
214
if (!attach) {
security/apparmor/apparmorfs.c
1189
if (profile->attach.xmatch_str)
security/apparmor/apparmorfs.c
1190
seq_printf(seq, "%s\n", profile->attach.xmatch_str);
security/apparmor/apparmorfs.c
1191
else if (profile->attach.xmatch->dfa)
security/apparmor/apparmorfs.c
1219
SEQ_PROFILE_FOPS(attach);
security/apparmor/domain.c
317
struct aa_attachment *attach = &profile->attach;
security/apparmor/domain.c
318
int size, value_size = 0, ret = attach->xattr_count;
security/apparmor/domain.c
320
if (!bprm || !attach->xattr_count)
security/apparmor/domain.c
325
state = aa_dfa_outofband_transition(attach->xmatch->dfa, state);
security/apparmor/domain.c
328
for (i = 0; i < attach->xattr_count; i++) {
security/apparmor/domain.c
329
size = vfs_getxattr_alloc(&nop_mnt_idmap, d, attach->xattrs[i],
security/apparmor/domain.c
339
state = aa_dfa_null_transition(attach->xmatch->dfa,
security/apparmor/domain.c
342
state = aa_dfa_match_len(attach->xmatch->dfa, state,
security/apparmor/domain.c
344
perms = aa_lookup_perms(attach->xmatch, state);
security/apparmor/domain.c
351
state = aa_dfa_outofband_transition(attach->xmatch->dfa, state);
security/apparmor/domain.c
403
struct aa_attachment *attach = &profile->attach;
security/apparmor/domain.c
420
if (attach->xmatch->dfa) {
security/apparmor/domain.c
425
state = aa_dfa_leftmatch(attach->xmatch->dfa,
security/apparmor/domain.c
426
attach->xmatch->start[AA_CLASS_XMATCH],
security/apparmor/domain.c
428
perms = aa_lookup_perms(attach->xmatch, state);
security/apparmor/domain.c
436
if (bprm && attach->xattr_count) {
security/apparmor/domain.c
475
candidate_len = max(count, attach->xmatch_len);
security/apparmor/include/policy.h
271
struct aa_attachment attach;
security/apparmor/policy.c
267
static void free_attachment(struct aa_attachment *attach)
security/apparmor/policy.c
271
if (!attach)
security/apparmor/policy.c
274
for (i = 0; i < attach->xattr_count; i++)
security/apparmor/policy.c
275
kfree_sensitive(attach->xattrs[i]);
security/apparmor/policy.c
276
kfree_sensitive(attach->xattrs);
security/apparmor/policy.c
277
aa_put_pdb(attach->xmatch);
security/apparmor/policy.c
334
free_attachment(&profile->attach);
security/apparmor/policy.c
696
profile->attach.xmatch = aa_get_pdb(nullpdb);
security/apparmor/policy_unpack.c
1164
(void) aa_unpack_str(e, &profile->attach.xmatch_str, "attach");
security/apparmor/policy_unpack.c
1167
error = unpack_pdb(e, &profile->attach.xmatch, false, false, &info);
security/apparmor/policy_unpack.c
1174
if (profile->attach.xmatch->dfa) {
security/apparmor/policy_unpack.c
1179
profile->attach.xmatch_len = tmp;
security/apparmor/policy_unpack.c
1180
profile->attach.xmatch->start[AA_CLASS_XMATCH] = DFA_START;
security/apparmor/policy_unpack.c
1181
if (!profile->attach.xmatch->perms) {
security/apparmor/policy_unpack.c
1182
error = aa_compat_map_xmatch(profile->attach.xmatch);
security/apparmor/policy_unpack.c
1588
if (!verify_perms(profile->attach.xmatch)) {
security/apparmor/policy_unpack.c
599
profile->attach.xattr_count = size;
security/apparmor/policy_unpack.c
600
profile->attach.xattrs = kcalloc(size, sizeof(char *), GFP_KERNEL);
security/apparmor/policy_unpack.c
601
if (!profile->attach.xattrs)
security/apparmor/policy_unpack.c
604
if (!aa_unpack_strdup(e, &profile->attach.xattrs[i], NULL))
sound/aoa/core/core.c
106
attach:
sound/aoa/core/core.c
93
goto attach;
sound/core/control_led.c
513
bool attach)
sound/core/control_led.c
559
err = snd_ctl_led_set_id(led_card->number, &id, led_card->led->group, attach);
sound/core/control_led.c
623
static DEVICE_ATTR_WO(attach);
sound/soc/renesas/rcar/dma.c
763
int (*attach)(struct rsnd_dai_stream *io, struct rsnd_dma *dma,
sound/soc/renesas/rcar/dma.c
782
attach = rsnd_dmapp_attach;
sound/soc/renesas/rcar/dma.c
787
attach = rsnd_dmaen_attach;
sound/soc/renesas/rcar/dma.c
795
attach = rsnd_dmaen_attach;
sound/soc/renesas/rcar/dma.c
816
ret = attach(io, dma, mod_from, mod_to);
tools/perf/tests/event-times.c
161
static int test_times(int (attach)(struct evlist *),
tools/perf/tests/event-times.c
186
err = attach(evlist);
tools/perf/tests/event-times.c
222
#define _T(attach, detach) \
tools/perf/tests/event-times.c
223
err = test_times(attach, detach); \
tools/testing/selftests/bpf/flow_dissector_load.c
62
bool attach = false;
tools/testing/selftests/bpf/flow_dissector_load.c
71
attach = true;
tools/testing/selftests/bpf/flow_dissector_load.c
74
if (attach)
tools/testing/selftests/bpf/prog_tests/ip_check_defrag.c
186
if (!ASSERT_OK(attach(skel, ipv6), "attach"))
tools/testing/selftests/bpf/prog_tests/recursive_attach.c
36
static void test_recursive_fentry_chain(bool attach, bool detach)
tools/testing/selftests/bpf/prog_tests/recursive_attach.c
74
if (attach) {
tools/testing/selftests/bpf/test_cpp.cpp
44
int attach() { return T::attach(skel); }
tools/testing/selftests/bpf/test_cpp.cpp
84
err = skel.attach();
tools/testing/selftests/ptrace/vmaccess.c
46
TEST(attach)
tools/testing/selftests/seccomp/seccomp_bpf.c
5129
bool attach;
tools/testing/selftests/seccomp/seccomp_bpf.c
5137
.attach = false,
tools/testing/selftests/seccomp/seccomp_bpf.c
5142
.attach = true,
tools/testing/selftests/seccomp/seccomp_bpf.c
5147
.attach = true,
tools/testing/selftests/seccomp/seccomp_bpf.c
5162
if (!variant->attach)