public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Re: IDE/ATAPI in 2.5
@ 2002-07-15 13:26 Joerg Schilling
  2002-07-16  3:16 ` Christer Weinigel
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-15 13:26 UTC (permalink / raw)
  To: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2245 bytes --]


As my textual description has not been read, here comes a acsii art
of the proposal for a driver structure:



			User programs

----------------------------------------------------------------
----------------------------------------------------------------
|								|
|		Kernel driver interface				|
|								|
----------------------------------------------------------------
		|				|
--------------------------------  ------------------------------
|				| |				|
|	One or more SCSI	| |	One or more simple	|
|	target drivers		| |	Block based drivers	|
|	    e.g. sd.c		| |	  e.g. dsata.c		|
|				| |				|
|				| |				|
--------------------------------  ------------------------------
		|				|
		|				|------------------ Locked when
		|				|		    SCSI glue
----------------------------------------------------------------    Interface is
|				|				|   used for a
|				|				|   specific
|	SCSI glue layer		|   Block access glue layer	|   drive.
|				|				|
|	Will check if target	|				|
|	supports SCSI commands	|				|
|	and lock Block access	|				|
|	layer in this case.	|				|
|				|				|
----------------------------------------------------------------
|								|
|			 Low level glue				|
|								|
----------------------------------------------------------------
	| SCSI CDB/IF			| SCSI CDB/IF | Block IF
--------------------------------  ------------------------------
|				| |				|
|				| |				|
|	SCSI HBA driver		| |	ATA HBA driver		|
|				| |	deals with simple ATA	|
|	Only supports		| |	interface and with	|
|	SCSI CDB interface	| |	ATA packet interface	|
|				| |				|
|				| |				|
--------------------------------  ------------------------------


All HBA drivers include DMA setup callback functions to make the
target drivers completely independant from the HW.

Communication for all types of interfaces is HW address cookie
based and done via callback.

Above the glue layer, no knowledge about SCSI disconnect/reconnect
is needed.



Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-17 14:58 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-17 14:58 UTC (permalink / raw)
  To: schilling, viro; +Cc: James.Bottomley, linux-kernel, riel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1186 bytes --]

>From viro@math.psu.edu Wed Jul 17 16:00:59 2002

>> Is there any problem with using a ioctl() from upper layer kernel to the low 
>> level drivers (living under the SW raid) to reduce the number of retries to a 
>> reasonable value in this case?
>> 
>> The main design goal for UNIX as to keep it simple. There is no need for a 
>> complex cross layer error control.

>... and ioctl(2) is a gross violation of that design goal.  Ask the authors
>of UNIX how they feel about that kludge, let alone propagation of said kludge
>beyond the TTY layer where it had originated (or about the entire v7 TTY layer,
>for that matter - v8 and later had thrown that crap away).

ioctl()s do introduce a common abstract interface layer.

Tell me how else you would like to set similar things in e.g. different disk 
type drivers.

In Plan 9, they did replace them with a text interface to /dev/{driver}.ctl

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-17 13:46 Joerg Schilling
  2002-07-17 14:00 ` Alexander Viro
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-17 13:46 UTC (permalink / raw)
  To: riel, schilling; +Cc: James.Bottomley, linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1629 bytes --]


>From riel@imladris.surriel.com Wed Jul 17 15:37:18 2002

>> >Error handling is more than local.  Some errors, you are correct, can only be
>> >handled at the SCSI layer.  However, a large class of drivers (Think
>> >multi-path or software raid) want the ability to direct how SCSI handles
>> >errors themselves.  It is unacceptable to have SCSI all on its own retry a
>> >medium error command x times, taking minutes before the upper layers become
>> >aware anything went wrong.
>>
>> It looks like you have the wrong ideas about software raid. If you have
>> software raid, you will stack a SW raid driver just on top of the disk
>> drivers that handle the access to the real drives. The real drives first
>> do own error handling and if they cannot correct errors, the error is
>> handled inside the raid layer.

>Did you even read what James wrote ?

>When one of the disks in a RAID array develops a bad block
>it shouldn't stall the box for minutes when the error can
>be handled by simply doing the IO from other disks instead.

Is there any problem with using a ioctl() from upper layer kernel to the low 
level drivers (living under the SW raid) to reduce the number of retries to a 
reasonable value in this case?

The main design goal for UNIX as to keep it simple. There is no need for a 
complex cross layer error control.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-17 12:32 Joerg Schilling
  2002-07-17 13:36 ` Rik van Riel
  2002-07-17 13:54 ` Anton Altaparmakov
  0 siblings, 2 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-17 12:32 UTC (permalink / raw)
  To: James.Bottomley, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 4153 bytes --]


>From James.Bottomley@SteelEye.com Tue Jul 16 16:33:32 2002
>schilling@fokus.gmd.de said:
>> Why should the character interface be connected to the block layer?
>> This would contradict UNIX rules. 

>Well, first and foremost Linux isn't UNIX, especially where block and 
>character devices are concerned.  But secondly, the block layer provides 
>command queueing.  If any device (SCSI, IDE or more exotic) can't accept a 
>character command (like QUEUE_FULL in SCSI), it goes back to the block layer 
>queue to await reissue.  It's really exactly a block request without the block 
>position.

You describe here how the block layer in UNIX works....

>This is actually almost the way linux operates now:  all the character tap for 
>a SCSI tape device does is take the read or write and convert it into an 
>appropriate SCSI command, which now has a block extent attached.  Since we 
>have all the machinery for handling block command queuing in the block layer, 
>it makes no sense to duplicate it for the character layer.

If Linux really handles it this way, then I don't see any sense in it.
If you like to do things that are different from the UNIX default for block
or character drivers for disk devices, you should try to use mmap() and 
madvise().

>Error handling is more than local.  Some errors, you are correct, can only be 
>handled at the SCSI layer.  However, a large class of drivers (Think 
>multi-path or software raid) want the ability to direct how SCSI handles 
>errors themselves.  It is unacceptable to have SCSI all on its own retry a 
>medium error command x times, taking minutes before the upper layers become 
>aware anything went wrong.

It looks like you have the wrong ideas about software raid. If you have 
software raid, you will stack a SW raid driver just on top of the disk drivers 
that handle the access to the real drives. The real drives first do own error 
handling and if they cannot correct errors, the error is handled inside the 
raid layer. As the raid layer itself will at it's top level act as if it was a 
disk driver, there is no relation to the block layer.


>The solution is to have a stacking error handler where the error handler for 
>upper devices would be notified of a problem and asked for direction as soon 
>as it occurs.

See above, this makes no sense.

>But the new scheme allows that.  The block queues accept translated requests 
>(that's really what sg does).

A SCSI request is _not_ a translated request. It is the real request itself. 
You usually even cannot translate a SCSI request into something else.


>> It would help, if somebody would correct the current SCSI addressng

>> Why do you believe that you need to have something that is not a
>> bumber? 

>Look at a solaris fibre driver for instance.  On the fabric, most of them 
>think of targets in terms of WWN/PORT (because that's what the fibre LIP 
>uses).  They then have an internal database to translate what they use 
>(WWN/PORT, soft loop ID, etc.) into a target number for the user to see.  
>Next, because the fibre topology is mutable, they have to have a way of 
>mapping the WWN/PORT to the device across reboots, hence persistent binding.  
>Ultimately you get a huge chunk of code whose sole job is to preserve the 
>fiction that targets are numbers.

You also need to authenticate yourself before you may get access to the network 
media. Once you did this, you simply may assign a Bus number to the cabinet.


>> Let me add my modified artwork: 

>But you're still too SCSI transport specific.  The ongoing goal is to make the 
>physical transport protocol an adjunct to the Linux internal transport (the 
>struct request) so that we can treat all block/character devices on an equal 
>footing.

You seem to forget that all main control is done via SCSI commands. You are too 
anti SCSI wthout a real reason.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-16 17:49 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-16 17:49 UTC (permalink / raw)
  To: jauderho, schilling; +Cc: James.Bottomley, linux-kernel, vojtech

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1966 bytes --]

>From: Jauder Ho <jauderho@carumba.com>

>And path_to_inst does not always do the RightThing(tm). [1] [2] Two
>systems identically configured has the potential of having path_to_inst
>look different. Especially if you have previously installed a device or
>moved stuff around. And if the expectation is that a group of devices will
>come up in a certain sequence (think shared tape devices for instance) and
>it changes, it quickly becomes a nightmare. Not a fun proposition by any
>means.

The Solaris /etc/path_to_inst method works 99.9% as expected. And important,
it is very stable in special for novice users. If you really have the problems 
as described, you could alwas edit /etc/path_to_inst manually and reboot.
Please note: If you install two systems with te same hardware configuration the 
same way _and_ in the same _order_, the will have an identical 
/etc/path_to_inst.

If I have to decide between a mostly rock solid system and a system that always 
behaves in a way that is not predictable, I would take the first one.


>[1] eg http://www.myri.com/scs/documentation/mug/installation/solaris.html

The author of this driver lacks the needed experience in writing DLPI drivers.
Although this lack of knowledge seems to be not uncommon (the FORE ATM driver 
is broken too), it is possible to do it right. The ATM DLPI driver I did write 
in 1995 did work correctly after I did educate me about the correct interface.
You simply need to be able to deal with the fact that instance #0 os a driver 
is not present while one or more instances with instance # > 0 _are_ present.

>[2] http://www.magma.com/support/sun.htm

Looks like a similar problem as above.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-16 17:34 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-16 17:34 UTC (permalink / raw)
  To: Richard.Zidlicky, schilling; +Cc: andersen, linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1160 bytes --]

>From: Richard Zidlicky <Richard.Zidlicky@stud.informatik.uni-erlangen.de>

>> >Solaris vold? Thanks no, floppy access was so easy in SunOS before the 
>> >days of the volume manager.
>> 
>> .... and it is even simpler since vold is present. Call volcheck to tell vold
>> that the media changed or use a SCSI floppy which supports to tell the kernel
>> that a media change did happen.

>when it is properly configured which doesn't seem the common case.
>More often than not, things like accessing raw floppy images turn
>out to be a problem.

Being properly configured _is_ the common case if you don't change things 
manually. A standard Solaris system install from scratch will always result in 
a usable floppy drive that is handled as expected by vold.

Try to keep your fingers away from the vold configuration files after you did a 
clean install from scratch.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-16 14:30 Richard Zidlicky
  0 siblings, 0 replies; 204+ messages in thread
From: Richard Zidlicky @ 2002-07-16 14:30 UTC (permalink / raw)
  To: schilling; +Cc: andersen, linux-kernel


> 
> >Solaris vold? Thanks no, floppy access was so easy in SunOS before the 
> >days of the volume manager.
> 
> .... and it is even simpler since vold is present. Call volcheck to tell vold
> that the media changed or use a SCSI floppy which supports to tell the kernel
> that a media change did happen.

when it is properly configured which doesn't seem the common case.
More often than not, things like accessing raw floppy images turn
out to be a problem.

> >> -	The volume manager should have a documented interface that allows 
> >> 	programs like e.g. cdrecord to gain exclusive access to a CD drive.
> 
> >much simpler, cdrom driver needs an ioctl to claim exclusive use of
> >the device and cdrecord than needs to use that ioctl.
> 
> This will not work. What should happen when the drive is mounted?

block or return -EBUSY.

Richard

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-16 14:06 Joerg Schilling
  2002-07-16 14:15 ` Christoph Hellwig
  2002-07-16 14:17 ` Lars Marowsky-Bree
  0 siblings, 2 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-16 14:06 UTC (permalink / raw)
  To: James.Bottomley, lmb, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1416 bytes --]


>From lars@marowsky-bree.de Tue Jul 16 13:45:59 2002

>> Why should the character interface be connected to the block layer?
>> This would contradict UNIX rules.

>How would it? At some layer, the two are merged anyway (for example, at least
>on disk you'll have blocks again). Doing it up high means more unified code
>below.

Just a hint: the block layer is for caching blocks from disk type deveices.

-	Block device access is always going directly into the block cache.
	So the I/O is always kernel I/O. In addition, it is async I/O - the 
	block layer fires it up and may wait for it later after sending out other
	requests.

-	Character device access is synchronous access and may be either kernel
	or user space DMA access. In most cases, it is user space DMA access.

How try to ask your question again...


>> AFAIK, tagged command queuing is a SCSI specific property, why should this
>> be part of a generif block layer?

>That is not true. Late IDE also has this, and systems like drbd - which
>currently uses a quite clever heuristic to deduce barriers - could also
>utilize this input.

How is it implemented?

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-16 14:02 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-16 14:02 UTC (permalink / raw)
  To: dalecki, schilling; +Cc: James.Bottomley, linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 3634 bytes --]

>From dalecki@evision-ventures.com Tue Jul 16 13:43:18 2002

>>>                  User Level
>>>--------------------------------------------------------------
>>=20
>>=20
>>>+----------------+   +---------------------+
>>>| Block Interface|   | Character Interface |
>>>+----------------+   +---------------------+
>>>        |                        |
>>>        |   +--------------------+
>>=20
>>=20
>> Why should the character interface be connected to the block layer?
>> This would contradict UNIX rules.

>Bullshit. UNIX sees even every single block device as both: char and bloc=
>k
>even under the same major number. The reason above is - tape devices.

