Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Linux: Kernel

[PATCH] libata: fix translation for START STOP UNIT

 

 

Linux kernel RSS feed   Index | Next | Previous | View Threaded


hancockr at shaw

Jan 28, 2007, 5:29 PM

Post #1 of 8 (804 views)
Permalink
[PATCH] libata: fix translation for START STOP UNIT

Applies to 2.6.20-rc6.

---

libata's SCSI translation for the SCSI START STOP UNIT command with the
START bit clear (i.e. stopping the drive) appears to be incorrect. It
sends an ATA STANDBY command with the time period set to 0, which the
code comment says means "now", but the ATA standard says this means
disable the standby timer, which effectively does nothing. Change this
to issue a STANDBY IMMEDIATE command which will actually spin the drive
down. The SAT (SCSI/ATA Translation) standard revision 9 concurs with
this choice.

Signed-off-by: Robert Hancock <hancockr [at] shaw>

--
Robert Hancock Saskatoon, SK, Canada
To email, remove "nospam" from hancockr [at] nospamshaw
Home Page: http://www.roberthancock.com/
Attachments: libata-fix-start-stop-unit-translation.patch (0.67 KB)


jeff at garzik

Jan 30, 2007, 6:24 AM

Post #2 of 8 (784 views)
Permalink
Re: [PATCH] libata: fix translation for START STOP UNIT [In reply to]

Robert Hancock wrote:
> Applies to 2.6.20-rc6.
>
> ---
>
> libata's SCSI translation for the SCSI START STOP UNIT command with the
> START bit clear (i.e. stopping the drive) appears to be incorrect. It
> sends an ATA STANDBY command with the time period set to 0, which the
> code comment says means "now", but the ATA standard says this means
> disable the standby timer, which effectively does nothing. Change this
> to issue a STANDBY IMMEDIATE command which will actually spin the drive
> down. The SAT (SCSI/ATA Translation) standard revision 9 concurs with
> this choice.
>
> Signed-off-by: Robert Hancock <hancockr [at] shaw>

FWIW, I am having to apply Andrew Morton's version of your patches,
because your patch form isn't quite right. Review
Documentation/SubmittingPatches and http://linux.yyz.us/patch-format.html

Most notably:

* Your patch description follows the "---" terminator, which is
precisely the opposite of what should happen. In the correct form, any
comments such as "Applies to 2.6.20-rc6" should follow the "---"
terminator, which in turn follows the patch description and signoff.

* Include the patch inline rather than as an attachment. Even a
text/plain attachment is very difficult to review and quote in popular
email programs.

Jeff


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo [at] vger
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/


hancockr at shaw

Jan 30, 2007, 6:36 AM

Post #3 of 8 (778 views)
Permalink
Re: [PATCH] libata: fix translation for START STOP UNIT [In reply to]

Jeff Garzik wrote:
> * Include the patch inline rather than as an attachment. Even a
> text/plain attachment is very difficult to review and quote in popular
> email programs.
>
> Jeff

I'd love to, but unfortunately nobody seems to have come up with a way
of doing this in Thunderbird that keeps it from mangling whitespace
without a ton of hassle. I was able to get it to cooperate once (sort
of, anyway, I think it may have still damaged something on the first
try), but it required mangling a bunch of settings that made using it
for normal mail impossible.

The last time I looked, the main "how-to" page I found had an addendum
that "I gave up on this, it's too hard, I just attach the patches". If
anyone has gotten any new insight..

--
Robert Hancock Saskatoon, SK, Canada
To email, remove "nospam" from hancockr [at] nospamshaw
Home Page: http://www.roberthancock.com/


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo [at] vger
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/


jeff at garzik

Jan 30, 2007, 6:43 AM

Post #4 of 8 (782 views)
Permalink
Re: [PATCH] libata: fix translation for START STOP UNIT [In reply to]

