From: Bas Westerbaan <bas.westerbaan@gmail.com>
To: Nick Piggin <nickpiggin@yahoo.com.au>
Cc: James Courtier-Dutton <James@superbug.co.uk>,
Ahmad Reza Cheraghi <a_r_cheraghi@yahoo.com>,
linux-kernel@vger.kernel.org
Subject: Re: Why no XML in the Kernel?
Date: Sun, 2 Oct 2005 13:57:35 +0200 [thread overview]
Message-ID: <6880bed30510020457l49454b45s894ab314ba10be3f@mail.gmail.com> (raw)
In-Reply-To: <433FB863.5070009@yahoo.com.au>
Hello Nick,
In case /proc or /sys wouldn't be preffered, a simple key value
binary format would do.
First a key/value pair count. Followed by the key/value pairs, which
consist out of the value and key prefixed by their size.
Your user and kernel code could ignore keys they don't regognize.
A better way though, is negotiate what types of structures to pass.
The user space program would support all previous version of the kernel module.
Bas
On 10/2/05, Nick Piggin <nickpiggin@yahoo.com.au> wrote:
> James Courtier-Dutton wrote:
>
> > I have a requirement to pass information from the kernel to user space.
> > The information is passed fairly rarely, but over time extra parameters
> > are added. At the moment we just use a struct, but that means that the
> > kernel and the userspace app have to both keep in step. If something
> > like XML was used, we could implement new parameters in the kernel, and
> > the user space could just ignore them, until the user space is upgraded.
> > XML would initially seem a good idea for this, but are there any methods
> > currently used in the kernel that could handle these parameter changes
> > over time.
> >
> > For example, should the sysfs be used for this?
> >
> > Any comments?
> >
>
> Yes use sysfs (or procfs if the information is related to a process).
> Using ASCII text representation, and a single value per file is
> noramlly the preferred method to do this I think.
>
> Nick
>
> --
> SUSE Labs, Novell Inc.
>
>
> Send instant messages to your online friends http://au.messenger.yahoo.com
>
> -
> 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/
>
--
Bas Westerbaan
http://blog.w-nz.com/
GPG Public Keys: http://w-nz.com/keys/bas.westerbaan.asc
next prev parent reply other threads:[~2005-10-02 11:57 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-10-02 9:41 Ahmad Reza Cheraghi
2005-10-02 9:50 ` Nick Piggin
2005-10-02 11:02 ` James Courtier-Dutton
2005-10-02 10:37 ` Nick Piggin
2005-10-02 11:57 ` Bas Westerbaan [this message]
2005-10-02 11:09 ` James Bruce
2005-10-02 13:47 ` Willy Tarreau
2005-10-03 19:21 ` Bill Davidsen
2005-10-02 18:53 ` Jon Masters
2005-10-03 15:08 ` Nix
2005-10-03 15:35 ` Al Viro
2005-10-03 19:47 ` Nix
2005-10-03 19:56 ` linux-os (Dick Johnson)
2005-10-05 21:11 ` Dave Airlie
2005-10-05 21:31 ` Nix
2005-10-05 22:57 ` Dave Airlie
2005-10-05 23:07 ` Nix
2005-10-05 23:36 ` Dave Airlie
2005-10-05 22:22 ` jmerkey
2005-10-05 23:46 ` Dave Airlie
2005-10-07 22:14 ` Matan Ziv-Av
2005-10-02 21:55 ` Martin J. Bligh
2005-10-03 4:45 ` Nick Piggin
2005-10-08 1:34 Luke Kenneth Casson Leighton
2005-10-09 15:38 ` Horst von Brand
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=6880bed30510020457l49454b45s894ab314ba10be3f@mail.gmail.com \
--to=bas.westerbaan@gmail.com \
--cc=James@superbug.co.uk \
--cc=a_r_cheraghi@yahoo.com \
--cc=linux-kernel@vger.kernel.org \
--cc=nickpiggin@yahoo.com.au \
/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®