Curt Sampson | 13 Aug 08:34 2004
Picon

newfs and DVD-RAM


Anybody know how to put a filesystem on to a DVD-RAM under
NetBSD-2.0_BETA/i386? It's a fine 2048 byte per sector block device, and
I can disklabel it, but newfs doesn't seem to like it.

dev1 # disklabel cd0
disklabel: Can't read master boot record 0: Invalid argument
# /dev/rcd0d:
type: ATAPI
disk: dvdram
label: dvdram
flags: removable
bytes/sector: 2048
sectors/track: 100
tracks/cylinder: 1
sectors/cylinder: 100
cylinders: 22368
total sectors: 2236704
rpm: 300
interleave: 1
trackskew: 0
cylinderskew: 0
headswitch: 0           # microseconds
track-to-track seek: 0  # microseconds
drivedata: 0

4 partitions:
#        size    offset     fstype [fsize bsize cpg/sgs]
 a:   2236700         0     4.2BSD   2048 16384     0  # (Cyl.      0 -  22366)
 d:   2236700         0     unused      0     0        # (Cyl.      0 -  22366)
(Continue reading)

Hubert Feyrer | 13 Aug 10:52 2004
Picon

Re: newfs and DVD-RAM

On Fri, 13 Aug 2004, Curt Sampson wrote:
> 4 partitions:
> #        size    offset     fstype [fsize bsize cpg/sgs]
>  a:   2236700         0     4.2BSD   2048 16384     0  # (Cyl.      0 -  22366)
                                            ^^^^^
