[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1299516532-28866-1-git-send-email-tlinder@codeaurora.org>
Date: Mon, 7 Mar 2011 18:48:51 +0200
From: Tatyana Brokhman <tlinder@...eaurora.org>
To: gregkh@...e.de
Cc: linux-arm-msm@...r.kernel.org, ablay@...eaurora.org,
Tatyana Brokhman <tlinder@...eaurora.org>,
linux-usb@...r.kernel.org (open list:USB GADGET/PERIPH...),
linux-kernel@...r.kernel.org (open list)
Subject: [RFC/PATCH 5/5] uas: HACK needed for UAS host.
REMOVE LATER ON!
In today's UAS host driver MODE SENSE command isn't handled correctly.
Each time after power up there is a unit attention condition of
RESET_OCCURRED that needs to be cleared (= acknowledged by the
host) by the MODE SENSE command.
Due to the above this patch resets the RESET_OCCURRED unit attention.
Signed-off-by: Tatyana Brokhman <tlinder@...eaurora.org>
diff --git a/drivers/usb/gadget/uasp_cmdiu.c b/drivers/usb/gadget/uasp_cmdiu.c
index 4df3d98..51eb132 100644
--- a/drivers/usb/gadget/uasp_cmdiu.c
+++ b/drivers/usb/gadget/uasp_cmdiu.c
@@ -83,6 +83,13 @@ static __u32 check_cmdiu(struct uasp_dev *udev,
curlun->lun->unit_attention_data = SS_NO_SENSE;
return ua_data;
}
+ /* HACK!!! REMOVE!!! */
+ if (curlun->lun->unit_attention_data == SS_RESET_OCCURRED &&
+ cmdiu->cdb[0] == INQUIRY) {
+ curlun->lun->unit_attention_data = SS_NO_SENSE;
+ DBG(udev->ucommon->common, "check_cmdiu() - "
+ "HACK!!! RESETTING unit attention condition\n");
+ }
}
if (curlun && !(curlun->lun->filp) && needs_medium) {
--
1.7.0.4
--
Sent by a Consultant for Qualcomm Innovation Center, Inc.
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists