Commit graph

13 commits

Author SHA1 Message Date
Daniel Lee
350e262415 storage: turn off writebooster flags upon init
Enabling writebooster capability for Pixel UFS (pa/2994670)
enabled the following flags in Android Common Kernel:

  - wb_flush_en
  - wb_flush_during_h8
  - wb_enable

This patch disables these writebooster-related flags to restore the
intended behavior for Pixel devices. This overrides the default Android
Common Kernel behavior.

While 'wb_flush_en' and 'wb_enable' have corresponding sysfs entries
('enable_wb_buf_flush' and 'wb_on') for toggling,
'wb_flush_during_h8' currently lacks this functionality in the Android
Common Kernel. Pixel provides the 'manual_gc' sysfs entry as a
workaround. Setting 'manual_gc' to 0 disables 'wb_flush_during_h8'.

Bug: 377958570
Flag: EXEMPT bugfix
Test: check if all writebooster-realated flags are false upon init
Change-Id: I918bf6939de3e208b715f554a96ccbd053f68a18
Signed-off-by: Daniel Lee <chullee@google.com>
2024-11-19 17:22:10 +00:00
Ocean Chen
3330640782 Revert "storage: Defer blkio class configuration"
This patch change the I/O schedulor back to mq-deadline before boot completed.

Bug:374905027
Test: forrest run

This reverts commit 0af034bf9f.

Change-Id: Ie49fb8a62d6fdb8da112e83d5a8e3551b0072379
2024-11-12 02:21:23 +00:00
Ocean Chen
0af034bf9f storage: Defer blkio class configuration
Move blkio class configuration from on init to on property:sys.boot_completed=1.
This improves I/O balance between foreground and background processes during boot,
as many background processes compete for I/O resources at that time.
Deferring the configuration ensures a smoother user experience
by prioritizing foreground processes.

Bug: 364960533
Test: forrest build and test on felix
Change-Id: If15343d4d96d55032618a4611bf9fdf47105c974
2024-10-07 14:48:56 +08:00
Bart Van Assche
1b0ca637f9 Merge "Make foreground and background I/O priority different" into main am: 56b74041e3 am: a24099e61b
Original change: https://android-review.googlesource.com/c/device/google/gs-common/+/3132360

Change-Id: Id6da9d867acf8fb616f75992757f7bda6083d2d4
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-19 00:22:02 +00:00
Bart Van Assche
56b74041e3 Merge "Make foreground and background I/O priority different" into main 2024-06-18 23:46:59 +00:00
Bart Van Assche
fbf228931c Make foreground and background I/O priority different
Assign a higher I/O priority to foreground I/O compared to background
I/O to improve responsiveness of the foreground app.

The command below shows that this CL has the intended effect on a device
with kernel 5.10:

    $ adb shell 'cd /dev/blkio && grep -aH . blkio.prio.class background/blkio.prio.class'
    blkio.prio.class:none-to-rt
    background/blkio.prio.class:restrict-to-be

From a device with an Android 6.1 kernel:

    $ grep -aH . blkio.prio.class background/blkio.prio.class'
    blkio.prio.class:promote-to-rt
    background/blkio.prio.class:restrict-to-be

Bug: 347109476
Change-Id: I6f1ea6a89a8dfaa223e8d2a82917b4de2d7bf1cf
Signed-off-by: Bart Van Assche <bvanassche@google.com>
2024-06-14 14:29:23 -07:00
Bart Van Assche
41836d64ce Change rq_affinity of the zoned storage logical unit from one into two
Bug: 335708738
Flag: EXEMPT This change only affects ZUFS devices
Change-Id: I3bb655856f0c27a42f26c6dd1a8fc53e7f6e1a00
Signed-off-by: Bart Van Assche <bvanassche@google.com>
2024-05-30 12:59:57 -07:00
Daniel Lee
1a0943166d Fixed a typo in init.storage.rc
"sys" -> "dev"

Change-Id: Ie7103a668cab027fb339762a7f4761b776b431f9
Signed-off-by: Daniel Lee <chullee@google.com>
2024-04-24 12:33:55 -07:00
Jaegeuk Kim
8ce08dfc7e storage: tune f2fs to get max performance
max_io_bytes : block will split out, so let's submit asap.

min_hot_blocks : don't mess up the logs per the chunk size.

Change-Id: I0795fea90c3aaee0ef6058fce7f4a3c31fc3fb42
Signed-off-by: Jaegeuk Kim <jaegeuk@google.com>
2024-04-23 16:07:15 -07:00
Qais Yousef
bebef42dbd init.storage.rc: Set rq_affinity to 2
When rq_affinity is 1, it will default to servicing the softirq on the
same CPU that has serviced the interrupt.

By setting it to 2, completions are processed by the CPU core that
submitted the I/O.

Bug: 311655524
Signed-off-by: Qais Yousef <qyousef@google.com>
Change-Id: I21421f97f069083793fe2e2fa51739dac12eca1d
2023-12-21 19:04:11 +00:00
Jaegeuk Kim
911292ecca Storage: clean up init.rc for storage
Bug: 311655524
Change-Id: Ic08d6cd42f90c2c6b697077d63fea6a2454f1cc1
Signed-off-by: Jaegeuk Kim <jaegeuk@google.com>
2023-12-20 11:22:41 -08:00
Randall Huang
c299df119e storage: dump UFS error history when capturing bugreport
Bug: 264001741
Test: capture bugreport
Change-Id: Ie910377c6378240188ff09b2a686efb02b2ac972
Signed-off-by: Randall Huang <huangrandall@google.com>
2023-10-23 06:59:04 +00:00
Randall Huang
cd8e622678 storage: turn off pixel storage debugging code on user builds
The debugging code introduces too much performance overhead for random I/O operations.
Only enable the debugging feature on non-user builds.

Bug: 284231590
Test: boot device
Change-Id: Idf6852060dfd3a250d92147a3ee0f1fe9e6140d4
Signed-off-by: Randall Huang <huangrandall@google.com>
2023-08-07 23:37:06 +00:00