Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Linux: Kernel

I would implement 'ksh' like this if there weren't any ksh before

 

 

Linux kernel RSS feed   Index | Next | Previous | View Threaded


dancer at netfort

Jan 6, 2006, 8:55 PM

Post #1 of 2 (339 views)
Permalink
I would implement 'ksh' like this if there weren't any ksh before

Hi,

Over the winter holidays I've implemented a 'ksh' that should have
been implemeted this way if we didn't have anything named under the
name of ksh and implemented today.

An example session will look like this:

$ gcc realksh.c -I /usr/include/readline -Wall -O2 -o realksh
# ./realksh
REAL ksh: printk("Hello world\n");
Building modules, stage 2.
KMSG: <4>Hello world
REAL ksh: printk("Hello world %li\n", jiffies);
Building modules, stage 2.
KMSG: <4>Hello world 4302979318



For each line entered, it will generate a C source-code, and create a
module, and run insmod/rmmod. For convenience, /proc/kmsg is monitored
for your printk pleasure.

If noone realized this, this is on the 'this is a joke' category, but
available as part of binfmtc[1] package, which provides mostly useless
plethora of binfmt-misc related tools.

[1] http://www.netfort.gr.jp/~dancer/software/binfmtc.html.en


regards,
junichi
Attachments: realksh.c (7.68 KB)


greg at kroah

Jan 10, 2006, 10:22 PM

Post #2 of 2 (291 views)
Permalink
Re: I would implement 'ksh' like this if there weren't any ksh before [In reply to]

On Sat, Jan 07, 2006 at 01:55:05PM +0900, Junichi Uekawa wrote:
>
> If noone realized this, this is on the 'this is a joke' category, but
> available as part of binfmtc[1] package, which provides mostly useless
> plethora of binfmt-misc related tools.
>
> [1] http://www.netfort.gr.jp/~dancer/software/binfmtc.html.en

Yeah, it might be a joke, but a nice one to keep in the toolbox for when
it's impossible to get systemtap up and working due to libelf issues :)

Nice hack, I like it...

greg k-h
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo [at] vger
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

Linux kernel RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.