search for: dma_area_dma

Displaying 20 results from an estimated 25 matches for "dma_area_dma".

2019 Jun 03
2
[PATCH v3 3/8] s390/cio: add basic protected virtualization support
...ERNEL | GFP_DMA); > - if (!io_priv) { > - put_device(&sch->dev); > - return ERR_PTR(-ENOMEM); > - } > + if (!io_priv) > + goto err_priv; > + io_priv->dma_area = dma_alloc_coherent(&sch->dev, > + sizeof(*io_priv->dma_area), > + &io_priv->dma_area_dma, GFP_KERNEL); > + if (!io_priv->dma_area) > + goto err_dma_area; > set_io_private(sch, io_priv); > cdev = io_subchannel_create_ccwdev(sch); > if (IS_ERR(cdev)) { > put_device(&sch->dev); > + dma_free_coherent(&sch->dev, sizeof(*io_priv->dma_area),...
2019 Jun 03
2
[PATCH v3 3/8] s390/cio: add basic protected virtualization support
...ERNEL | GFP_DMA); > - if (!io_priv) { > - put_device(&sch->dev); > - return ERR_PTR(-ENOMEM); > - } > + if (!io_priv) > + goto err_priv; > + io_priv->dma_area = dma_alloc_coherent(&sch->dev, > + sizeof(*io_priv->dma_area), > + &io_priv->dma_area_dma, GFP_KERNEL); > + if (!io_priv->dma_area) > + goto err_dma_area; > set_io_private(sch, io_priv); > cdev = io_subchannel_create_ccwdev(sch); > if (IS_ERR(cdev)) { > put_device(&sch->dev); > + dma_free_coherent(&sch->dev, sizeof(*io_priv->dma_area),...
2019 Jun 03
1
[PATCH v3 3/8] s390/cio: add basic protected virtualization support
...p;sch->dev); > >> - return ERR_PTR(-ENOMEM); > >> - } > >> + if (!io_priv) > >> + goto err_priv; > >> + io_priv->dma_area = dma_alloc_coherent(&sch->dev, > >> + sizeof(*io_priv->dma_area), > >> + &io_priv->dma_area_dma, GFP_KERNEL); > >> + if (!io_priv->dma_area) > >> + goto err_dma_area; > >> set_io_private(sch, io_priv); > >> cdev = io_subchannel_create_ccwdev(sch); > >> if (IS_ERR(cdev)) { > >> put_device(&sch->dev); > >> +...
2019 May 08
3
[PATCH 06/10] s390/cio: add basic protected virtualization support
...gt;private->dma_area)? > @@ -1062,6 +1082,14 @@ static int io_subchannel_probe(struct subchannel *sch) > if (!io_priv) > goto out_schedule; > > + io_priv->dma_area = dma_alloc_coherent(&sch->dev, > + sizeof(*io_priv->dma_area), > + &io_priv->dma_area_dma, GFP_KERNEL); This needs GFP_DMA. You use a genpool for ccw_private->dma and not for iopriv->dma - looks kinda inconsistent.
2019 May 08
3
[PATCH 06/10] s390/cio: add basic protected virtualization support
...gt;private->dma_area)? > @@ -1062,6 +1082,14 @@ static int io_subchannel_probe(struct subchannel *sch) > if (!io_priv) > goto out_schedule; > > + io_priv->dma_area = dma_alloc_coherent(&sch->dev, > + sizeof(*io_priv->dma_area), > + &io_priv->dma_area_dma, GFP_KERNEL); This needs GFP_DMA. You use a genpool for ccw_private->dma and not for iopriv->dma - looks kinda inconsistent.
2019 May 27
3
[PATCH v2 3/8] s390/cio: add basic protected virtualization support
...ERNEL | GFP_DMA); > - if (!io_priv) { > - put_device(&sch->dev); > - return ERR_PTR(-ENOMEM); > - } > + if (!io_priv) > + goto err_priv; > + io_priv->dma_area = dma_alloc_coherent(&sch->dev, > + sizeof(*io_priv->dma_area), > + &io_priv->dma_area_dma, GFP_KERNEL); Even though we'll only end up here for 3215 or 3270 consoles, this sent me looking. This code is invoked via console_init(). A few lines down in start_kernel(), we have /* * This needs to be...
2019 May 27
3
[PATCH v2 3/8] s390/cio: add basic protected virtualization support
...ERNEL | GFP_DMA); > - if (!io_priv) { > - put_device(&sch->dev); > - return ERR_PTR(-ENOMEM); > - } > + if (!io_priv) > + goto err_priv; > + io_priv->dma_area = dma_alloc_coherent(&sch->dev, > + sizeof(*io_priv->dma_area), > + &io_priv->dma_area_dma, GFP_KERNEL); Even though we'll only end up here for 3215 or 3270 consoles, this sent me looking. This code is invoked via console_init(). A few lines down in start_kernel(), we have /* * This needs to be...
2019 Jun 03
0
[PATCH v3 3/8] s390/cio: add basic protected virtualization support
..._priv) { >> - put_device(&sch->dev); >> - return ERR_PTR(-ENOMEM); >> - } >> + if (!io_priv) >> + goto err_priv; >> + io_priv->dma_area = dma_alloc_coherent(&sch->dev, >> + sizeof(*io_priv->dma_area), >> + &io_priv->dma_area_dma, GFP_KERNEL); >> + if (!io_priv->dma_area) >> + goto err_dma_area; >> set_io_private(sch, io_priv); >> cdev = io_subchannel_create_ccwdev(sch); >> if (IS_ERR(cdev)) { >> put_device(&sch->dev); >> + dma_free_coherent(&sch->dev...
2019 Apr 26
0
[PATCH 06/10] s390/cio: add basic protected virtualization support
...in interrupt context so * we schedule a work item. */ @@ -1062,6 +1082,14 @@ static int io_subchannel_probe(struct subchannel *sch) if (!io_priv) goto out_schedule; + io_priv->dma_area = dma_alloc_coherent(&sch->dev, + sizeof(*io_priv->dma_area), + &io_priv->dma_area_dma, GFP_KERNEL); + if (!io_priv->dma_area) { + kfree(io_priv); + goto out_schedule; + } + set_io_private(sch, io_priv); css_schedule_eval(sch->schid); return 0; @@ -1088,6 +1116,8 @@ static int io_subchannel_remove(struct subchannel *sch) set_io_private(sch, NULL); spin_unlock_irq(sc...
2019 May 23
0
[PATCH v2 3/8] s390/cio: add basic protected virtualization support
...in interrupt context so * we schedule a work item. */ @@ -1062,6 +1081,14 @@ static int io_subchannel_probe(struct subchannel *sch) if (!io_priv) goto out_schedule; + io_priv->dma_area = dma_alloc_coherent(&sch->dev, + sizeof(*io_priv->dma_area), + &io_priv->dma_area_dma, GFP_KERNEL); + if (!io_priv->dma_area) { + kfree(io_priv); + goto out_schedule; + } + set_io_private(sch, io_priv); css_schedule_eval(sch->schid); return 0; @@ -1088,6 +1115,8 @@ static int io_subchannel_remove(struct subchannel *sch) set_io_private(sch, NULL); spin_unlock_irq(sc...
2019 May 29
0
[PATCH v3 3/8] s390/cio: add basic protected virtualization support
...in interrupt context so * we schedule a work item. */ @@ -1062,6 +1084,14 @@ static int io_subchannel_probe(struct subchannel *sch) if (!io_priv) goto out_schedule; + io_priv->dma_area = dma_alloc_coherent(&sch->dev, + sizeof(*io_priv->dma_area), + &io_priv->dma_area_dma, GFP_KERNEL); + if (!io_priv->dma_area) { + kfree(io_priv); + goto out_schedule; + } + set_io_private(sch, io_priv); css_schedule_eval(sch->schid); return 0; @@ -1088,6 +1118,8 @@ static int io_subchannel_remove(struct subchannel *sch) set_io_private(sch, NULL); spin_unlock_irq(sc...
2019 Jun 12
0
[PATCH v5 3/8] s390/cio: add basic protected virtualization support
...in interrupt context so * we schedule a work item. */ @@ -1062,6 +1084,14 @@ static int io_subchannel_probe(struct subchannel *sch) if (!io_priv) goto out_schedule; + io_priv->dma_area = dma_alloc_coherent(&sch->dev, + sizeof(*io_priv->dma_area), + &io_priv->dma_area_dma, GFP_KERNEL); + if (!io_priv->dma_area) { + kfree(io_priv); + goto out_schedule; + } + set_io_private(sch, io_priv); css_schedule_eval(sch->schid); return 0; @@ -1088,6 +1118,8 @@ static int io_subchannel_remove(struct subchannel *sch) set_io_private(sch, NULL); spin_unlock_irq(sc...
2019 May 27
2
[PATCH v2 3/8] s390/cio: add basic protected virtualization support
...gt;dev); > > > - return ERR_PTR(-ENOMEM); > > > - } > > > + if (!io_priv) > > > + goto err_priv; > > > + io_priv->dma_area = dma_alloc_coherent(&sch->dev, > > > + sizeof(*io_priv->dma_area), > > > + &io_priv->dma_area_dma, GFP_KERNEL); > > > > Even though we'll only end up here for 3215 or 3270 consoles, this sent > > me looking. > > > > This code is invoked via console_init(). A few lines down in > > start_kernel(), we have > > > > /*...
2019 May 27
2
[PATCH v2 3/8] s390/cio: add basic protected virtualization support
...gt;dev); > > > - return ERR_PTR(-ENOMEM); > > > - } > > > + if (!io_priv) > > > + goto err_priv; > > > + io_priv->dma_area = dma_alloc_coherent(&sch->dev, > > > + sizeof(*io_priv->dma_area), > > > + &io_priv->dma_area_dma, GFP_KERNEL); > > > > Even though we'll only end up here for 3215 or 3270 consoles, this sent > > me looking. > > > > This code is invoked via console_init(). A few lines down in > > start_kernel(), we have > > > > /*...
2019 May 08
0
[PATCH 06/10] s390/cio: add basic protected virtualization support
...; @@ -1062,6 +1082,14 @@ static int io_subchannel_probe(struct subchannel *sch) > > if (!io_priv) > > goto out_schedule; > > > > + io_priv->dma_area = dma_alloc_coherent(&sch->dev, > > + sizeof(*io_priv->dma_area), > > + &io_priv->dma_area_dma, GFP_KERNEL); > > This needs GFP_DMA. Christoph already answered this one. Thanks Christoph! > You use a genpool for ccw_private->dma and not for iopriv->dma - looks > kinda inconsistent. > Please have a look at patch #9. A virtio-ccw device uses the genpool of it's cc...
2019 May 27
0
[PATCH v2 3/8] s390/cio: add basic protected virtualization support
...> > - put_device(&sch->dev); > > - return ERR_PTR(-ENOMEM); > > - } > > + if (!io_priv) > > + goto err_priv; > > + io_priv->dma_area = dma_alloc_coherent(&sch->dev, > > + sizeof(*io_priv->dma_area), > > + &io_priv->dma_area_dma, GFP_KERNEL); > > Even though we'll only end up here for 3215 or 3270 consoles, this sent > me looking. > > This code is invoked via console_init(). A few lines down in > start_kernel(), we have > > /*...
2019 May 29
16
[PATCH v3 0/8] s390: virtio: support protected virtualization
Enhanced virtualization protection technology may require the use of bounce buffers for I/O. While support for this was built into the virtio core, virtio-ccw wasn't changed accordingly. Some background on technology (not part of this series) and the terminology used. * Protected Virtualization (PV): Protected Virtualization guarantees, that non-shared memory of a guest that operates in PV
2019 May 23
18
[PATCH v2 0/8] s390: virtio: support protected virtualization
Enhanced virtualization protection technology may require the use of bounce buffers for I/O. While support for this was built into the virtio core, virtio-ccw wasn't changed accordingly. Some background on technology (not part of this series) and the terminology used. * Protected Virtualization (PV): Protected Virtualization guarantees, that non-shared memory of a guest that operates in PV
2019 May 29
0
[PATCH v2 3/8] s390/cio: add basic protected virtualization support
...gt;>> - return ERR_PTR(-ENOMEM); >>>> - } >>>> + if (!io_priv) >>>> + goto err_priv; >>>> + io_priv->dma_area = dma_alloc_coherent(&sch->dev, >>>> + sizeof(*io_priv->dma_area), >>>> + &io_priv->dma_area_dma, GFP_KERNEL); >>> >>> Even though we'll only end up here for 3215 or 3270 consoles, this sent >>> me looking. >>> >>> This code is invoked via console_init(). A few lines down in >>> start_kernel(), we have >>> >>>...
2019 Apr 26
33
[PATCH 00/10] s390: virtio: support protected virtualization
Enhanced virtualization protection technology may require the use of bounce buffers for I/O. While support for this was built into the virtio core, virtio-ccw wasn't changed accordingly. Some background on technology (not part of this series) and the terminology used. * Protected Virtualization (PV): Protected Virtualization guarantees, that non-shared memory of a guest that operates in PV