Don't make conclusions from Linux, have a look at UNIX first:

-	All traditional UNIXes including vanilla SVSvr4 use different
	major numbers for block and char dev entries.

	... I call this a design bug, but take it for given.

-	UNOS, a real time UNIX clone from 1982 did have a unique driver
	switch table and the same major for block/character devices.
	UNOS has no connection to the UNIX genealogy tree.

-	Solaris 2.1 introduced together with dynamic and virtual major device
	numbers a unique interface for block and character devices.

The fact that Linux did not have character device nodes for disks until shortly
should not confuse you.

Tape block drivers only make sense with something like DECtapes.
DECtapes used as block device have been used to boot emergency recovery systems
on PDP-11 sty computers. Booting took a long long time then.

>>>The driving vision for this is to move into the generic block layer as =
>much of=20
>>>the individual transport stack as makes sense (i.e. if other transports=
> can=20
>>>make use of the functions), so, for example, Tag command queueing is al=
>ready=20
>>>in there and shared between IDE and SCSI.
>>=20
>>=20
>> AFAIK, tagged command queuing is a SCSI specific property, why should t=
>his
>> be part of a generif block layer?

>Becouse it is not SCSI specific. SerialATA will *nearly* require it.
>And there are ATA disks out there which do it *right now* too.

How do you access these properties then? Using SCSI commands?


>Your proposal has one flaw - it thinks that SCSI is the mother of
>all block devices and thinks that the kernel should have a SCSI driver
>with some kind of direct translation for any other devices. This is
>wrong becouse you go:

>1. abstract access.

Which is not a problem

>2. SCSI access.

Not a problem too for all drives that support SCSI commands.

>3. back to abstract access.

??? Looks like you missundertood even the ATAPI layering.
BTW: I don't reqiest that SCSI commands are used for ATA only drives.

>4. ATA access.

See above...

>This is at least not fine. The proposal by James takes in to
>account that dealing with ATAPI ver. SCSI MMC shouldn't be done
>on any kind of "layer" it fits better in the abstraction
>of an utility library supposed to help unify code. But not an
>additional layer between the generic one and the device transfer.
>You have to have an independant transport layer for IDE attached
>devices becouse the whole handling of the transfer works significantly
>different from SCSI.

Please show me how you would like to read a sector of audio data off
a MMC ATAPI drive without using SCSI commands. Vanilla ATA read access
is of vely limited use.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-16 12:49 Joerg Schilling
  2002-07-16 14:28 ` Jauder Ho
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-16 12:49 UTC (permalink / raw)
  To: schilling, vojtech; +Cc: James.Bottomley, linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1080 bytes --]

>From vojtech@ucw.cz Tue Jul 16 13:59:27 2002

>> It would help, if somebody would correct the current SCSI addressng scheme used 
>> in Linux. Linux currently uses something called BUS/channel/target/lun.
>> This does not reflect reality.
>> 
>> What Linux calls a SCSI bus is definitely not a SCSI bus but a SCSI HBA card.
>> What Linux calls a channel really is one of possibly more SCSI busses going
>> off one of the SCSI HBA cards. It makes sense to just count SCSI busses.

>Well, no. It doesn't. Because the numbers will change if you add a card
>(even at runtime - hotplugging USB SCSI is something real happening
>today. And that'd be a very bad thing.

It hey change, then this is a Linux kernel problem. On Solaris they don't 
change because Solaris manages /etc/path_to_inst

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-16 11:28 Joerg Schilling
  2002-07-16  9:33 ` James Bottomley
                   ` (3 more replies)
  0 siblings, 4 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-16 11:28 UTC (permalink / raw)
  To: James.Bottomley, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 7942 bytes --]


>From James.Bottomley@steeleye.com Mon Jul 15 18:09:52 2002

>Actually, the diagram is very similar to what we possess internally today.

>This represents where I think the SCSI stack is going:

>                   User Level
>--------------------------------------------------------------

> +----------------+   +---------------------+
> | Block Interface|   | Character Interface |
> +----------------+   +---------------------+
>         |                        |
>         |   +--------------------+

Why should the character interface be connected to the block layer?
This would contradict UNIX rules.

>         |   |
> +---------------------+
> | Block Layer         |     +----------------------+
> | provides queueing   |     | Device Prep Functions|
> | and elevator if     |     | st, sd, sg, etc.     |
> | necessary.          |-----| Does transport       |
> | Also provides all   |     | translation          |
> | support functions   |     +----------------------+
> | that may be shared  |                |
> | across transports.  |     +----------------------+
> |                     |     | Stackable error      |
> |                     |-----| handling (not well   |
> |                     |     | thought out yet)     |
> |                     |     +----------------------+

Why should the error handlers interface with the block layer?
This is not true for UNIX and it would not help. However, it would
be nice to have a way to make the blocklayer find out that e.g. 
only the last sector  of a multi sector read ahead instruction 
did fail.

> |                     |
> |                     |         +--------------------+
> |                     |         | Transport helper   |
> |                     |         | Contains all fns   |
> |                     |         | not shareable by   |
> |                     |         | other transports   |
> +---------------------+         +--------------------+
>                   |                  |
>                   |                  |
>                 +-------------------------+
>                 | Card driver (deals with |
>                 | attached transport      |
>                 | translation             |
>                 +-------------------------+


>As you can see, I plan to leverage the generic block layer to build the 
>transport stack.  The upper layer drivers become mere request_prep_fns whose 
>job is to translate the request to a transport specific command.

>The struct request will go all the way down to the card driver, but the card 
>driver may choose to deal only with the transport translation if it wants.

>The driving vision for this is to move into the generic block layer as much of 
>the individual transport stack as makes sense (i.e. if other transports can 
>make use of the functions), so, for example, Tag command queueing is already 
>in there and shared between IDE and SCSI.

AFAIK, tagged command queuing is a SCSI specific property, why should this
be part of a generif block layer?
The block layer shuld simply send more than one request before waiting for
the requests to finish. Then a tagged command queuing aware sd.c could choose 
to fill up the tagged queue that is handled by the SCSI glue layer.

>The ultimate end point will be when the correct balance between what belongs 
>in the generic block layer and what belongs in the transport helpers is 
>achieved.  I speculate that, for CDROMS, this will lead to two small request 
>prep modules sharing quite a large helper library (The helper library would do 
>SCSI command translation, and probably the IDE prep module would fix up the 
>transport command for the specific device).  However, I don't rule out that it 
>would lead to a single prep module for both IDE and SCSI.

With my proposal, anything that speaks SCSI is used via SCSI commands and a 
generic SCSI driver like scg.c could access the SCSI transport aware drives
of any type. An important (communication baesed) feature of my SCSI glue layer 
would be to make it possible to insert SCSI commands from scg.c without making 
sd.c believe that something strange and unexpected happened to one of it's drives.

>The device naming issues are totally separate from the above.  I intend that 

Agreed.

>driverfs will cope with them.  Internally, the block layer just thinks of the 
>stack as a series of entry points for physical devices.  Driverfs gives the 
>card driver freedom to provide a hierarchical ascii device name as it sees 
>fit.  Hopefully this will finesse the so called persistent binding issues that 
>plague solaris.

It would help, if somebody would correct the current SCSI addressng scheme used 
in Linux. Linux currently uses something called BUS/channel/target/lun.
This does not reflect reality.

What Linux calls a SCSI bus is definitely not a SCSI bus but a SCSI HBA card.
What Linux calls a channel really is one of possibly more SCSI busses going
off one of the SCSI HBA cards. It makes sense to just count SCSI busses.

>Ultimately, this means that host and channel is subsumed into the card 
>identification scheme, target ID may no longer be a number and even LUN may 
>end up being a LUN hierarchy representation.  As we do this, we'll move to 
>exposing persistent names, so the user shouldn't necessarily care about this.


Why do you believe that you need to have something that is not a bumber?

As a result of your drawing, I introduced the block layer (which is the 
traditional UNIX block cache). I also had the idea that it may be a good
idea to make the simple block based I/O driver part or slave of the SCSI
CDB based driver (although it would use a different portal to the glue layer).
This way, it would be possible to have e.g. a single name space for all
hard disks.


Let me add my modified artwork:

			User programs

----------------------------------------------------------------
----------------------------------------------------------------
|								|
|		Kernel driver interface				|
|								|
----------------------------------------------------------------
		|				|
------------------------			|
|			|			|
| Block I/O layer	|			| Raw I/O IF
|			|			|
------------------------			|
		|				|
Block I/O IF	|				|
		|				|
----------------------------------------------------------------
|				  ------------------------------
|				 |				|
|	One or more SCSI	 |	Block based I/O       	|
|	target drivers		 |	handling routines	|
|	    e.g. sd.c		 |	not used if SCSI based	|
|	st.c, scg.c		 |	I/O is possible to a	|
|				 |	specific drive		|
				  ------------------------------
----------------------------------------------------------------
		|				|
SCSI CDB IF	|		 Block based IF	|------------------ Locked when
		|				|		    SCSI glue
----------------------------------------------------------------    Interface is
|				|				|   used for a
|				|				|   specific
|	SCSI glue layer		|   Block access glue layer	|   drive.
|				|				|
|	Will check if target	|				|
|	supports SCSI commands	|				|
|	and lock Block access	|				|
|	layer in this case.	|				|
|				|				|
----------------------------------------------------------------
|								|
|			 Low level glue				|
|								|
----------------------------------------------------------------
	| SCSI CDB/IF			| SCSI CDB/IF | Block IF
--------------------------------  ------------------------------
|				| |				|
|				| |				|
|	SCSI HBA driver		| |	ATA HBA driver		|
|				| |	deals with simple ATA	|
|	Only supports		| |	interface and with	|
|	SCSI CDB interface	| |	ATA packet interface	|
|				| |				|
|				| |				|
--------------------------------  ------------------------------
Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-16 11:02 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-16 11:02 UTC (permalink / raw)
  To: riel, schilling; +Cc: linux-kernel, willy

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1012 bytes --]

>From: Rik van Riel <riel@conectiva.com.br>

>> I would be happy to hear about concepts. Currently it looks as if at
>> least some people like to keep everything as it is. This is not a
>> conceptional OS but a grown structure. If you like to keep code
>> maintainable for a long time, you need to clean up the thicket from time
>> to time.

>I couldn't agree more.  Now, why do you oppose cleaning up
>the "use scsi as everyone's mid layer" hack and putting a
>better generic abstraction in place ?

Why do you try to invert my postings?

I definitely like to see a better overall solution and I am talking about it
the same way during the last 4 years. Why should I change my mind if Linux 
did not change in between?

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-16 10:47 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-16 10:47 UTC (permalink / raw)
  To: Richard.Zidlicky, schilling; +Cc: andersen, linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1424 bytes --]

>From rdzidlic@faui02.informatik.uni-erlangen.de Tue Jul 16 12:37:56 2002

>> >The potential for breakage is huge, people run automounters on CD's,
>> >file managers may try to mount the CD without asking the user.
>> 
>> The bad news is that it seems that the automounters are part of the GUIs and 
>> not well enough documented. There should be:
>> 
>> -	Something like the Solaris volume manager that is part of the base OS 
>> 	and kernel folks should forbid GUI folks to add such tasks to the GUI

>Solaris vold? Thanks no, floppy access was so easy in SunOS before the 
>days of the volume manager.

.... and it is even simpler since vold is present. Call volcheck to tell vold
that the media changed or use a SCSI floppy which supports to tell the kernel
that a media change did happen.

>> -	The volume manager should have a documented interface that allows 
>> 	programs like e.g. cdrecord to gain exclusive access to a CD drive.

>much simpler, cdrom driver needs an ioctl to claim exclusive use of
>the device and cdrecord than needs to use that ioctl.

This will not work. What should happen when the drive is mounted?


Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* RE: IDE/ATAPI in 2.5
@ 2002-07-15 18:27 Nick Bellinger
  2002-07-15 20:12 ` Jauder Ho
  2002-07-16  7:49 ` Buddy Lumpkin
  0 siblings, 2 replies; 204+ messages in thread
From: Nick Bellinger @ 2002-07-15 18:27 UTC (permalink / raw)
  To: Buddy Lumpkin; +Cc: linux-kernel



>I think someone is misunderstanding some industry buzz words here ...
>NAS refers to Network Attached Storage, as in via NFS, AFS, et al.
>What your showing in the output of the Solaris format command are
>raw SCSI LUNS attached via fibre channel (fabric or loop) or native
>scsi.

Just as a matter of clarification, the above two examples NFS and AFS
are most certainly NOT Network Attached Storage aka NAS.  The former is
an simple Networked File System, and the latter the first practical
distributed file system (ie: multiple client access to shares), but they
both provide access to storage resources at the FILE SYSTEM level.  

The term 'NAS' (and SAN for that matter as the terms are pretty much
used interchangeably these days) refer to moving raw disk protocol
Command Descriptor Blocks aka CDBs and its associated data across the
network at the BLOCK level.  But storage folks generically regard the
terms as: NAS refers to BLOCK level storage over IP networks,  and SAN
to BLOCK level storage over a Fibre Channel setup. 

The reason being a Storage Area Network is generally a closed, secure,
and seperate entity from ones IP network,  while Network Attached
Storage is storage added directly into an existing IP network.  Of
course this opens up all of related security considerations when dealing
with IP networks,  but a discussion of the related issues is beyond the
scope of this reply, and dangerously off-topic.


		Nicholas 'trying to keep it real' Bellinger


>>From venom@sns.it Mon Jul 15 11:11:59 2002
>>On Sun, 14 Jul 2002, Rik van Riel wrote:

>>> > BTW: did you ever look at Solaris / HP-UX, ... and the way they
>>> > name disks?
>>> >
>>> > someting like: /dev/{r}dsk/c0t0d0s0
>>> > This is SCSI bus, target, lun and slice.
>>>
>>> I wonder what they'll change it to in order to support
>>> network attached storage.
>>>
>>Actually notthing:

>>dbtecnocasa:{root}:/>format
>>Searching for disks...done

>>c2t1d0: configured with capacity of 6.56MB
>>c2t1d30: configured with capacity of 34.04GB
>>c2t1d31: configured with capacity of 34.04GB
>>c2t1d81: configured with capacity of 34.04GB


>>AVAILABLE DISK SELECTIONS:
>>       0. c0t0d0 <SUN18G cyl 7506 alt 2 hd 19 sec 248>
>>          /pci@1f,4000/scsi@3/sd@0,0
>>       1. c2t1d0 <EMC-SYMMETRIX-5567 cyl 14 alt 2 hd 15 sec 64>
>>          /pci@4,2000/scsi@1/sd@1,0
>>       2. c2t1d30 <EMC-SYMMETRIX-5567 cyl 37178 alt 2 hd 30 sec 64>
>>          /pci@4,2000/scsi@1/sd@1,1e
>>       3. c2t1d31 <EMC-SYMMETRIX-5567 cyl 37178 alt 2 hd 30 sec 64>
>>          /pci@4,2000/scsi@1/sd@1,1f
>>       4. c2t1d81 <EMC-SYMMETRIX-5567 cyl 37178 alt 2 hd 30 sec 64>
>>          /pci@4,2000/scsi@1/sd@1,51

>>except of c0t0d0 everything else is network attached...


>How is it attached? Using FACL or ISCSI?

>In any case, it seems to be a natural solution to do it this way.

>In order to access a network disk, you need to obtain the right to
>do so first. Once this has been done, the netork subsystem just looks
>like a new SCSI bus.

>Jörg




^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-15 15:08 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-15 15:08 UTC (permalink / raw)
  To: riel, schilling; +Cc: linux-kernel, willy

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1200 bytes --]


>From: Rik van Riel <riel@conectiva.com.br>
>On Mon, 15 Jul 2002, Joerg Schilling wrote:

>> I would be happy to hear about concepts. Currently it looks as if at
>> least some people like to keep everything as it is. This is not a
>> conceptional OS but a grown structure. If you like to keep code
>> maintainable for a long time, you need to clean up the thicket from time
>> to time.

>I couldn't agree more.  Now, why do you oppose cleaning up
>the "use scsi as everyone's mid layer" hack and putting a
>better generic abstraction in place ?

I never said this.

I would like to see a integrated aproach where the mid level prevents something
like ide-cd to access ATAPI drives. In this case, there is a unique address 
space and generic SCSI transport systems like libscg will be able to work
in a way that is easy to understand by outsiders and does not force me to add
one workaround after the other.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-15 13:07 Joerg Schilling
  2002-07-16 10:16 ` Richard Zidlicky
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-15 13:07 UTC (permalink / raw)
  To: Richard.Zidlicky, schilling; +Cc: andersen, linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1639 bytes --]


