From: Bart Trojanowski <bart@jukie.net>
To: <antonpoon@hongkong.com>
Cc: <linux-kernel@vger.kernel.org>
Subject: Re: How can I add a function to the kernel initialization
Date: Wed, 11 Apr 2001 07:22:44 -0400 (EDT) [thread overview]
Message-ID: <Pine.LNX.4.30.0104110718010.31213-100000@localhost> (raw)
In-Reply-To: <Eq989588839292.22828@mail2.hongkong.com>
First it does not work because you do not have access to libc in the
kernel. Secondly your LCD driver is not available at the time of
start_kernel so there is no one to listen to the /dev/lcd.
The quickest hack would be to find your lcd driver and modify it to spit
out the Loading Kernel, after it initializes.
B.
On Wed, 11 Apr 2001, antonpoon@hongkong.com wrote:
> I have written a driver for a character set LCD module using parallel port. I want to display a message when the kernel is initialized.
>
> I added the following to start_kernel() in init/main.c
>
> #include <stdio.h>
>
> {
> int i;
> char line = "Loading Kernel";
> FILE *ptr;
> ptr = fopen("/dev/lcd","w");
>
> for (i=0;i<10;i++)
> {
> fprintf(ptr, "%s\n", line);
> }
> fclose(ptr);
> }
>
> Error was found, it looks like that it can not include stdio.h in the initialization.
> How can I do that?
>
> I wish to be personally CC'ed the answers/comments posted to the list in response to my posting. Thank you.
>
> Best Regards,
> Anton
>
>
>
> ---------------------------------------------
> Åwªï¨Ï¥ÎHongKong.com¶l¥ó¨t²Î
> Thank you for using hongkong.com Email system
>
> -
> 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/
>
--
WebSig: http://www.jukie.net/~bart/sig/
next prev parent reply other threads:[~2001-04-11 11:23 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-04-11 8:07 antonpoon
2001-04-11 11:22 ` Bart Trojanowski [this message]
2001-04-11 13:16 ` Padraig Brady
2001-04-15 14:20 James Simmons
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=Pine.LNX.4.30.0104110718010.31213-100000@localhost \
--to=bart@jukie.net \
--cc=antonpoon@hongkong.com \
--cc=linux-kernel@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®