Linux-Development-Sys Digest #348, Volume #6     Sat, 30 Jan 99 02:14:52 EST

Contents:
  Re: libc5 and glibc (Johan Kullstam)
  Need Linux developer in Houston ("INZ")
  Re: trying to write a module which uses parallel port, but inb( port ) is   always 
the same (Jens Kristian S�gaard)
  Re: Modest next goal for Linux (Peter Samuelson)
  How to flush the file cache ? (Renaud Lottiaux)
  Re: 2 stacks? (Nix)
  Re: Adopting COM? (Nix)
  Re: Linux 2.2.0 final won't compile. (Mark Swanson)
  BIOS passwords (nexus)
  Re: COM for Linux? (Matthias Warkus)
  Printing to HP DeskWriter 560C ("Scott Nielson")
  How do I scroll back/forward the current VC? (Loren Osborn)
  Re: Linux Phase 2: A Consumer Operating System (Paul D. Smith)
  help!!! On reinstalling Red Hat ("Scott MacDonald")
  Re: COM for Linux? (Christopher Browne)
  Reserving physical memory (Jan Willamowius)
  Re: Infos an�bout Intel's Manual Reference (i386+) (Emile van Bergen)
  Re: disheartened gnome developer (jedi)
  Re: LINKER PROBLEM (INTERACTIVE - SCO - LINUX) ("Robert")
  Re: COM for Linux? (Christopher B. Browne)
  Re: Why I'm dumping Linux, going back to Windblows (Leslie Mikesell)
  Re: How do you dynamically pass port addresses to a device driver? (Marc Lefranc)
  Re: assert() change (Andreas Schwab)
  Re: /dev/rdsk  - help (Villy Kruse)

----------------------------------------------------------------------------

Subject: Re: libc5 and glibc
From: Johan Kullstam <[EMAIL PROTECTED]>
Date: 29 Jan 1999 20:49:44 -0500

Ronald Cole <[EMAIL PROTECTED]> writes:

> Johan Kullstam <[EMAIL PROTECTED]> writes:
> > in order to avoid unmounting problems with new kernels, i have
> > compiled my init statically (albeit with glibc).
> 
> You should have just upgraded to a glibc that didn't suffer from this
> problem.  Perhaps 2.0.x, where x > 6...

thanks.  however, i am running redhat's glibc-2.0.7-29 (it is well
known to be a patched up glibc-2.0.6).  perhaps if
the FSF would ever *release* a glibc 2.0.x where x > 6....

-- 
Johan Kullstam [[EMAIL PROTECTED]] Don't Fear the Penguin!

------------------------------

From: "INZ" <[EMAIL PROTECTED]>
Subject: Need Linux developer in Houston
Date: Sat, 30 Jan 1999 02:53:46 GMT

Hello Everybody,

We are looking for a Linux programmer/administrator for our Houston office.
Very interesting and challenging work on an Internet appliance using
embedded Linux. Must have good system administrator skills and TCP/IP
configuration knowledge. Must be familiar with UNIX shell programming. Perl
and  C++ definite asset. Knowledge of fax/modems programming also preferred.

Please reply to:
[EMAIL PROTECTED]

Thanks,

Ivo Zivkov, VP Technology.
FaxTel, Inc.
www.FaxTel.com





------------------------------

From: [EMAIL PROTECTED] (Jens Kristian S�gaard)
Subject: Re: trying to write a module which uses parallel port, but inb( port ) is   
always the same
Date: 30 Jan 1999 04:05:57 +0100

Olof Wolgast <[EMAIL PROTECTED]> writes:

> I got my hands on a module which is supposed to create a link to your
> texas-calculator using the parallel port. It didn't work, so I sat down

Should this happen to be a Texas Instruments 8x calculator ?

The modules written for those are quite old ( and obsolete ). One
exists though that I succeded in installing. It offered just a
character device - but I lacked user-space programs using this device
to transfer programs, etc.

So I wrote a new user-space driver for the link. I then made a series
of programmes for this link:

        1. Send/Receive programs
        2. Receive graph-data ( outputs gnuplot data )
        3. Get screendump
        4. Detect calculatortype