>From: Richard Zidlicky <Richard.Zidlicky@stud.informatik.uni-erlangen.de>

>> >There is another problem, with your scsi transport library you
>> >are bypassing normal Linux devices. Try
>> >  mount /dev/scd0 /mnt
>> >  cdrecord -dev 0,0,0 -blank=fast
>> >  ls -al /mnt
>> 
>> >Nice? It certainly isn't the fault of Linux if you choose to
>> >bypass normal device usage and it can be very annoying not
>> >only for beginners.
>> 
>> It is not a fault of cdrecord either.

>A cure would be nice and I don't see what the kernel could do
>to solve this problem as long as cdrecord insists on talking
>to the SCSI bus directly.

>If nothing else, cdrecord manpage
> - should make a big fat warning about it
> - should stop claiming that it is safe to suid cdrecord

>The potential for breakage is huge, people run automounters on CD's,
>file managers may try to mount the CD without asking the user.

The bad news is that it seems that the automounters are part of the GUIs and 
not well enough documented. There should be:

-	Something like the Solaris volume manager that is part of the base OS 
	and kernel folks should forbid GUI folks to add such tasks to the GUI

-	The volume manager should have a documented interface that allows 
	programs like e.g. cdrecord to gain exclusive access to a CD drive.

Then the problem above could be solved.


Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-15 12:58 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-15 12:58 UTC (permalink / raw)
  To: root, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1693 bytes --]

>From: "Richard B. Johnson" <root@chaos.analogic.com>
>> >From root@chaos.analogic.com Fri Jul 12 22:18:47 2002
>> 
>> >As much as I hate IDE, IDE isn't going away. All my systems use SCSI
>> >so on machines that have CD/ROMS, I use your libraries and your tools.
>> 
>> >Maybe somebody should make CD/ROM code that directly talks to IDE via
>> >/dev/hdwhatever, instead of expecting you to modify your code that
>> >has worked so well for so long.
>> 
>> This would be a really bad idea.
>> 
>> Such a change would force me to add a 6th (and unneeded) new interface.
>> Why? What problem would be solved if you did introduce such an interface?
>> 

>Well for one thing it eliminates the requirement to
>include SCSI interface code on machines that don't
>have SCSI. That's the practical aspect.

>Now, the esoteric. Do you truly think that it is
>proper to encapsulate devices in various layers?

>The IDE interface, if it wasn't for the bug-workarounds,
>is just a floppy disk interface that uses a different
>controller chip. It is register-based, not message-
>based. If you throw in a message-based control layer
>(SCSI), what problems are you solving? It's a
>rhetorical question. No answer is required.

If you like to use the floppy only via the ATA registers, then
you don't like to be able to format media?

BTW: the overhead to set up DMA is higher than the overhead to set up a SCSI 
CDB.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-15 12:27 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-15 12:27 UTC (permalink / raw)
  To: andre, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2401 bytes --]

>From: Andre Hedrick <andre@linux-ide.org>

>> >Now your silly PCATA stupid ass Tailgate Bridge that you are boasting
>> >about does some of the worst things anyone could ever imagine.
>> 
>> ???? Looks stupid (like dou did not get the message).

>I guess I need to break it down to simple terms, and hoped that your
>broadcast in expertise could cover your mouth.  This makes it harder for
>me because I do not communicate well over email.

>Firewire 1394, USB, Parallel Port, PCMCIA/CardBus are all effective
>tailgates via an alternate physical transport layer and protocol.
>Therefore it should be obvious many different versions of the hardware get
>it wrong.  Now in other operating system which are commerial based, there
>are device specific drivers to perform soft-protocol corrections to
>generate the appearance of a perfect product.  Much as in optics, here is
>another case where two wrongs make a right.  COSTAR for Hubble Space
>Telescope is real world example.

If _you_ had the experience you pretend, then why do you claim that the fact 
that I cannot use ide-scsi with a PCATA connection to my CD writer is caused
by bad hardware?

As the drive becomes usable with CDROM_SEND_PACKET and is completely unusable 
via ide-scsi it is obvious that the reason cannot be a hardware problem but must 
be a driver design bug.


>If you knew anything about the production industry, and maybe you do, it
>would be obvious that most of the Far East and Pacific Ring hardware
>people are still creating product based on SFF-8020 a retired document.

If this affects the drivers, then there need to be a workaround regardless of 
the driver layering model in use.

>> I am not whining, but you answer with  unrelated stuff. Why? Are you missing
>> experience and arguments?

>I just asked you for a formal preferred model coresponding to READ/WRITE
>10/16 fixed to the OS standard CDB as the base of a Packet Interface, yet
>you counter with a redirect. :-/

>Put up or shut up.

>Insert "Joerg Schilling" Perfect Packet Interface for review.

Why didn't you read my short abstract I send out yesterday?

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-15 11:27 Joerg Schilling
  2002-07-15 14:52 ` Rik van Riel
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-15 11:27 UTC (permalink / raw)
  To: schilling, willy; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2487 bytes --]

>From willy@w.ods.org Sun Jul 14 21:02:38 2002

>Jörg,

>could you please stop starting all your mails like this one and
>insulting every people who don't obviously understand what you
>nearly didn't explain in 30 mails ? You're whinning about people
>who don't take you seriously, but you don't try to be constructive.

I have already been constructive and wrote some lines that showed up
how a driver tree could look like. Unfortunately nobody did take this
proposal as a base for a future discussion.

Being constuctive does not make sense if it is obvious that other
people don't listen.

The discussion now looks better than a day ago... If I have read my mail
from the weekend, I may try to draw an image as it may be that people in this 
list do not like text.

>Since you claim to have very clear ideas about what you'd like to
>see in the kernel, please post a clear and complete proposal here
>(with another subject, BTW since most people won't read it else).

I already did (see above).

>This way, you'll be able to argue on technical points with some
>competent and clever people, but you won't if you continue to
>measure your personal experience to that of others. You say you
>don't want to talk to them because, unlike you, they don't know
>what a kernel is, but this is non sense. They may have a different
>conception than you, that's all.

I would be happy to hear about concepts. Currently it looks as if at least
some people like to keep everything as it is. This is not a conceptional OS but 
a grown structure. If you like to keep code maintainable for a long time,
you need to clean up the thicket from time to time. This seems to be something 
that is not done frequent enough with most free software. I know how to
clean up software and I do it from time to time with my software.
Look e.g. at star, it started in 1982 and the fully usable version is now 17 
years old. It was still possible to add something like POSIX.1-2001 compliance 
within ~ 2 weeks. Try to do this with GNU tar...


>>From your claimed experience, you seem to be 45, but from your
>attitude, 8. I think reality is between both, but I hope the
>former.

Well, I try to match with the crowd ;-)


Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-15 11:09 James Bottomley
  0 siblings, 0 replies; 204+ messages in thread
From: James Bottomley @ 2002-07-15 11:09 UTC (permalink / raw)
  To: Joerg Schilling; +Cc: linux-kernel, James.Bottomley

James.Bottomley@SteelEye.com said:
> As my textual description has not been read, here comes a acsii art of
> the proposal for a driver structure:

Actually, the diagram is very similar to what we possess internally today.

This represents where I think the SCSI stack is going:

                   User Level
--------------------------------------------------------------

 +----------------+   +---------------------+
 | Block Interface|   | Character Interface |
 +----------------+   +---------------------+
         |                        |
         |   +--------------------+
         |   |
 +---------------------+
 | Block Layer         |     +----------------------+
 | provides queueing   |     | Device Prep Functions|
 | and elevator if     |     | st, sd, sg, etc.     |
 | necessary.          |-----| Does transport       |
 | Also provides all   |     | translation          |
 | support functions   |     +----------------------+
 | that may be shared  |                |
 | across transports.  |     +----------------------+
 |                     |     | Stackable error      |
 |                     |-----| handling (not well   |
 |                     |     | thought out yet)     |
 |                     |     +----------------------+
 |                     |
 |                     |         +--------------------+
 |                     |         | Transport helper   |
 |                     |         | Contains all fns   |
 |                     |         | not shareable by   |
 |                     |         | other transports   |
 +---------------------+         +--------------------+
                   |                  |
                   |                  |
                 +-------------------------+
                 | Card driver (deals with |
                 | attached transport      |
                 | translation             |
                 +-------------------------+


As you can see, I plan to leverage the generic block layer to build the 
transport stack.  The upper layer drivers become mere request_prep_fns whose 
job is to translate the request to a transport specific command.

The struct request will go all the way down to the card driver, but the card 
driver may choose to deal only with the transport translation if it wants.

The driving vision for this is to move into the generic block layer as much of 
the individual transport stack as makes sense (i.e. if other transports can 
make use of the functions), so, for example, Tag command queueing is already 
in there and shared between IDE and SCSI.

The ultimate end point will be when the correct balance between what belongs 
in the generic block layer and what belongs in the transport helpers is 
achieved.  I speculate that, for CDROMS, this will lead to two small request 
prep modules sharing quite a large helper library (The helper library would do 
SCSI command translation, and probably the IDE prep module would fix up the 
transport command for the specific device).  However, I don't rule out that it 
would lead to a single prep module for both IDE and SCSI.

The device naming issues are totally separate from the above.  I intend that 
driverfs will cope with them.  Internally, the block layer just thinks of the 
stack as a series of entry points for physical devices.  Driverfs gives the 
card driver freedom to provide a hierarchical ascii device name as it sees 
fit.  Hopefully this will finesse the so called persistent binding issues that 
plague solaris.

Ultimately, this means that host and channel is subsumed into the card 
identification scheme, target ID may no longer be a number and even LUN may 
end up being a LUN hierarchy representation.  As we do this, we'll move to 
exposing persistent names, so the user shouldn't necessarily care about this.

James Bottomley



^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-15  9:20 Joerg Schilling
  2002-07-15 11:23 ` Buddy Lumpkin
                   ` (2 more replies)
  0 siblings, 3 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-15  9:20 UTC (permalink / raw)
  To: riel, venom; +Cc: Richard.Zidlicky, andersen, linux-kernel, schilling

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1785 bytes --]

>From venom@sns.it Mon Jul 15 11:11:59 2002
>On Sun, 14 Jul 2002, Rik van Riel wrote:

>> > BTW: did you ever look at Solaris / HP-UX, ... and the way they
>> > name disks?
>> >
>> > someting like: /dev/{r}dsk/c0t0d0s0
>> > This is SCSI bus, target, lun and slice.
>>
>> I wonder what they'll change it to in order to support
>> network attached storage.
>>
>Actually notthing:

>dbtecnocasa:{root}:/>format
>Searching for disks...done

>c2t1d0: configured with capacity of 6.56MB
>c2t1d30: configured with capacity of 34.04GB
>c2t1d31: configured with capacity of 34.04GB
>c2t1d81: configured with capacity of 34.04GB


>AVAILABLE DISK SELECTIONS:
>       0. c0t0d0 <SUN18G cyl 7506 alt 2 hd 19 sec 248>
>          /pci@1f,4000/scsi@3/sd@0,0
>       1. c2t1d0 <EMC-SYMMETRIX-5567 cyl 14 alt 2 hd 15 sec 64>
>          /pci@4,2000/scsi@1/sd@1,0
>       2. c2t1d30 <EMC-SYMMETRIX-5567 cyl 37178 alt 2 hd 30 sec 64>
>          /pci@4,2000/scsi@1/sd@1,1e
>       3. c2t1d31 <EMC-SYMMETRIX-5567 cyl 37178 alt 2 hd 30 sec 64>
>          /pci@4,2000/scsi@1/sd@1,1f
>       4. c2t1d81 <EMC-SYMMETRIX-5567 cyl 37178 alt 2 hd 30 sec 64>
>          /pci@4,2000/scsi@1/sd@1,51

>except of c0t0d0 everything else is network attached...


How is it attached? Using FACL or ISCSI?

In any case, it seems to be a natural solution to do it this way.

In order to access a network disk, you need to obtain the right to
do so first. Once this has been done, the netork subsystem just looks
like a new SCSI bus.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 20:18 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 20:18 UTC (permalink / raw)
  To: schilling, szepe; +Cc: linux-kernel, zaitcev

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 846 bytes --]

>From: Tomas Szepe <szepe@pinerecords.com>

>> >Umm, let's see if I can fish out the install media from somewhere...
>> >jup, Solaris 2.6 5/98.
>> 
>> So did you compare Solaris performance with a 4 year old Linux?

>No, but you did the comparison with the most recent version of Solaris for
>me, only it was on IA-32. And the result is still the same, Linux wins hands
>down.


The differences are not big enough to prove this. I did use a slow old IDE
disk. As you see from my timings, the Solaris test results have been mainly 
caused by disk speed. 

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 20:13 Joerg Schilling
  2002-07-14 20:18 ` Rik van Riel
  2002-07-15 10:01 ` Richard Zidlicky
  0 siblings, 2 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 20:13 UTC (permalink / raw)
  To: Richard.Zidlicky, schilling; +Cc: andersen, linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1673 bytes --]

>From: Richard Zidlicky <Richard.Zidlicky@stud.informatik.uni-erlangen.de>

> 
>> For a starter, it is easier to understand the SCSI concept of
>> addressing than to understand the Linux concept. In addition,
>> the SCSI addressing concept can be used on different platforms
>> in a unique way. This helps people (and GUI writers) to use 
>> cdrecord on more than Linux only.

>whether it is easier is matter of taste, however in a situation
>where the kernel and 99% of other applications refer to something
>as '/dev/scd0' I fail to see any benefit of having another scheme.
>Do you want to suggest that all other Linux apps should now use
>'-dev x,y,z' instead of normal device names?

Did I request this? No, definitely not. Hoewver, it helps a lot
if a GUI for cdrecord may use cdrecord to find potential drives
and if there is a unique addressing scheme.

BTW: did you ever look at Solaris / HP-UX, ... and the way they
name disks?

someting like: /dev/{r}dsk/c0t0d0s0

This is SCSI bus, target, lun and slice.

>There is another problem, with your scsi transport library you
>are bypassing normal Linux devices. Try
>  mount /dev/scd0 /mnt
>  cdrecord -dev 0,0,0 -blank=fast
>  ls -al /mnt

>Nice? It certainly isn't the fault of Linux if you choose to
>bypass normal device usage and it can be very annoying not
>only for beginners.

It is not a fault of cdrecord either.


Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 20:04 Joerg Schilling
  2002-07-14 20:15 ` Tomas Szepe
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 20:04 UTC (permalink / raw)
  To: schilling, szepe; +Cc: linux-kernel, zaitcev

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 3278 bytes --]

