All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 2/4] drivers/scsi/lpfc/lpfc_sli.c: convert GFP_KERNEL to GFP_ATOMIC
@ 2012-01-09  9:40 ` Julia Lawall
  0 siblings, 0 replies; 6+ messages in thread
From: Julia Lawall @ 2012-01-09  9:40 UTC (permalink / raw)
  To: James Smart
  Cc: kernel-janitors, James E.J. Bottomley, linux-scsi, linux-kernel,
	Julia Lawall

From: Julia Lawall <julia.lawall@lip6.fr>

The function is called with locks held and thus should not use GFP_KERNEL.

The semantic patch that makes this report is available
in scripts/coccinelle/locks/call_kern.cocci.

More information about semantic patching is available at
http://coccinelle.lip6.fr/

Signed-off-by: Julia Lawall <julia.lawall@lip6.fr>

---
 drivers/scsi/lpfc/lpfc_sli.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/scsi/lpfc/lpfc_sli.c b/drivers/scsi/lpfc/lpfc_sli.c
index 23a2759..622d24f 100644
--- a/drivers/scsi/lpfc/lpfc_sli.c
+++ b/drivers/scsi/lpfc/lpfc_sli.c
@@ -601,7 +601,7 @@ __lpfc_set_rrq_active(struct lpfc_hba *phba, struct lpfc_nodelist *ndlp,
 	if (test_and_set_bit(xritag, ndlp->active_rrqs.xri_bitmap))
 		goto out;
 
-	rrq = mempool_alloc(phba->rrq_pool, GFP_KERNEL);
+	rrq = mempool_alloc(phba->rrq_pool, GFP_ATOMIC);
 	if (rrq) {
 		rrq->send_rrq = send_rrq;
 		rrq->xritag = xritag;


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 2/4] drivers/scsi/lpfc/lpfc_sli.c: convert GFP_KERNEL to GFP_ATOMIC
@ 2012-01-09  9:40 ` Julia Lawall
  0 siblings, 0 replies; 6+ messages in thread
From: Julia Lawall @ 2012-01-09  9:40 UTC (permalink / raw)
  To: James Smart
  Cc: kernel-janitors, James E.J. Bottomley, linux-scsi, linux-kernel,
	Julia Lawall

From: Julia Lawall <julia.lawall@lip6.fr>

The function is called with locks held and thus should not use GFP_KERNEL.

The semantic patch that makes this report is available
in scripts/coccinelle/locks/call_kern.cocci.

More information about semantic patching is available at
http://coccinelle.lip6.fr/

Signed-off-by: Julia Lawall <julia.lawall@lip6.fr>

---
 drivers/scsi/lpfc/lpfc_sli.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/scsi/lpfc/lpfc_sli.c b/drivers/scsi/lpfc/lpfc_sli.c
