diff --git a/ChangeLog b/ChangeLog
index b8f2db27..75e65008 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2021-12-03  Joerg Wunsch <j.gnu@uriah.heep.sax.de>
+
+	Submitted by Alex Sverdlin:
+	patch #10153: linuxspi: Support "-E reset" and "-E noreset"
+	* linuxspi.c (linuxspi_parseexitspecs): New function
+
 2021-11-27  Joerg Wunsch <j.gnu@uriah.heep.sax.de>
 
 	bug #58440: linuxgpio PIN limit too low
diff --git a/NEWS b/NEWS
index 14b86938..a8dcca04 100644
--- a/NEWS
+++ b/NEWS
@@ -135,6 +135,7 @@ Current:
     patch #9304: [Bug #48767] Implemented WinSock variation of "ser_drain(...)" functionality
     patch #8996: Remove lock byte read mask (bug#21954, bug#46759)
     patch #8923: Enable TPI for linuxgpio
+    patch #10153: linuxspi: Support "-E reset" and "-E noreset"
 
   * Internals:
     - New avrdude.conf keyword "family_id", used to verify SIB attributes
diff --git a/linuxspi.c b/linuxspi.c
index d539773e..1ad6bcda 100644
--- a/linuxspi.c
+++ b/linuxspi.c
@@ -245,6 +245,19 @@ close_spidev:
 
 static void linuxspi_close(PROGRAMMER *pgm)
 {
+    switch (pgm->exit_reset) {
+    case EXIT_RESET_ENABLED:
+        linuxspi_reset_mcu(pgm, true);
+        break;
+
+    case EXIT_RESET_DISABLED:
+        linuxspi_reset_mcu(pgm, false);
+        break;
+
+    default:
+        break;
+    }
+
     close(fd_linehandle);
     close(fd_spidev);
     close(fd_gpiochip);
@@ -354,6 +367,26 @@ static int linuxspi_chip_erase(PROGRAMMER *pgm, AVRPART *p)
     return 0;
 }
 
+static int linuxspi_parseexitspecs(PROGRAMMER *pgm, char *s)
+{
+    char *cp;
+
+    while ((cp = strtok(s, ","))) {
+        s = 0;
+        if (!strcmp(cp, "reset")) {
+            pgm->exit_reset = EXIT_RESET_ENABLED;
+            continue;
+        }
+        if (!strcmp(cp, "noreset")) {
+            pgm->exit_reset = EXIT_RESET_DISABLED;
+            continue;
+        }
+        return -1;
+    }
+
+    return 0;
+}
+
 void linuxspi_initpgm(PROGRAMMER *pgm)
 {
     strcpy(pgm->type, LINUXSPI);
@@ -376,6 +409,7 @@ void linuxspi_initpgm(PROGRAMMER *pgm)
     /* optional functions */
     pgm->setup          = linuxspi_setup;
     pgm->teardown       = linuxspi_teardown;
+    pgm->parseexitspecs = linuxspi_parseexitspecs;
 }
 
 const char linuxspi_desc[] = "SPI using Linux spidev driver";