>From: Tomas Szepe <szepe@pinerecords.com>

>> >A Pentium 1200, eh?
>> >More like Pentium 120 or star just doesn't cut it.
>> 
>> star uses less CPU time than GNU tar. As GNU tar uses a proprietary 
>> archive format, I never use it if I may avoid to use it.

>How does this relate to the test? I got the archive directly off your
>ftp site -> the software has been dealing with exactly the same format
>in both cases.

Well. it took me only 8 years of repeated bug reports to make the GNU tar
maintaners fix the worst problems so it is finally able to extract standard 
compliant tar archives ;-).

As recent GNU tar is still unable to _list_ those tar files correctly
(try ftp://ftp.fokus.gme.de/pub/unix/star/testscripts/gtarfail.tar
and ftp://ftp.fokus.gme.de/pub/unix/star/testscripts/gtarfail2.tar),
I would never trust GNU tar. A program that behaves inconsistent in
list vs. extract mode is not what I like to use.

The real problem of GNU tar is that is does still not create POSIX.1-1988
compliantarchives while star is able to create POSIX.1-2001 archives for a year.
This causes that many archives out on ftp servgers cannot be unpacked using
compliant implementations.

To understand the problem, please fetch a recent star distribution and use the
contained program 'tartest' together with 

ftp://ftp.fokus.gme.de/pub/unix/star/testscripts/ustar-all-quicktest.tar

and the instructions in: 

ftp://ftp.fokus.gme.de/pub/unix/star/testscripts/README.quicktest

to find the POSIX deviations in GNU tar.

>> >Athlon 1GHz:
>> 
>> >kala@nibbler:/tmp/1$ time tar xjf rock.tar.bz2
>> >real    3m19.703s
>> >user    0m9.870s
>> >sys     0m24.840s
>> 
>> >According to top, the system was ~90% idle during the extraction.
>> >Linux 2.4.19-rc1-ac3, reiserfs 3.6.
>> 
>> Well, I wrote that this has been done with ext3 (I also checked ext2
>> which is approx. the same speed.
>> I don't have access to a reiserfs system that has not been compiled
>> with debug and I don't like to put out false statements.

>I honestly doubt ext3 would perform significantly worse than what I've
>observed with reiserfs.

Just try it, I did try it.

>Never mind, however, the sole aim of my having tested the extraction of
>rock.tar.bz2 was to show how easily you get to accuse people on lkml of
>being incompetent w/o having any real support for your claims.

It was (as I mentioned before) to show that there need to be some sort 
of high level coordination to make Linux better and address the needs of the 
future.

>> >PS. Solaris is over 60% slower than Linux 2.2/2.4 in common fs
>> >operations on my SMP SPARCstation 10.
>> 
>> If you make such statements, it would help a lot of you would mention
>> the Solaris version you are running. I am always running a recent
>> Solaris beta kernel - you may have used an outdated version.

>Umm, let's see if I can fish out the install media from somewhere...
>jup, Solaris 2.6 5/98.

So did you compare Solaris performance with a 4 year old Linux?

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 19:41 Joerg Schilling
  2002-07-14 19:51 ` Tomas Szepe
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 19:41 UTC (permalink / raw)
  To: schilling, szepe; +Cc: linux-kernel, zaitcev

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1847 bytes --]

>From: Tomas Szepe <szepe@pinerecords.com>

>> A Pentium 1200 running Linux-2.5.25 (ext3) results in:
>> 
>> # star -xp -time < rock.tar.bz2
>> star: WARNING: Archive is bzip2 compressed, trying to use the -bz option.
>> star: 10372 blocks + 1536 bytes (total of 106210816 bytes = 103721.50k).
>> star: Total time 3190.483sec (32 kBytes/sec)
>> 53:10.490r 12.299u 2970.099s 93% 0M 0+0k 0st 0+0io 4411pf+0w
>> 
>> You see, during the 53:20, the machine is only 7% idle!


>A Pentium 1200, eh?
>More like Pentium 120 or star just doesn't cut it.

star uses less CPU time than GNU tar. As GNU tar uses a proprietary 
archive format, I never use it if I may avoid to use it.

>--

>Athlon 1GHz:

>kala@nibbler:/tmp/1$ time tar xjf rock.tar.bz2
>real    3m19.703s
>user    0m9.870s
>sys     0m24.840s

>According to top, the system was ~90% idle during the extraction.
>Linux 2.4.19-rc1-ac3, reiserfs 3.6.

Well, I wrote that this has been done with ext3 (I also checked ext2
which is approx. the same speed.
I don't have access to a reiserfs system that has not been compiled
with debug and I don't like to put out false statements.

>PS. Solaris is over 60% slower than Linux 2.2/2.4 in common fs
>operations on my SMP SPARCstation 10.

If you make such statements, it would help a lot of you would mention
the Solaris version you are running. I am always running a recent
Solaris beta kernel - you may have used an outdated version.

The filesystem speed on Solaris did dramatically improve to the beginning
of the year 2001. This equates Solaris 8 01/01.


Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 19:20 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 19:20 UTC (permalink / raw)
  To: andersen, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 842 bytes --]

>From: Erik Andersen <andersen@codepoet.org>

>> >cdrecord should use the CDROM_SEND_PACKET ioctl, then it would
>> >work regardless,
>> 
>> This only prooves that you are uninformed :-(

>No.  This only proves _you_ have not tried it.  I've used the
>CDROM_SEND_PACKET ioctl on both SCSI and ATAPI cdrom devices.
>What do you need to do in cdrecord that cannot be done with it?

The only reason, why I did add support for it was to be able
to use a CD writer in my notbook circumventing the driver bugs
that prevent to use ise-scsi on top of PCATA.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 19:18 Joerg Schilling
  2002-07-14 19:27 ` Thunder from the hill
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 19:18 UTC (permalink / raw)
  To: andersen, schilling; +Cc: alan, linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1006 bytes --]

>From: Erik Andersen <andersen@codepoet.org>

>> We don't need just another unrelated interface but a generic
>> transort. CDROM_SEND_PACKET is not a generic interface, it is limited
>> to ATAPI CD-ROM's.

>Wrong.  It is a _generic CD-ROM packet interface.  Thanks for not even
>spending the two seconds it would take reading the kernel source code
>to discover this.

>$ grep -l CDC_GENERIC_PACKET drivers/scsi/sr.c drivers/ide/ide-cd.c 
>drivers/scsi/sr.c
>drivers/ide/ide-cd.c

That does not change anything.

Having a transport of limited usability is a problem for libscg.

BTW: If it turns out that people are interested in useful discussions, 
I may put more effort in reading current Linux kernel sources.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 19:10 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 19:10 UTC (permalink / raw)
  To: alan, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2555 bytes --]

>From alan@lxorguk.ukuu.org.uk Sun Jul 14 17:35:44 2002


>Try doing the following in SCSI

>-	Device managed storage layout  "Allocate x blocks close to 	handle y
>and give me a new handle"

You don't want do do this in SCSI because it is a task of a layer above SCSI.


>-	Per I/O request readahead hints (please read on xyzK , please 	dont
>readahead)

Again:	this is a task of a layer above SCSI.
	In some cases, where you might refer to medium access level read ahead,
	this is done by implementing tagged SCSI command queueing.

>-	Per I/O request writeback hints (write back cache is ok, write 	back
>cache is ok only if NV, don't bother caching, streaming I/O
>	hint)

Again: this is a task of a layer above SCSI. See Solaris and FreeBSD as 
examples.

It would help if you first do some homework and read some decent kernel 
sources to understand how a kernel needs to be layered to implement
e.g. Storage/FS/kernel/user interface layering.

Then use e.g. 'iostat' to see how overlapping disk I/O is done.

>I have controllers which can do most of the above. I don't want to talk
>scsi to them and spend all my cpu time faking, decoding and recoding
>command blocks, spoofing error handling and the like.

>Its simply inappropriate to consider the SCSI command set as a high
>level interface for block and related I/O. 

It looks like you never did metering tests to see what amount of time
is needed to handle the SCSI protocol.

I did many tests when implementing RSCSI. Even when you include TCP/IP
times, the overhead is <= 100 µs per SCSI command.


>As to your comments on sg. Everyone except you happened to think that
>Doug Gilberts very nice sg changes were the right path. I still think it
>was the right decision. 

Not knowing what is bad may make people believe that something is good.

