]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
cmd/scsi: drop scsi reset command
authorDavid Lechner <dlechner@baylibre.com>
Thu, 26 Mar 2026 20:39:52 +0000 (15:39 -0500)
committerTom Rini <trini@konsulko.com>
Wed, 8 Apr 2026 17:07:00 +0000 (11:07 -0600)
Since commit b630f8b3aefc ("scsi: Forceably finish migration to DM_SCSI")
the "scsi reset" command has no possibility of actually resetting any
SCSI controller. Drop the command to avoid confusion that the command is
actually resetting the SCSI controller.

Signed-off-by: David Lechner <dlechner@baylibre.com>
cmd/scsi.c
test/py/tests/test_scsi.py

index 9f7613424e59d6580f190f68b93664ae915ca020..ad7d8a4b664441ad7a8b5c28fdfda1c4fdf87c1d 100644 (file)
@@ -31,13 +31,6 @@ static int do_scsi(struct cmd_tbl *cmdtp, int flag, int argc,
        int ret;
 
        if (argc == 2) {
-               if (strncmp(argv[1], "res", 3) == 0) {
-                       printf("\nReset SCSI\n");
-                       ret = scsi_scan(true);
-                       if (ret)
-                               return CMD_RET_FAILURE;
-                       return ret;
-               }
                if (strncmp(argv[1], "scan", 4) == 0) {
                        ret = scsi_scan(true);
                        if (ret)
@@ -52,7 +45,6 @@ static int do_scsi(struct cmd_tbl *cmdtp, int flag, int argc,
 U_BOOT_CMD(
        scsi, 5, 1, do_scsi,
        "SCSI sub-system",
-       "reset - reset SCSI controller\n"
        "scsi info  - show available SCSI devices\n"
        "scsi scan  - (re-)scan SCSI bus\n"
        "scsi device [dev] - show or set current device\n"
index 2a35e47e55810400937652cd289081386c9b6f50..4390ff6584576b846d0c8021fd3e45bb370ca5e8 100644 (file)
@@ -38,16 +38,6 @@ def scsi_setup(ubman):
 
     return dev_num, dev_type, dev_size
 
-@pytest.mark.buildconfigspec('cmd_scsi')
-def test_scsi_reset(ubman):
-    dev_num, dev_type, dev_size = scsi_setup(ubman)
-    output = ubman.run_command('scsi reset')
-    assert f'Device {dev_num}:' in output
-    assert f'Type: {dev_type}' in output
-    assert f'Capacity: {dev_size}' in output
-    output = ubman.run_command('echo $?')
-    assert output.endswith('0')
-
 @pytest.mark.buildconfigspec('cmd_scsi')
 def test_scsi_info(ubman):
     dev_num, dev_type, dev_size = scsi_setup(ubman)