]> git.ipfire.org Git - thirdparty/u-boot.git/commit
spi: mtk_snor: avoid alloc in mtk_snor_cmd_program()
authorNoah.Shen <noah.shen@mediatek.com>
Mon, 6 Apr 2026 20:13:28 +0000 (15:13 -0500)
committerDavid Lechner <dlechner@baylibre.com>
Tue, 28 Apr 2026 18:11:19 +0000 (13:11 -0500)
commit4eac47d4eb661c019b84723628bab2f0c826403f
tree9ea2ca48ee7b0e473d7e71b225462d05f2965107
parent4f9842e4799c6c3c98cc27c723ba223b42d739d8
spi: mtk_snor: avoid alloc in mtk_snor_cmd_program()

Rework mtk_snor_cmd_program() to avoid allocating a temporary buffer
for tx data. This improves performance a bit by avoiding the need to
allocate memory and copy data an extra time.

Signed-off-by: Noah.Shen <noah.shen@mediatek.com>
Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260406-mtk-spi-nor-improvements-v1-2-66f675cbbd3e@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
drivers/spi/mtk_snor.c