It works okay, although I only tested it on the 83-model and the
parallel link-cable ( although serial-link cable code is included ).

Please email me, if you're interesed...

> haven't any support for lp in the kernel, so that shouldn't affect. What
> can be the problem? The code is about 1.5 years old, does that old code

Using the newer kernels, I've noticed that programs using direct port
I/O to interface the parport needed to have the parport_pc module
loaded...


-- 
Jens Kristian S�gaard,
[EMAIL PROTECTED]

------------------------------

From: [EMAIL PROTECTED] (Peter Samuelson)
Crossposted-To: comp.os.linux.advocacy
Subject: Re: Modest next goal for Linux
Date: 28 Jan 1999 23:13:27 -0600
Reply-To: Peter Samuelson <[EMAIL PROTECTED]>

[John De Hoog <[EMAIL PROTECTED]>]
> "Faster file access. Version 2.2 can store filenames in a high-speed
> cache in memory, meaning that users won't have to wait for the
> computer to retrieve the information off relatively slow hard disks."

Right, the dcache.

> OK, maybe CNet news isn't the right place to be finding out this
> stuff.<g>

CNet probably has no more clue what it means than you did, but whoever
they are parroting got it right.

Linux has always had block caching, so that for a block device such as
a hard disk partition, the OS caches all the blocks it knows about
(previously read or written) and the cache grows to use available
memory.  (Unused memory is wasted memory.)  The cache grows and shrinks
per memory demand.  So far so good; any decent OS will do this much.

But in the 2.1 series they introduce a directory entry cache, or
`dentry cache' for short, or `dcache' for shorter.  This is simply a
cache of `dentries' (file pathnames, hashed for speed) holding such
useful information as inode numbers.  When a user process either reads
a directory or asks for a specific filename, Linux 2.2 looks up the
dentry in the dcache and, if not found, starts searching the usual way.
In the case of a dcache hit this is *much* faster than just searching
through the inodes and directory contents, even if *those* are already
in the block cache.  AFAIK most Unices do not have a dcache.  Someone
said NT does; I don't know.

-- 
Peter Samuelson
<sampo.creighton.edu!psamuels>

------------------------------

From: Renaud Lottiaux <[EMAIL PROTECTED]>
Subject: How to flush the file cache ?
Date: Fri, 29 Jan 1999 14:41:38 +0100

Is anybody know how to flush the file cache
quickly and easily ?

------------------------------

From: Nix <$}xin{[email protected]>
Subject: Re: 2 stacks?
Date: 30 Jan 1999 03:49:05 +0000

[EMAIL PROTECTED] (Stefaan A Eeckels) writes:

> That would be *stoopid*, and I mean it. 'C' is a useful
> language in its current form, and IMHO doesn't need to
> be brought closer to C++.

In any case, this has already happened.

Consider where `const' came from in ISO C.

-- 
`I didn't want the bug *fixed*, I wanted to bitch pointlessly.' - Matthew
                                        R. Williams on alt.religion.emacs

------------------------------

From: Nix <$}xin{[email protected]>
Crossposted-To: comp.os.linux.advocacy
Subject: Re: Adopting COM?
Date: 30 Jan 1999 03:53:20 +0000

[EMAIL PROTECTED] (Wuff) writes:

> 'stable orbit'

At least it isn't decaying.

-- 
`I didn't want the bug *fixed*, I wanted to bitch pointlessly.' - Matthew
                                        R. Williams on alt.religion.emacs

------------------------------

From: Mark Swanson <[EMAIL PROTECTED]>
Subject: Re: Linux 2.2.0 final won't compile.
Date: Fri, 29 Jan 1999 01:50:28 GMT

No. I've never done that in the seven years I've been compiling Linux.
After patching it endlessly I must have screwed up somewhere as
downloading the latest full archive compiled just fine. aic7xxx support is
still broken on my SMP machine, but all else seems well.

Nathan Myers wrote:

