Commit cadae477 authored by Lorenzo Bianconi's avatar Lorenzo Bianconi Committed by Felix Fietkau
Browse files

mt76: usb: reduce code indentation in mt76u_alloc_tx



Improve code readability reducing code indentation in
mt76u_alloc_tx

Signed-off-by: default avatarLorenzo Bianconi <lorenzo@kernel.org>
Signed-off-by: default avatarFelix Fietkau <nbd@nbd.name>
parent 4e04ba6a
Loading
Loading
Loading
Loading
+8 −9
Original line number Diff line number Diff line
@@ -818,17 +818,16 @@ static int mt76u_alloc_tx(struct mt76_dev *dev)
			if (!buf->urb)
				return -ENOMEM;

			if (dev->usb.sg_en) {
				size_t size = MT_SG_MAX_SIZE *
					      sizeof(struct scatterlist);
			if (!dev->usb.sg_en)
				continue;

				buf->urb->sg = devm_kzalloc(dev->dev, size,
			buf->urb->sg = devm_kcalloc(dev->dev, MT_SG_MAX_SIZE,
						    sizeof(struct scatterlist),
						    GFP_KERNEL);
			if (!buf->urb->sg)
				return -ENOMEM;
		}
	}
	}
	return 0;
}