Re: [PATCH] ibmvscsi: use GFP_ATOMIC with dma_alloc_coherent in map_sg_data

2019-01-11 Thread Christoph Hellwig
On Thu, Jan 10, 2019 at 03:15:35PM -0800, Tyrel Datwyler wrote: > On a secondary note I was unaware of the GFP_ATOMIC limitations. Should this > be > added to the documentation somewhere? I don't see any mention here form > DMA-API-HOWTO.txt. The DMA documentation unfortauntely doesn't seem very

Re: [PATCH] ibmvscsi: use GFP_ATOMIC with dma_alloc_coherent in map_sg_data

2019-01-11 Thread Christoph Hellwig
On Thu, Jan 10, 2019 at 12:11:53PM -0800, Tyrel Datwyler wrote: > This allocation isn't a single use allocation. The driver is just lazy about > allocating our ext_list area for large SG lists (ie. SG_ALL). When the driver > was first written it only supported up to 10 indirect SRP buffers. James

Re: [PATCH] ibmvscsi: use GFP_ATOMIC with dma_alloc_coherent in map_sg_data

2019-01-10 Thread Tyrel Datwyler
On 01/10/2019 07:07 AM, Christoph Hellwig wrote: > On Wed, Jan 09, 2019 at 06:58:56PM -0800, Tyrel Datwyler wrote: >> While mapping DMA for scatter list when a scsi command is queued the >> existing call to dma_alloc_coherent() in our map_sg_data() function >> passes zero for the gfp_flags paramete

Re: [PATCH] ibmvscsi: use GFP_ATOMIC with dma_alloc_coherent in map_sg_data

2019-01-10 Thread Tyrel Datwyler
On 01/10/2019 07:07 AM, Christoph Hellwig wrote: > On Wed, Jan 09, 2019 at 06:58:56PM -0800, Tyrel Datwyler wrote: >> While mapping DMA for scatter list when a scsi command is queued the >> existing call to dma_alloc_coherent() in our map_sg_data() function >> passes zero for the gfp_flags paramete

Re: [PATCH] ibmvscsi: use GFP_ATOMIC with dma_alloc_coherent in map_sg_data

2019-01-10 Thread Christoph Hellwig
On Wed, Jan 09, 2019 at 06:58:56PM -0800, Tyrel Datwyler wrote: > While mapping DMA for scatter list when a scsi command is queued the > existing call to dma_alloc_coherent() in our map_sg_data() function > passes zero for the gfp_flags parameter. We are most definitly in atomic > context at this p

Re: [PATCH] ibmvscsi: use GFP_ATOMIC with dma_alloc_coherent in map_sg_data

2019-01-10 Thread Brian King
On 01/09/2019 08:58 PM, Tyrel Datwyler wrote: > While mapping DMA for scatter list when a scsi command is queued the > existing call to dma_alloc_coherent() in our map_sg_data() function > passes zero for the gfp_flags parameter. We are most definitly in atomic > context at this point as queue_comm

[PATCH] ibmvscsi: use GFP_ATOMIC with dma_alloc_coherent in map_sg_data

2019-01-09 Thread Tyrel Datwyler
While mapping DMA for scatter list when a scsi command is queued the existing call to dma_alloc_coherent() in our map_sg_data() function passes zero for the gfp_flags parameter. We are most definitly in atomic context at this point as queue_command() is called in softirq context and further we have