[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20210112093329.3639-4-martin.kepplinger@puri.sm>
Date: Tue, 12 Jan 2021 10:33:29 +0100
From: Martin Kepplinger <martin.kepplinger@...i.sm>
To: jejb@...ux.ibm.com, martin.petersen@...cle.com,
stern@...land.harvard.edu, bvanassche@....org
Cc: linux-scsi@...r.kernel.org, linux-kernel@...r.kernel.org,
Martin Kepplinger <martin.kepplinger@...i.sm>
Subject: [PATCH v2 3/3] scsi: sd: Documentation: describe ignore_resume_medium_changed
Add notes about the new sd sysfs knob that works around problems
with runtime PM for certain types of SD cardreaders.
Signed-off-by: Martin Kepplinger <martin.kepplinger@...i.sm>
---
Documentation/scsi/sd-parameters.rst | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/Documentation/scsi/sd-parameters.rst b/Documentation/scsi/sd-parameters.rst
index 87d554008bfb..a77b9fdffddf 100644
--- a/Documentation/scsi/sd-parameters.rst
+++ b/Documentation/scsi/sd-parameters.rst
@@ -25,3 +25,17 @@ To modify the caching mode without making the change persistent, prepend
"temporary " to the cache type string. E.g.::
# echo "temporary write back" > cache_type
+
+ignore_resume_medium_changed (RW)
+---------------------------------
+Some SD cardreaders deliver a "media changed" unit attention (that results
+in I/O error) when they are resumed from suspend. This prevents users
+to use runtime PM with these devices. To enable runtime PM for an SD
+cardreader (here, device number 0:0:0:0), do something like:
+
+echo 0 > /sys/module/block/parameters/events_dfl_poll_msecs
+echo 1000 > /sys/bus/scsi/devices/0:0:0:0/power/autosuspend_delay_ms
+echo auto > /sys/bus/scsi/devices/0:0:0:0/power/control
+
+And if using the mounted disk filesystem causes trouble, try setting
+ignore_resume_medium_changed to 1.
--
2.20.1
Powered by blists - more mailing lists