aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/storage/transport.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@kernel.org>2021-03-21 22:16:08 +0100
committerIngo Molnar <mingo@kernel.org>2021-03-21 22:16:08 +0100
commitca8778c45e401067cefe2abbfb8b547c30d45908 (patch)
treec10beaf40adb2bbc6a8933f87ff9da7a5366bf42 /drivers/usb/storage/transport.c
parentx86/kaslr: Return boolean values from a function returning bool (diff)
parentMerge tag 'io_uring-5.12-2021-03-21' of git://git.kernel.dk/linux-block (diff)
downloadlinux-dev-ca8778c45e401067cefe2abbfb8b547c30d45908.tar.xz
linux-dev-ca8778c45e401067cefe2abbfb8b547c30d45908.zip
Merge branch 'linus' into x86/cleanups, to resolve conflict
Conflicts: arch/x86/kernel/kprobes/ftrace.c Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'drivers/usb/storage/transport.c')
-rw-r--r--drivers/usb/storage/transport.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/usb/storage/transport.c b/drivers/usb/storage/transport.c
index 5eb895b19c55..f4304ce69350 100644
--- a/drivers/usb/storage/transport.c
+++ b/drivers/usb/storage/transport.c
@@ -656,6 +656,13 @@ void usb_stor_invoke_transport(struct scsi_cmnd *srb, struct us_data *us)
need_auto_sense = 1;
}
+ /* Some devices (Kindle) require another command after SYNC CACHE */
+ if ((us->fflags & US_FL_SENSE_AFTER_SYNC) &&
+ srb->cmnd[0] == SYNCHRONIZE_CACHE) {
+ usb_stor_dbg(us, "-- sense after SYNC CACHE\n");
+ need_auto_sense = 1;
+ }
+
/*
* If we have a failure, we're going to do a REQUEST_SENSE
* automatically. Note that we differentiate between a command