mirror of
https://github.com/freebsd/freebsd-src.git
synced 2026-10-28 11:25:21 +01:00
ufshci: initialize alloc_units before the dedicated-buffer scan
If every unit descriptor read failed in the LU-dedicated WriteBooster scan, alloc_units was used uninitialized. Start it at zero so that case is treated as a zero-sized buffer and WriteBooster is disabled. Sponsored by: Samsung Electronics Reviewed by: imp (mentor) Differential Revision: https://reviews.freebsd.org/D58663
This commit is contained in:
1 parent
c71705a083
commit
456ab423dd
1 file changed
+1
-1
@@ -745,7 +745,7 @@ ufshci_dev_config_write_booster(struct ufshci_controller *ctrlr)
|
||||
{
|
||||
struct ufshci_device *dev = &ctrlr->ufs_dev;
|
||||
uint32_t extended_ufs_feature_support;
|
||||
uint32_t alloc_units;
|
||||
uint32_t alloc_units = 0;
|
||||
struct ufshci_unit_descriptor unit_desc;
|
||||
uint8_t lun;
|
||||
bool is_life_time_left;
|
||||
|
||||
Reference in new issue
Block a user