>  Mark Swanson <[EMAIL PROTECTED]> wrote:
> >The error I get is:
> >
> >net/network.a(sock_n_syms.o)(__ksymtab+0x288): undefined reference to
> >`csum_partial' ...
>
> You did what lots of other people did: unpacked the new kernel
> on top of the same source tree as the old one.  Don't.
>
> --
> Nathan Myers
> [EMAIL PROTECTED]  http://www.cantrip.org/

--
1999 - The year of the penguin.



------------------------------

From: [EMAIL PROTECTED] (nexus)
Subject: BIOS passwords
Date: 29 Jan 1999 06:27:21 GMT

how would one write a program in linux that would display BIOS passwords 
to the user......?.........for that matter, where is BIOS memory mapped 
in linux and how would you access it?


------------------------------

From: [EMAIL PROTECTED] (Matthias Warkus)
Crossposted-To: comp.os.linux.misc
Subject: Re: COM for Linux?
Date: Sat, 30 Jan 1999 00:40:27 +0000
Reply-To: [EMAIL PROTECTED]

It was the Fri, 29 Jan 1999 15:11:43 -0400...
..and Aaron Perrin <[EMAIL PROTECTED]> wrote:
> Does anyone know if a Component Object Model (COM) port is available for
> linux?
> If not, is any group or company planning or developing such a port?
> 
> I'd like to work on some applications for linux that would utilize
> distributed COM
> components, and I want to know if this is possible.

There is no COM under Linux[*].
On Unix platforms, one uses CORBA, which is a real standard, as opposed to
COM.

mawa

[*] If you don't count the COM implementation in the Crystal Space 3D engine.
-- 
Matthias Warkus    |    [EMAIL PROTECTED]    |    Dyson Spheres for sale!
My Geek Code is no longer in my .signature. It's available on e-mail request.
It's sad to live in a world where knowing how to program your VCR actually
lowers your social status...

------------------------------

From: "Scott Nielson" <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.networking
Subject: Printing to HP DeskWriter 560C
Date: Fri, 29 Jan 1999 01:02:54 -0700

I have been using the cdj550 device in ghostscript 4.30 to print to a HP
DeskWriter 560C.  It works, but before the job and after each page I am
getting an extra sheet with one line on it.  The line will say something
like: "gnu ghostscript 4.30" or "Page 1" or "Last Page".

Am I using the right ghostscript device?  Or, is there a better one?



------------------------------

From: Loren Osborn <[EMAIL PROTECTED]>
Subject: How do I scroll back/forward the current VC?
Date: Sun, 24 Jan 1999 10:39:35 -0800

I'm doing some work on gpm.  I'm trying to add "scroll wheel" support to
it.  I need to know a function call to scroll the current VC (so that I
can do so within gpm).

Thanks in advance,

Loren


------------------------------

From: [EMAIL PROTECTED] (Paul D. Smith)
Crossposted-To: alt.os.linux,comp.os.linux.development.apps,comp.os.linux.setup
Subject: Re: Linux Phase 2: A Consumer Operating System
Date: 29 Jan 1999 02:40:59 -0500
Reply-To: [EMAIL PROTECTED]

I recently switched from RH to Debian (I'm going to write something
later describing my reason(s), because hopefully RH can fix them).

I agree that dselect, once you get used to the (for me, being an Emacs
person) very odd keybindings and understand the basics, is a nice
tool--certainly head and shoulders above Glimpse!

However, dselect/dpkg does have a few obvious shortcomings compared to RPM:

 1) No idea how large a package is from within dselect.  My first
    install of Debian 2.0 blew out my /usr partition with absolutely no
    warning.

    The _cool_ thing was that I just had to go back, deselect a bunch of
    stuff, and dselect reinstalled stuff and configured it just fine.

    But it would have been nice to get info about this issue up-front.

 2) It would be nice to get a better organization of packages, and have
    a way to see an overview of packages, then open them up, etc.
    Esp. during an initial install it's pretty intimidating to see 1525
    packages listed...

 3) It really annoys me how it scans through the entire suite of 1500
    packages any time I want to add one new one.  I don't see why it
    can't just jump right to the package I added/removed/whatever and
    deal with that one directly.

Seems like there was another important one, but I forget now...

-- 
===============================================================================
 Paul D. Smith <[EMAIL PROTECTED]>         Network Management Development
 "Please remain calm...I may be mad, but I am a professional." --Mad Scientist
===============================================================================
   These are my opinions---Nortel Networks takes no responsibility for them.

------------------------------

From: "Scott MacDonald" <[EMAIL PROTECTED]>
Subject: help!!! On reinstalling Red Hat
Date: Fri, 29 Jan 1999 23:20:52 -0600

Hi, I have a linux box someone gave me with red hat 5.1. He says he doesn't
remember the password(yeah right,) so I need to reinstall(I have a red hat
cd). Well, can someone tell me the best way to reformat the hardrive and
reinstall linux clean? I have the cd, but no boot floppy disk. When I try to
boot to Win98 floppy disk, it doesn't even see it, and lilo does its thing.
Can I copy fdisk from redhat cd to a floppy and use it if I can get the box
to boot to floppy before it goes to the hardrive? Any help would be greatly
appreciated because I can' t get pass this login prompt! thanks!

Scott



------------------------------

From: [EMAIL PROTECTED] (Christopher Browne)
Crossposted-To: comp.os.linux.misc
Subject: Re: COM for Linux?
Reply-To: [EMAIL PROTECTED]
Date: Sat, 30 Jan 1999 04:46:07 GMT

On Fri, 29 Jan 1999 15:11:43 -0400, Aaron Perrin
<[EMAIL PROTECTED]> wrote: 
>Does anyone know if a Component Object Model (COM) port is available for
>linux?
>If not, is any group or company planning or developing such a port?
>
>I'd like to work on some applications for linux that would utilize
>distributed COM
>components, and I want to know if this is possible.

Microsoft has released a version for "toy" use. 

See:
<"http://www.sagus.com/prod-i~1/net-comp/dcom/dcom-avail.htm"> 
<"http://www.sagus.com/prod-i~1/net-comp/dcom/linuxbeta.htm">
<"http://www.softwareag.com/corporat/solutions/entirex/entirex.htm">

There is *ZERO* interest in actually using this for anything important,
as this is the sort of thing whose adoption puts any applications built
into a forcible dependancy on Microsoft's good graces.  Licensing the
applications for release outside your site would require licensing COM
for Linux from MSFT, and that is something that I wouldn't trust enough
to spend a single *hour* of my time on on coding. 

There is, in contrast, a rich set of tools for working with the Common
Object Request Broker Architecture; see the URL below for links.  There
exist both free and commercial tools that can be deployed on Linux for
development in a whole variety of languages.

If you build interesting CORBA client/server code, people may prove
interested.  DCOM-related efforts are unlikely to be of much interest. 

-- 
"The idea that Bill Gates has appeared like a knight in shining armour to
lead all customers out of a mire of technological chaos neatly ignores the
fact that it was he who, by peddling second-rate technology, led them into
it in the first place." - Douglas Adams in Guardian, 25-Aug-95
[EMAIL PROTECTED] <http://www.ntlug.org/~cbbrowne/corba.html>

------------------------------

From: Jan Willamowius <[EMAIL PROTECTED]>
Subject: Reserving physical memory
Date: 29 Jan 1999 09:09:14 GMT

For a device driver, I need to reserve a certain position of physical
memory, where
a ISA card communicates with the PC. This memory is not located on the
card, bit in
the main PC memory; request_region() seems to be meant for IO ports
only.

What would be the equivalent in main memory ?

Thanks,
Jan



------------------------------

From: Emile van Bergen <[EMAIL PROTECTED]>
Subject: Re: Infos an�bout Intel's Manual Reference (i386+)
Date: Fri, 29 Jan 1999 10:19:47 +0100

Berto wrote:
> 
> I'm Sorry for my bad English, I'm a Italian student and a I would like to
> know about low level Linux programming (assembler).
> I found some infos on Intel site but I've got some Time downloading
> problems!! (Intel site go slonly from Italy). I search another site for
> this info
> Thank to all anyway.

I could recommend the paper version: 386 DX Microprocessor Programmer's
reference Manual, ISBN 1-55512-131-4. This kind of manual is rather
awkward if you read it online. Besides; you can put the paper version on
your bed-side table! (No, just kidding).

Keep in mind, however, that the assembly syntax in the book is intel's
own, not the unix assembly syntax gcc/gas uses... But that shouldn't be
too much of a problem, as long as you have the gcc info pages nearby.

-- 

M.vr.gr. / Best regards,

Emile van Bergen (e-mail address: [EMAIL PROTECTED])

This e-mail message is 100% electronically degradeable and produced
on a GNU/Linux system.

------------------------------

From: [EMAIL PROTECTED] (jedi)
Crossposted-To: comp.os.linux.advocacy,comp.os.linux.development.apps,comp.os.linux.x
Subject: Re: disheartened gnome developer
Date: Fri, 29 Jan 1999 20:17:50 -0800

On 30 Jan 1999 03:38:10 +0000, Nix <$}xin{[email protected]> wrote:
>[EMAIL PROTECTED] (jedi) writes:
>
>>                                                      supporting the
>>      whole cult of Hitler.
>
>This thread's utility has now officially declined to zero.
>
>(It's the first time I've ever seen Godwin's Law invoked accidentally...)
>

        ...that's assuming it wasn't intentional...     

-- 
                Herding Humans ~ Herding Cats
  
Neither will do a thing unless they really want to, or         |||
is coerced to the point where it will scratch your eyes out   / | \
as soon as your grip slips.

        In search of sane PPP docs? Try http://penguin.lvcm.com

------------------------------

From: "Robert" <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.development.apps
Subject: Re: LINKER PROBLEM (INTERACTIVE - SCO - LINUX)
Date: Fri, 29 Jan 1999 10:33:29 +0100

Thanks for your time.

My "library file formats" knowledge is not so deep, so I do not know
anything about COFF, ELF, IMHO. BTW, iBCS...

I'd like if you can help me with advice; is there any chance of converting
somehow my INTERACTIVE Unix library to work with LINUX linker.

This is about JYACC's JAM for ix which is very expensive for me to buy it
for LINUX.

Thanks again
May the force be with you

Robert Manestar

Stefaan A Eeckels wrote in message <78p6sm$u1f$[EMAIL PROTECTED]>...
>In article <78nh0m$d6e$[EMAIL PROTECTED]>,
> "Robert" <[EMAIL PROTECTED]> writes:
>> I have a C library for INTERACTIVE Unix ver 2.2.1.
>>
>> When I try to link it on Linux, I get:
>>
>> could not read symbols: File format not recognized
>>
>> Robert
>> P.S. It works just fine on SCO OpenServer 5.0.4
>Could that be perchance because Interactive and SCO both
>use COFF, and Linux uses ELF? :-)
>You could try to use iBCS if you want to run binaries
>from other systems, but setting up a second compiler
>to compile using old libraries doesn't seem worth
>the hassle, IMHO. BTW, iBCS does support dynamic
>linking to COFF libraries.
>
>Take care,
>
>--
>Stefaan
>--
>
>PGP key available from PGP key servers (http://www.pgp.net/pgpnet/)
>___________________________________________________________________
>Perfection is reached, not when there is no longer anything to add,
>but when there is no longer anything to take away. -- Saint-Exup�ry
>



------------------------------

From: [EMAIL PROTECTED] (Christopher B. Browne)
Crossposted-To:  comp.os.linux.misc
Subject: Re: COM for Linux?
Reply-To: [EMAIL PROTECTED]
Date: Sat, 30 Jan 1999 06:19:15 GMT

On Sat, 30 Jan 1999 04:46:07 GMT, Christopher Browne <[EMAIL PROTECTED]> posted:
>On Fri, 29 Jan 1999 15:11:43 -0400, Aaron Perrin
><[EMAIL PROTECTED]> wrote: 
>>Does anyone know if a Component Object Model (COM) port is available for
>>linux?
>>If not, is any group or company planning or developing such a port?
>>
>>I'd like to work on some applications for linux that would utilize
>>distributed COM
>>components, and I want to know if this is possible.
>
>Microsoft has released a version for "toy" use. 
>
>See:
><"http://www.sagus.com/prod-i~1/net-comp/dcom/dcom-avail.htm"> 
><"http://www.sagus.com/prod-i~1/net-comp/dcom/linuxbeta.htm">
><"http://www.softwareag.com/corporat/solutions/entirex/entirex.htm">
>
>There is *ZERO* interest in actually using this for anything important,
>as this is the sort of thing whose adoption puts any applications built
>into a forcible dependancy on Microsoft's good graces.  Licensing the
>applications for release outside your site would require licensing COM
>for Linux from MSFT, and that is something that I wouldn't trust enough
>to spend a single *hour* of my time on on coding. 

Note that only the last of those three URLs is still active...

Note that the Linux DCOM FAQ
<http://softworksltd.com/dcomlinuxfaq.html> asks the following:

"1.7 Should I get involved in DCOM for Linux/UNIX? 

DCOM for Linux has been released by Software AG but without
support. So production use is out of the question.  However, it works
pretty well for purposes of evaluating the technology and developing
proof of concept programs.  DCOM for UNIX won't hit full stride for
several years but its feasible to start the evaluation process
now. More maturity and a killer app is needed for widespread
acceptance. My guess is that distributed computing will get a kick
start when Netscape releases a CORBA enabled version of
Navigator. That will peak interest.

2.0 Where can I get DCOM for Linux? 

DCOM for Linux runtime, SDK, examples and documentation are available
for free from Software AG. However, Software AG doesn't provide any
support for DCOM for Linux, neither for free nor for pay. Your best
chance for support is from the dcomunix email discussion list
mentioned above."

When considering whether to use DCOM, consider:
a) It is completely unsupported.
b) There are no promises to fix bugs.
c) A number of problems with running DCOM are noted in the
documentation; seems to reflect the pathological MS problem of things
not working well, and for no particularly good reason.
d) Note the "won't hit full stride for several years" comment.
e) Note that they suggest that CORBA is likely to result in people
getting interested in distributed computing.  Which begs the question:
Why not use CORBA instead.
f) "That will peak interest."  The word that they probably wanted to
use was "pique."  If something "peaks" interest, that means that
interest has reached its high point, and is about to go into decline.
I expect that interest has already "peaked."

-- 
Those who do not understand Unix are condemned to reinvent it, poorly.  
-- Henry Spencer          <http://www.hex.net/~cbbrowne/lsf.html>
[EMAIL PROTECTED] - "What have you contributed to Linux today?..."

------------------------------

From: [EMAIL PROTECTED] (Leslie Mikesell)
Crossposted-To: alt.os.linux,comp.os.linux.development.apps,comp.os.linux.setup
Subject: Re: Why I'm dumping Linux, going back to Windblows
Date: 30 Jan 1999 00:29:01 -0600

In article <78sr8b$[EMAIL PROTECTED]>,  <[EMAIL PROTECTED]> wrote:
>In article <78rk5v$iug$[EMAIL PROTECTED]>, [EMAIL PROTECTED]
>
>Beg to differ. You also not thinking here.
>
>An example helps one UNDERSTAND. this is something you or les dont 
>seem to understand.

Perhaps we would understand if you gave an example that is somehow
better than your description???

>my, a typical Unix arrogance.
>
>"I learned Linux the hard way, and so should you".

The hard way is to try typing commands without first spending
some time learning the shell metacharacters and the way
the tools interact via pipelines, process grouping and
the like.  The best way to do that is to read the sh man
page until you understand it, and after that you won't have
any trouble reading the other man pages.  This is in fact much
easier than learning by experience what the metacharacters do
by accidentally including them in filenames.

>How do you know? was have not yet tried man pages with examples.
>I say people do not read man pages now becuase it has no examples.
>Imagin having to spend 3 hours to figure what option and suboption
>one needs to do some typical thing with the command. Most people do 
>not have the time or the inclination to do this everytime. An example
>can quickly get them started. and Later when they get more familar,
>they can learn more and more.

I wonder if your dentist starting working on teeth that way? 

>I learn CVS first time by looking at examples. Then I went and read about
>CVS from design point of view, and the examples did help me allot as
>I was reading more about CVS.  

Cvs has about 4 commands that you need to get started if someone else
set up the repository and is pretty careful with your data even if
you mistype something.  If you type your backup command backwards
it won't be so forgiving.

>Sure. You are the only one who is smart and want to learn, and every
>one else is dumb and do not want to learn.

You really have this backwards.  Most people can learn if they take
the time.  What we are trying to point out is that acting without
understanding can be dangerous, and that is the way I see blindly
following textbook examples.  The other problem regarding examples
in man pages is that many/most of the programs are typically used in
combinations:
  find /dir -name 'wild*' -print | xargs chmod g+w
  dump 0f - /source | (cd /dest ; restore xf -)
  rsh remotehost 'cd /dir ; tar -cf -  . ' | dd obs=10k of=/dev/tape 

Which man page should contain the example and would you clutter all of
them with the quoting, grouping, piping details that are really done
by the shell?

  Les Mikesell
    [EMAIL PROTECTED]

------------------------------

From: Marc Lefranc <[EMAIL PROTECTED]>
Subject: Re: How do you dynamically pass port addresses to a device driver?
Date: 29 Jan 1999 12:49:03 +0100

Ken Sills <[EMAIL PROTECTED]> writes:

> I am writing a device driver for a CCD camera (for astronomical
> imaging).   The CCD interface card is a very simple ISA port i/o card.
> This card has 12 registers (base_address + REG_*) that I need to write
> to, but which port will be written to varies in such a way that
> hard-coding isn't useful.  How do I pass the port address to the module
> so that my write command puts data on the right address?  I'm really
> hoping that I don't have to make a device for each register, and then
> open up 12 file descriptors in my acquisition program.  Do I get around
> this by having the port address be a global variable that I set with
> ioctl before each write?  I find it worrisome that I haven't been able
> to find any information about this on the web...am I missing something
> fundamental here?

I assume the writes to the registers are for setting acquisition
parameters. The most logical design would be IMHO to have several
ioctl call, one for parameter setting, where you simply pass the
desired value of the parameter [ i.e.,
ioctl(dev,SET_ACQ_FREQ,&new_acq_freq) ]. In this way, only the driver
code has to know the address of each register relative to base
address, and this simplifies the coding of the user space program.

Reserve the use of read() and write() for the transfer of the real
data (in this case, it looks like you only need read()).

-- 
_____________________________________________________________
 Marc Lefranc, Charge de Recherche au CNRS
 Laboratoire de Physique des Lasers, Atomes, Molecules
 Bat P5, UFR de Physique
 Universite des Sciences et Technologies de Lille
 F-59655 Villeneuve d'Ascq CEDEX (FRANCE)
 e-mail: [EMAIL PROTECTED] ; FAX : +33 (0)3 20 33 70 20
_____________________________________________________________

------------------------------

From: Andreas Schwab <[EMAIL PROTECTED]>
Subject: Re: assert() change
Date: 29 Jan 1999 12:46:04 +0100

gilley <[EMAIL PROTECTED]> writes:

|> This is probably pretty stupid but...

|>     assert(i = malloc(10));   //some real work inside the assert

The argument of assert should not contain any side effects.  That's not
how it's defined to work.

-- 
Andreas Schwab                                      "And now for something
[EMAIL PROTECTED]                      completely different"
[EMAIL PROTECTED]

------------------------------

From: [EMAIL PROTECTED] (Villy Kruse)
Subject: Re: /dev/rdsk  - help
Date: 29 Jan 1999 09:17:57 +0100


Please turn OFF the HTML formatting.  It makes the message completely
unreadable.


In article <[EMAIL PROTECTED]>,
InfoXchange Customer Service  <[EMAIL PROTECTED]> wrote:
><!doctype html public "-//w3c//dtd html 4.0 transitional//en">
><html>
>We have created a CPIO disk for Interactive Unix to read into Linux.
><br>The device used was&nbsp; /dev/rdsk/fd0q18dt
><p>fd0H1440 does not read track 0 and not sure if it is a raw device.

------------------------------


** FOR YOUR REFERENCE **

The service address, to which questions about the list itself and requests
to be added to or deleted from it should be directed, is:

    Internet: [EMAIL PROTECTED]

You can send mail to the entire list (and comp.os.linux.development.system) via:

    Internet: [EMAIL PROTECTED]

Linux may be obtained via one of these FTP sites:
    ftp.funet.fi                                pub/Linux
    tsx-11.mit.edu                              pub/linux
    sunsite.unc.edu                             pub/Linux

End of Linux-Development-System Digest
******************************

Reply via email to