>> If this discussion stays as it currently looks like, it does not make 
>> sense for me to try to find a better solution. Let me call it this
>> way: this thread was just another proof that it is not possible to
>> have a technical based solution with the Linux folks. It seems t be >
>> just a waste of time :-(

>The Linux development process aggressively filters bad ideas.

It definitely did not help 4 years ago, when the sg problem did came up.


Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 18:22 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 18:22 UTC (permalink / raw)
  To: riel, schilling; +Cc: aia21, linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1908 bytes --]

>From: Rik van Riel <riel@conectiva.com.br>

>> Well, I get pissed of the fact that it seems to be impossible to have a
>> technical based discussion in the Linux kernel environment.

>Then please, show us your technical arguments on why the SCSI
>layer is enough for every CD writing hardware out there.

Simple: there is not a single CD writer out that uses something other
than SCSI commands to write media or do DAE.


>Now compare them with the results from the NAS and SCSI talks
>and BoFs at the kernel summit and OLS, where everybody agreed
>that the current SCSI addressing and discovery schemes just
>don't cut it on things like iscsi and other network storage
>solutions.

I defined RSCSI before iscsi came out. I did not yet look at ISCSI.
There sould be just an additional IP address in the iscsi addressing
model.

>It's not just about the fact that the controller/bus/unit/lun
>addressing doesn't deal well with network attached storage and
>multipath, it's also about things like the impossability of
>device discovery on a bus with 2^32 possible device addresses.

You don't need as you might net be allowed to access many of them.
Just have a look at my RSCSI protocol. It just puts "user@host:"
before the old SCSI address.

>This, in turn, makes the current sd[a-z] and sg[a-h] more than
>a little inadequate.  Furthermore, you suddenly require the
>ability to tell the kernel to talk to devices the kernel doesn't
>yet know about (because it can't scan 2^32 device addresses at
>boot time).

You are right, but this is what programs like e.g. cdrtools which use
libscg already do for two years.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 18:11 Joerg Schilling
  2002-07-14 18:40 ` Tomas Szepe
                   ` (2 more replies)
  0 siblings, 3 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 18:11 UTC (permalink / raw)
  To: schilling, zaitcev; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 4394 bytes --]

>From zaitcev@redhat.com Sun Jul 14 17:05:31 2002

>>>I will violently oppose anything that implies that the IDE layer uses the
>>>SCSI layer normally.  No way, Jose. I'm all for scrapping, but the thing
>>>that should be scrapped is ide-scsi.
>> 
>> Nobody who has a technical backgroupd and knows what to do wuld ever
>> make such a proposal.
>> 
>> Instead, there needs to be one or more SCSI HA driver as part of the
>> SCSI stack. This driver also needs to deal with plain ATA in order
>> to be able to coordinate access.
>> 
>> Jörg

>Such driver would only work with ATAPI devices. Joerg, does not
>seem to realize that the vast majority of IDE devices do not
>support ATAPI at all. As a rule of thumb, winchesters do not,
>CD-ROMs and such do, and tapes do too. To make a pseudo-HA
>driver which speaks plain IDE and plugs into SCSI subsistem
>would saddle the IDE with SCSI limitations, and add one more
>layer for no benefit whatsoever.

You did not seem to read my previous postings. It is simple to have
a second upper level interface for the IDE HBS driver that connects to
e.g. the ATA HD driver interface. If you like to have 100% backwards
compatibility you could even put the current non-standard part from 
ide-cd on top of this 2nd type of upper level code. Make sure, that 
the ATAPI/SCSI part is probed first, to allow to connect the SCSI 
drivers first and lock the ATA type interface against being used by
drivers like ide-cd in case that a SCSI type of high level driver did
feel responsible to deal with a specific drive.

Of curse this will only work if there is some kind of accepted 
development leadership that makes a concept, works on data structures and 
finally instructs the maintainers of old code to find a way to convert
their current driver to the new model. This new model usually would
cause parts of the code that exists more than once to be removed from
all the old drivers that have been considered to represent 'the wrong way'
in the tree of the evolution of the kernel.

Stop looking at your own belly and have a look at what other OS do.
It seems to be one of the main problems in the Linux development.


People usually only look at Linux and inside Linux, they only look at 
their part of the kernel. Doing it this way, they define their own 
interfaces and don't look enough to the left and to the right.

To make it not look as if I am only bashing current IDE/SCSI code, let
me give an example from the filesystem part.

Have a look at the file 

ftp://ftp.fokus.gmd.de/pub/unix/star/testscript/rock.tar.bz2

It is a tar archive that contains 207,440 empty files and one directory 
using the names of the files in the 'rock' subdirectory from the 
freedb project. This is a snapshot taken on May 30th 2002.

If you extract this archive on a machine running Solaris or FreeBSD,
it takes less than 7 minutes.

A pentium 800 running Solaris 9 results in:

# star -xp -time < rock.tar.bz2
star: WARNING: Archive is bzip2 compressed, trying to use the -bz option.
star: 10372 blocks + 1536 bytes (total of 106210816 bytes = 103721.50k).
star: Total time 405.988sec (255 kBytes/sec)
6:46.051r 12.920u 63.420s 18% 0M 0+0k 0st 0+0io 0pf+0w

You see during the 6:43, the machine is 82% idle.


A Pentium 1200 running Linux-2.5.25 (ext3) results in:

# star -xp -time < rock.tar.bz2
star: WARNING: Archive is bzip2 compressed, trying to use the -bz option.
star: 10372 blocks + 1536 bytes (total of 106210816 bytes = 103721.50k).
star: Total time 3190.483sec (32 kBytes/sec)
53:10.490r 12.299u 2970.099s 93% 0M 0+0k 0st 0+0io 4411pf+0w

You see, during the 53:20, the machine is only 7% idle!

It wasted 2900 seconds of CPU time on Linux. Let me guess: this was done
inside the function strcmp().

There are ~ 5 different filesystems on Linux, but none if the projects seem
to care about the code outside the FS low level code. I suspect, that
this is not any better if you use reiserfs.

Solaris and FreeBSD put all the effort into one filesystem trying to make
it as good as possible. In Linux, it seems that nobody prooved the overall
concept of the kernel.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 15:15 Joerg Schilling
  2002-07-14 15:27 ` Rik van Riel
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 15:15 UTC (permalink / raw)
  To: aia21, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1652 bytes --]

>From: Anton Altaparmakov <aia21@cantab.net>

>>Name a single drive that is DAE capable, does not support ATAPI and
>>doesn't do DAE in lousy quality.

>I don't need to. As I said in the following paragraph, I never claimed such 
>a thing existed. I am only complaining about your generalisations which to 
>me imply that an alternative better interface cannot and could not exist. 
>Which is a pile of crap. Maybe tomorrow someone will come up with a much 
>better interface/drive. That is all I am saying. You cannot see into the 
>future to be able to make such generalisations...

Why should there be such a device when there is a standard that manufacturers
implement?


>> >Note: I am not saying that there is an alternative interface or anything
>> >like that... just that your statement is fallacious.
>>
>>Your statements just proove that you didn't try to get the background 
>>information
>>that is needed to find a useful and seminal future development.

>WHAT?!? Get off your high horse, will you? I never claimed anything to 
>prompt this response. I am just telling you off for misleading people with 
>your statements...

>Anton, who is starting to get pissed off with Mr Joerg "I know everything" 
>Schilling

Well, I get pissed of the fact that it seems to be impossible to have a 
technical based discussion in the Linux kernel environment.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 15:12 Joerg Schilling
  2002-07-14 16:45 ` Alan Cox
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 15:12 UTC (permalink / raw)
  To: alan, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 4101 bytes --]

>From alan@lxorguk.ukuu.org.uk Sun Jul 14 16:18:38 2002

>On Sun, 2002-07-14 at 15:07, Joerg Schilling wrote:
>> >From alan@lxorguk.ukuu.org.uk Fri Jul 12 22:22:45 2002

>> >There are lots that fudge around and pretend scsi is the block layer
>> >when it is not. That sort of misses the point and slows down high end
>> >raid cards.
>> 
>> It seems that you miss to understand the needed underlying driver structures.
>> SCSI is not a block layer, it is a generic transport.

>It is not generic - its handling of sophisticated I/O stuff is non

The fact that you don't know st does not make this statement true.

>existant. SCSI gave rise to a convenient command set for low end devices
>thats since been applied (with endless problems due to its use) to
>things like fibrechannel.

The endless problems are problems caused by e.g. a bad transport implementation
in Linux. Your "fibrechannel" words leads to another problem in Linux.
usb_storage is a module that seems to suffer from a correct implementation
if concurrent driver tasks. If usb_storage steps over the 'memory stick'
interface on a Sony VAIO, it hangs itself for 10 minutes and is unable
to recognise any other drive during this time period. If you like to use
a USB CD writer on a VAIO, you need to unplug it and let the OS settle
down after the boot until you are able to reconnect the writer. If you like
to use the USB floppy the same problems ossur. This leads to the fact 
that you cannot boot from a USB floppy: once the kernel is up, it cannot
mount the root disk because the driver is hung from the memory stick adaptor.

>Of course if you'd actually bothered to read the code (as I told you to
>go do a while back) you might understand the 2.5 direction with the
>block I/O layers. Using scsi command sets as a driver abstraction is a
>nonsense, its incomplete, inefficient and too full of messy rules that
>its not reasonable to inflict on hardware that doesn't care (eg recovery
>from tagged command sequences on an error from the drive). 2.5 has a
>much much saner abstraction thank you.

Well, I _did_ read the code a while ago and I did even write a patch for
the sg.c driver that helped to fix a lot of problems. But instead of using
this driver in the official kernel, _you_ preferred a sg.c hack made by a 
OS novice that mainly did address some DMA specifics that should not occur
at all in sg.c in a cleanly layered kernel.

I had a concept on how to go to a more usable interface in the future.

Do you really believe that I will ever start again to put effort in a
Linux kernel module unless you did previously proove that you are willing
and able to run a tecnically based discusion? 


Look at this discussion: you sit on a high horse and behave as if you had 
serious kernel experiences and do not even need to react on my statements
in a senseful way. From looking at your statements it rather looks as if
you are missing the needed experience. You do not really believe that this
is the right way to treat someone with 20 year of kernel experience
on different places of the kernel and on different OS implementations, do you?

If you don't like to look like a 'I know everything but I don't have to proove'
troll, it would help a lot to have a serious discussion where you would start
to use arguments instead of just telling people no more than 'I know better'.

Give yourself a hitch and admit that you are the person who is responsible
that I believe that it is useless to try to help in Linux kernel development.

If this discussion stays as it currently looks like, it does not make sense
for me to try to find a better solution. Let me call it this way: this thread
was just another proof that it is not possible to have a technical based 
solution with the Linux folks. It seems t be just a waste of time :-(

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
[parent not found: <mailman.1026651901.18426.linux-kernel2news@redhat.com>]
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 14:28 Joerg Schilling
  2002-07-14 14:45 ` Anton Altaparmakov
  2002-07-14 14:46 ` Thunder from the hill
  0 siblings, 2 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 14:28 UTC (permalink / raw)
  To: aia21, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1170 bytes --]


>From aia21@cantab.net Sun Jul 14 15:38:33 2002

>At 14:24 14/07/02, Joerg Schilling wrote:
>>[...] In addition, if the drive would support DAE via some non-standard 
>>interface [...]. The DAE quality would be lousy [...].

>This is a very presumptuous statement! You cannot assume that an 
>alternative interface would be of lousy quality. Maybe it is a million 
>times better? The current one (at least as some drives implement it on the 
>drive side) can be of very, very poor quality indeed.

Name a single drive that is DAE capable, does not support ATAPI and
doesn't do DAE in lousy quality.

>Note: I am not saying that there is an alternative interface or anything 
>like that... just that your statement is fallacious.

Your statements just proove that you didn't try to get the background information
that is needed to find a useful and seminal future development.


Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 14:25 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 14:25 UTC (permalink / raw)
  To: alan, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 835 bytes --]

>From alan@lxorguk.ukuu.org.uk Sun Jul 14 15:35:09 2002

>On Sun, 2002-07-14 at 14:17, Joerg Schilling wrote:
>> Did you ever looks at the ATAPI specs?
>> 
>> ATAPI _is_ SCSI over IDE with a few "bugs"/deviations:

>In other words as he said ATAPI is not SCSI


It would really help not to turn a technically based discussion
into personal bashing. I am still waiting to see any tecnical based
argument from you.

