Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1624812 > unrolled thread
| Started by | Tyrel Datwyler <turtle.in.the.kernel@gmail.com> |
|---|---|
| First post | 2017-04-17 21:10 +0200 |
| Last post | 2017-04-17 21:10 +0200 |
| Articles | 1 — 1 participant |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: [PATCH] scsi: ibmvfc: don't check for failure from mempool_alloc() Tyrel Datwyler <turtle.in.the.kernel@gmail.com> - 2017-04-17 21:10 +0200
| From | Tyrel Datwyler <turtle.in.the.kernel@gmail.com> |
|---|---|
| Date | 2017-04-17 21:10 +0200 |
| Subject | Re: [PATCH] scsi: ibmvfc: don't check for failure from mempool_alloc() |
| Message-ID | <txkca-4vI-5@gated-at.bofh.it> |
On 04/09/2017 07:15 PM, NeilBrown wrote:
>
> mempool_alloc() cannot fail when passed GFP_NOIO or any
> other gfp setting that is permitted to sleep.
> So remove this pointless code.
>
> Signed-off-by: NeilBrown <neilb@suse.com>
Acked-by: Tyrel Datwyler <tyreld@linux.vnet.ibm.com>
> ---
> drivers/scsi/ibmvscsi/ibmvfc.c | 6 ------
> 1 file changed, 6 deletions(-)
>
> diff --git a/drivers/scsi/ibmvscsi/ibmvfc.c b/drivers/scsi/ibmvscsi/ibmvfc.c
> index 2c92dabb55f6..26cd3c28186a 100644
> --- a/drivers/scsi/ibmvscsi/ibmvfc.c
> +++ b/drivers/scsi/ibmvscsi/ibmvfc.c
> @@ -3910,12 +3910,6 @@ static int ibmvfc_alloc_target(struct ibmvfc_host *vhost, u64 scsi_id)
> spin_unlock_irqrestore(vhost->host->host_lock, flags);
>
> tgt = mempool_alloc(vhost->tgt_pool, GFP_NOIO);
> - if (!tgt) {
> - dev_err(vhost->dev, "Target allocation failure for scsi id %08llx\n",
> - scsi_id);
> - return -ENOMEM;
> - }
> -
> memset(tgt, 0, sizeof(*tgt));
> tgt->scsi_id = scsi_id;
> tgt->new_scsi_id = scsi_id;
>
Back to top | Article view | linux.kernel
csiph-web