search for: devm_kcalloc

Displaying 8 results from an estimated 8 matches for "devm_kcalloc".

2016 Aug 30
1
[PATCH v8 05/18] dmaengine: st_fdma: Add STMicroelectronics FDMA engine driver support
...> @@ -567,7 +580,6 @@ config ZX_DMA > help > Support the DMA engine for ZTE ZX296702 platform devices. > > - unrelated change? > + fdev->chans = devm_kzalloc(&pdev->dev, > + fdev->nr_channels > + * sizeof(struct st_fdma_chan), GFP_KERNEL); devm_kcalloc() > + if (!fdev->chans) > + return -ENOMEM; > + > + fdev->dev = &pdev->dev; > + fdev->drvdata = drvdata; > + platform_set_drvdata(pdev, fdev); > + > + fdev->irq = platform_get_irq(pdev, 0); > + if (fdev->irq < 0) { > + dev_err(&pdev->...
2016 Aug 30
1
[PATCH v8 05/18] dmaengine: st_fdma: Add STMicroelectronics FDMA engine driver support
...> @@ -567,7 +580,6 @@ config ZX_DMA > help > Support the DMA engine for ZTE ZX296702 platform devices. > > - unrelated change? > + fdev->chans = devm_kzalloc(&pdev->dev, > + fdev->nr_channels > + * sizeof(struct st_fdma_chan), GFP_KERNEL); devm_kcalloc() > + if (!fdev->chans) > + return -ENOMEM; > + > + fdev->dev = &pdev->dev; > + fdev->drvdata = drvdata; > + platform_set_drvdata(pdev, fdev); > + > + fdev->irq = platform_get_irq(pdev, 0); > + if (fdev->irq < 0) { > + dev_err(&pdev->...
2019 Sep 05
0
[PATCH 10/18] virtiofs: Do not use device managed mem for virtio_fs and virtio_fs_vq
...names; unsigned int i; - int ret; + int ret = 0; virtio_cread(vdev, struct virtio_fs_config, num_queues, &fs->num_queues); @@ -454,9 +454,7 @@ static int virtio_fs_setup_vqs(struct virtio_device *vdev, return -EINVAL; fs->nvqs = 1 + fs->num_queues; - - fs->vqs = devm_kcalloc(&vdev->dev, fs->nvqs, - sizeof(fs->vqs[VQ_HIPRIO]), GFP_KERNEL); + fs->vqs = kcalloc(fs->nvqs, sizeof(fs->vqs[VQ_HIPRIO]), GFP_KERNEL); if (!fs->vqs) return -ENOMEM; @@ -504,6 +502,8 @@ static int virtio_fs_setup_vqs(struct virtio_device *vdev, kfree(names); k...
2019 Sep 05
38
[PATCH 00/18] virtiofs: Fix various races and cleanups round 1
Hi, Michael Tsirkin pointed out issues w.r.t various locking related TODO items and races w.r.t device removal. In this first round of cleanups, I have taken care of most pressing issues. These patches apply on top of following. git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse.git#virtiofs-v4 I have tested these patches with mount/umount and device removal using qemu monitor. For
2019 Sep 03
4
[PATCH v4 15/16] virtio-fs: add virtiofs filesystem
...t char **names; > + unsigned int i; > + int ret; > + > + virtio_cread(vdev, struct virtio_fs_config, num_queues, > + &fs->num_queues); > + if (fs->num_queues == 0) > + return -EINVAL; > + > + fs->nvqs = 1 + fs->num_queues; > + > + fs->vqs = devm_kcalloc(&vdev->dev, fs->nvqs, > + sizeof(fs->vqs[VQ_HIPRIO]), GFP_KERNEL); > + if (!fs->vqs) > + return -ENOMEM; > + > + vqs = kmalloc_array(fs->nvqs, sizeof(vqs[VQ_HIPRIO]), GFP_KERNEL); > + callbacks = kmalloc_array(fs->nvqs, sizeof(callbacks[VQ_HIPRIO]), >...
2019 Sep 03
4
[PATCH v4 15/16] virtio-fs: add virtiofs filesystem
...t char **names; > + unsigned int i; > + int ret; > + > + virtio_cread(vdev, struct virtio_fs_config, num_queues, > + &fs->num_queues); > + if (fs->num_queues == 0) > + return -EINVAL; > + > + fs->nvqs = 1 + fs->num_queues; > + > + fs->vqs = devm_kcalloc(&vdev->dev, fs->nvqs, > + sizeof(fs->vqs[VQ_HIPRIO]), GFP_KERNEL); > + if (!fs->vqs) > + return -ENOMEM; > + > + vqs = kmalloc_array(fs->nvqs, sizeof(vqs[VQ_HIPRIO]), GFP_KERNEL); > + callbacks = kmalloc_array(fs->nvqs, sizeof(callbacks[VQ_HIPRIO]), >...
2016 Aug 26
32
[PATCH v8 00/18] Add support for FDMA DMA controller and slim core rproc found on STi chipsets
Hi Vinod, Bjorn, Patrice, This patchset adds support for the Flexible Direct Memory Access (FDMA) core found on STi chipsets from STMicroelectronics. The FDMA is a slim core CPU with a dedicated firmware. It is a general purpose DMA controller supporting 16 independent channels and data can be moved from memory to memory or between memory and paced latency critical real time targets. After quite
2016 Aug 26
32
[PATCH v8 00/18] Add support for FDMA DMA controller and slim core rproc found on STi chipsets
Hi Vinod, Bjorn, Patrice, This patchset adds support for the Flexible Direct Memory Access (FDMA) core found on STi chipsets from STMicroelectronics. The FDMA is a slim core CPU with a dedicated firmware. It is a general purpose DMA controller supporting 16 independent channels and data can be moved from memory to memory or between memory and paced latency critical real time targets. After quite