It seems that you are not nterested in a better technical based solution
but in preventing other people's ideas from being used.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 14:20 Joerg Schilling
  2002-07-14 15:56 ` Erik Andersen
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 14:20 UTC (permalink / raw)
  To: alan, andersen; +Cc: linux-kernel, schilling

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1054 bytes --]


>From andersen@codepoet.org Sat Jul 13 07:49:29 2002

>On Fri Jul 12, 2002 at 10:17:21PM +0100, Alan Cox wrote:
>> CD burning is a side issue to stability and reliability. 
>> 
>> In terms of supporting old hardware most of that is irrelevant to cd
>> recording anyway, so why do you care ? What you actually need is a
>> generic interface for cd packet sending.

>A generic interface for cd packet sending?  Sounds useful.  So
>useful someone thought of it years ago, and called it the
>CDROM_SEND_PACKET ioctl.  Its been in the kernel since Aug 1999.
>What'll those crazy Linux CD-ROM people think of next?

We don't need just another unrelated interface but a generic
transort. CDROM_SEND_PACKET is not a generic interface, it is limited
to ATAPI CD-ROM's.


Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 14:18 Joerg Schilling
  2002-07-14 14:35 ` Tomas Szepe
                   ` (2 more replies)
  0 siblings, 3 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 14:18 UTC (permalink / raw)
  To: andersen, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2657 bytes --]

>From andersen@codepoet.org Sat Jul 13 07:40:59 2002

>> If you force cdrecord to rely on CD-ROM only interfaces, you make Linux
>> unusable in general. Do you really like to create an unusable Linux just
>> to avoid creating a usable generic SCSI transport interface?

>Lets step back a moment here.  The cdrecord package is not
>responsible for making "Linux usable in general".  It is
>responsible for writing data to CD-ROMs.  It is _not_ responsible
>for driving scanners, hard drives, or enforcing policy on the
>Linux kernel.

It looks like you miss important issues. 

-	More and more people like to use CD writers in their PC.

-	There are no new "SCSI"  (which rather means SCSI with 
	1984 transport layer) drives on the market. However,
	once you have a devent SCSI transport abstraction layer
	as I have in libscg, there is no difference in the high
	level code.

-	While it has been quite simple to add a SCSI CD writer
	to a PC and it is still simple on platforms that treat
	ATAPI ad SCSI over IDE, it is a big problem for novices
	to make a ATAPI CD writer work on Linux.

-	The people who have these sort of problems are those people
	who are new to Linux and who believe that Linux is unusable
	after they get those problems.

>If you would throw away crdrecord's desire to do its own private
>SCSI bus scanning, and throw away your attachment to addressing
>devices only by host, channel, id, and lun a number of things

It looks that you miss to understand what cdrecord does!
Cdrecord in special and libscg in general definitely does not
scan the bus. This is done by the kernel.

Cdrecord only tries to find all devices that already have been
found by the kernel.

>happen.  For starters, Linux devices don't have to be forced to
>all be sitting on the SCSI bus.  You could use standard Linux
>device names (i.e. /dev/hdc or /dev/scd0).  And you could still
>send all the SCSI/ATAPI packet commands you want to the device
>that was selected  using the CDROM_SEND_PACKET ioctl.

For a starter, it is easier to understand the SCSI concept of
addressing than to understand the Linux concept. In addition,
the SCSI addressing concept can be used on different platforms
in a unique way. This helps people (and GUI writers) to use 
cdrecord on more than Linux only.

>Ever look at the CDROM_SEND_PACKET ioctl?

I did, but you obviously did not :-(

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 14:07 Joerg Schilling
  2002-07-14 15:28 ` Alan Cox
  2002-07-18 18:51 ` Kelsey Hudson
  0 siblings, 2 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 14:07 UTC (permalink / raw)
  To: alan, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2204 bytes --]


>From alan@lxorguk.ukuu.org.uk Fri Jul 12 22:22:45 2002

>On Fri, 2002-07-12 at 21:08, Joerg Schilling wrote:
>> There are enough other OS that use a common ATAPI/SCSI driver concept and
>> do not have the problems you vagely name but never really describe.

>There are lots that fudge around and pretend scsi is the block layer
>when it is not. That sort of misses the point and slows down high end
>raid cards.

It seems that you miss to understand the needed underlying driver structures.
SCSI is not a block layer, it is a generic transport.


>> I believe it's OK to drop support for 10 year old hardware in case this
>> is no important hardware that _really_ needs continued support (like
>> e.g. 9 track trapes).

>We support and people continue to use large amounts of ten year old
>hardware. Thats why children at quite a few schools have access to
>computing through things like LTSP. There are people actively
>maintaining much of this stuff too. 

I never agued to completely drop support for them. You cannot do decent
DAE with pre-1998 CD-ROM drives, so why try to support DAE for old drives?
Just use them as read-only DA drives.

>Some things such as ide tapes which have needs rather different to scsi
>tape are still being made and released in newer and larger forms.

If you have a IDE tape that acts as tape, it most likely uses SCSI 
tape commands. If it acts as a big floppy, it is not relevent in this
discussion.

>> ATA devices that are neither hard disks, nor do support ATAPI decently
>> are Y 1992 crap - so unless you like to have continued support for your
>> provate museum, what is the reason that you like to prevent a change
>> to a more usable driver interface?

>You still don't seem to understand the difference between a driver
>interface and a hardware layer. 

Well, from previous discussions with you, you did proove that this is exactly
what _you_ don't understand.




Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 14:00 Joerg Schilling
  2002-07-15  0:29 ` Richard B. Johnson
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 14:00 UTC (permalink / raw)
  To: root, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 844 bytes --]

>From root@chaos.analogic.com Fri Jul 12 22:18:47 2002

>As much as I hate IDE, IDE isn't going away. All my systems use SCSI
>so on machines that have CD/ROMS, I use your libraries and your tools.

>Maybe somebody should make CD/ROM code that directly talks to IDE via
>/dev/hdwhatever, instead of expecting you to modify your code that
>has worked so well for so long.

This would be a really bad idea.

Such a change would force me to add a 6th (and unneeded) new interface.
Why? What problem would be solved if you did introduce such an interface?

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 13:55 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 13:55 UTC (permalink / raw)
  To: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 411 bytes --]

>Eric Anderson wrote:

>Cool.  I've not read over anything newer then cdrtools-1.10.

So you are living in the past...

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 13:47 Joerg Schilling
  2002-07-14 14:31 ` Thunder from the hill
  2002-07-14 21:23 ` Andre Hedrick
  0 siblings, 2 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 13:47 UTC (permalink / raw)
  To: andre, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 3065 bytes --]


>From: Andre Hedrick <andre@linux-ide.org>

First: Top posting is something that disqualifies you. Please don't 
top post otherwise people will belive that you are just a troll.

>Don't take this personally but you are just a top level application.
>The only reason you have such blinders on is because you always had a
>bottom layer transport working around and doing its best to prevent
>errors form showing up.  You are wrong and because you are not down on the
>bus at the physical layer you do see the mess.

I don't take this personal, but the main problem seems to be that most
of the people in this discussion have far less kernel experience than I have.
I did actively write code from many different places in different OS 
implementaions. Ans more important, I did read a lot of other people's code.
If Linux people have kernel experience at all, they usually only know
a specific part of one single OS: Linux.

Writing good kernel code is more! It educates a lot to read read read
a lot in other OS sources to understand other ideas and to become
able to judge about the quality os a specific implementation.

You seem to have no experience than IDE in Linux. It would help if you 
first look at other implementations in order to become able to judge yourself.

>Now your silly PCATA stupid ass Tailgate Bridge that you are boasting
>about does some of the worst things anyone could ever imagine.

???? Looks stupid (like dou did not get the message).

>Oh and the bad idea you call is to permit dynamic subdriver shifting.
>Now that it may never be completed you have the advantage to call it a bad
>idea.  I suspect you are an ASPI lover and soone SPI will die.

Please read what I wrote and don't guess what I might have written.

>Next your statements about name a drive is a straw man.
>More basic proof you do not look down at the hardware.

???? Looks completely unrelated to the thread and to my mail.

>BurnProof is a result lame devices which improperly hold off the bus
>because release the BUSY Bit while still performing transfers.
>The very fact that a huge pile of devices went into the market place
>based on SFF-8020 rev 2.5 total roasts your strawman, please try again.

Again: this is completely unrelated to the problem. Why do you introduce
it?


>So instead of whining about what is there and not from your location in
>end user land, try and offer something useful like a preferred API to
>allow clean packet-driver interfaces.  Doing that little would allow the
>transport layer people and the transistion-api folks to user land to
>greatly increase compatablity.  Then you would not need 5 interfaces for
>Linux.

>Have a good day.

I am not whining, but you answer with  unrelated stuff. Why? Are you missing
experience and arguments?

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 13:26 Joerg Schilling
  2002-07-14 14:28 ` Thunder from the hill
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 13:26 UTC (permalink / raw)
  To: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 555 bytes --]


>Thunder wrote:

>I got a drive at home which is from 1996 and doesn't do ATAPI. It's some 
>Mitsumi indestructible, but I can't tell you details since I won't be at 
>home within the next few weeks.

What can you do with the drive - besides using it as CD-ROM?

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 13:24 Joerg Schilling
  2002-07-14 13:39 ` Anton Altaparmakov
                   ` (2 more replies)
  0 siblings, 3 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 13:24 UTC (permalink / raw)
  To: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1076 bytes --]

>Thunder wrote:

>Because we can't tell Linux users "your (once favorite) CD-ROM is not 
>implemented in Linux (any more), and will never ever be". If we explicitly 
>exclude hardware, where do we end?!

It would help if you educate yourself before you wrtite to the thread.
This could help a lot to keep this discussion technical.

If a CD-ROM does not support ATAPI, you are not able to

-	open/close/lock the door.

-	Rip Audio from it.

People who really cannot affort to buy a new drive will still be able
to see the drive as read-only HD.

In addition, if the drive would support DAE via some non-standard interface
nobody would be happy with it. The DAE 	quality would be lousy and none of 
the programs that is still supported would be able to use the drive
decently for DAE.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 13:17 Joerg Schilling
  2002-07-14 14:03 ` Thunder from the hill
  2002-07-14 14:44 ` Alan Cox
  0 siblings, 2 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 13:17 UTC (permalink / raw)
  To: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1339 bytes --]

Bartlomiej Zolnierkiewicz wrote:

Please stop calling ATAPI as SCSI over IDE, it is not. It is Packet
Interface over ATA (IDE). Some ATAPI/SCSI devices are functionally
equivalent because they support the same command set (i.e. MMC).

Did you ever looks at the ATAPI specs?

ATAPI _is_ SCSI over IDE with a few "bugs"/deviations:

-	The inquiry format uses wrong protocol version numbers.
	
	This mainly gives provblems with creating Mode sense / mode select
	commands. If you know (e.g. from MMC-3) that the transport is
	IDE, then you just bump the version to 2 and it works.

-	6-byte SCSI commands in general are not supported. This is not
	a real problem for a well designed high level driver.

-	Commands that take a long time are allowed to behave as if
	the high level code did set the IMMED bit in the CDB.

	This can be handled if the high level code handles the
	resulting error codes for the following commands to 
	introduce a wait loop.

-	There is no disconnect/reconnect.

	This is nothing that high level code should be aware of.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 13:08 Joerg Schilling
  2002-07-14 13:59 ` Thunder from the hill
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 13:08 UTC (permalink / raw)
  To: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1197 bytes --]

>H. Peter Anvin wrote:

>hen *please* make a *compatible* interface available to user space. 
>This certainly can be done; the parallel port IDE interface stuff had 
>exactly such an interface (/dev/pg*) -- we could have a /dev/hg* 
>interface presumably.  That is an acceptable solution.

I would not call the /dev/pg* nterface a cmpatible interface.

It has advantages to the interface in the ide-cdrom driver in being
able to talk to different types of drives at the end, but it is
another incompatible user interface.

>Note again that this discussion (and it's a discussion, not a voting 
>session -- technical pros and cons is what applies) apply to ATAPI (SCSI 
>over IDE) only.  Alan has already brought up the fact of non-hard disk 
>non-ATAPI devices, and IMO those devices are explicitly out of scope. 

This is my idea too: CD-ROM drives should be accessed via ATAPI or 
handled as ATA disk.


Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 13:02 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 13:02 UTC (permalink / raw)
  To: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 765 bytes --]

>Linus Torvalds wrote:

>I will violently oppose anything that implies that the IDE layer uses the
>SCSI layer normally.  No way, Jose. I'm all for scrapping, but the thing
>that should be scrapped is ide-scsi.

Nobody who has a technical backgroupd and knows what to do wuld ever
make such a proposal.

Instead, there needs to be one or more SCSI HA driver as part of the SCSI stack.
This driver also needs to deal with plain ATA in order to be able to
coordinate access.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 12:50 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 12:50 UTC (permalink / raw)
  To: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 734 bytes --]

>Alan Cox wrote:


>If you load ide-scsi they are run as ATAPI, whats the problem ? Just don't
>do that for very old ide cdroms or for some ide floppies

Sounds like you got the message to some extent.

Why don't think this to it's reasonable end: Use ATAPI for all modern
(1993..1995 or newer) drives and support what old drives can do - reading
data CD-ROM media via the IDE read interface. This can be done via
the ATA HD drive interface.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 12:44 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 12:44 UTC (permalink / raw)
  To: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1331 bytes --]

H. Peter Anvin wrote:

I'm talking specifically about ATAPI devices here.  As we have already 
covered, not all ATA devices are ATAPI, but unless I'm completely off 
the wall, ATAPI is SCSI over IDE, and should be able to be driven as 
such.  The lack of access to that interface using the established 
interface mechanisms just bites.

You fund it!

Other people did not even think about the problem, or even lack the 
needed knowledge.