A blocksize of 2048 would make sense to me - but (playing with my DVD-RAM
myself right now) it seems that the minimum enforced by disklabel(8) &
newfs(8) there is 4k. :(

 - Hubert

--

-- 
                         ,,_
If wishes were wings,  o"   )~  would fly.            -- Go www.NetBSD.org!
                        ''''

Curt Sampson | 13 Aug 10:54 2004
Picon

Re: newfs and DVD-RAM

On Fri, 13 Aug 2004, Hubert Feyrer wrote:

> On Fri, 13 Aug 2004, Curt Sampson wrote:
> > 4 partitions:
> > #        size    offset     fstype [fsize bsize cpg/sgs]
> >  a:   2236700         0     4.2BSD   2048 16384     0  # (Cyl.      0 -  22366)
>                                             ^^^^^
> A blocksize of 2048 would make sense to me

Why? This is entirely unrelated to the sector size (except that
blocksize must be at least the sector size); it's only related to the
size and quantity of files you anticipate storing on the disk.

cjs
--

-- 
Curt Sampson  <cjs <at> cynic.net>   +81 90 7737 2974   http://www.NetBSD.org
    Don't you know, in this new Dark Age, we're all light.  --XTC

David Brownlee | 13 Aug 11:04 2004
Picon

Re: newfs and DVD-RAM

On Fri, 13 Aug 2004, Hubert Feyrer wrote:

> On Fri, 13 Aug 2004, Curt Sampson wrote:
>> 4 partitions:
>> #        size    offset     fstype [fsize bsize cpg/sgs]
>>  a:   2236700         0     4.2BSD   2048 16384     0  # (Cyl.      0 -  22366)
>                                            ^^^^^
> A blocksize of 2048 would make sense to me - but (playing with my DVD-RAM
> myself right now) it seems that the minimum enforced by disklabel(8) &
> newfs(8) there is 4k. :(

 	Wouldn't a fragmentsize of the native media blocksize make more
 	sense?

--

-- 
 		David/absolute       -- www.NetBSD.org: No hype required --

Curt Sampson | 13 Aug 11:02 2004
Picon

Re: newfs and DVD-RAM

Actually, I've discovered the problem and filed a PR about this:

    http://www.netbsd.org/cgi-bin/query-pr-single.pl?number=26636

Anybody got a fix?

cjs
-- 
Curt Sampson  <cjs <at> cynic.net>   +81 90 7737 2974   http://www.NetBSD.org
    Don't you know, in this new Dark Age, we're all light.  --XTC

On Fri, 13 Aug 2004, Curt Sampson wrote:

>
> Anybody know how to put a filesystem on to a DVD-RAM under
> NetBSD-2.0_BETA/i386? It's a fine 2048 byte per sector block device, and
> I can disklabel it, but newfs doesn't seem to like it.
>
> dev1 # disklabel cd0
> disklabel: Can't read master boot record 0: Invalid argument
> # /dev/rcd0d:
> type: ATAPI
> disk: dvdram
> label: dvdram
> flags: removable
> bytes/sector: 2048
> sectors/track: 100
> tracks/cylinder: 1
> sectors/cylinder: 100
> cylinders: 22368
(Continue reading)

David Laight | 13 Aug 19:56 2004
Picon

Re: newfs and DVD-RAM

On Fri, Aug 13, 2004 at 03:34:52PM +0900, Curt Sampson wrote:
> 
> Anybody know how to put a filesystem on to a DVD-RAM under
> NetBSD-2.0_BETA/i386? It's a fine 2048 byte per sector block device, and

I think you'll find that there are quite a few places where non-512
bytes sectors just don't work.

This is partially lazyness on the part of coders, and partially because
it is difficult to test non-512 byte sectors.

IIRC there are some PRs that contain fixes for non-512 byte sectors
to various parts of the system

	David

--

-- 
David Laight: david <at> l8s.co.uk

Josh Sandbrook | 14 Aug 18:38 2004

DELAY performance...

Hello... 

Im writing a driver for an LCD ( HD44780 ) which is wired to the printer 
port. Im having performance issues when throwing lots of data to it.. and I 
think it is because of the DELAY function. 

With each byte I send out the printer port to the lcd, I need to call 
DELAY() about 4 times, with about a 1100 usec delay in total. When I send 
many megs to the lcd, I find that the rest of the system gets very bogged 
down... 

AFAIK, DELAY halts the kernel from doing other things (except for handling 
interrupts). I am guessing that is what is causing most of the system 
slowdown.. 

So, can anyone suggest a nicer way for me to delay ( even if it is not as 
accurate )? 

Thanks 

Hubert Feyrer | 14 Aug 23:18 2004
Picon

Re: DELAY performance...

On Sun, 15 Aug 2004, Josh Sandbrook wrote:
> So, can anyone suggest a nicer way for me to delay ( even if it is not as
> accurate )?

callout(9)?

 - Hubert

--

-- 
                         ,,_
If wishes were wings,  o"   )~  would fly.            -- Go www.NetBSD.org!
                        ''''

Jason Thorpe | 15 Aug 17:34 2004

Re: DELAY performance...


On Aug 14, 2004, at 9:38 AM, Josh Sandbrook wrote:

> Hello...
> Im writing a driver for an LCD ( HD44780 ) which is wired to the 
> printer port. Im having performance issues when throwing lots of data 
> to it.. and I think it is because of the DELAY function.
> With each byte I send out the printer port to the lcd, I need to call 
> DELAY() about 4 times, with about a 1100 usec delay in total. When I 
> send many megs to the lcd, I find that the rest of the system gets 
> very bogged down...
> AFAIK, DELAY halts the kernel from doing other things (except for 
> handling interrupts). I am guessing that is what is causing most of 
> the system slowdown..
> So, can anyone suggest a nicer way for me to delay ( even if it is not 
> as accurate )?

You can either use a state machine to output the bytes and use 
callout(9) to call your action functions after a period of time has 
passed, or might be able to use tsleep(9) (tsleep() can only be called 
from a process context, however).

         -- Jason R. Thorpe <thorpej <at> wasabisystems.com>

netbsd | 18 Aug 10:20 2004
Picon

Installboot fails

Hello list!
I have already posted this problem to the port-i386 list, but haven't got
an answer so far.The url is: http://mail-index.netbsd.org/port-i386/2004/08/17/0008.html

I was wondering if anyone here could give me a hint why it fails.

Thanks, Mario


Gmane