Re: ide-scsi is deprecated for cd burning! Use ide-cd and give dev=/dev/hdX as device

From: Kiniger, Karl (GE Healthcare) (karl.kiniger_at_med.ge.com)
Date: 02/28/05

  • Next message: James Chapman: "[PATCH: 2.6.11-rc5] i2c chips: add adt7461 support to lm90 driver"
    To: Valdis.Kletnieks@vt.edu
    Date:	Mon, 28 Feb 2005 18:11:27 +0100
    
    

    On Sat, Feb 19, 2005 at 01:23:10AM +0100, Valdis.Kletnieks@vt.edu wrote:
    >
    > On Fri, 18 Feb 2005 15:23:44 EST, Bill Davidsen said:
    >
    > > I'll try to build a truth table for this, I'm now working with some
    > > non-iso data sets, so I'm a bit more interested. I would expect read()
    > > to only try to read one sector, so I'll just do a quick and dirty to get
    > > the size from the command line, seek and read.
    > >
    > > I haven't had a problem using dd to date, as long as I know how long the
    > > data set was, but I'll try to have results tonight.
    >
    > The problem is that often you don't know exactly how long the data set is
    > (think "backup burned to CD/RW") - there's a *lot* of code that does stuff
    > like
    >
    > while (actual=read(fd,buffer,65536) > 0) {
    > ...
    > }
    >
    > with the realistic expectation that the last read might return less than
    > 64k,
    > in which case 'actual' will tell us how much was read. Instead, we just get
    > an error on the read.
    >
    > Note that 'dd' does this - that's why you get messages like '12343+1 blocks
    > read'.
    > We *really* want to get to a point where 'dd' will work *without* having to
    > tell it a 'bs=' and 'count=' to get the size right....
    > )

    my point was that even specifying the exact byte count was not sufficient.
    e.g

    strace sdd if=/dev/zero bs=32k of=/dev/null ivsize=41234 gives:
    ......
    munmap(0x46a000, 4096) = 0
    _llseek(3, 0, [0], SEEK_SET) = 0
    _llseek(4, 0, [0], SEEK_SET) = 0
    read(3, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 32768) = 32768
    write(4, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 32768) = 32768
    read(3, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 8466) = 8466
    write(2, "sdd: Done with input volume # 1."..., 33sdd: Done with input volume # 1.
    ) = 33
    write(2, "Do you want to continue with inp"..., 53Do you want to continue with input volume # 2 (y/n): ) = 53

    that is, it requests exactly ivsize bytes (for iso cd's this can be got from isosize).

    even this was not good enough....

    Karl

    -- 
    Karl Kiniger   mailto:karl.kiniger@med.ge.com
    GE Medical Systems Kretztechnik GmbH & Co OHG
    Tiefenbach 15       Tel: (++43) 7682-3800-710
    A-4871 Zipf Austria Fax: (++43) 7682-3800-47
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at  http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at  http://www.tux.org/lkml/
    

  • Next message: James Chapman: "[PATCH: 2.6.11-rc5] i2c chips: add adt7461 support to lm90 driver"

    Relevant Pages

    • Re: ide-scsi is deprecated for cd burning! Use ide-cd and give dev=/dev/hdX as device
      ... >>to only try to read one sector, so I'll just do a quick and dirty to get ... >>data set was, but I'll try to have results tonight. ... It sounds as if the problem with ide-cd is going to get fixed, ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: IT8212/ITE RAID
      ... > What does a full identify data set for the drive look like? ... Here it is for the two drives. ... Checksum: correct ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: PREEMPT_RT vs I-PIPE: the numbers, part 2
      ... Paul E. McKenney wrote: ... > data set might be a bit large... ... > how one goes about deriving individual-latency CDFgiven a single ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: ide-scsi is deprecated for cd burning! Use ide-cd and give dev=/dev/hdX as device
      ... > non-iso data sets, so I'm a bit more interested. ... The problem is that often you don't know exactly how long the data set is ... with the realistic expectation that the last read might return less than 64k, ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)