search for: iv_size

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

Did you mean: iov_size
2019 Apr 26
0
[PATCH 07/10] s390/airq: use DMA memory for adapter interrupts
...7 @@ #include <asm/airq.h> #include <asm/isc.h> +#include <asm/cio.h> #include "cio.h" #include "cio_debug.h" @@ -113,6 +114,11 @@ void __init init_airq_interrupts(void) setup_irq(THIN_INTERRUPT, &airq_interrupt); } +static inline unsigned long iv_size(unsigned long bits) +{ + return BITS_TO_LONGS(bits) * sizeof(unsigned long); +} + /** * airq_iv_create - create an interrupt vector * @bits: number of bits in the interrupt vector @@ -123,14 +129,15 @@ void __init init_airq_interrupts(void) struct airq_iv *airq_iv_create(unsigned long bits, u...
2019 May 10
3
[PATCH 05/10] s390/cio: introduce DMA pools to cio
On Fri, 10 May 2019 00:11:12 +0200 Halil Pasic <pasic at linux.ibm.com> wrote: > On Thu, 9 May 2019 12:11:06 +0200 > Cornelia Huck <cohuck at redhat.com> wrote: > > > On Wed, 8 May 2019 23:22:10 +0200 > > Halil Pasic <pasic at linux.ibm.com> wrote: > > > > > On Wed, 8 May 2019 15:18:10 +0200 (CEST) > > > Sebastian Ott <sebott
2019 May 10
3
[PATCH 05/10] s390/cio: introduce DMA pools to cio
On Fri, 10 May 2019 00:11:12 +0200 Halil Pasic <pasic at linux.ibm.com> wrote: > On Thu, 9 May 2019 12:11:06 +0200 > Cornelia Huck <cohuck at redhat.com> wrote: > > > On Wed, 8 May 2019 23:22:10 +0200 > > Halil Pasic <pasic at linux.ibm.com> wrote: > > > > > On Wed, 8 May 2019 15:18:10 +0200 (CEST) > > > Sebastian Ott <sebott
2019 May 23
0
[PATCH v2 4/8] s390/airq: use DMA memory for adapter interrupts
...atic struct kmem_cache *airq_iv_cache; +static struct dma_pool *airq_iv_cache; /** * register_adapter_interrupt() - register adapter interrupt handler @@ -115,6 +117,11 @@ void __init init_airq_interrupts(void) setup_irq(THIN_INTERRUPT, &airq_interrupt); } +static inline unsigned long iv_size(unsigned long bits) +{ + return BITS_TO_LONGS(bits) * sizeof(unsigned long); +} + /** * airq_iv_create - create an interrupt vector * @bits: number of bits in the interrupt vector @@ -132,17 +139,18 @@ struct airq_iv *airq_iv_create(unsigned long bits, unsigned long flags) goto out; iv-&g...
2019 May 13
2
[PATCH 05/10] s390/cio: introduce DMA pools to cio
...0/cio/airq.c b/drivers/s390/cio/airq.c > index 7a5c0a0..f11f437 100644 > --- a/drivers/s390/cio/airq.c > +++ b/drivers/s390/cio/airq.c > @@ -136,8 +136,7 @@ struct airq_iv *airq_iv_create(unsigned long bits, unsigned long flags) > goto out; > iv->bits = bits; > size = iv_size(bits); > - iv->vector = dma_alloc_coherent(cio_get_dma_css_dev(), size, > - &iv->vector_dma, GFP_KERNEL); > + iv->vector = cio_dma_zalloc(size); > if (!iv->vector) > goto out_free; > if (flags & AIRQ_IV_ALLOC) { > @@ -172,8 +171,7 @@ struct airq...
2019 May 13
2
[PATCH 05/10] s390/cio: introduce DMA pools to cio
...0/cio/airq.c b/drivers/s390/cio/airq.c > index 7a5c0a0..f11f437 100644 > --- a/drivers/s390/cio/airq.c > +++ b/drivers/s390/cio/airq.c > @@ -136,8 +136,7 @@ struct airq_iv *airq_iv_create(unsigned long bits, unsigned long flags) > goto out; > iv->bits = bits; > size = iv_size(bits); > - iv->vector = dma_alloc_coherent(cio_get_dma_css_dev(), size, > - &iv->vector_dma, GFP_KERNEL); > + iv->vector = cio_dma_zalloc(size); > if (!iv->vector) > goto out_free; > if (flags & AIRQ_IV_ALLOC) { > @@ -172,8 +171,7 @@ struct airq...
2019 Jun 06
0
[PATCH v4 4/8] s390/airq: use DMA memory for adapter interrupts
...atic struct kmem_cache *airq_iv_cache; +static struct dma_pool *airq_iv_cache; /** * register_adapter_interrupt() - register adapter interrupt handler @@ -115,6 +117,11 @@ void __init init_airq_interrupts(void) setup_irq(THIN_INTERRUPT, &airq_interrupt); } +static inline unsigned long iv_size(unsigned long bits) +{ + return BITS_TO_LONGS(bits) * sizeof(unsigned long); +} + /** * airq_iv_create - create an interrupt vector * @bits: number of bits in the interrupt vector @@ -132,17 +139,18 @@ struct airq_iv *airq_iv_create(unsigned long bits, unsigned long flags) goto out; iv-&g...
2019 Jun 12
0
[PATCH v5 4/8] s390/airq: use DMA memory for adapter interrupts
...atic struct kmem_cache *airq_iv_cache; +static struct dma_pool *airq_iv_cache; /** * register_adapter_interrupt() - register adapter interrupt handler @@ -115,6 +117,11 @@ void __init init_airq_interrupts(void) setup_irq(THIN_INTERRUPT, &airq_interrupt); } +static inline unsigned long iv_size(unsigned long bits) +{ + return BITS_TO_LONGS(bits) * sizeof(unsigned long); +} + /** * airq_iv_create - create an interrupt vector * @bits: number of bits in the interrupt vector @@ -132,17 +139,19 @@ struct airq_iv *airq_iv_create(unsigned long bits, unsigned long flags) goto out; iv-&g...
2019 May 29
0
[PATCH v3 4/8] s390/airq: use DMA memory for adapter interrupts
...atic struct kmem_cache *airq_iv_cache; +static struct dma_pool *airq_iv_cache; /** * register_adapter_interrupt() - register adapter interrupt handler @@ -115,6 +117,11 @@ void __init init_airq_interrupts(void) setup_irq(THIN_INTERRUPT, &airq_interrupt); } +static inline unsigned long iv_size(unsigned long bits) +{ + return BITS_TO_LONGS(bits) * sizeof(unsigned long); +} + /** * airq_iv_create - create an interrupt vector * @bits: number of bits in the interrupt vector @@ -132,17 +139,18 @@ struct airq_iv *airq_iv_create(unsigned long bits, unsigned long flags) goto out; iv-&g...
2019 May 12
0
[PATCH 05/10] s390/cio: introduce DMA pools to cio
...ach bit */ diff --git a/drivers/s390/cio/airq.c b/drivers/s390/cio/airq.c index 7a5c0a0..f11f437 100644 --- a/drivers/s390/cio/airq.c +++ b/drivers/s390/cio/airq.c @@ -136,8 +136,7 @@ struct airq_iv *airq_iv_create(unsigned long bits, unsigned long flags) goto out; iv->bits = bits; size = iv_size(bits); - iv->vector = dma_alloc_coherent(cio_get_dma_css_dev(), size, - &iv->vector_dma, GFP_KERNEL); + iv->vector = cio_dma_zalloc(size); if (!iv->vector) goto out_free; if (flags & AIRQ_IV_ALLOC) { @@ -172,8 +171,7 @@ struct airq_iv *airq_iv_create(unsigned long b...
2019 May 15
0
[PATCH 05/10] s390/cio: introduce DMA pools to cio
...q.c > > index 7a5c0a0..f11f437 100644 > > --- a/drivers/s390/cio/airq.c > > +++ b/drivers/s390/cio/airq.c > > @@ -136,8 +136,7 @@ struct airq_iv *airq_iv_create(unsigned long bits, unsigned long flags) > > goto out; > > iv->bits = bits; > > size = iv_size(bits); > > - iv->vector = dma_alloc_coherent(cio_get_dma_css_dev(), size, > > - &iv->vector_dma, GFP_KERNEL); > > + iv->vector = cio_dma_zalloc(size); > > if (!iv->vector) > > goto out_free; > > if (flags & AIRQ_IV_ALLOC) { > &...
2019 Jun 12
1
[PATCH v5 4/8] s390/airq: use DMA memory for adapter interrupts
...gt; * @bits: number of bits in the interrupt vector > @@ -132,17 +139,19 @@ struct airq_iv *airq_iv_create(unsigned long bits, unsigned long flags) > goto out; > iv->bits = bits; > iv->flags = flags; > - size = BITS_TO_LONGS(bits) * sizeof(unsigned long); > + size = iv_size(bits); > > if (flags & AIRQ_IV_CACHELINE) { > - if ((cache_line_size() * BITS_PER_BYTE) < bits) > + if ((cache_line_size() * BITS_PER_BYTE) < bits > + || !airq_iv_cache) I still think squashing this into the same if statement is a bit ugly, but not really an issue...
2019 Jun 11
2
[PATCH v4 4/8] s390/airq: use DMA memory for adapter interrupts
On Tue, 11 Jun 2019 16:27:21 +0200 Halil Pasic <pasic at linux.ibm.com> wrote: > On Tue, 11 Jun 2019 12:17:21 +0200 > Cornelia Huck <cohuck at redhat.com> wrote: > > > On Thu, 6 Jun 2019 13:51:23 +0200 > > Halil Pasic <pasic at linux.ibm.com> wrote: > > > > > Protected virtualization guests have to use shared pages for airq > > >
2019 Jun 11
2
[PATCH v4 4/8] s390/airq: use DMA memory for adapter interrupts
On Tue, 11 Jun 2019 16:27:21 +0200 Halil Pasic <pasic at linux.ibm.com> wrote: > On Tue, 11 Jun 2019 12:17:21 +0200 > Cornelia Huck <cohuck at redhat.com> wrote: > > > On Thu, 6 Jun 2019 13:51:23 +0200 > > Halil Pasic <pasic at linux.ibm.com> wrote: > > > > > Protected virtualization guests have to use shared pages for airq > > >
2019 Jun 12
0
[PATCH v4 4/8] s390/airq: use DMA memory for adapter interrupts
...tomorrow in the afternoon: diff --git a/drivers/s390/cio/airq.c b/drivers/s390/cio/airq.c index 89d26e43004d..427b2e24a8ce 100644 --- a/drivers/s390/cio/airq.c +++ b/drivers/s390/cio/airq.c @@ -142,7 +142,8 @@ struct airq_iv *airq_iv_create(unsigned long bits, unsigned long flags) size = iv_size(bits); if (flags & AIRQ_IV_CACHELINE) { - if ((cache_line_size() * BITS_PER_BYTE) < bits) + if ((cache_line_size() * BITS_PER_BYTE) < bits + || !airq_iv_cache) goto out_free; iv-&...
2019 Jun 12
2
[PATCH v4 4/8] s390/airq: use DMA memory for adapter interrupts
...> diff --git a/drivers/s390/cio/airq.c b/drivers/s390/cio/airq.c > index 89d26e43004d..427b2e24a8ce 100644 > --- a/drivers/s390/cio/airq.c > +++ b/drivers/s390/cio/airq.c > @@ -142,7 +142,8 @@ struct airq_iv *airq_iv_create(unsigned long bits, unsigned long flags) > size = iv_size(bits); > > if (flags & AIRQ_IV_CACHELINE) { > - if ((cache_line_size() * BITS_PER_BYTE) < bits) > + if ((cache_line_size() * BITS_PER_BYTE) < bits > + || !airq_iv_cache) It's perhaps a bit more readabl...
2019 Jun 12
2
[PATCH v4 4/8] s390/airq: use DMA memory for adapter interrupts
...> diff --git a/drivers/s390/cio/airq.c b/drivers/s390/cio/airq.c > index 89d26e43004d..427b2e24a8ce 100644 > --- a/drivers/s390/cio/airq.c > +++ b/drivers/s390/cio/airq.c > @@ -142,7 +142,8 @@ struct airq_iv *airq_iv_create(unsigned long bits, unsigned long flags) > size = iv_size(bits); > > if (flags & AIRQ_IV_CACHELINE) { > - if ((cache_line_size() * BITS_PER_BYTE) < bits) > + if ((cache_line_size() * BITS_PER_BYTE) < bits > + || !airq_iv_cache) It's perhaps a bit more readabl...
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
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
2019 Jun 12
21
[PATCH v5 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