fdev 1000 drivers/dma/fsldma.c struct fsldma_device *fdev = data; fdev 1006 drivers/dma/fsldma.c gsr = (fdev->feature & FSL_DMA_BIG_ENDIAN) ? in_be32(fdev->regs) fdev 1007 drivers/dma/fsldma.c : in_le32(fdev->regs); fdev 1009 drivers/dma/fsldma.c dev_dbg(fdev->dev, "IRQ: gsr 0x%.8x\n", gsr); fdev 1012 drivers/dma/fsldma.c chan = fdev->chan[i]; fdev 1017 drivers/dma/fsldma.c dev_dbg(fdev->dev, "IRQ: chan %d\n", chan->id); fdev 1029 drivers/dma/fsldma.c static void fsldma_free_irqs(struct fsldma_device *fdev) fdev 1034 drivers/dma/fsldma.c if (fdev->irq) { fdev 1035 drivers/dma/fsldma.c dev_dbg(fdev->dev, "free per-controller IRQ\n"); fdev 1036 drivers/dma/fsldma.c free_irq(fdev->irq, fdev); fdev 1041 drivers/dma/fsldma.c chan = fdev->chan[i]; fdev 1049 drivers/dma/fsldma.c static int fsldma_request_irqs(struct fsldma_device *fdev) fdev 1056 drivers/dma/fsldma.c if (fdev->irq) { fdev 1057 drivers/dma/fsldma.c dev_dbg(fdev->dev, "request per-controller IRQ\n"); fdev 1058 drivers/dma/fsldma.c ret = request_irq(fdev->irq, fsldma_ctrl_irq, IRQF_SHARED, fdev 1059 drivers/dma/fsldma.c "fsldma-controller", fdev); fdev 1065 drivers/dma/fsldma.c chan = fdev->chan[i]; fdev 1088 drivers/dma/fsldma.c chan = fdev->chan[i]; fdev 1105 drivers/dma/fsldma.c static int fsl_dma_chan_probe(struct fsldma_device *fdev, fdev 1122 drivers/dma/fsldma.c dev_err(fdev->dev, "unable to ioremap registers\n"); fdev 1129 drivers/dma/fsldma.c dev_err(fdev->dev, "unable to find 'reg' property\n"); fdev 1134 drivers/dma/fsldma.c if (!fdev->feature) fdev 1135 drivers/dma/fsldma.c fdev->feature = chan->feature; fdev 1141 drivers/dma/fsldma.c WARN_ON(fdev->feature != chan->feature); fdev 1143 drivers/dma/fsldma.c chan->dev = fdev->dev; fdev 1148 drivers/dma/fsldma.c dev_err(fdev->dev, "too many channels for device\n"); fdev 1153 drivers/dma/fsldma.c fdev->chan[chan->id] = chan; fdev 1183 drivers/dma/fsldma.c chan->common.device = &fdev->common; fdev 1190 drivers/dma/fsldma.c list_add_tail(&chan->common.device_node, &fdev->common.channels); fdev 1192 drivers/dma/fsldma.c dev_info(fdev->dev, "#%d (%s), irq %d\n", chan->id, compatible, fdev 1193 drivers/dma/fsldma.c chan->irq ? chan->irq : fdev->irq); fdev 1215 drivers/dma/fsldma.c struct fsldma_device *fdev; fdev 1219 drivers/dma/fsldma.c fdev = kzalloc(sizeof(*fdev), GFP_KERNEL); fdev 1220 drivers/dma/fsldma.c if (!fdev) { fdev 1225 drivers/dma/fsldma.c fdev->dev = &op->dev; fdev 1226 drivers/dma/fsldma.c INIT_LIST_HEAD(&fdev->common.channels); fdev 1229 drivers/dma/fsldma.c fdev->regs = of_iomap(op->dev.of_node, 0); fdev 1230 drivers/dma/fsldma.c if (!fdev->regs) { fdev 1237 drivers/dma/fsldma.c fdev->irq = irq_of_parse_and_map(op->dev.of_node, 0); fdev 1239 drivers/dma/fsldma.c dma_cap_set(DMA_MEMCPY, fdev->common.cap_mask); fdev 1240 drivers/dma/fsldma.c dma_cap_set(DMA_SLAVE, fdev->common.cap_mask); fdev 1241 drivers/dma/fsldma.c fdev->common.device_alloc_chan_resources = fsl_dma_alloc_chan_resources; fdev 1242 drivers/dma/fsldma.c fdev->common.device_free_chan_resources = fsl_dma_free_chan_resources; fdev 1243 drivers/dma/fsldma.c fdev->common.device_prep_dma_memcpy = fsl_dma_prep_memcpy; fdev 1244 drivers/dma/fsldma.c fdev->common.device_tx_status = fsl_tx_status; fdev 1245 drivers/dma/fsldma.c fdev->common.device_issue_pending = fsl_dma_memcpy_issue_pending; fdev 1246 drivers/dma/fsldma.c fdev->common.device_config = fsl_dma_device_config; fdev 1247 drivers/dma/fsldma.c fdev->common.device_terminate_all = fsl_dma_device_terminate_all; fdev 1248 drivers/dma/fsldma.c fdev->common.dev = &op->dev; fdev 1250 drivers/dma/fsldma.c fdev->common.src_addr_widths = FSL_DMA_BUSWIDTHS; fdev 1251 drivers/dma/fsldma.c fdev->common.dst_addr_widths = FSL_DMA_BUSWIDTHS; fdev 1252 drivers/dma/fsldma.c fdev->common.directions = BIT(DMA_DEV_TO_MEM) | BIT(DMA_MEM_TO_DEV); fdev 1253 drivers/dma/fsldma.c fdev->common.residue_granularity = DMA_RESIDUE_GRANULARITY_DESCRIPTOR; fdev 1257 drivers/dma/fsldma.c platform_set_drvdata(op, fdev); fdev 1266 drivers/dma/fsldma.c fsl_dma_chan_probe(fdev, child, fdev 1272 drivers/dma/fsldma.c fsl_dma_chan_probe(fdev, child, fdev 1285 drivers/dma/fsldma.c err = fsldma_request_irqs(fdev); fdev 1287 drivers/dma/fsldma.c dev_err(fdev->dev, "unable to request IRQs\n"); fdev 1291 drivers/dma/fsldma.c dma_async_device_register(&fdev->common); fdev 1295 drivers/dma/fsldma.c irq_dispose_mapping(fdev->irq); fdev 1296 drivers/dma/fsldma.c iounmap(fdev->regs); fdev 1298 drivers/dma/fsldma.c kfree(fdev); fdev 1305 drivers/dma/fsldma.c struct fsldma_device *fdev; fdev 1308 drivers/dma/fsldma.c fdev = platform_get_drvdata(op); fdev 1309 drivers/dma/fsldma.c dma_async_device_unregister(&fdev->common); fdev 1311 drivers/dma/fsldma.c fsldma_free_irqs(fdev); fdev 1314 drivers/dma/fsldma.c if (fdev->chan[i]) fdev 1315 drivers/dma/fsldma.c fsl_dma_chan_remove(fdev->chan[i]); fdev 1318 drivers/dma/fsldma.c iounmap(fdev->regs); fdev 1319 drivers/dma/fsldma.c kfree(fdev); fdev 1327 drivers/dma/fsldma.c struct fsldma_device *fdev = dev_get_drvdata(dev); fdev 1332 drivers/dma/fsldma.c chan = fdev->chan[i]; fdev 1347 drivers/dma/fsldma.c chan = fdev->chan[i]; fdev 1358 drivers/dma/fsldma.c struct fsldma_device *fdev = dev_get_drvdata(dev); fdev 1364 drivers/dma/fsldma.c chan = fdev->chan[i]; fdev 33 drivers/dma/st_fdma.c struct st_fdma_dev *fdev = fchan->fdev; fdev 44 drivers/dma/st_fdma.c if (fdev->dreq_mask == ~0L) { fdev 45 drivers/dma/st_fdma.c dev_err(fdev->dev, "No req lines available\n"); fdev 50 drivers/dma/st_fdma.c dev_err(fdev->dev, "Invalid or used req line\n"); fdev 57 drivers/dma/st_fdma.c } while (test_and_set_bit(dreq_line, &fdev->dreq_mask)); fdev 59 drivers/dma/st_fdma.c dev_dbg(fdev->dev, "get dreq_line:%d mask:%#lx\n", fdev 60 drivers/dma/st_fdma.c dreq_line, fdev->dreq_mask); fdev 67 drivers/dma/st_fdma.c struct st_fdma_dev *fdev = fchan->fdev; fdev 69 drivers/dma/st_fdma.c dev_dbg(fdev->dev, "put dreq_line:%#x\n", fchan->dreq_line); fdev 70 drivers/dma/st_fdma.c clear_bit(fchan->dreq_line, &fdev->dreq_mask); fdev 91 drivers/dma/st_fdma.c fchan->fdev->slim_rproc->peri + FDMA_CMD_SET_OFST); fdev 93 drivers/dma/st_fdma.c dev_dbg(fchan->fdev->dev, "start chan:%d\n", fchan->vchan.chan.chan_id); fdev 101 drivers/dma/st_fdma.c struct st_fdma_dev *fdev = fchan->fdev; fdev 108 drivers/dma/st_fdma.c dev_warn(fdev->dev, "chan:%d, error:%ld\n", ch_id, ch_err); fdev 126 drivers/dma/st_fdma.c struct st_fdma_dev *fdev = dev_id; fdev 128 drivers/dma/st_fdma.c struct st_fdma_chan *fchan = &fdev->chans[0]; fdev 131 drivers/dma/st_fdma.c int_sta = fdma_read(fdev, FDMA_INT_STA_OFST); fdev 160 drivers/dma/st_fdma.c fdma_write(fdev, clr, FDMA_INT_CLR_OFST); fdev 168 drivers/dma/st_fdma.c struct st_fdma_dev *fdev = ofdma->of_dma_data; fdev 176 drivers/dma/st_fdma.c if (fdev->dma_device.dev->of_node != dma_spec->np) fdev 179 drivers/dma/st_fdma.c ret = rproc_boot(fdev->slim_rproc->rproc); fdev 185 drivers/dma/st_fdma.c chan = dma_get_any_slave_channel(&fdev->dma_device); fdev 213 drivers/dma/st_fdma.c dev_dbg(fdev->dev, "xlate req_line:%d type:%d req_ctrl:%#lx\n", fdev 219 drivers/dma/st_fdma.c rproc_shutdown(fdev->slim_rproc->rproc); fdev 270 drivers/dma/st_fdma.c fchan->fdev->dev, fdev 276 drivers/dma/st_fdma.c dev_err(fchan->fdev->dev, "unable to allocate desc pool\n"); fdev 280 drivers/dma/st_fdma.c dev_dbg(fchan->fdev->dev, "alloc ch_id:%d type:%d\n", fdev 289 drivers/dma/st_fdma.c struct rproc *rproc = fchan->fdev->slim_rproc->rproc; fdev 292 drivers/dma/st_fdma.c dev_dbg(fchan->fdev->dev, "%s: freeing chan:%d\n", fdev 325 drivers/dma/st_fdma.c dev_err(fchan->fdev->dev, "no memory for desc\n"); fdev 351 drivers/dma/st_fdma.c struct st_fdma_dev *fdev = fchan->fdev; fdev 404 drivers/dma/st_fdma.c dev_dbg(fdev->dev, "chan:%d config_reqctrl:%#x req_ctrl:%#lx\n", fdev 439 drivers/dma/st_fdma.c dev_err(fchan->fdev->dev, "bad direction?\n"); fdev 463 drivers/dma/st_fdma.c dev_err(fchan->fdev->dev, "bad width or direction\n"); fdev 469 drivers/dma/st_fdma.c dev_err(fchan->fdev->dev, "len is not multiple of period\n"); fdev 476 drivers/dma/st_fdma.c dev_err(fchan->fdev->dev, "no memory for desc\n"); fdev 525 drivers/dma/st_fdma.c dev_err(fchan->fdev->dev, "no memory for desc\n"); fdev 626 drivers/dma/st_fdma.c dev_dbg(fchan->fdev->dev, "pause chan:%d\n", ch_id); fdev 630 drivers/dma/st_fdma.c fdma_write(fchan->fdev, cmd, FDMA_CMD_SET_OFST); fdev 643 drivers/dma/st_fdma.c dev_dbg(fchan->fdev->dev, "resume chan:%d\n", ch_id); fdev 664 drivers/dma/st_fdma.c dev_dbg(fchan->fdev->dev, "terminate chan:%d\n", ch_id); fdev 667 drivers/dma/st_fdma.c fdma_write(fchan->fdev, cmd, FDMA_CMD_SET_OFST); fdev 713 drivers/dma/st_fdma.c struct st_fdma_dev *fdev) fdev 715 drivers/dma/st_fdma.c snprintf(fdev->fw_name, FW_NAME_SIZE, "fdma_%s_%d.elf", fdev 719 drivers/dma/st_fdma.c &fdev->nr_channels); fdev 726 drivers/dma/st_fdma.c static void st_fdma_free(struct st_fdma_dev *fdev) fdev 731 drivers/dma/st_fdma.c for (i = 0; i < fdev->nr_channels; i++) { fdev 732 drivers/dma/st_fdma.c fchan = &fdev->chans[i]; fdev 740 drivers/dma/st_fdma.c struct st_fdma_dev *fdev; fdev 754 drivers/dma/st_fdma.c fdev = devm_kzalloc(&pdev->dev, sizeof(*fdev), GFP_KERNEL); fdev 755 drivers/dma/st_fdma.c if (!fdev) fdev 758 drivers/dma/st_fdma.c ret = st_fdma_parse_dt(pdev, drvdata, fdev); fdev 764 drivers/dma/st_fdma.c fdev->chans = devm_kcalloc(&pdev->dev, fdev->nr_channels, fdev 766 drivers/dma/st_fdma.c if (!fdev->chans) fdev 769 drivers/dma/st_fdma.c fdev->dev = &pdev->dev; fdev 770 drivers/dma/st_fdma.c fdev->drvdata = drvdata; fdev 771 drivers/dma/st_fdma.c platform_set_drvdata(pdev, fdev); fdev 773 drivers/dma/st_fdma.c fdev->irq = platform_get_irq(pdev, 0); fdev 774 drivers/dma/st_fdma.c if (fdev->irq < 0) fdev 777 drivers/dma/st_fdma.c ret = devm_request_irq(&pdev->dev, fdev->irq, st_fdma_irq_handler, 0, fdev 778 drivers/dma/st_fdma.c dev_name(&pdev->dev), fdev); fdev 784 drivers/dma/st_fdma.c fdev->slim_rproc = st_slim_rproc_alloc(pdev, fdev->fw_name); fdev 785 drivers/dma/st_fdma.c if (IS_ERR(fdev->slim_rproc)) { fdev 786 drivers/dma/st_fdma.c ret = PTR_ERR(fdev->slim_rproc); fdev 792 drivers/dma/st_fdma.c INIT_LIST_HEAD(&fdev->dma_device.channels); fdev 793 drivers/dma/st_fdma.c for (i = 0; i < fdev->nr_channels; i++) { fdev 794 drivers/dma/st_fdma.c struct st_fdma_chan *fchan = &fdev->chans[i]; fdev 796 drivers/dma/st_fdma.c fchan->fdev = fdev; fdev 798 drivers/dma/st_fdma.c vchan_init(&fchan->vchan, &fdev->dma_device); fdev 802 drivers/dma/st_fdma.c fdev->dreq_mask = BIT(0) | BIT(31); fdev 804 drivers/dma/st_fdma.c dma_cap_set(DMA_SLAVE, fdev->dma_device.cap_mask); fdev 805 drivers/dma/st_fdma.c dma_cap_set(DMA_CYCLIC, fdev->dma_device.cap_mask); fdev 806 drivers/dma/st_fdma.c dma_cap_set(DMA_MEMCPY, fdev->dma_device.cap_mask); fdev 808 drivers/dma/st_fdma.c fdev->dma_device.dev = &pdev->dev; fdev 809 drivers/dma/st_fdma.c fdev->dma_device.device_alloc_chan_resources = st_fdma_alloc_chan_res; fdev 810 drivers/dma/st_fdma.c fdev->dma_device.device_free_chan_resources = st_fdma_free_chan_res; fdev 811 drivers/dma/st_fdma.c fdev->dma_device.device_prep_dma_cyclic = st_fdma_prep_dma_cyclic; fdev 812 drivers/dma/st_fdma.c fdev->dma_device.device_prep_slave_sg = st_fdma_prep_slave_sg; fdev 813 drivers/dma/st_fdma.c fdev->dma_device.device_prep_dma_memcpy = st_fdma_prep_dma_memcpy; fdev 814 drivers/dma/st_fdma.c fdev->dma_device.device_tx_status = st_fdma_tx_status; fdev 815 drivers/dma/st_fdma.c fdev->dma_device.device_issue_pending = st_fdma_issue_pending; fdev 816 drivers/dma/st_fdma.c fdev->dma_device.device_terminate_all = st_fdma_terminate_all; fdev 817 drivers/dma/st_fdma.c fdev->dma_device.device_config = st_fdma_slave_config; fdev 818 drivers/dma/st_fdma.c fdev->dma_device.device_pause = st_fdma_pause; fdev 819 drivers/dma/st_fdma.c fdev->dma_device.device_resume = st_fdma_resume; fdev 821 drivers/dma/st_fdma.c fdev->dma_device.src_addr_widths = FDMA_DMA_BUSWIDTHS; fdev 822 drivers/dma/st_fdma.c fdev->dma_device.dst_addr_widths = FDMA_DMA_BUSWIDTHS; fdev 823 drivers/dma/st_fdma.c fdev->dma_device.directions = BIT(DMA_DEV_TO_MEM) | BIT(DMA_MEM_TO_DEV); fdev 824 drivers/dma/st_fdma.c fdev->dma_device.residue_granularity = DMA_RESIDUE_GRANULARITY_BURST; fdev 826 drivers/dma/st_fdma.c ret = dmaenginem_async_device_register(&fdev->dma_device); fdev 833 drivers/dma/st_fdma.c ret = of_dma_controller_register(np, st_fdma_of_xlate, fdev); fdev 840 drivers/dma/st_fdma.c dev_info(&pdev->dev, "ST FDMA engine driver, irq:%d\n", fdev->irq); fdev 845 drivers/dma/st_fdma.c st_fdma_free(fdev); fdev 846 drivers/dma/st_fdma.c st_slim_rproc_put(fdev->slim_rproc); fdev 853 drivers/dma/st_fdma.c struct st_fdma_dev *fdev = platform_get_drvdata(pdev); fdev 855 drivers/dma/st_fdma.c devm_free_irq(&pdev->dev, fdev->irq, fdev); fdev 856 drivers/dma/st_fdma.c st_slim_rproc_put(fdev->slim_rproc); fdev 118 drivers/dma/st_fdma.h struct st_fdma_dev *fdev; fdev 166 drivers/dma/st_fdma.h #define fdma_read(fdev, name) \ fdev 167 drivers/dma/st_fdma.h readl((fdev)->slim_rproc->peri + name) fdev 169 drivers/dma/st_fdma.h #define fdma_write(fdev, val, name) \ fdev 170 drivers/dma/st_fdma.h writel((val), (fdev)->slim_rproc->peri + name) fdev 185 drivers/dma/st_fdma.h readl((fchan)->fdev->slim_rproc->mem[ST_SLIM_DMEM].cpu_addr \ fdev 190 drivers/dma/st_fdma.h writel((val), (fchan)->fdev->slim_rproc->mem[ST_SLIM_DMEM].cpu_addr \ fdev 197 drivers/dma/st_fdma.h writel((val), (fchan)->fdev->slim_rproc->mem[ST_SLIM_DMEM].cpu_addr \ fdev 207 drivers/dma/st_fdma.h readl((fchan)->fdev->slim_rproc->mem[ST_SLIM_DMEM].cpu_addr \ fdev 212 drivers/dma/st_fdma.h writel((val), (fchan)->fdev->slim_rproc->mem[ST_SLIM_DMEM].cpu_addr \ fdev 556 drivers/fpga/dfl-afu-main.c struct platform_device *fdev = dfl_fpga_inode_to_feature_dev(inode); fdev 560 drivers/fpga/dfl-afu-main.c pdata = dev_get_platdata(&fdev->dev); fdev 568 drivers/fpga/dfl-afu-main.c dev_dbg(&fdev->dev, "Device File Open\n"); fdev 569 drivers/fpga/dfl-afu-main.c filp->private_data = fdev; fdev 211 drivers/fpga/dfl-fme-main.c struct platform_device *fdev = dfl_fpga_inode_to_feature_dev(inode); fdev 212 drivers/fpga/dfl-fme-main.c struct dfl_feature_platform_data *pdata = dev_get_platdata(&fdev->dev); fdev 222 drivers/fpga/dfl-fme-main.c dev_dbg(&fdev->dev, "Device File Open\n"); fdev 471 drivers/fpga/dfl.c struct platform_device *fdev = binfo->feature_dev; fdev 477 drivers/fpga/dfl.c if (!fdev) fdev 480 drivers/fpga/dfl.c type = feature_dev_id_type(fdev); fdev 495 drivers/fpga/dfl.c pdata->dev = fdev; fdev 511 drivers/fpga/dfl.c fdev->dev.platform_data = pdata; fdev 514 drivers/fpga/dfl.c fdev->num_resources = binfo->feature_num; fdev 515 drivers/fpga/dfl.c fdev->resource = kcalloc(binfo->feature_num, sizeof(*fdev->resource), fdev 517 drivers/fpga/dfl.c if (!fdev->resource) fdev 528 drivers/fpga/dfl.c fdev->resource[index++] = finfo->mmio_res; fdev 559 drivers/fpga/dfl.c struct platform_device *fdev; fdev 574 drivers/fpga/dfl.c fdev = platform_device_alloc(dfl_devs[type].name, -ENODEV); fdev 575 drivers/fpga/dfl.c if (!fdev) fdev 578 drivers/fpga/dfl.c binfo->feature_dev = fdev; fdev 583 drivers/fpga/dfl.c fdev->id = dfl_id_alloc(type, &fdev->dev); fdev 584 drivers/fpga/dfl.c if (fdev->id < 0) fdev 585 drivers/fpga/dfl.c return fdev->id; fdev 587 drivers/fpga/dfl.c fdev->dev.parent = &binfo->cdev->region->dev; fdev 588 drivers/fpga/dfl.c fdev->dev.devt = dfl_get_devt(dfl_devs[type].devt_type, fdev->id); fdev 966 drivers/fsi/fsi-core.c int fsi_get_new_minor(struct fsi_device *fdev, enum fsi_dev_type type, fdev 969 drivers/fsi/fsi-core.c return __fsi_get_new_minor(fdev->slave, type, out_dev, out_index); fdev 3531 drivers/md/raid5.c struct r5dev *fdev[2] = { &sh->dev[s->failed_num[0]], fdev 3555 drivers/md/raid5.c if ((s->failed >= 1 && fdev[0]->toread) || fdev 3556 drivers/md/raid5.c (s->failed >= 2 && fdev[1]->toread)) fdev 3583 drivers/md/raid5.c if (fdev[i]->towrite && fdev 3584 drivers/md/raid5.c !test_bit(R5_UPTODATE, &fdev[i]->flags) && fdev 3585 drivers/md/raid5.c !test_bit(R5_OVERWRITE, &fdev[i]->flags)) fdev 3609 drivers/md/raid5.c !test_bit(R5_UPTODATE, &fdev[i]->flags) && fdev 3610 drivers/md/raid5.c !test_bit(R5_OVERWRITE, &fdev[i]->flags)) fdev 57 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c dma_device = &conn->fdev->mdev->pdev->dev; fdev 62 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_warn(conn->fdev, "DMA error on sg 0: %d\n", err); fdev 74 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_warn(conn->fdev, "DMA error on sg 1: %d\n", err); fdev 89 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c dma_device = &conn->fdev->mdev->pdev->dev; fdev 118 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c data->lkey = cpu_to_be32(conn->fdev->conn_res.mkey.key); fdev 138 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_write64(wqe, conn->fdev->conn_res.uar->map + MLX5_BF_OFFSET); fdev 158 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c data->lkey = cpu_to_be32(conn->fdev->conn_res.mkey.key); fdev 262 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_warn(conn->fdev, "RQ buf %p on FPGA QP %u completion status %d\n", fdev 265 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_dbg(conn->fdev, "RQ buf %p on FPGA QP %u completion status %d\n", fdev 277 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_dbg(conn->fdev, "Message with %u bytes received successfully\n", fdev 284 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_warn(conn->fdev, fdev 317 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_warn(conn->fdev, "SQ buf %p on FPGA QP %u completion status %d\n", fdev 320 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_dbg(conn->fdev, "SQ buf %p on FPGA QP %u completion status %d\n", fdev 326 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c buf->complete(conn, conn->fdev, buf, status); fdev 354 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_warn(conn->fdev, "Unexpected cqe opcode %u\n", fdev 362 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c conn->fdev->conn_res.uar->map, conn->cq.wq.cc); fdev 371 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_warn(conn->fdev, "CQ event %u on CQ #%u\n", event, mcq->cqn); fdev 379 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_warn(conn->fdev, "QP event %u on QP #%u\n", event, mqp->qpn); fdev 402 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_dbg(conn->fdev, "Re-arming CQ with cc# %u\n", conn->cq.wq.cc); fdev 430 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_fpga_device *fdev = conn->fdev; fdev 431 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_core_dev *mdev = fdev->mdev; fdev 475 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c MLX5_SET(cqc, cqc, uar_page, fdev->conn_res.uar->index); fdev 498 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c conn->cq.mcq.uar = fdev->conn_res.uar; fdev 502 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_dbg(fdev, "Created CQ #0x%x\n", conn->cq.mcq.cqn); fdev 516 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_core_destroy_cq(conn->fdev->mdev, &conn->cq.mcq); fdev 522 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_fpga_device *fdev = conn->fdev; fdev 523 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_core_dev *mdev = fdev->mdev; fdev 536 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_fpga_device *fdev = conn->fdev; fdev 537 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_core_dev *mdev = fdev->mdev; fdev 582 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c MLX5_SET(qpc, qpc, uar_page, fdev->conn_res.uar->index); fdev 589 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c MLX5_SET(qpc, qpc, pd, fdev->conn_res.pdn); fdev 608 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_dbg(fdev, "Created QP #0x%x\n", conn->qp.mqp.qpn); fdev 649 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c buf->complete(conn, conn->fdev, buf, MLX5_CQE_SYNDROME_WR_FLUSH_ERR); fdev 655 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c buf->complete(conn, conn->fdev, buf, MLX5_CQE_SYNDROME_WR_FLUSH_ERR); fdev 661 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_core_destroy_qp(conn->fdev->mdev, &conn->qp.mqp); fdev 671 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_core_dev *mdev = conn->fdev->mdev; fdev 673 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_dbg(conn->fdev, "Modifying QP %u to RST\n", conn->qp.mqp.qpn); fdev 681 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_fpga_device *fdev = conn->fdev; fdev 682 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_core_dev *mdev = fdev->mdev; fdev 686 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_dbg(conn->fdev, "Modifying QP %u to INIT\n", conn->qp.mqp.qpn); fdev 698 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c MLX5_SET(qpc, qpc, pd, conn->fdev->conn_res.pdn); fdev 706 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_warn(fdev, "qp_modify RST2INIT failed: %d\n", err); fdev 717 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_fpga_device *fdev = conn->fdev; fdev 718 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_core_dev *mdev = fdev->mdev; fdev 722 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_dbg(conn->fdev, "QP RTR\n"); fdev 751 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_warn(fdev, "qp_modify RST2INIT failed: %d\n", err); fdev 762 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_fpga_device *fdev = conn->fdev; fdev 763 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_core_dev *mdev = fdev->mdev; fdev 768 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_dbg(conn->fdev, "QP RTS\n"); fdev 788 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_warn(fdev, "qp_modify RST2INIT failed: %d\n", err); fdev 799 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_fpga_device *fdev = conn->fdev; fdev 803 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c err = mlx5_fpga_modify_qp(conn->fdev->mdev, conn->fpga_qpn, fdev 806 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "Failed to activate FPGA RC QP: %d\n", err); fdev 812 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "Failed to change QP state to reset\n"); fdev 818 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "Failed to modify QP from RESET to INIT\n"); fdev 828 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "Failed to change QP state from INIT to RTR\n"); fdev 834 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "Failed to change QP state from RTR to RTS\n"); fdev 843 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c if (mlx5_fpga_modify_qp(conn->fdev->mdev, conn->fpga_qpn, fdev 845 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "Failed to revert FPGA QP to INIT\n"); fdev 850 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_fpga_conn *mlx5_fpga_conn_create(struct mlx5_fpga_device *fdev, fdev 865 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c conn->fdev = fdev; fdev 874 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c err = mlx5_query_mac_address(fdev->mdev, remote_mac); fdev 876 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "Failed to query local MAC: %d\n", err); fdev 887 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c err = mlx5_core_reserved_gid_alloc(fdev->mdev, &conn->qp.sgid_index); fdev 889 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "Failed to allocate SGID: %d\n", err); fdev 894 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c err = mlx5_core_roce_gid_set(fdev->mdev, conn->qp.sgid_index, fdev 900 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "Failed to set SGID: %d\n", err); fdev 904 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_dbg(fdev, "Reserved SGID index %u\n", conn->qp.sgid_index); fdev 912 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "Failed to create CQ: %d\n", err); fdev 921 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "Failed to create QP: %d\n", err); fdev 938 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c err = mlx5_fpga_create_qp(fdev->mdev, &conn->fpga_qpc, fdev 941 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "Failed to create FPGA RC QP: %d\n", err); fdev 952 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_dbg(fdev, "FPGA QPN is %u\n", conn->fpga_qpn); fdev 957 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_destroy_qp(conn->fdev->mdev, conn->fpga_qpn); fdev 963 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_core_roce_gid_set(fdev->mdev, conn->qp.sgid_index, 0, 0, NULL, fdev 966 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_core_reserved_gid_free(fdev->mdev, conn->qp.sgid_index); fdev 975 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_fpga_device *fdev = conn->fdev; fdev 976 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c struct mlx5_core_dev *mdev = fdev->mdev; fdev 983 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_destroy_qp(conn->fdev->mdev, conn->fpga_qpn); fdev 987 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_warn(fdev, "qp_modify 2ERR failed: %d\n", err); fdev 991 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_core_roce_gid_set(conn->fdev->mdev, conn->qp.sgid_index, 0, 0, fdev 993 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_core_reserved_gid_free(conn->fdev->mdev, conn->qp.sgid_index); fdev 997 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c int mlx5_fpga_conn_device_init(struct mlx5_fpga_device *fdev) fdev 1001 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c err = mlx5_nic_vport_enable_roce(fdev->mdev); fdev 1003 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "Failed to enable RoCE: %d\n", err); fdev 1007 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c fdev->conn_res.uar = mlx5_get_uars_page(fdev->mdev); fdev 1008 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c if (IS_ERR(fdev->conn_res.uar)) { fdev 1009 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c err = PTR_ERR(fdev->conn_res.uar); fdev 1010 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "get_uars_page failed, %d\n", err); fdev 1013 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_dbg(fdev, "Allocated UAR index %u\n", fdev 1014 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c fdev->conn_res.uar->index); fdev 1016 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c err = mlx5_core_alloc_pd(fdev->mdev, &fdev->conn_res.pdn); fdev 1018 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "alloc pd failed, %d\n", err); fdev 1021 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_dbg(fdev, "Allocated PD %u\n", fdev->conn_res.pdn); fdev 1023 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c err = mlx5_fpga_conn_create_mkey(fdev->mdev, fdev->conn_res.pdn, fdev 1024 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c &fdev->conn_res.mkey); fdev 1026 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_err(fdev, "create mkey failed, %d\n", err); fdev 1029 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_fpga_dbg(fdev, "Created mkey 0x%x\n", fdev->conn_res.mkey.key); fdev 1034 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_core_dealloc_pd(fdev->mdev, fdev->conn_res.pdn); fdev 1036 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_put_uars_page(fdev->mdev, fdev->conn_res.uar); fdev 1038 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_nic_vport_disable_roce(fdev->mdev); fdev 1043 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c void mlx5_fpga_conn_device_cleanup(struct mlx5_fpga_device *fdev) fdev 1045 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_core_destroy_mkey(fdev->mdev, &fdev->conn_res.mkey); fdev 1046 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_core_dealloc_pd(fdev->mdev, fdev->conn_res.pdn); fdev 1047 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_put_uars_page(fdev->mdev, fdev->conn_res.uar); fdev 1048 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.c mlx5_nic_vport_disable_roce(fdev->mdev); fdev 45 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.h struct mlx5_fpga_device *fdev; fdev 86 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.h int mlx5_fpga_conn_device_init(struct mlx5_fpga_device *fdev); fdev 87 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.h void mlx5_fpga_conn_device_cleanup(struct mlx5_fpga_device *fdev); fdev 89 drivers/net/ethernet/mellanox/mlx5/core/fpga/conn.h mlx5_fpga_conn_create(struct mlx5_fpga_device *fdev, fdev 61 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c struct mlx5_fpga_device *fdev = NULL; fdev 63 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c fdev = kzalloc(sizeof(*fdev), GFP_KERNEL); fdev 64 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c if (!fdev) fdev 67 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c spin_lock_init(&fdev->state_lock); fdev 68 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c fdev->state = MLX5_FPGA_STATUS_NONE; fdev 69 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c return fdev; fdev 99 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c static int mlx5_fpga_device_load_check(struct mlx5_fpga_device *fdev) fdev 104 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c err = mlx5_fpga_query(fdev->mdev, &query); fdev 106 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_fpga_err(fdev, "Failed to query status: %d\n", err); fdev 110 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c fdev->last_admin_image = query.admin_image; fdev 111 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c fdev->last_oper_image = query.oper_image; fdev 113 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_fpga_dbg(fdev, "Status %u; Admin image %u; Oper image %u\n", fdev 117 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_fpga_err(fdev, "%s image failed to load; status %u\n", fdev 118 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_fpga_image_name(fdev->last_oper_image), fdev 126 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c static int mlx5_fpga_device_brb(struct mlx5_fpga_device *fdev) fdev 129 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c struct mlx5_core_dev *mdev = fdev->mdev; fdev 133 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_fpga_err(fdev, "Failed to set bypass on: %d\n", err); fdev 138 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_fpga_err(fdev, "Failed to reset SBU: %d\n", err); fdev 143 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_fpga_err(fdev, "Failed to set bypass off: %d\n", err); fdev 153 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c struct mlx5_fpga_device *fdev = mlx5_nb_cof(nb, struct mlx5_fpga_device, fpga_err_nb); fdev 155 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c return mlx5_fpga_event(fdev, event, eqe); fdev 160 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c struct mlx5_fpga_device *fdev = mlx5_nb_cof(nb, struct mlx5_fpga_device, fpga_qp_err_nb); fdev 162 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c return mlx5_fpga_event(fdev, event, eqe); fdev 167 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c struct mlx5_fpga_device *fdev = mdev->fpga; fdev 173 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c if (!fdev) fdev 176 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c err = mlx5_fpga_device_load_check(fdev); fdev 180 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c err = mlx5_fpga_caps(fdev->mdev); fdev 184 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c fpga_device_id = MLX5_CAP_FPGA(fdev->mdev, fpga_device); fdev 185 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_fpga_info(fdev, "%s:%u; %s image, version %u; SBU %06x:%04x version %d\n", fdev 188 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_fpga_image_name(fdev->last_oper_image), fdev 189 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c MLX5_CAP_FPGA(fdev->mdev, image_version), fdev 190 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c MLX5_CAP_FPGA(fdev->mdev, ieee_vendor_id), fdev 191 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c MLX5_CAP_FPGA(fdev->mdev, sandbox_product_id), fdev 192 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c MLX5_CAP_FPGA(fdev->mdev, sandbox_product_version)); fdev 196 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_fpga_err(fdev, "FPGA reports 0 QPs in SHELL_CAPS\n"); fdev 205 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c MLX5_NB_INIT(&fdev->fpga_err_nb, fpga_err_event, FPGA_ERROR); fdev 206 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c MLX5_NB_INIT(&fdev->fpga_qp_err_nb, fpga_qp_err_event, FPGA_QP_ERROR); fdev 207 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_eq_notifier_register(fdev->mdev, &fdev->fpga_err_nb); fdev 208 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_eq_notifier_register(fdev->mdev, &fdev->fpga_qp_err_nb); fdev 210 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c err = mlx5_fpga_conn_device_init(fdev); fdev 214 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c if (fdev->last_oper_image == MLX5_FPGA_IMAGE_USER) { fdev 215 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c err = mlx5_fpga_device_brb(fdev); fdev 223 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_fpga_conn_device_cleanup(fdev); fdev 226 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_eq_notifier_unregister(fdev->mdev, &fdev->fpga_err_nb); fdev 227 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_eq_notifier_unregister(fdev->mdev, &fdev->fpga_qp_err_nb); fdev 230 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c spin_lock_irqsave(&fdev->state_lock, flags); fdev 231 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c fdev->state = err ? MLX5_FPGA_STATUS_FAILURE : MLX5_FPGA_STATUS_SUCCESS; fdev 232 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c spin_unlock_irqrestore(&fdev->state_lock, flags); fdev 238 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c struct mlx5_fpga_device *fdev = NULL; fdev 247 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c fdev = mlx5_fpga_device_alloc(); fdev 248 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c if (!fdev) fdev 251 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c fdev->mdev = mdev; fdev 252 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mdev->fpga = fdev; fdev 259 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c struct mlx5_fpga_device *fdev = mdev->fpga; fdev 264 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c if (!fdev) fdev 267 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c spin_lock_irqsave(&fdev->state_lock, flags); fdev 268 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c if (fdev->state != MLX5_FPGA_STATUS_SUCCESS) { fdev 269 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c spin_unlock_irqrestore(&fdev->state_lock, flags); fdev 272 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c fdev->state = MLX5_FPGA_STATUS_NONE; fdev 273 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c spin_unlock_irqrestore(&fdev->state_lock, flags); fdev 275 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c if (fdev->last_oper_image == MLX5_FPGA_IMAGE_USER) { fdev 278 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_fpga_err(fdev, "Failed to re-set SBU bypass on: %d\n", fdev 282 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_fpga_conn_device_cleanup(fdev); fdev 283 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_eq_notifier_unregister(fdev->mdev, &fdev->fpga_err_nb); fdev 284 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_eq_notifier_unregister(fdev->mdev, &fdev->fpga_qp_err_nb); fdev 292 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c struct mlx5_fpga_device *fdev = mdev->fpga; fdev 295 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c kfree(fdev); fdev 313 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c static int mlx5_fpga_event(struct mlx5_fpga_device *fdev, fdev 335 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c spin_lock_irqsave(&fdev->state_lock, flags); fdev 336 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c switch (fdev->state) { fdev 338 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_fpga_warn(fdev, "Error %u: %s\n", syndrome, event_name); fdev 342 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_fpga_warn_ratelimited(fdev, "Unexpected error event %u: %s\n", fdev 345 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c spin_unlock_irqrestore(&fdev->state_lock, flags); fdev 352 drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c mlx5_trigger_health_work(fdev->mdev); fdev 100 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_device *fdev; fdev 141 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_device *fdev, fdev 150 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c mlx5_fpga_warn(fdev, "IPSec command send failed with status %u\n", fdev 178 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_device *fdev = cb_arg; fdev 182 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c mlx5_fpga_warn(fdev, "Short receive from FPGA IPSec: %u < %zu bytes\n", fdev 187 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c mlx5_fpga_dbg(fdev, "mlx5_ipsec recv_cb syndrome %08x\n", fdev 190 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c spin_lock_irqsave(&fdev->ipsec->pending_cmds_lock, flags); fdev 191 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c context = list_first_entry_or_null(&fdev->ipsec->pending_cmds, fdev 196 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c spin_unlock_irqrestore(&fdev->ipsec->pending_cmds_lock, flags); fdev 199 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c mlx5_fpga_warn(fdev, "Received IPSec offload response without pending command request\n"); fdev 202 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c mlx5_fpga_dbg(fdev, "Handling response for %p\n", context); fdev 210 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c mlx5_fpga_warn(fdev, "IPSec command failed with syndrome %08x\n", fdev 220 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_device *fdev = mdev->fpga; fdev 224 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c if (!fdev || !fdev->ipsec) fdev 235 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c context->dev = fdev; fdev 242 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c spin_lock_irqsave(&fdev->ipsec->pending_cmds_lock, flags); fdev 243 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c res = mlx5_fpga_sbu_conn_sendmsg(fdev->ipsec->conn, &context->buf); fdev 245 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c list_add_tail(&context->list, &fdev->ipsec->pending_cmds); fdev 246 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c spin_unlock_irqrestore(&fdev->ipsec->pending_cmds_lock, flags); fdev 249 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c mlx5_fpga_warn(fdev, "Failed to send IPSec command: %d\n", res); fdev 286 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c static int mlx5_fpga_ipsec_update_hw_sa(struct mlx5_fpga_device *fdev, fdev 290 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_core_dev *dev = fdev->mdev; fdev 297 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c if (is_v2_sadb_supported(fdev->ipsec)) fdev 313 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c mlx5_fpga_err(fdev, "mismatch SA handle. cmd 0x%08x vs resp 0x%08x\n", fdev 326 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_device *fdev = mdev->fpga; fdev 336 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c if (!fdev->ipsec) fdev 339 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c if (MLX5_GET(ipsec_extended_cap, fdev->ipsec->caps, esp)) fdev 342 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c if (MLX5_GET(ipsec_extended_cap, fdev->ipsec->caps, ipv6)) fdev 345 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c if (MLX5_GET(ipsec_extended_cap, fdev->ipsec->caps, lso)) fdev 348 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c if (MLX5_GET(ipsec_extended_cap, fdev->ipsec->caps, rx_no_trailer)) fdev 351 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c if (MLX5_GET(ipsec_extended_cap, fdev->ipsec->caps, esn)) { fdev 361 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_device *fdev = mdev->fpga; fdev 363 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c if (!fdev || !fdev->ipsec) fdev 366 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c return MLX5_GET(ipsec_extended_cap, fdev->ipsec->caps, fdev 373 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_device *fdev = mdev->fpga; fdev 380 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c if (!fdev || !fdev->ipsec) fdev 383 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c addr = (u64)MLX5_GET(ipsec_extended_cap, fdev->ipsec->caps, fdev 385 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c ((u64)MLX5_GET(ipsec_extended_cap, fdev->ipsec->caps, fdev 396 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c ret = mlx5_fpga_mem_read(fdev, count * sizeof(u64), addr, data, fdev 399 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c mlx5_fpga_err(fdev, "Failed to read IPSec counters from HW: %d\n", fdev 675 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_device *fdev = mdev->fpga; fdev 676 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_ipsec *fipsec = fdev->ipsec; fdev 722 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c opcode = is_v2_sadb_supported(fdev->ipsec) ? fdev 725 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c err = mlx5_fpga_ipsec_update_hw_sa(fdev, &sa_ctx->hw_sa, opcode); fdev 825 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_device *fdev = sa_ctx->dev->fpga; fdev 826 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_ipsec *fipsec = fdev->ipsec; fdev 827 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c int opcode = is_v2_sadb_supported(fdev->ipsec) ? fdev 832 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c err = mlx5_fpga_ipsec_update_hw_sa(fdev, &sa_ctx->hw_sa, opcode); fdev 1050 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_device *fdev = dev->fpga; fdev 1051 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_ipsec *fipsec = fdev->ipsec; fdev 1130 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_device *fdev = dev->fpga; fdev 1131 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_ipsec *fipsec = fdev->ipsec; fdev 1250 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_device *fdev = mdev->fpga; fdev 1257 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c fdev->ipsec = kzalloc(sizeof(*fdev->ipsec), GFP_KERNEL); fdev 1258 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c if (!fdev->ipsec) fdev 1261 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c fdev->ipsec->fdev = fdev; fdev 1263 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c err = mlx5_fpga_get_sbu_caps(fdev, sizeof(fdev->ipsec->caps), fdev 1264 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c fdev->ipsec->caps); fdev 1266 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c mlx5_fpga_err(fdev, "Failed to retrieve IPSec extended capabilities: %d\n", fdev 1271 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c INIT_LIST_HEAD(&fdev->ipsec->pending_cmds); fdev 1272 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c spin_lock_init(&fdev->ipsec->pending_cmds_lock); fdev 1277 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c init_attr.cb_arg = fdev; fdev 1278 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c conn = mlx5_fpga_sbu_conn_create(fdev, &init_attr); fdev 1281 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c mlx5_fpga_err(fdev, "Error creating IPSec command connection %d\n", fdev 1285 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c fdev->ipsec->conn = conn; fdev 1287 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c err = rhashtable_init(&fdev->ipsec->sa_hash, &rhash_sa); fdev 1290 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c mutex_init(&fdev->ipsec->sa_hash_lock); fdev 1292 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c fdev->ipsec->rules_rb = RB_ROOT; fdev 1293 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c mutex_init(&fdev->ipsec->rules_rb_lock); fdev 1297 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c mlx5_fpga_err(fdev, "Failed to enable IPSec extended capabilities: %d\n", fdev 1305 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c rhashtable_destroy(&fdev->ipsec->sa_hash); fdev 1311 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c kfree(fdev->ipsec); fdev 1312 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c fdev->ipsec = NULL; fdev 1329 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_device *fdev = mdev->fpga; fdev 1334 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c destroy_rules_rb(&fdev->ipsec->rules_rb); fdev 1335 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c rhashtable_destroy(&fdev->ipsec->sa_hash); fdev 1337 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c mlx5_fpga_sbu_conn_destroy(fdev->ipsec->conn); fdev 1338 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c kfree(fdev->ipsec); fdev 1339 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c fdev->ipsec = NULL; fdev 1472 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_device *fdev = mdev->fpga; fdev 1473 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c struct mlx5_fpga_ipsec *fipsec = fdev->ipsec; fdev 1516 drivers/net/ethernet/mellanox/mlx5/core/fpga/ipsec.c err = mlx5_fpga_ipsec_update_hw_sa(fdev, &fpga_xfrm->sa_ctx->hw_sa, fdev 41 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c mlx5_fpga_sbu_conn_create(struct mlx5_fpga_device *fdev, fdev 44 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c return mlx5_fpga_conn_create(fdev, attr, MLX5_FPGA_QPC_QP_TYPE_SANDBOX_QP); fdev 61 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c static int mlx5_fpga_mem_read_i2c(struct mlx5_fpga_device *fdev, size_t size, fdev 72 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c if (!fdev->mdev) fdev 78 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c err = mlx5_fpga_access_reg(fdev->mdev, actual_size, fdev 82 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c mlx5_fpga_err(fdev, "Failed to read over I2C: %d\n", fdev 93 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c static int mlx5_fpga_mem_write_i2c(struct mlx5_fpga_device *fdev, size_t size, fdev 104 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c if (!fdev->mdev) fdev 110 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c err = mlx5_fpga_access_reg(fdev->mdev, actual_size, fdev 114 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c mlx5_fpga_err(fdev, "Failed to write FPGA crspace\n"); fdev 124 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c int mlx5_fpga_mem_read(struct mlx5_fpga_device *fdev, size_t size, u64 addr, fdev 131 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c ret = mlx5_fpga_mem_read_i2c(fdev, size, addr, buf); fdev 136 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c mlx5_fpga_warn(fdev, "Unexpected read access_type %u\n", fdev 145 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c int mlx5_fpga_mem_write(struct mlx5_fpga_device *fdev, size_t size, u64 addr, fdev 152 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c ret = mlx5_fpga_mem_write_i2c(fdev, size, addr, buf); fdev 157 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c mlx5_fpga_warn(fdev, "Unexpected write access_type %u\n", fdev 166 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c int mlx5_fpga_get_sbu_caps(struct mlx5_fpga_device *fdev, int size, void *buf) fdev 168 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.c return mlx5_fpga_sbu_caps(fdev->mdev, buf, size); fdev 92 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.h struct mlx5_fpga_device *fdev, fdev 134 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.h mlx5_fpga_sbu_conn_create(struct mlx5_fpga_device *fdev, fdev 176 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.h int mlx5_fpga_mem_read(struct mlx5_fpga_device *fdev, size_t size, u64 addr, fdev 194 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.h int mlx5_fpga_mem_write(struct mlx5_fpga_device *fdev, size_t size, u64 addr, fdev 210 drivers/net/ethernet/mellanox/mlx5/core/fpga/sdk.h int mlx5_fpga_get_sbu_caps(struct mlx5_fpga_device *fdev, int size, void *buf); fdev 44 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c (struct mlx5_fpga_conn *conn, struct mlx5_fpga_device *fdev, fdev 69 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c static void mlx5_fpga_tls_cmd_complete(struct mlx5_fpga_device *fdev, fdev 72 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c struct mlx5_fpga_conn *conn = fdev->tls->conn; fdev 74 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c struct mlx5_fpga_tls *tls = fdev->tls; fdev 82 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c ctx->complete(conn, fdev, ctx, resp); fdev 86 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c struct mlx5_fpga_device *fdev, fdev 96 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c mlx5_fpga_tls_cmd_complete(fdev, NULL); fdev 99 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c static void mlx5_fpga_tls_cmd_send(struct mlx5_fpga_device *fdev, fdev 103 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c struct mlx5_fpga_tls *tls = fdev->tls; fdev 120 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c complete(tls->conn, fdev, cmd, NULL); fdev 164 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c struct mlx5_fpga_device *fdev, fdev 172 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c struct mlx5_fpga_device *fdev, fdev 180 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c mlx5_fpga_err(fdev, fdev 306 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c struct mlx5_fpga_device *fdev, fdev 327 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c mlx5_fpga_err(fdev, "Command was abandoned, syndrome = %u\n", fdev 337 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c mlx5_fpga_tls_del_flow(fdev->mdev, fdev 382 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c struct mlx5_fpga_device *fdev = (struct mlx5_fpga_device *)cb_arg; fdev 384 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c mlx5_fpga_tls_cmd_complete(fdev, buf); fdev 406 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c static int mlx5_fpga_tls_get_caps(struct mlx5_fpga_device *fdev, fdev 417 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c err = mlx5_fpga_get_sbu_caps(fdev, cap_size, buf); fdev 448 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c struct mlx5_fpga_device *fdev = mdev->fpga; fdev 454 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c if (!mlx5_fpga_is_tls_device(mdev) || !fdev) fdev 461 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c err = mlx5_fpga_tls_get_caps(fdev, &tls->caps); fdev 473 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c init_attr.cb_arg = fdev; fdev 474 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c conn = mlx5_fpga_sbu_conn_create(fdev, &init_attr); fdev 477 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c mlx5_fpga_err(fdev, "Error creating TLS command connection %d\n", fdev 490 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c fdev->tls = tls; fdev 500 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c struct mlx5_fpga_device *fdev = mdev->fpga; fdev 502 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c if (!fdev || !fdev->tls) fdev 505 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c mlx5_fpga_sbu_conn_destroy(fdev->tls->conn); fdev 506 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c kfree(fdev->tls); fdev 507 drivers/net/ethernet/mellanox/mlx5/core/fpga/tls.c fdev->tls = NULL; fdev 81 include/linux/fsi.h extern int fsi_get_new_minor(struct fsi_device *fdev, enum fsi_dev_type type, fdev 577 net/bridge/br_private.h struct net_device *dev, struct net_device *fdev, int *idx);