Alan Cox is one of the latter ones :-( he only tries to avoid needed
changes ithout any technical reason.

If you have a IDE based CD-ROM drive that does not support ATAPI,
why not handle it the only way it makes sense?

Such a drive is no more than a read-only hard disk and may be accessed
via the HD IDE read interface. You will never be able to use it 
to e.g. rip audio data off it.

If there really is a poor school that cannot afford to buy a modern
20-30 Euro CD-ROM drive, then this school can liveas long as they 
are able to install the OS from the old (1992) CD-ROM they currently own.



Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 12:38 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 12:38 UTC (permalink / raw)
  To: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 786 bytes --]

>H. Peter Anvin wrote:

>OK, non-ATAPI devices need not apply, obviously, but the argument
>still applies for ATAPI devices...

It is bad to see, that you are the only person in this thread who
seems to did already think about the problem and who tries to find
a useful solution.

Nearly all other people only track personal wishes and aversions.

To find a useful solution, we need a tecnical and knowledge base
driven idea - not only trying to prevent other people's ideas to become
reality.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14 12:32 Joerg Schilling
  2002-07-14 16:01 ` Erik Andersen
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-14 12:32 UTC (permalink / raw)
  To: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 937 bytes --]

>Eric Anderson wrote:

>cdrecord should use the CDROM_SEND_PACKET ioctl, then it would
>work regardless,

This only prooves that you are uninformed :-(

In addition, the exiestence of thiid ioctl is just another proof
that there is no overall planning in Linux. Everyone adds new 
interfaces without any concept. If Linux likes to convert from 
a hobbyist kernel to a professional OS, there is need for overall
planning by people who know about OS concepts.

For now, I only see people who may know a lot about Linux but lack
general OS knowledge. Knowlede does not result from looking at your belly
but from looking at other people's ideas...


Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-14  6:20 Adam J. Richter
  2002-07-14 15:22 ` Bartlomiej Zolnierkiewicz
  0 siblings, 1 reply; 204+ messages in thread
From: Adam J. Richter @ 2002-07-14  6:20 UTC (permalink / raw)
  To: B.Zolnierkiewicz; +Cc: alan, linux-kernel

On Sat, 13 Jul 2002, Bartlomiej Zolnierkiewicz wrote:
>On Sat, 13 Jul 2002, Adam J. Richter wrote:
>> On Sat, 13 Jul 2002, Bartlomiej Zolnierkiewicz wrote:
>> >Wrong impression. ;)
>> >Hint: look for STANDARD_ATAPI macro usage.
>>
>>       It looks like that macro should be renamed to something like
>> STANDARD_MMC.  Everything that that macro controls still appears to
>> go through ATA Packet Interface encapsulation.  Those quirks look like
>
>Please verify against sff8020.

	I don't know what you mean by this.  It's not a question of
whether the behavior being accomodated is conformant or nonconformant
to a standard.  The question is whether the accomodations controlled
by the "STANDARD_ATAPI" macro can easily be implemented in sr_mod.
Since the accomodations are translating a couple of numbers that
are repeseneted as binary coded decimal instead of integers (0-255)
on some drives, and sending a slightly different SCSI command to
change discs on a Sanyo three CD changer, it seems that they can easily
be implemented in sr_mod.

>> they would likely be duplicated in a SCSI version of the same drives
>> anyhow.  It should be easy to have sr_mod accomodate those drives.
>
>I can't find them, there are some in sr_vendor.c but they are diffirent

	From you email address, I would guess that English is not your
first language.  While you do write English very well, I think you made
a mistake in understanding what I siad.  "It should be easy to
have sr_mod accomodate those drives" means that it would be easy for
someone to write code in the near future to do this (that is, to change
sr_mod.c).  It does not mean that it has already been done.

Adam J. Richter     __     ______________   575 Oroville Road
adam@yggdrasil.com     \ /                  Milpitas, California 95035
+1 408 309-6081         | g g d r a s i l   United States of America
                         "Free Software For The Rest Of Us."

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-13 23:27 Adam J. Richter
  2002-07-13 23:47 ` Bartlomiej Zolnierkiewicz
  0 siblings, 1 reply; 204+ messages in thread
From: Adam J. Richter @ 2002-07-13 23:27 UTC (permalink / raw)
  To: B.Zolnierkiewicz; +Cc: alan, linux-kernel

On Sat, 13 Jul 2002, Bartlomiej Zolnierkiewicz wrote:
>On Sat, 13 Jul 2002, Adam J. Richter wrote:
[...]
>> 	Are there some non-ATAPI IDE CDROM's that
>> linux-2.5.25/drivers/ide/ide-cdrom.c supports?   I was under
>> the impression that ide-cdrom.c operated only through ATAPI.

>Wrong impression. ;)
>Hint: look for STANDARD_ATAPI macro usage.

	It looks like that macro should be renamed to something like
STANDARD_MMC.  Everything that that macro controls still appears to 
go through ATA Packet Interface encapsulation.  Those quirks look like
they would likely be duplicated in a SCSI version of the same drives
anyhow.  It should be easy to have sr_mod accomodate those drives.

Adam J. Richter     __     ______________   575 Oroville Road
adam@yggdrasil.com     \ /                  Milpitas, California 95035
+1 408 309-6081         | g g d r a s i l   United States of America
                         "Free Software For The Rest Of Us."

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-13 14:46 Adam J. Richter
  2002-07-13 15:38 ` Bartlomiej Zolnierkiewicz
  0 siblings, 1 reply; 204+ messages in thread
From: Adam J. Richter @ 2002-07-13 14:46 UTC (permalink / raw)
  To: alan; +Cc: linux-kernel

Alan Cox writes:
|o       Not all ide cdrom devices are ATAPI capable
[...]

	Are there some non-ATAPI IDE CDROM's that
linux-2.5.25/drivers/ide/ide-cdrom.c supports?   I was under
the impression that ide-cdrom.c operated only through ATAPI.

Adam J. Richter     __     ______________   575 Oroville Road
adam@yggdrasil.com     \ /                  Milpitas, California 95035
+1 408 309-6081         | g g d r a s i l   United States of America
                         "Free Software For The Rest Of Us."

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-12 20:08 Joerg Schilling
  2002-07-12 21:31 ` Alan Cox
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-12 20:08 UTC (permalink / raw)
  To: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1454 bytes --]


>Alan Cox wrote:

>> In favour of the scrap:
>> 
>> 1. HPA.
>> 2. Adam J. Richter.
>> 3. Marcin Dalecki (basically due to give up on the idea
>> of gradual unification).

>In other words nobody who understands IDE is for and everyone who 
>understands you can't actually get rid of ide-floppy, tape, cdrom internal
>support and knows about IDE is..


I am not sure if any of your statements before does proove that you have 
knowledge on IDE, you definitely seem to miss important knowledge about SCSI.

I hope that this will not result in missing the chance of converting
to a more useful driver concept.

There are enough other OS that use a common ATAPI/SCSI driver concept and
do not have the problems you vagely name but never really describe.

I believe it's OK to drop support for 10 year old hardware in case this
is no important hardware that _really_ needs continued support (like
e.g. 9 track trapes).

ATA devices that are neither hard disks, nor do support ATAPI decently
are Y 1992 crap - so unless you like to have continued support for your
provate museum, what is the reason that you like to prevent a change
to a more usable driver interface?

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-12 19:57 Joerg Schilling
  2002-07-12 21:17 ` Alan Cox
  0 siblings, 1 reply; 204+ messages in thread
From: Joerg Schilling @ 2002-07-12 19:57 UTC (permalink / raw)
  To: alan, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 889 bytes --]

>From alan@lxorguk.ukuu.org.uk Fri Jul 12 21:56:54 2002

>On Fri, 2002-07-12 at 20:49, Joerg Schilling wrote:
>> >> Describe the problems.
>> 
>> >Go read the source code, do your own homework
>> 
>> Fine! You repeat that you have no argument that stands a check.
>> So let us take it as prooven that there is no problem with resent
>> (< 10 year old) drives. 

>Read the source code, then you'd already know you are talking crap


If you are unable to use arguments, I cannot take you for serious.
Please educate yourself about SCSI and ATAPI, this would help a lot
haveing a serious discussion.

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-12 19:55 Joerg Schilling
  2002-07-12 20:19 ` Richard B. Johnson
  2002-07-13  5:40 ` Erik Andersen
  0 siblings, 2 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-12 19:55 UTC (permalink / raw)
  To: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 985 bytes --]

Erik Andersen wrote:

>cdrecord should use the CDROM_SEND_PACKET ioctl, then it would
>work regardless,

Wis you ever look at the cdrecord sources?

Cdrecord relies on libscg which is a generic SCSI transport library.
It has been first written in August 1986 when I wrote the first SCSI
pass through driver (for SunOS-3.0) - long before Adapted came out with
ASPI. In the 16 years of evolution, it has been ported to > 30
different platforms (not including CPU variants like sparc/x86).

If you force cdrecord to rely on CD-ROM only interfaces, you make Linux
unusable in general. Do you really like to create an unusable Linux just
to avoid creating a usable generic SCSI transport interface?
Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-12 19:49 Joerg Schilling
  2002-07-12 19:58 ` Thunder from the hill
  2002-07-12 21:05 ` Alan Cox
  0 siblings, 2 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-12 19:49 UTC (permalink / raw)
  To: alan, schilling; +Cc: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1040 bytes --]


>From alan@lxorguk.ukuu.org.uk Fri Jul 12 21:43:27 2002

>On Fri, 2002-07-12 at 20:37, Joerg Schilling wrote:
>> >o       Many ide floppy devices can do ATAPI but get it horribly wrong
>> 
>> Describe the problems.

>Go read the source code, do your own homework

Fine! You repeat that you have no argument that stands a check.
So let us take it as prooven that there is no problem with resent
(< 10 year old) drives. 

>> 
>> Sorry, this has nothing to do with dev_t

>It has a huge amount to do with dev_t. It should be immediately obvious
>why dev_t is a critical factor in getting that interface working in a
>sane fashion.


If a sane driver interface depends on dev_t being 32 bits, then there
would be a lot og junk in the Linux kernel :-(

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* Re: IDE/ATAPI in 2.5
@ 2002-07-12 19:37 Joerg Schilling
  2002-07-12 19:52 ` Thunder from the hill
                   ` (2 more replies)
  0 siblings, 3 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-12 19:37 UTC (permalink / raw)
  To: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2228 bytes --]

>Alan Cox wrote:

>> Please consider deprecating or removing ide-floppy/ide-tape/ide-cdrom
>> and treat all ATAPI devices as what they really are -- SCSI over IDE.

>They aren't.

Please don't start again to tell onprooven statements....
We had a similar discussion in January 2001 and you did not give a proove
for this statement.


>o       Not all ide cdrom devices are ATAPI capable

Name one drive made after 1993, one drive made after 1995 and one drive made 
after 2000 to verify your statement.

>o       Many ide floppy devices can do ATAPI but get it horribly wrong

Describe the problems.

>o       ide-tape is -totally- weird and unrelated to st

Describe problems and name drives that will not work via ATAPI.

>Andre did the framework ready to move to a situation where you could open
>either the ide-scsi or the ide-cdrom name without module reloading mess.
>You'd need to ask our new 2.5 IDE maintainer to finish that work off.

This is a really bad idea!

The result of such bad hacks is that nobody really tests whether the new
code works.

Let me give an example:

If you try to put ide-scsi on top of PCATA (the interface that is used
in notebooks to connect external disks and CD-writers).

Depending on the kernel version, this either causes a system panic or
just does not work at all. As all ATAPI CD-writers and CD-rom drives
have a fallback to ATA commands, nobody who does not like to use a writer
will ever notice the problem. They simply access the CD-ROM as read only
ATA disk. If ide-cd would have been banned this bug would have been fixed years 
ago.

>For disk it gets much easier. Linus has already said he wants a single
>'disk' device, which once we get 32bit dev_t will be nice. With that we
>can finally turn aacraid, megaraid and other 'fake scsi' devices back to
>raw block devices without breaking compatibility assumptions, and get more
>throughput.


Sorry, this has nothing to do with dev_t

Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* IDE/ATAPI in 2.5
@ 2002-07-12 19:25 Joerg Schilling
  0 siblings, 0 replies; 204+ messages in thread
From: Joerg Schilling @ 2002-07-12 19:25 UTC (permalink / raw)
  To: linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1566 bytes --]

H.P. Anvin wrote:

>Please consider deprecating or removing ide-floppy/ide-tape/ide-cdrom
>and treat all ATAPI devices as what they really are -- SCSI over IDE.
>It is a source of no ending confusion that a Linux system will not
>write CDs to an IDE CD-writer out of the box, for the simple reason
>that cdrecord needs access to the generic packet interface, which is
>only available in the nonstandard ide-scsi configuration.

Thank you for this thread!

libscg now has 5 different SCSI transport interface implementations
only for Linux.

There are still problems like e.g. USB which not really usable.

>There really seems to be no decent reason to treat ATAPI devices as
>anything else.  I understand the ide-* drivers contain some
>workarounds for specific devices, but those really should be moved to
>their respective SCSI drivers anyway -- after all, manufacturers
>readily slap IDE or SCSI interfaces on the same devices anyway.

>Note that this is specific to ATAPI devices.  ATA hard drives are
>another matter entirely.

A reasonable idea would be to make the ATA driver a SCSI HBAdriver and
in case that there is a need for pure ATA (e.g. Hard disks) there should
be a second interface for a ATA driver stack.

