All of lore.kernel.org
 help / color / mirror / Atom feed
From: 嵌入式工程师 <ericvic@163.com>
To: Xenomai@xenomai.org
Subject: [Xenomai] freescale(imx53) with xenomai patch
Date: Sat, 1 Jun 2013 16:43:51 +0800 (CST)	[thread overview]
Message-ID: <1427d68d.5288.13efee8374a.Coremail.ericvic@163.com> (raw)

I have try the kernal-3.4.6 with ipipe-core-3.4.6-arm-4.patch 
when I set three same Priority tasks I found untill the tasks stop ,the interrut founction will not run.
It same like before version kernal-2.6.35.9 with  ipipe-core-2.6.35.9-arm-4.patch


static int test_thread(void *data)
{
	//phase=ctrl_mnm1221_m();
	while(1)
	{
	if(flag)
	{
		printk("runting %lld\n",tt3);
		flag=0;
		}
	SLEEP_MILLI_SEC(50);

	}
	return 0;
}

int irq_handle_function(int irq, void *device_id)
{
	//if(phase==PH_RUNNING)
	//ctrl_mnm1221_m();
	rt_intr_disable(&amp;intr_desc);
	tt1=rt_timer_read();
	tt3=tt1-tt2;
	if(tt3&gt;300000)
	flag=1;
	tt2=tt1;
	rt_intr_enable(&amp;intr_desc);
	return RT_INTR_HANDLED;;
}


void taskOne(void*arg)
{
	int i;
	for (i=0; i &lt; 0xffff; i++)
	{	
		printk("Iam taskOneand global = %d................\n", tt3);
	}
}
void taskTwo(void*arg)
{
	int i;
	for (i=0; i &lt; 0xffff; i++)
	{	
		printk("Iam taskTwo global = %d................\n", tt3);
	}
}
void taskThree(void*arg)
{
	int i;
	for (i=0; i &lt; 0xffff; i++)
	{	
		printk("Iam taskThree global = %d................\n", tt3);
	}
}


static int __init rtex_init(void){
	irq= gpio_to_irq(MY_GPIO2_14);
	
	/*err=request_irq(irq, irq_handle_function, 0, "rtex", (void *)&amp;irq);
	if(err)
	{
		printk("regist irq failure...\n");
		return -EIO;
	}*/
	err = rt_intr_create(&amp;intr_desc,"MyIrq",irq,irq_handle_function,NULL,I_SHARED|I_EDGE);
	/* ... */
	
	rt_intr_enable(&amp;intr_desc);



	rt_task_create(&amp;t1, "task1", 0, 1, 0);
	rt_task_create(&amp;t2, "task2", 0, 1, 0);/* start the two tasks */
	rt_task_create(&amp;t3, "task2", 0, 1, 0);/* start the two tasks */
	rt_task_start(&amp;t1, &amp;taskOne, 0);
	rt_task_start(&amp;t2, &amp;taskTwo, 0);
	rt_task_start(&amp;t2, &amp;taskThree, 0);
}




 Every 500m gpio send an interrupt.
 The result like blow:
tt1=rt_timer_read();

global = 	tt3=tt1-tt2;

Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................     
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755.                            
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Iam taskTwo global = 1610612755................                                 
Irunting 502230                                                                 
root@freescale /opt$ runting 499995                                             
runting 500025                                                                  
runting 500115                                                                  
runting 500055                                                                  
runting 500025                                                                  
runting 500025                                                                  
runting 500010        
runting 500085                                                                  
runting 500010                                                                  
runting 500025                                                                  
runting 500055                                                                  
runting 500010                                                                  
runting 500055                                                                  
runting 499905                                                                  
runting 500460                                                                  
runting 500085                                                                  
runting 500070                                                                  
runting 500070                                                                  
runting 500010                                                                  
runting 500010                                                                  
runting 500085                                                                  
runting 500025                                                                  
runting 499980                                                                  
runting 500070                                                                  
runting 500040                                                                  
runting 500025                                                                  
runting 498735                                                                  
runting 500040                                                                  
runting 500025                                                                  
runting 500025                                                                  
runting 500220                                                                  
runting 499995                                                                  
runting 500010                                                                  
runting 500055                                                                  
runting 500010                                                                  
runting 500055                                                                  
runting 500025                                                                  
runting 500085                                                                  
runting 500025                                                                  
runting 500055                                                                  
runting 500025                                                                  
runting 500010                                                                  
runting 500100                                                                  
runting 500085                                                                  
runting 500010    

Then I do not know what should i do next?
在 2013-05-31 13:54:49,"嵌入式工程师" <ericvic@163.com> 写道:
>ok ,thanks,i have a try
>在 2013-05-31 13:32:14,"Gilles Chanteperdrix" <gilles.chanteperdrix@xenomai.org> 写道:
>>On 05/31/2013 03:36 AM, 嵌入式工程师 wrote:
>>
>>> The I-pipe path version is adeos-ipipe-2.6.35.9-arm-1.18-01.patch ,
>>> the kernal version is 2.6.35.9 ,i am so sorry for he details do not speak clearly
>>
>>
>>Hi,
>>
>>there is no need to send your answer three times either. GPIO irqs are
>>broken with this version of the I-pipe kernel. Please try updating to
>>the I-pipe core patch for Linux 3.4 or 3.5.
>>
>>Regards.
>>
>>-- 
>>                                                                Gilles.
>
>
>_______________________________________________
>Xenomai mailing list
>Xenomai@xenomai.org
>http://www.xenomai.org/mailman/listinfo/xenomai

             reply	other threads:[~2013-06-01  8:43 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-01  8:43 嵌入式工程师 [this message]
  -- strict thread matches above, loose matches on Subject: below --
2013-05-31  1:50 [Xenomai] freescale(imx53) with xenomai patch 嵌入式工程师
2013-05-30 15:27 嵌入式工程师
2013-05-30 18:21 ` Gilles Chanteperdrix
2013-05-31  1:34   ` 嵌入式工程师
2013-05-31  1:36     ` 嵌入式工程师
2013-05-31  5:32       ` Gilles Chanteperdrix
2013-05-31  5:54         ` 嵌入式工程师
2013-06-01  8:41           ` 嵌入式工程师
2013-06-01 10:16             ` Gilles Chanteperdrix
2013-06-03  1:36               ` 嵌入式工程师
2013-06-03  1:47                 ` 嵌入式工程师
2013-06-03  6:03                 ` Gilles Chanteperdrix
2013-06-03  6:31                   ` 嵌入式工程师
2013-06-03  8:24                   ` 嵌入式工程师
2013-06-03 11:46                     ` Gilles Chanteperdrix
2013-06-05 14:34                       ` 嵌入式工程师
2013-06-05 18:31                         ` Gilles Chanteperdrix

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=1427d68d.5288.13efee8374a.Coremail.ericvic@163.com \
    --to=ericvic@163.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.