From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <52CB23F5.6000006@xenomai.org> Date: Mon, 06 Jan 2014 22:45:25 +0100 From: Gilles Chanteperdrix MIME-Version: 1.0 References: <52C7CF1E.2050404@xenomai.org> <52C85088.7020501@xenomai.org> <52C86093.4000609@xenomai.org> <52C891C1.2090007@xenomai.org> <52C949D6.6090904@xenomai.org> <52C9B255.7030702@xenomai.org> <52CA622D.806@xenomai.org> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Subject: Re: [Xenomai] rtdm_task_init call freezes the system List-Id: Discussions about the Xenomai project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Nima Nourozi Cc: xenomai@xenomai.org On 01/06/2014 08:10 PM, Nima Nourozi wrote: > Here is the task initialization code: > > *rtdm_printk("kicking of tasklet...\n");* > * retval = rtdm_task_init(&heartbeat_task, "spi_transfer", > xx_start_transfer, NULL, 99, 100000000 /* 100 ms */);* > * __ipipe_serial_debug("*******return value = %d\n", retval);* > * if(retval)* > * {* > * __ipipe_serial_debug("error initializing task: %i\n", retval);* > * }* > > Here is the task function: > > void xx_start_transfer(void *arg) > { > > int ret; > > while (1) { > ret = rtdm_task_wait_period(); > __ipipe_serial_debug("*******return value = %d\n", ret); > gpio_set_value(LED, 1); > rtdm_task_sleep(0); > } > } I can not reproduce your problem, it works fine here. Could you post the full code of a simplified driver which triggers the problem ? -- Gilles.