diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2026-02-21 20:03:00 -0800 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2026-02-21 20:03:00 -0800 |
| commit | 32a92f8c89326985e05dce8b22d3f0aa07a3e1bd (patch) | |
| tree | 65f84985b9ed2d5cf3c5243aca78d9428e25c312 /drivers/target | |
| parent | 323bbfcf1ef8836d0d2ad9e2c1f1c684f0e3b5b3 (diff) | |
Convert more 'alloc_obj' cases to default GFP_KERNEL arguments
This converts some of the visually simpler cases that have been split
over multiple lines. I only did the ones that are easy to verify the
resulting diff by having just that final GFP_KERNEL argument on the next
line.
Somebody should probably do a proper coccinelle script for this, but for
me the trivial script actually resulted in an assertion failure in the
middle of the script. I probably had made it a bit _too_ trivial.
So after fighting that far a while I decided to just do some of the
syntactically simpler cases with variations of the previous 'sed'
scripts.
The more syntactically complex multi-line cases would mostly really want
whitespace cleanup anyway.
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/target')
| -rw-r--r-- | drivers/target/target_core_iblock.c | 3 | ||||
| -rw-r--r-- | drivers/target/target_core_pr.c | 3 |
2 files changed, 2 insertions, 4 deletions
diff --git a/drivers/target/target_core_iblock.c b/drivers/target/target_core_iblock.c index c50828eb844a..3c92f94497b4 100644 --- a/drivers/target/target_core_iblock.c +++ b/drivers/target/target_core_iblock.c @@ -66,8 +66,7 @@ static struct se_device *iblock_alloc_device(struct se_hba *hba, const char *nam } ib_dev->ibd_exclusive = true; - ib_dev->ibd_plug = kzalloc_objs(*ib_dev->ibd_plug, nr_cpu_ids, - GFP_KERNEL); + ib_dev->ibd_plug = kzalloc_objs(*ib_dev->ibd_plug, nr_cpu_ids); if (!ib_dev->ibd_plug) goto free_dev; diff --git a/drivers/target/target_core_pr.c b/drivers/target/target_core_pr.c index 24e0667483bd..f88e63aefcd8 100644 --- a/drivers/target/target_core_pr.c +++ b/drivers/target/target_core_pr.c @@ -1712,8 +1712,7 @@ core_scsi3_decode_spec_i_port( * the dest_node_acl and dest_se_deve pointers for the * loop below. */ - tidh_new = kzalloc_obj(struct pr_transport_id_holder, - GFP_KERNEL); + tidh_new = kzalloc_obj(struct pr_transport_id_holder); if (!tidh_new) { pr_err("Unable to allocate tidh_new\n"); core_scsi3_lunacl_undepend_item(dest_se_deve); |