Robert Hancock wrote:
> Jeff Garzik wrote:
>> * Include the patch inline rather than as an attachment. Even a
>> text/plain attachment is very difficult to review and quote in popular
>> email programs.
>>
>> Jeff
>
> I'd love to, but unfortunately nobody seems to have come up with a way
> of doing this in Thunderbird that keeps it from mangling whitespace
> without a ton of hassle. I was able to get it to cooperate once (sort
> of, anyway, I think it may have still damaged something on the first
> try), but it required mangling a bunch of settings that made using it
> for normal mail impossible.
>
> The last time I looked, the main "how-to" page I found had an addendum
> that "I gave up on this, it's too hard, I just attach the patches". If
> anyone has gotten any new insight..

Just use "cat mail | sendmail -t" or git-send-email, Thunderbird will
never get this stuff right.

I'm fighting Thunderbird right this second, in fact, because it randomly
decided to stop supporting drag-n-drop to sub-folders in Fedora Core 6 :(

Jeff



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo [at] vger
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/


liml at rtr

Jan 30, 2007, 4:38 PM

Post #5 of 8 (790 views)
Permalink
Re: [PATCH] libata: fix translation for START STOP UNIT [In reply to]

Robert Hancock wrote:
> Jeff Garzik wrote:
>> * Include the patch inline rather than as an attachment.

..
>
> I'd love to, but unfortunately nobody seems to have come up with a way
> of doing this in Thunderbird that keeps it from mangling whitespace

Yup, major nuisance. I have to fire up Kmail whenever I'm posting patches,
and then go back to Thunderbird again afterwards.

Cheers
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo [at] vger
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/


mbligh at mbligh

Jan 31, 2007, 12:22 AM

Post #6 of 8 (780 views)
Permalink
Re: [PATCH] libata: fix translation for START STOP UNIT [In reply to]

Jeff Garzik wrote:
> Robert Hancock wrote:
>> Jeff Garzik wrote:
>>> * Include the patch inline rather than as an attachment. Even a
>>> text/plain attachment is very difficult to review and quote in
>>> popular email programs.
>>>
>>> Jeff
>>
>> I'd love to, but unfortunately nobody seems to have come up with a way
>> of doing this in Thunderbird that keeps it from mangling whitespace
>> without a ton of hassle. I was able to get it to cooperate once (sort
>> of, anyway, I think it may have still damaged something on the first
>> try), but it required mangling a bunch of settings that made using it
>> for normal mail impossible.
>>
>> The last time I looked, the main "how-to" page I found had an addendum
>> that "I gave up on this, it's too hard, I just attach the patches". If
>> anyone has gotten any new insight..
>
> Just use "cat mail | sendmail -t" or git-send-email, Thunderbird will
> never get this stuff right.
>
> I'm fighting Thunderbird right this second, in fact, because it randomly
> decided to stop supporting drag-n-drop to sub-folders in Fedora Core 6 :(

http://mbligh.org/linuxdocs/Email/Clients/Thunderbird

Describes how to fix this.

M.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo [at] vger
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/


htejun at gmail

Jan 31, 2007, 4:27 PM

Post #7 of 8 (779 views)
Permalink
Re: [PATCH] libata: fix translation for START STOP UNIT [In reply to]

Mark Lord wrote:
> Robert Hancock wrote:
>> I'd love to, but unfortunately nobody seems to have come up with a way
>> of doing this in Thunderbird that keeps it from mangling whitespace
>
> Yup, major nuisance. I have to fire up Kmail whenever I'm posting patches,
> and then go back to Thunderbird again afterwards.

A much better solution with thunderbird is using external editor
extension.

http://globs.org/articles.php?lng=en&pg=2

Install the extension. Configure it with your favorite editor.
Thunderbird won't do a thing about your message if you turn off
linewrap.

For example, this line starts with a tab and a space and (double tab) is very long and I'm writing in emacs fired up from thunderbird. (double space)

Cheers.

--
tejun
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo [at] vger
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/


liml at rtr

Jan 31, 2007, 5:04 PM

Post #8 of 8 (788 views)
Permalink
Re: [PATCH] libata: fix translation for START STOP UNIT [In reply to]

Tejun Heo wrote:
>
> A much better solution with thunderbird is using external editor
> extension.
>
> http://globs.org/articles.php?lng=en&pg=2

Brilliant! Installed, and now tested (the max_cmd_len patch posting).

-ml
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo [at] vger
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

Linux kernel RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.