]> www.infradead.org Git - users/jedix/linux-maple.git/commit
scsi: ufs: exynos: Add gs101_ufs_drv_init() hook and enable WriteBooster
authorPeter Griffin <peter.griffin@linaro.org>
Thu, 31 Oct 2024 15:00:28 +0000 (15:00 +0000)
committerMartin K. Petersen <martin.petersen@oracle.com>
Sun, 3 Nov 2024 01:13:01 +0000 (21:13 -0400)
commit9cc4a4a5767756b1ebe45a76c4673432545ea70e
tree90439d06d04f774c5b71e8b01673e71302cdc2ac
parentf8fe71a3fe89836e9b694f4a338157f5e36abae8
scsi: ufs: exynos: Add gs101_ufs_drv_init() hook and enable WriteBooster

Factor out the common code into a new exynos_ufs_shareability() function
and provide a dedicated gs101_drv_init() hook.

This allows us to enable WriteBooster capability (UFSHCD_CAP_WB_EN) in a
way that doesn't effect other SoCs supported in this driver.

WriteBooster improves write speeds by enabling a pseudo SLC cache. Using
the 'fio seqwrite' test we can achieve speeds of 945MB/s with this
feature enabled (until the cache is exhausted) before dropping back to
~260MB/s (which are the speeds we see without the WriteBooster feature
enabled).

Assuming the UFSHCD_CAP_WB_EN capability is set by the host then
WriteBooster can also be enabled and disabled via sysfs so it is
possible for the system to only enable it when extra write performance
is required.

Signed-off-by: Peter Griffin <peter.griffin@linaro.org>
Link: https://lore.kernel.org/r/20241031150033.3440894-10-peter.griffin@linaro.org
Reviewed-by: Tudor Ambarus <tudor.ambarus@linaro.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/ufs/host/ufs-exynos.c