All of lore.kernel.org
 help / color / mirror / Atom feed
* Real time
@ 2004-07-01  8:22 michael trimarchi
  2004-07-01 10:57 ` Richard B. Johnson
  0 siblings, 1 reply; 4+ messages in thread
From: michael trimarchi @ 2004-07-01  8:22 UTC (permalink / raw)
  To: Linux Kernel Mailing List

Hi,
I'm working on porting modular real time scheduler on linux layer ... 
I'm using only kernel thread... Actually I dont't call the 
kernel_thread(init, .... and I inizialize my scheduler and OS struct... 
I schedule my kernel thread... I'm trying to use the printk in the 
kernel_thread but sometimes I dont't having result on the console. The 
console does't print my debug on screen... Is there an unburred printk?

Best regards
Michael Trimarchi



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Real time
  2004-07-01  8:22 Real time michael trimarchi
@ 2004-07-01 10:57 ` Richard B. Johnson
  2004-07-01 13:43   ` michael trimarchi
  2004-07-07 10:00   ` michael trimarchi
  0 siblings, 2 replies; 4+ messages in thread
From: Richard B. Johnson @ 2004-07-01 10:57 UTC (permalink / raw)
  To: michael trimarchi; +Cc: Linux Kernel Mailing List

On Thu, 1 Jul 2004, michael trimarchi wrote:

> Hi,
> I'm working on porting modular real time scheduler on linux layer ...
> I'm using only kernel thread... Actually I dont't call the
> kernel_thread(init, .... and I inizialize my scheduler and OS struct...
> I schedule my kernel thread... I'm trying to use the printk in the
> kernel_thread but sometimes I dont't having result on the console. The
> console does't print my debug on screen... Is there an unburred printk?
>
> Best regards
> Michael Trimarchi
>

You probably need to set up your kernel thread correctly. You should
use:
	kernel_thread(your_thread, NULL, CLONE_FS|CLONE_FILES);

your_thread(void *whatever)
{
    exit_files(current);
    daemonize();
    /.../ fix up signals, etc.
}

Without CLONE_FILES, the file-descriptors and handles ultimately
used for printk() may not work.

Cheers,
Dick Johnson
Penguin : Linux version 2.4.26 on an i686 machine (5570.56 BogoMips).
            Note 96.31% of all statistics are fiction.



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Real time
  2004-07-01 10:57 ` Richard B. Johnson
@ 2004-07-01 13:43   ` michael trimarchi
  2004-07-07 10:00   ` michael trimarchi
  1 sibling, 0 replies; 4+ messages in thread
From: michael trimarchi @ 2004-07-01 13:43 UTC (permalink / raw)
  To: linux Kernel Mailing List

Richard B. Johnson wrote:

>On Thu, 1 Jul 2004, michael trimarchi wrote:
>
>  
>
>>Hi,
>>I'm working on porting modular real time scheduler on linux layer ...
>>I'm using only kernel thread... Actually I dont't call the
>>kernel_thread(init, .... and I inizialize my scheduler and OS struct...
>>I schedule my kernel thread... I'm trying to use the printk in the
>>kernel_thread but sometimes I dont't having result on the console. The
>>console does't print my debug on screen... Is there an unburred printk?
>>
>>Best regards
>>Michael Trimarchi
>>
>>    
>>
>
>You probably need to set up your kernel thread correctly. You should
>use:
>	kernel_thread(your_thread, NULL, CLONE_FS|CLONE_FILES);
>
>your_thread(void *whatever)
>{
>    exit_files(current);
>    daemonize();
>    /.../ fix up signals, etc.
>}
>
>Without CLONE_FILES, the file-descriptors and handles ultimately
>used for printk() may not work.
>
>Cheers,
>Dick Johnson
>Penguin : Linux version 2.4.26 on an i686 machine (5570.56 BogoMips).
>            Note 96.31% of all statistics are fiction.
>
>
>-
>To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
>the body of a message to majordomo@vger.kernel.org
>More majordomo info at  http://vger.kernel.org/majordomo-info.html
>Please read the FAQ at  http://www.tux.org/lkml/
>
>  
>
I use CLONE_KERNEL but in my body I dont't call exit_files and
demonize... I change the linux scheduler width my scheduler and I use
only the switch_to  for context_switch from a task to another... I have
a task descriptor with a pointer to the task_t * ... At this time I have
a linux task_t struct and my personal task struct...

Best regards
Michael




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Real time
  2004-07-01 10:57 ` Richard B. Johnson
  2004-07-01 13:43   ` michael trimarchi
@ 2004-07-07 10:00   ` michael trimarchi
  1 sibling, 0 replies; 4+ messages in thread
From: michael trimarchi @ 2004-07-07 10:00 UTC (permalink / raw)
  To: root; +Cc: Linux Kernel Mailing List

Richard B. Johnson wrote:

>On Thu, 1 Jul 2004, michael trimarchi wrote:
>
>  
>
>>Hi,
>>I'm working on porting modular real time scheduler on linux layer ...
>>I'm using only kernel thread... Actually I dont't call the
>>kernel_thread(init, .... and I inizialize my scheduler and OS struct...
>>I schedule my kernel thread... I'm trying to use the printk in the
>>kernel_thread but sometimes I dont't having result on the console. The
>>console does't print my debug on screen... Is there an unburred printk?
>>
>>Best regards
>>Michael Trimarchi
>>
>>    
>>
>
>You probably need to set up your kernel thread correctly. You should
>use:
>	kernel_thread(your_thread, NULL, CLONE_FS|CLONE_FILES);
>
>your_thread(void *whatever)
>{
>    exit_files(current);
>    daemonize();
>    /.../ fix up signals, etc.
>}
>
>Without CLONE_FILES, the file-descriptors and handles ultimately
>used for printk() may not work.
>
>Cheers,
>Dick Johnson
>Penguin : Linux version 2.4.26 on an i686 machine (5570.56 BogoMips).
>            Note 96.31% of all statistics are fiction.
>
>
>-
>To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
>the body of a message to majordomo@vger.kernel.org
>More majordomo info at  http://vger.kernel.org/majordomo-info.html
>Please read the FAQ at  http://www.tux.org/lkml/
>
>  
>
Thank's,
now I schedule kernel thread width edf, rr, and other...
Best regards
Michael Trimarchi



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2004-07-07  9:57 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-07-01  8:22 Real time michael trimarchi
2004-07-01 10:57 ` Richard B. Johnson
2004-07-01 13:43   ` michael trimarchi
2004-07-07 10:00   ` michael trimarchi

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.