search for: io_priv

Displaying 20 results from an estimated 30 matches for "io_priv".

2019 Jun 03
2
[PATCH v3 3/8] s390/cio: add basic protected virtualization support
..._sch.h | 20 +++++++++--- > drivers/s390/virtio/virtio_ccw.c | 10 ------ > 10 files changed, 163 insertions(+), 83 deletions(-) (...) > @@ -1593,20 +1625,31 @@ struct ccw_device * __init ccw_device_create_console(struct ccw_driver *drv) > return ERR_CAST(sch); > > io_priv = kzalloc(sizeof(*io_priv), GFP_KERNEL | 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_...
2019 Jun 03
2
[PATCH v3 3/8] s390/cio: add basic protected virtualization support
..._sch.h | 20 +++++++++--- > drivers/s390/virtio/virtio_ccw.c | 10 ------ > 10 files changed, 163 insertions(+), 83 deletions(-) (...) > @@ -1593,20 +1625,31 @@ struct ccw_device * __init ccw_device_create_console(struct ccw_driver *drv) > return ERR_CAST(sch); > > io_priv = kzalloc(sizeof(*io_priv), GFP_KERNEL | 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_...
2019 Jun 03
1
[PATCH v3 3/8] s390/cio: add basic protected virtualization support
...: > > On Wed, 29 May 2019 14:26:52 +0200 > > Michael Mueller <mimu at linux.ibm.com> wrote: > >> @@ -1593,20 +1625,31 @@ struct ccw_device * __init ccw_device_create_console(struct ccw_driver *drv) > >> return ERR_CAST(sch); > >> > >> io_priv = kzalloc(sizeof(*io_priv), GFP_KERNEL | GFP_DMA); > >> - if (!io_priv) { > >> - put_device(&sch->dev); > >> - return ERR_PTR(-ENOMEM); > >> - } > >> + if (!io_priv) > >> + goto err_priv; > >> + io_priv->dma_area = dma_allo...
2019 May 27
3
[PATCH v2 3/8] s390/cio: add basic protected virtualization support
...| 20 +++++++++---- > drivers/s390/virtio/virtio_ccw.c | 10 ------- > 10 files changed, 164 insertions(+), 83 deletions(-) > (...) > @@ -1593,20 +1622,31 @@ struct ccw_device * __init ccw_device_create_console(struct ccw_driver *drv) > return ERR_CAST(sch); > > io_priv = kzalloc(sizeof(*io_priv), GFP_KERNEL | 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_...
2019 May 27
3
[PATCH v2 3/8] s390/cio: add basic protected virtualization support
...| 20 +++++++++---- > drivers/s390/virtio/virtio_ccw.c | 10 ------- > 10 files changed, 164 insertions(+), 83 deletions(-) > (...) > @@ -1593,20 +1622,31 @@ struct ccw_device * __init ccw_device_create_console(struct ccw_driver *drv) > return ERR_CAST(sch); > > io_priv = kzalloc(sizeof(*io_priv), GFP_KERNEL | 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_...
2019 Jun 03
0
[PATCH v3 3/8] s390/cio: add basic protected virtualization support
...rivers/s390/virtio/virtio_ccw.c | 10 ------ >> 10 files changed, 163 insertions(+), 83 deletions(-) > > (...) > >> @@ -1593,20 +1625,31 @@ struct ccw_device * __init ccw_device_create_console(struct ccw_driver *drv) >> return ERR_CAST(sch); >> >> io_priv = kzalloc(sizeof(*io_priv), GFP_KERNEL | 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, >&g...
2019 May 08
3
[PATCH 06/10] s390/cio: add basic protected virtualization support
...*sch) > { [..] > + cdev->private = kzalloc(sizeof(struct ccw_device_private), > + GFP_KERNEL | GFP_DMA); Do we still need GFP_DMA here (since we now have cdev->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 kind...
2019 May 08
3
[PATCH 06/10] s390/cio: add basic protected virtualization support
...*sch) > { [..] > + cdev->private = kzalloc(sizeof(struct ccw_device_private), > + GFP_KERNEL | GFP_DMA); Do we still need GFP_DMA here (since we now have cdev->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 kind...
2019 Apr 26
0
[PATCH 06/10] s390/cio: add basic protected virtualization support
...e(struct ccw_device *cdev) wake_up(&ccw_device_init_wq); break; case DEV_STATE_OFFLINE: - /* + /* * We can't register the device 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_ev...
2019 May 23
0
[PATCH v2 3/8] s390/cio: add basic protected virtualization support
...e(struct ccw_device *cdev) wake_up(&ccw_device_init_wq); break; case DEV_STATE_OFFLINE: - /* + /* * We can't register the device 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_ev...
2019 May 29
0
[PATCH v3 3/8] s390/cio: add basic protected virtualization support
...e(struct ccw_device *cdev) wake_up(&ccw_device_init_wq); break; case DEV_STATE_OFFLINE: - /* + /* * We can't register the device 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_ev...
2019 Jun 12
0
[PATCH v5 3/8] s390/cio: add basic protected virtualization support
...e(struct ccw_device *cdev) wake_up(&ccw_device_init_wq); break; case DEV_STATE_OFFLINE: - /* + /* * We can't register the device 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_ev...
2019 May 27
2
[PATCH v2 3/8] s390/cio: add basic protected virtualization support
...0 files changed, 164 insertions(+), 83 deletions(-) > > > > > > > (...) > > > > > @@ -1593,20 +1622,31 @@ struct ccw_device * __init ccw_device_create_console(struct ccw_driver *drv) > > > return ERR_CAST(sch); > > > > > > io_priv = kzalloc(sizeof(*io_priv), GFP_KERNEL | GFP_DMA); > > > - if (!io_priv) { > > > - put_device(&sch->dev); > > > - return ERR_PTR(-ENOMEM); > > > - } > > > + if (!io_priv) > > > + goto err_priv; > > > + io_priv->dma_area = d...
2019 May 27
2
[PATCH v2 3/8] s390/cio: add basic protected virtualization support
...0 files changed, 164 insertions(+), 83 deletions(-) > > > > > > > (...) > > > > > @@ -1593,20 +1622,31 @@ struct ccw_device * __init ccw_device_create_console(struct ccw_driver *drv) > > > return ERR_CAST(sch); > > > > > > io_priv = kzalloc(sizeof(*io_priv), GFP_KERNEL | GFP_DMA); > > > - if (!io_priv) { > > > - put_device(&sch->dev); > > > - return ERR_PTR(-ENOMEM); > > > - } > > > + if (!io_priv) > > > + goto err_priv; > > > + io_priv->dma_area = d...
2019 May 27
0
[PATCH v2 3/8] s390/cio: add basic protected virtualization support
...irtio/virtio_ccw.c | 10 ------- > > 10 files changed, 164 insertions(+), 83 deletions(-) > > > > (...) > > > @@ -1593,20 +1622,31 @@ struct ccw_device * __init ccw_device_create_console(struct ccw_driver *drv) > > return ERR_CAST(sch); > > > > io_priv = kzalloc(sizeof(*io_priv), GFP_KERNEL | 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,...
2019 Apr 11
0
[RFC PATCH 05/12] s390/cio: add protected virtualization support to cio
On Fri, 5 Apr 2019, Halil Pasic wrote: > @@ -1593,20 +1609,29 @@ struct ccw_device * __init ccw_device_create_console(struct ccw_driver *drv) > return ERR_CAST(sch); > > io_priv = kzalloc(sizeof(*io_priv), GFP_KERNEL | GFP_DMA); > - if (!io_priv) { > - put_device(&sch->dev); > - return ERR_PTR(-ENOMEM); > - } > + if (!io_priv) > + goto err_priv; > + io_priv->dma_area = cio_dma_zalloc(sizeof(*io_priv->dma_area)); This is called very ear...
2019 May 29
0
[PATCH v2 3/8] s390/cio: add basic protected virtualization support
...sertions(+), 83 deletions(-) >>>> >>> >>> (...) >>> >>>> @@ -1593,20 +1622,31 @@ struct ccw_device * __init ccw_device_create_console(struct ccw_driver *drv) >>>> return ERR_CAST(sch); >>>> >>>> io_priv = kzalloc(sizeof(*io_priv), GFP_KERNEL | GFP_DMA); >>>> - if (!io_priv) { >>>> - put_device(&sch->dev); >>>> - return ERR_PTR(-ENOMEM); >>>> - } >>>> + if (!io_priv) >>>> + goto err_priv; >>>> + io_priv-&g...
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
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 08
0
[PATCH 06/10] s390/cio: add basic protected virtualization support
...ere (since we now have cdev->private->dma_area)? > We probably do not. I kept it GFP_DMA to keep changes to the minimum. Should changing this in your opinion be a part of this patch? > > @@ -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 C...