index 23a2759..622d24f 100644
--- a/drivers/scsi/lpfc/lpfc_sli.c
+++ b/drivers/scsi/lpfc/lpfc_sli.c
@@ -601,7 +601,7 @@ __lpfc_set_rrq_active(struct lpfc_hba *phba, struct lpfc_nodelist *ndlp,
 	if (test_and_set_bit(xritag, ndlp->active_rrqs.xri_bitmap))
 		goto out;
 
-	rrq = mempool_alloc(phba->rrq_pool, GFP_KERNEL);
+	rrq = mempool_alloc(phba->rrq_pool, GFP_ATOMIC);
 	if (rrq) {
 		rrq->send_rrq = send_rrq;
 		rrq->xritag = xritag;

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH 2/4] drivers/scsi/lpfc/lpfc_sli.c: convert GFP_KERNEL to GFP_ATOMIC
  2012-01-09  9:40 ` Julia Lawall
@ 2012-01-12 20:00   ` James Smart
  -1 siblings, 0 replies; 6+ messages in thread
From: James Smart @ 2012-01-12 20:00 UTC (permalink / raw)
  To: Julia Lawall
  Cc: kernel-janitors@vger.kernel.org, James E.J. Bottomley,
	linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org

Julia,

We actually do not want any ATOMIC allocations if we can avoid them.  We 
reworked the calling sequence to deal with the locks being held. The change 
will be in the next patch set.

As such - Nack on the patch.

-- james s



On 1/9/2012 4:40 AM, Julia Lawall wrote:
> From: Julia Lawall<julia.lawall@lip6.fr>
>
> The function is called with locks held and thus should not use GFP_KERNEL.
>
> The semantic patch that makes this report is available
> in scripts/coccinelle/locks/call_kern.cocci.
>
> More information about semantic patching is available at
> http://coccinelle.lip6.fr/
>
> Signed-off-by: Julia Lawall<julia.lawall@lip6.fr>
>
> ---
>   drivers/scsi/lpfc/lpfc_sli.c |    2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/scsi/lpfc/lpfc_sli.c b/drivers/scsi/lpfc/lpfc_sli.c
> index 23a2759..622d24f 100644
> --- a/drivers/scsi/lpfc/lpfc_sli.c
> +++ b/drivers/scsi/lpfc/lpfc_sli.c
> @@ -601,7 +601,7 @@ __lpfc_set_rrq_active(struct lpfc_hba *phba, struct lpfc_nodelist *ndlp,
>   	if (test_and_set_bit(xritag, ndlp->active_rrqs.xri_bitmap))
>   		goto out;
>
> -	rrq = mempool_alloc(phba->rrq_pool, GFP_KERNEL);
> +	rrq = mempool_alloc(phba->rrq_pool, GFP_ATOMIC);
>   	if (rrq) {
>   		rrq->send_rrq = send_rrq;
>   		rrq->xritag = xritag;
>
>

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 2/4] drivers/scsi/lpfc/lpfc_sli.c: convert GFP_KERNEL to GFP_ATOMIC
@ 2012-01-12 20:00   ` James Smart
  0 siblings, 0 replies; 6+ messages in thread
From: James Smart @ 2012-01-12 20:00 UTC (permalink / raw)
  To: Julia Lawall
  Cc: kernel-janitors@vger.kernel.org, James E.J. Bottomley,
	linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org

Julia,

We actually do not want any ATOMIC allocations if we can avoid them.  We 
reworked the calling sequence to deal with the locks being held. The change 
will be in the next patch set.

As such - Nack on the patch.

-- james s



On 1/9/2012 4:40 AM, Julia Lawall wrote:
> From: Julia Lawall<julia.lawall@lip6.fr>
>
> The function is called with locks held and thus should not use GFP_KERNEL.
>
> The semantic patch that makes this report is available
> in scripts/coccinelle/locks/call_kern.cocci.
>
> More information about semantic patching is available at
> http://coccinelle.lip6.fr/
>
> Signed-off-by: Julia Lawall<julia.lawall@lip6.fr>
>
> ---
>   drivers/scsi/lpfc/lpfc_sli.c |    2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/scsi/lpfc/lpfc_sli.c b/drivers/scsi/lpfc/lpfc_sli.c
> index 23a2759..622d24f 100644
> --- a/drivers/scsi/lpfc/lpfc_sli.c
> +++ b/drivers/scsi/lpfc/lpfc_sli.c
> @@ -601,7 +601,7 @@ __lpfc_set_rrq_active(struct lpfc_hba *phba, struct lpfc_nodelist *ndlp,
>   	if (test_and_set_bit(xritag, ndlp->active_rrqs.xri_bitmap))
>   		goto out;
>
> -	rrq = mempool_alloc(phba->rrq_pool, GFP_KERNEL);
> +	rrq = mempool_alloc(phba->rrq_pool, GFP_ATOMIC);
>   	if (rrq) {
>   		rrq->send_rrq = send_rrq;
>   		rrq->xritag = xritag;
>
>

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 2/4] drivers/scsi/lpfc/lpfc_sli.c: convert GFP_KERNEL to GFP_ATOMIC
  2012-01-12 20:00   ` James Smart
@ 2012-01-12 20:08     ` Julia Lawall
  -1 siblings, 0 replies; 6+ messages in thread
From: Julia Lawall @ 2012-01-12 20:08 UTC (permalink / raw)
  To: James Smart
  Cc: Julia Lawall, kernel-janitors@vger.kernel.org,
	James E.J. Bottomley, linux-scsi@vger.kernel.org,
	linux-kernel@vger.kernel.org

On Thu, 12 Jan 2012, James Smart wrote:

> Julia,
>
> We actually do not want any ATOMIC allocations if we can avoid them.  We 
> reworked the calling sequence to deal with the locks being held. The change 
> will be in the next patch set.
>
> As such - Nack on the patch.

No problem.  It was more a bug report than a real patch.

thanks,
julia

> -- james s
>
>
>
> On 1/9/2012 4:40 AM, Julia Lawall wrote:
>> From: Julia Lawall<julia.lawall@lip6.fr>
>> 
>> The function is called with locks held and thus should not use GFP_KERNEL.
>> 
>> The semantic patch that makes this report is available
>> in scripts/coccinelle/locks/call_kern.cocci.
>> 
>> More information about semantic patching is available at
>> http://coccinelle.lip6.fr/
>> 
>> Signed-off-by: Julia Lawall<julia.lawall@lip6.fr>
>> 
>> ---
>>   drivers/scsi/lpfc/lpfc_sli.c |    2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>> 
>> diff --git a/drivers/scsi/lpfc/lpfc_sli.c b/drivers/scsi/lpfc/lpfc_sli.c
>> index 23a2759..622d24f 100644
>> --- a/drivers/scsi/lpfc/lpfc_sli.c
>> +++ b/drivers/scsi/lpfc/lpfc_sli.c
>> @@ -601,7 +601,7 @@ __lpfc_set_rrq_active(struct lpfc_hba *phba, struct 
>> lpfc_nodelist *ndlp,
>>   	if (test_and_set_bit(xritag, ndlp->active_rrqs.xri_bitmap))
>>   		goto out;
>> 
>> -	rrq = mempool_alloc(phba->rrq_pool, GFP_KERNEL);
>> +	rrq = mempool_alloc(phba->rrq_pool, GFP_ATOMIC);
>>   	if (rrq) {
>>   		rrq->send_rrq = send_rrq;
>>   		rrq->xritag = xritag;
>> 
>> 
> --
> To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 2/4] drivers/scsi/lpfc/lpfc_sli.c: convert GFP_KERNEL to GFP_ATOMIC
@ 2012-01-12 20:08     ` Julia Lawall
  0 siblings, 0 replies; 6+ messages in thread
From: Julia Lawall @ 2012-01-12 20:08 UTC (permalink / raw)
  To: James Smart
  Cc: Julia Lawall, kernel-janitors@vger.kernel.org,
	James E.J. Bottomley, linux-scsi@vger.kernel.org,
	linux-kernel@vger.kernel.org

On Thu, 12 Jan 2012, James Smart wrote:

> Julia,
>
> We actually do not want any ATOMIC allocations if we can avoid them.  We 
> reworked the calling sequence to deal with the locks being held. The change 
> will be in the next patch set.
>
> As such - Nack on the patch.

No problem.  It was more a bug report than a real patch.

thanks,
julia

> -- james s
>
>
>
> On 1/9/2012 4:40 AM, Julia Lawall wrote:
>> From: Julia Lawall<julia.lawall@lip6.fr>
>> 
>> The function is called with locks held and thus should not use GFP_KERNEL.
>> 
>> The semantic patch that makes this report is available
>> in scripts/coccinelle/locks/call_kern.cocci.
>> 
>> More information about semantic patching is available at
>> http://coccinelle.lip6.fr/
>> 
>> Signed-off-by: Julia Lawall<julia.lawall@lip6.fr>
>> 
>> ---
>>   drivers/scsi/lpfc/lpfc_sli.c |    2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>> 
>> diff --git a/drivers/scsi/lpfc/lpfc_sli.c b/drivers/scsi/lpfc/lpfc_sli.c
>> index 23a2759..622d24f 100644
>> --- a/drivers/scsi/lpfc/lpfc_sli.c
>> +++ b/drivers/scsi/lpfc/lpfc_sli.c
>> @@ -601,7 +601,7 @@ __lpfc_set_rrq_active(struct lpfc_hba *phba, struct 
>> lpfc_nodelist *ndlp,
>>   	if (test_and_set_bit(xritag, ndlp->active_rrqs.xri_bitmap))
>>   		goto out;
>> 
>> -	rrq = mempool_alloc(phba->rrq_pool, GFP_KERNEL);
>> +	rrq = mempool_alloc(phba->rrq_pool, GFP_ATOMIC);
>>   	if (rrq) {
>>   		rrq->send_rrq = send_rrq;
>>   		rrq->xritag = xritag;
>> 
>> 
> --
> To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2012-01-12 20:08 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-01-09  9:40 [PATCH 2/4] drivers/scsi/lpfc/lpfc_sli.c: convert GFP_KERNEL to GFP_ATOMIC Julia Lawall
2012-01-09  9:40 ` Julia Lawall
2012-01-12 20:00 ` James Smart
2012-01-12 20:00   ` James Smart
2012-01-12 20:08   ` Julia Lawall
2012-01-12 20:08     ` Julia Lawall

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.