public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Deepak Saxena <dsaxena@plexity.net>
To: Robert Love <rml@ximian.com>
Cc: Andrew Morton <akpm@osdl.org>,
	linux-kernel@vger.kernel.org, zaitcev@redhat.com
Subject: Re: [patch] kernel events layer, updated
Date: Sat, 24 Jul 2004 00:58:52 -0700	[thread overview]
Message-ID: <20040724075852.GA21299@plexity.net> (raw)
In-Reply-To: <1090638679.2296.9.camel@localhost>

On Jul 23 2004, at 23:11, Robert Love was caught saying:
> @@ -59,9 +60,15 @@
>  	if (l & 0x1) {
>  		printk(KERN_EMERG "CPU%d: Temperature above threshold\n", cpu);
>  		printk(KERN_EMERG "CPU%d: Running in modulated clock mode\n",
> -				cpu);
> +			cpu);
> +		send_kevent(KMSG_POWER,
> +			"/org/kernel/devices/system/cpu/temperature", "high",
> +			"Cpu: %d\n", cpu);
>  	} else {
>  		printk(KERN_INFO "CPU%d: Temperature/speed normal\n", cpu);
> +		send_kevent(KMSG_POWER,
> +			"/org/kernel/devices/system/cpu/temperature", "normal",
> +			"Cpu: %d\n", cpu);

Robert,

What is the the specified naming scheme for objects and in the case of 
devices, why not use the sysfs path as part of the object path? For example:

	"/org/kernel/system/cpu/cpu0"

Since we have unique paths for devices in syfs, this would remove the need 
of having the anxiliary "CPU: %d" as it is embedded in the object name. 

Also, why the "/org/kernel"? Since all message from the kernel
can only come from the kernel, why do we need this as part of the object
name?  Looking at the D-BUS spec, it looks like the "org.foo" is part of the 
D-BUS/HAL/freedesktop naming scheme, but this should not be pushed into
the kernel IMHO. As you yourself mentioned in your talk today, D-BUS
is just one daemon that could use the kevents interface, so I don't
think we want to push it's naming scheme into the kernel messages.
The kernel should use an object name that is unique in the context 
of the kernel (hence my suggestion to use sysfs path, but perhaps there
is something else?) and D-BUS should generate the appropriate object 
name that it expects.  The kernel is never going to send messages for 
objects in org.freedesktop or anything !org.kernel, so we are just 
stuffing extra bytes in the message that are very specific to a given 
userland implementation.

You also mentioned some interesting usage examples of HAL/D-BUS/kevents 
in your talk. Any possibility of getting a patch with the kernel specific
changes?  I ask b/c I would like to see how you imagine this being used in 
the context of things like device add/remove and other things device driver 
writers would be dealing with it.

Tnx,
~Deepak

-- 
Deepak Saxena - dsaxena at plexity dot net - http://www.plexity.net/

"Unlike me, many of you have accepted the situation of your imprisonment and
 will die here like rotten cabbages." - Number 6

  reply	other threads:[~2004-07-24  7:58 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-07-23 17:41 [patch] kernel events layer Robert Love
2004-07-23 18:25 ` Tim Hockin
2004-07-23 18:31 ` Muli Ben-Yehuda
2004-07-23 18:35   ` Robert Love
2004-07-23 21:32 ` Dan Aloni
2004-07-24  2:47   ` Robert Love
2004-07-24  4:42     ` Keith Owens
2004-07-24  5:00       ` Robert Love
2004-07-24  8:11         ` Andrew Morton
2004-07-24  5:37           ` Robert Love
2004-07-24  6:02             ` Robert Love
2004-07-24  9:43               ` Wichert Akkerman
2004-07-24 20:21               ` James Morris
2004-07-25  2:12                 ` Robert Love
2004-07-24  6:53       ` Paul Jackson
2004-07-24 11:37       ` Bernd Petrovitsch
2004-07-24  3:02 ` Michael Clark
2004-07-24  3:14   ` Robert Love
2004-07-24  9:15     ` Michael Clark
2004-07-24 15:08     ` Deepak Saxena
2004-07-24 15:45       ` Robert Love
2004-07-24 17:33         ` Ryan Anderson
2004-07-24 17:46         ` Tim Hockin
2004-07-24 18:19           ` Robert Love
2004-07-25 18:11             ` Tim Hockin
2004-07-25 19:08               ` Robert Love
2004-07-27  5:09                 ` Daniel Stekloff
2004-07-24 17:54         ` Deepak Saxena
2004-07-24 18:13           ` Robert Love
2004-07-26 20:08             ` Rutger Nijlunsing
2004-07-26 20:10               ` Robert Love
2004-08-09 13:29     ` Pavel Machek
2004-08-09 19:47       ` Robert Love
2004-07-24  3:03 ` Andrew Morton
2004-07-24  2:14   ` Robert Love
2004-07-24  5:15     ` Chris Wedgwood
2004-07-24  5:41       ` Robert Love
2004-07-24  5:45         ` Chris Wedgwood
2004-07-24  3:11   ` [patch] kernel events layer, updated Robert Love
2004-07-24  7:58     ` Deepak Saxena [this message]
2004-07-24  8:23       ` Deepak Saxena

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=20040724075852.GA21299@plexity.net \
    --to=dsaxena@plexity.net \
    --cc=akpm@osdl.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rml@ximian.com \
    --cc=zaitcev@redhat.com \
    /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