<div dir="ltr"><div>Use pr_info() or pr_err() for getting it printed definitely as suggested. The caveat with pr_debug() is that, messages will only be printed in case you have dynamic debug control for that file enabled.(same goes with printk(KERN_DEBUG ).<br><br></div><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Nov 23, 2014 at 6:49 PM, karthik nayak <span dir="ltr"><<a href="mailto:karthik.188@gmail.com" target="_blank">karthik.188@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello,<br>Use the new macros such as pr_info(), pr_debug() and so on. <div class="HOEnZb"><div class="h5"><br><br><div class="gmail_quote">On Sun Nov 23 2014 at 2:04:27 PM Philipp Muhoray <<a href="mailto:philipp.muhoray@gmail.com" target="_blank">philipp.muhoray@gmail.com</a>> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
Am 2014-11-23 um 06:58 schrieb Mayank:<br>
> Hi,<br>
> I am trying to print something to the kernel debug log level using<br>
> printk, but while using dmesg i am not getting the output on the<br>
> console. My /proc/sys/kernel/printk setting is 4 4 1 7.<br>
> Please help<br>
><br>
> Thanks,<br>
> Mayank<br>
><br>
><br>
> ______________________________<u></u>_________________<br>
> Kernelnewbies mailing list<br>
> <a href="mailto:Kernelnewbies@kernelnewbies.org" target="_blank">Kernelnewbies@kernelnewbies.<u></u>org</a><br>
> <a href="http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies" target="_blank">http://lists.kernelnewbies.<u></u>org/mailman/listinfo/<u></u>kernelnewbies</a><br>
<br>
Hello,<br>
<br>
Does your string end with the newline character '\n'? Otherwise your<br>
output will not be flushed immediately (it remains in the buffer). So try<br>
<br>
printk(KERN_DEBUG "Hello World!\n");<br>
<br>
Maybe that helps.<br>
<br>
br,<br>
phil<br>
<br>
______________________________<u></u>_________________<br>
Kernelnewbies mailing list<br>
<a href="mailto:Kernelnewbies@kernelnewbies.org" target="_blank">Kernelnewbies@kernelnewbies.<u></u>org</a><br>
<a href="http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies" target="_blank">http://lists.kernelnewbies.<u></u>org/mailman/listinfo/<u></u>kernelnewbies</a><br>
</blockquote></div>
</div></div><br>_______________________________________________<br>
Kernelnewbies mailing list<br>
<a href="mailto:Kernelnewbies@kernelnewbies.org">Kernelnewbies@kernelnewbies.org</a><br>
<a href="http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies" target="_blank">http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature"><a href="http://vigneshradhakrishnan.blogspot.com/" target="_blank">http://vigneshradhakrishnan.blogspot.com/</a><br></div>
</div>