From: Jerome Poncin <JPoncin@hilscher.com>
To: "xenomai@xenomai.org" <xenomai@xenomai.org>
Subject: Re: [Xenomai] Hilscher driver for cifX boards
Date: Tue, 12 Mar 2013 10:10:08 +0100 [thread overview]
Message-ID: <513EF0F0.4070705@hilscher.com> (raw)
In-Reply-To: <5139D7F5.2090904@xenomai.org>
Le 08/03/2013 13:22, Gilles Chanteperdrix a écrit :
> On 03/08/2013 11:17 AM, Jerome Poncin wrote:
>
>> Le 07/03/2013 16:33, Jerome Poncin a écrit :
>>> Le 06/03/2013 22:05, Gilles Chanteperdrix a écrit :
>>>> On 03/06/2013 04:28 PM, Jan Kiszka wrote:
>>>>
>>>>> Also here: Do not misuse write(), define an IOCTL that contains
>>>>> something like "MMAP" and another one with MUNMAP in its name - that's
>>>>> the purpose of this service, no?
>>>> A lot of drivers probably have to reinvent a way to pass all the
>>>> parameters for an mmap, why not adding an "mmap" method to RTDM drivers?
>>>>
>>>>
>>> Hello,
>>>
>>> I re factored my code with all your remarks (I think and I hope).
>>>
>>> Could you say me if it's correct now ?
>>>
>>> Jan, you're right, It's possible to use Xenomai with UIO driver, but I
>>> would like to use more real time possibilities of Xenomai in future
>>> (like IRQ).
>>> My first goal is to have a code compliant.
>>> I added IRQ, and my next step will be to understand why the kernel
>>> crash after IRQ registration.
>>>
>>> Thank you for your help,
>>>
>>> Jerome
>>>
>>>
>>>
>> Hello,
>>
>> I have good news because, I arrived to validated driver with IRQ
>> support. I changed position of cifx on my motherboard in my PC and the
>> IRQ affected is not shared ;-) !
>>
>> I have now a question about IRQ. What is the good method to signal to
>> user-land that there is an IRQ. Is there an example ?
>
> Almost every "read" call is an example... ;-)
>
Hello,
I'm finishing my driver with IRQ. I saw that there is two mode, Real
time and Non real time for RTDM driver function.
My driver should run in the two mode. When I compile my User Space
Shared library that call Xenomai Kernel driver,
I saw that library call every time Non real time function and no real
time function...
I use a shared library with posix skin with makefile in attached file. I
read explanation for static library with posix skin :
http://www.xenomai.org/index.php/Porting_POSIX_applications_to_Xenomai
What must I do with shared library for using rt mode ?
Jerome
-------------- next part --------------
# ------------------------------------------------------------------------------
# line below should not be changed
# ------------------------------------------------------------------------------
### Default Xenomai installation path
XENO ?= /usr/xenomai
XENOCONFIG=$(shell PATH=$(XENO):$(XENO)/bin:$(PATH) which xeno-config 2>/dev/null)
### Sanity check
ifeq ($(XENOCONFIG),)
all::
@echo ">>> Invoke make like this: \"make XENO=/path/to/xeno-config\" <<<"
@echo
endif
CC=$(shell $(XENOCONFIG) --cc)
CFLAGS=-DCONSUMER $(shell $(XENOCONFIG) --skin=posix --cflags) $(MY_CFLAGS)
LDFLAGS=$(MY_LDFLAGS)
LDLIBS=$(shell $(XENOCONFIG) --skin=posix --ldflags)
# This includes the library path of given Xenomai into the binary to make live
# easier for beginners if Xenomai's libs are not in any default search path.
LDFLAGS+=-Xlinker -rpath -Xlinker $(shell $(XENOCONFIG) --libdir)
KSRC ?= /usr/xenomai/include
LSRC ?= ./
TKSRC ?= ./Toolkit
INCLUDE := -I$(KSRC)/include/xenomai -I$(KSRC)/include/xenomai/compat -I$(KSRC)/include/xenomai/posix -I$(LSRC) -I$(LSRC)/Toolkit
EXTRA_CFLAGS := -Wall -fpic -O2 # -DVERBOSE
EXTRA_LDFLAGS := -L/usr/xenomai/lib -shared
all:
$(CC) $(CFLAGS) $(INCLUDE) $(EXTRA_CFLAGS) -c $(TKSRC)/cifXDownload.c
$(CC) $(CFLAGS) $(INCLUDE) $(EXTRA_CFLAGS) -c $(TKSRC)/cifXEndianess.c
$(CC) $(CFLAGS) $(INCLUDE) $(EXTRA_CFLAGS) -c $(TKSRC)/cifXFunctions.c
$(CC) $(CFLAGS) $(INCLUDE) $(EXTRA_CFLAGS) -c $(TKSRC)/cifXHWFunctions.c
$(CC) $(CFLAGS) $(INCLUDE) $(EXTRA_CFLAGS) -c $(TKSRC)/cifXInit.c
$(CC) $(CFLAGS) $(INCLUDE) $(EXTRA_CFLAGS) -c $(TKSRC)/cifXInterrupt.c
$(CC) $(CFLAGS) $(INCLUDE) $(EXTRA_CFLAGS) -c $(TKSRC)/md5.c
$(CC) $(CFLAGS) $(INCLUDE) $(EXTRA_CFLAGS) -c $(LSRC)/cifx_xenomai.c
$(CC) $(CFLAGS) $(INCLUDE) $(EXTRA_CFLAGS) -c $(LSRC)/OS_xenomai.c
$(CC) $(CFLAGS) $(INCLUDE) $(EXTRA_CFLAGS) -c $(LSRC)/USER_xenomai.c
$(CC) $(CFLAGS) $(INCLUDE) $(EXTRA_LDFLAGS) -o libcifx.so $(LSRC)/cifXDownload.o $(LSRC)/cifXEndianess.o $(LSRC)/cifXFunctions.o $(LSRC)/cifXHWFunctions.o $(LSRC)/cifXInit.o $(LSRC)/cifXInterrupt.o $(LSRC)/md5.o $(LSRC)/cifx_xenomai.o $(LSRC)/OS_xenomai.o $(LSRC)/USER_xenomai.o $(EXTRA_LDFLAGS)
clean:
rm -f *.o *.so
next prev parent reply other threads:[~2013-03-12 9:10 UTC|newest]
Thread overview: 57+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-02-26 9:29 [Xenomai] Hilscher driver for cifX boards Jerome Poncin
2013-02-26 11:37 ` Jan Kiszka
2013-02-26 14:25 ` Jerome Poncin
2013-02-26 14:28 ` Jan Kiszka
2013-02-28 8:15 ` Jerome Poncin
2013-02-28 11:31 ` Jan Kiszka
2013-02-28 12:08 ` Jerome Poncin
2013-03-01 13:56 ` Jerome Poncin
2013-03-01 17:02 ` Jan Kiszka
2013-03-01 20:06 ` Gilles Chanteperdrix
2013-03-04 9:13 ` Jerome Poncin
2013-03-04 21:08 ` Gilles Chanteperdrix
2013-03-05 10:45 ` Jerome Poncin
2013-03-05 11:26 ` Jan Kiszka
2013-03-05 12:21 ` Gilles Chanteperdrix
2013-03-05 12:30 ` Gilles Chanteperdrix
2013-03-05 15:42 ` Jerome Poncin
2013-03-05 19:41 ` Gilles Chanteperdrix
2013-03-06 8:10 ` Jerome Poncin
2013-03-06 8:19 ` Gilles Chanteperdrix
2013-03-06 8:55 ` Jerome Poncin
2013-03-06 10:33 ` Jerome Poncin
2013-03-06 12:04 ` Gilles Chanteperdrix
2013-03-06 13:58 ` Jerome Poncin
2013-03-06 15:28 ` Jan Kiszka
2013-03-06 21:05 ` Gilles Chanteperdrix
2013-03-07 15:33 ` Jerome Poncin
2013-03-08 10:17 ` Jerome Poncin
2013-03-08 12:22 ` Gilles Chanteperdrix
2013-03-12 9:10 ` Jerome Poncin [this message]
2013-03-12 12:21 ` Gilles Chanteperdrix
2013-03-12 15:27 ` Jerome Poncin
2013-03-12 19:38 ` Gilles Chanteperdrix
2013-03-13 11:08 ` Jerome Poncin
2013-03-15 9:09 ` Jerome Poncin
2013-03-15 11:07 ` Jan Kiszka
2013-03-15 13:04 ` Jerome Poncin
2013-03-15 13:24 ` Jan Kiszka
2013-03-18 10:02 ` Jerome Poncin
2013-03-19 13:42 ` Jerome Poncin
2013-03-06 20:42 ` Gilles Chanteperdrix
-- strict thread matches above, loose matches on Subject: below --
2013-02-12 11:37 Stéphane LOS
2013-02-12 11:51 ` Jan Kiszka
2013-02-13 14:09 ` Stéphane LOS
2013-02-14 13:36 ` Stéphane LOS
2013-02-14 15:01 ` Stéphane LOS
2013-02-15 14:54 ` Jan Kiszka
2013-02-18 11:43 ` Stéphane LOS
2013-02-07 14:53 Stéphane LOS
2013-02-07 16:11 ` Gilles Chanteperdrix
2013-02-08 9:07 ` Stéphane LOS
2013-02-08 9:18 ` Gilles Chanteperdrix
2013-02-08 11:28 ` Jan Kiszka
2013-02-08 11:35 ` Gilles Chanteperdrix
2013-02-08 11:46 ` Jan Kiszka
[not found] ` <5114FD7B.20902@hilscher.com>
2013-02-08 13:40 ` Jan Kiszka
2013-02-08 14:33 ` Stéphane LOS
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=513EF0F0.4070705@hilscher.com \
--to=jponcin@hilscher.com \
--cc=xenomai@xenomai.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.