The saga continues:

I found that the file /usr/include/asm/uaccess.h doesn't exist in 2.0.x and
commented out the #include in rtai_smh.c

I found in the file that contains the directions for upgrading drivers from
2.0.x to 2.2.x the information that for a single processor the functions
spin_lock_irqsave() and spin_unlock_irqrestore() are essentially equivalent
to the old functions save_flags() and restore_flags()  and got past that
stumbling block.

I also found that I had to remove "-D__SMP__" in the makefile.  After I did
that, I could compile and insmod the driver.

Then I tried the tests in the test/ directory.  


There is a #define in the file rtai_shm.h which is used to define the
pre-processor macros rtai_kmalloc() and rtai_kfree() which uses a symbol
"__this_module" and in the corresponding position in the argument list of
the real functions rtai_kmalloc_f() and rtai_kfree_f() were arguments called
"pid".   In desperation I used a command-line define "-D__this_module=..."
with an arbitrary constant as the value (but something to which the
&operator could be applied).  This allows the make to succeed.

When I ran the tests, I got the following:
        1)  itest  terminates with a Segmentation fault
        2) ctest also terminates with a Segmentation fault


I'm not sure that for my application it's worth much more time spent on
trying to get this to work in 2.0.x unless someone knows what
"__this_module" is supposed to be and/or has already gotten the portable_shm
device to work in 2.0.x

Thanks
        Norm

> -----Original Message-----
> From: Dresner, Norman A. 
> Sent: Wednesday, September 22, 1999 9:49 AM
> To:   'Paolo Mantegazza'
> Cc:   'RTLinux'
> Subject:      RE: [rtl] a separate malloc for shared memory
> 
> I got the file and tried to compile it under RH 5.2 w/kernel 2.0.36.
> Unfortunately the following are undefined there 
>       data type       "spinlock_t"
>       constant        "SPIN_LOCK_UNLOCK"
>       functions       "spin_lock_irqsave"
>                       "spin_lock_irqrestore"
> 
> If you have any suggestions about how I can sidestep these problems, I'd
> appreciate hearing about it.
> 
> Thanks for the suggestion anyway
> 
>       Norm
> 
> > -----Original Message-----
> > From:       Paolo Mantegazza [SMTP:[EMAIL PROTECTED]]
> > Sent:       Tuesday, September 21, 1999 3:13 PM
> > To: Dresner, Norman A.
> > Subject:    Re: [rtl] a separate malloc for shared memory
> > 
> > Hi,
> > 
> > go to http://www.aero.polimi.it/projects/rtai/ and get portable_shm. If
> > the README and the test case are not enough just ask. After taking into
> > account that it is for kernels 2.2.xx, you'll find just what you need
> > without any append.
> > 
> > Ciao, Paolo.
> --- [rtl] ---
> To unsubscribe:
> echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
> echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
> ----
> For more information on Real-Time Linux see:
> http://www.rtlinux.org/~rtlinux/
--- [rtl] ---
To unsubscribe:
echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
----
For more information on Real-Time Linux see:
http://www.rtlinux.org/~rtlinux/

Reply via email to