Please keep me on the CC: I am not on the list.



Jörg

 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

^ permalink raw reply	[flat|nested] 204+ messages in thread
* IDE/ATAPI in 2.5
@ 2002-07-12  0:27 H. Peter Anvin
  2002-07-12  0:37 ` Bartlomiej Zolnierkiewicz
                   ` (4 more replies)
  0 siblings, 5 replies; 204+ messages in thread
From: H. Peter Anvin @ 2002-07-12  0:27 UTC (permalink / raw)
  To: linux-kernel

Okay, I have suggested this before, and I haven't quite looked at this
in detail, but I would again like to consider the following,
especially given the changes in 2.5:

Please consider deprecating or removing ide-floppy/ide-tape/ide-cdrom
and treat all ATAPI devices as what they really are -- SCSI over IDE.
It is a source of no ending confusion that a Linux system will not
write CDs to an IDE CD-writer out of the box, for the simple reason
that cdrecord needs access to the generic packet interface, which is
only available in the nonstandard ide-scsi configuration.

There really seems to be no decent reason to treat ATAPI devices as
anything else.  I understand the ide-* drivers contain some
workarounds for specific devices, but those really should be moved to
their respective SCSI drivers anyway -- after all, manufacturers
readily slap IDE or SCSI interfaces on the same devices anyway.

Note that this is specific to ATAPI devices.  ATA hard drives are
another matter entirely.

	-hpa

-- 
<hpa@transmeta.com> at work, <hpa@zytor.com> in private!
"Unix gives you enough rope to shoot yourself in the foot."
http://www.zytor.com/~hpa/puzzle.txt	<amsp@zytor.com>

^ permalink raw reply	[flat|nested] 204+ messages in thread

end of thread, other threads:[~2002-07-18 18:50 UTC | newest]

Thread overview: 204+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-07-15 13:26 IDE/ATAPI in 2.5 Joerg Schilling
2002-07-16  3:16 ` Christer Weinigel
  -- strict thread matches above, loose matches on Subject: below --
2002-07-17 14:58 Joerg Schilling
2002-07-17 13:46 Joerg Schilling
2002-07-17 14:00 ` Alexander Viro
2002-07-17 12:32 Joerg Schilling
2002-07-17 13:36 ` Rik van Riel
2002-07-17 13:54 ` Anton Altaparmakov
2002-07-16 17:49 Joerg Schilling
2002-07-16 17:34 Joerg Schilling
2002-07-16 14:30 Richard Zidlicky
2002-07-16 14:06 Joerg Schilling
2002-07-16 14:15 ` Christoph Hellwig
2002-07-16 14:17 ` Lars Marowsky-Bree
2002-07-16 14:02 Joerg Schilling
2002-07-16 12:49 Joerg Schilling
2002-07-16 14:28 ` Jauder Ho
2002-07-16 16:08   ` Buddy Lumpkin
2002-07-16 11:28 Joerg Schilling
2002-07-16  9:33 ` James Bottomley
2002-07-16 11:43 ` Martin Dalecki
2002-07-16 11:47 ` Lars Marowsky-Bree
2002-07-16 11:59 ` Vojtech Pavlik
2002-07-16 11:02 Joerg Schilling
2002-07-16 10:47 Joerg Schilling
2002-07-15 18:27 Nick Bellinger
2002-07-15 20:12 ` Jauder Ho
2002-07-16  7:49 ` Buddy Lumpkin
2002-07-15 15:08 Joerg Schilling
2002-07-15 13:07 Joerg Schilling
2002-07-16 10:16 ` Richard Zidlicky
2002-07-15 12:58 Joerg Schilling
2002-07-15 12:27 Joerg Schilling
2002-07-15 11:27 Joerg Schilling
2002-07-15 14:52 ` Rik van Riel
2002-07-15 11:09 James Bottomley
2002-07-15  9:20 Joerg Schilling
2002-07-15 11:23 ` Buddy Lumpkin
2002-07-15 12:22 ` Benjamin Herrenschmidt
2002-07-15 13:17 ` venom
2002-07-14 20:18 Joerg Schilling
2002-07-14 20:13 Joerg Schilling
2002-07-14 20:18 ` Rik van Riel
2002-07-15  9:11   ` venom
2002-07-15 10:01 ` Richard Zidlicky
2002-07-14 20:04 Joerg Schilling
2002-07-14 20:15 ` Tomas Szepe
2002-07-14 20:21   ` Mathieu Chouquet-Stringer
2002-07-14 20:27     ` Mathieu Chouquet-Stringer
     [not found]     ` <Pine.LNX.4.33.0207141704280.21492-100000@coffee.psychology.mcmaster.ca>
2002-07-14 21:09       ` Mathieu Chouquet-Stringer
2002-07-14 21:46     ` Alan Cox
2002-07-14 20:43       ` Mathieu Chouquet-Stringer
2002-07-14 21:59         ` Alan Cox
2002-07-14 20:54           ` Sean Neakums
2002-07-14 21:09             ` Mark Hahn
2002-07-14 22:20               ` Tomas Szepe
2002-07-14 21:07           ` Mathieu Chouquet-Stringer
2002-07-14 22:07             ` Mathieu Chouquet-Stringer
2002-07-14 22:14               ` Thunder from the hill
2002-07-15  3:34                 ` Mathieu Chouquet-Stringer
2002-07-15  3:38                   ` Thunder from the hill
2002-07-15  3:44                     ` Mathieu Chouquet-Stringer
2002-07-15  4:36                       ` Alexander Viro
2002-07-14 20:45       ` Mathieu Chouquet-Stringer
2002-07-14 20:49       ` Daniel Egger
2002-07-14 19:41 Joerg Schilling
2002-07-14 19:51 ` Tomas Szepe
2002-07-14 19:20 Joerg Schilling
2002-07-14 19:18 Joerg Schilling
2002-07-14 19:27 ` Thunder from the hill
2002-07-14 19:10 Joerg Schilling
2002-07-14 18:22 Joerg Schilling
2002-07-14 18:11 Joerg Schilling
2002-07-14 18:40 ` Tomas Szepe
2002-07-14 19:06   ` Tomas Szepe
2002-07-14 19:15     ` Sean Neakums
2002-07-14 19:42       ` Tomas Szepe
2002-07-14 19:02 ` Willy TARREAU
2002-07-14 23:58 ` Andrew Morton
     [not found]   ` <Pine.LNX.4.33.0207150831080.29242-100000@pc-3.office.scali.no>
2002-07-15  6:54     ` Andrew Morton
2002-07-14 15:15 Joerg Schilling
2002-07-14 15:27 ` Rik van Riel
2002-07-14 15:12 Joerg Schilling
2002-07-14 16:45 ` Alan Cox
     [not found] <mailman.1026651901.18426.linux-kernel2news@redhat.com>
2002-07-14 15:05 ` Pete Zaitcev
2002-07-14 14:28 Joerg Schilling
2002-07-14 14:45 ` Anton Altaparmakov
2002-07-14 14:52   ` Thunder from the hill
2002-07-14 14:46 ` Thunder from the hill
2002-07-14 14:25 Joerg Schilling
2002-07-14 14:20 Joerg Schilling
2002-07-14 15:56 ` Erik Andersen
2002-07-14 14:18 Joerg Schilling
2002-07-14 14:35 ` Tomas Szepe
2002-07-14 15:00 ` Rik van Riel
2002-07-14 19:13 ` Richard Zidlicky
2002-07-14 14:07 Joerg Schilling
2002-07-14 15:28 ` Alan Cox
2002-07-18 18:51 ` Kelsey Hudson
2002-07-14 14:00 Joerg Schilling
2002-07-15  0:29 ` Richard B. Johnson
2002-07-14 13:55 Joerg Schilling
2002-07-14 13:47 Joerg Schilling
2002-07-14 14:31 ` Thunder from the hill
2002-07-14 21:23 ` Andre Hedrick
2002-07-14 13:26 Joerg Schilling
2002-07-14 14:28 ` Thunder from the hill
2002-07-14 13:24 Joerg Schilling
2002-07-14 13:39 ` Anton Altaparmakov
2002-07-14 14:10 ` Thunder from the hill
2002-07-14 14:35 ` Adrian Bunk
2002-07-14 16:52   ` Kurt Garloff
2002-07-14 13:17 Joerg Schilling
2002-07-14 14:03 ` Thunder from the hill
2002-07-14 14:44 ` Alan Cox
2002-07-14 13:08 Joerg Schilling
2002-07-14 13:59 ` Thunder from the hill
2002-07-14 13:02 Joerg Schilling
2002-07-14 12:50 Joerg Schilling
2002-07-14 12:44 Joerg Schilling
2002-07-14 12:38 Joerg Schilling
2002-07-14 12:32 Joerg Schilling
2002-07-14 16:01 ` Erik Andersen
2002-07-14  6:20 Adam J. Richter
2002-07-14 15:22 ` Bartlomiej Zolnierkiewicz
2002-07-13 23:27 Adam J. Richter
2002-07-13 23:47 ` Bartlomiej Zolnierkiewicz
2002-07-13 14:46 Adam J. Richter
2002-07-13 15:38 ` Bartlomiej Zolnierkiewicz
2002-07-12 20:08 Joerg Schilling
2002-07-12 21:31 ` Alan Cox
2002-07-12 19:57 Joerg Schilling
2002-07-12 21:17 ` Alan Cox
2002-07-13  5:49   ` Erik Andersen
2002-07-12 19:55 Joerg Schilling
2002-07-12 20:19 ` Richard B. Johnson
2002-07-13  5:40 ` Erik Andersen
2002-07-13 10:52   ` Anssi Saari
2002-07-14  0:35     ` Erik Andersen
2002-07-13 16:53   ` Olivier Galibert
2002-07-14  0:34     ` Erik Andersen
2002-07-16  5:46       ` H. Peter Anvin
2002-07-12 19:49 Joerg Schilling
2002-07-12 19:58 ` Thunder from the hill
2002-07-12 20:38   ` Thunder from the hill
2002-07-12 21:05 ` Alan Cox
2002-07-12 19:37 Joerg Schilling
2002-07-12 19:52 ` Thunder from the hill
2002-07-13  6:36   ` jbradford
2002-07-13 14:25     ` Alan Cox
2002-07-13 13:55       ` Thomas Molina
2002-07-13 15:31         ` Alan Cox
2002-07-13 14:31           ` Thomas Molina
2002-07-13 14:07       ` jbradford
2002-07-13 15:32         ` Alan Cox
2002-07-13 14:36           ` jbradford
2002-07-15 11:47   ` Henning P. Schmiedehausen
2002-07-15 18:44     ` Thunder from the hill
2002-07-12 20:06 ` Andre Hedrick
2002-07-12 20:52 ` Alan Cox
2002-07-12 19:25 Joerg Schilling
2002-07-12  0:27 H. Peter Anvin
2002-07-12  0:37 ` Bartlomiej Zolnierkiewicz
2002-07-12  1:00 ` Alan Cox
2002-07-12  1:23   ` Andre Hedrick
2002-07-12  5:03   ` H. Peter Anvin
2002-07-12  4:13 ` Erik Andersen
2002-07-12  4:17   ` H. Peter Anvin
2002-07-12  4:44     ` Erik Andersen
2002-07-12  4:46       ` H. Peter Anvin
2002-07-12  5:03         ` Andre Hedrick
2002-07-12  5:11           ` H. Peter Anvin
2002-07-12 13:15             ` Alan Cox
2002-07-15 10:24             ` Eric W. Biederman
2002-07-16  5:28               ` H. Peter Anvin
2002-07-12 12:11 ` Martin Dalecki
2002-07-12 12:51   ` Thunder from the hill
2002-07-12 14:17     ` Bartlomiej Zolnierkiewicz
2002-07-12 14:29       ` Martin Dalecki
2002-07-12 14:41         ` Jens Axboe
2002-07-12 15:00           ` Martin Dalecki
2002-07-12 15:05             ` Jens Axboe
2002-07-12 15:41           ` Andre Hedrick
2002-07-12 15:35         ` Alan Cox
2002-07-14  8:19         ` Paul Bristow
2002-07-14  9:11           ` jbradford
2002-07-14  9:16           ` Matthew D. Pitts
2002-07-14 14:04           ` Martin Dalecki
2002-07-14 16:56             ` Thunder from the hill
2002-07-12 15:26     ` Andre Hedrick
2002-07-12 13:22   ` Alan Cox
2002-07-12 13:07     ` Tomas Szepe
2002-07-12 14:06       ` Alan Cox
2002-07-12 15:34       ` Andre Hedrick
2002-07-12 17:52   ` Linus Torvalds
2002-07-12 18:33     ` H. Peter Anvin
2002-07-12 18:54       ` Anton Altaparmakov
2002-07-12 18:55         ` H. Peter Anvin
2002-07-12 19:35         ` Zwane Mwaikambo
2002-07-12 19:06       ` Bartlomiej Zolnierkiewicz
2002-07-12 23:17     ` Matthias Andree
2002-07-12 15:02 ` Kevin P. Fleming
2002-07-12 15:10   ` Martin Dalecki
2002-07-12 16:47   ` Andre Hedrick

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox