public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Marcel Holtmann <marcel@holtmann.org>
To: Norbert Preining <preining@logic.at>
Cc: linux-kernel@vger.kernel.org, Johannes Berg <johannes@sipsolutions.net>
Subject: Re: rfkill rework in 2.6.31-rc, hal/dbus access changes?
Date: Sat, 11 Jul 2009 11:54:33 -0700	[thread overview]
Message-ID: <1247338473.9709.107.camel@localhost.localdomain> (raw)
In-Reply-To: <20090711091427.GB14367@gamma.logic.tuwien.ac.at>

Hi Norbert,

> I have written a Gnome applet for turning off and on the various
> hardware items using the rfkill interface. It was working very well on
> up to 2.6.30. With 2.6.31-rc that infrastructure has been changed, and
> now no access mode I know of still works.
> 
> - formerly writing 0 or 1 to /sys/class/rfkill/rfkillN/state worked, now
>   it returns access denied.

actually Johannes sent a patch to fix this. It will still return an
error if the RFKILL switch is hard-blocked btw.

> - access via Hal/Dbus (what I am doing) stopped working, too

Not the first time HAL broke in this area, because its RFKILL support is
a bunch of hacked up scripts. Send a patch to the HAL mailing list.

> In the Documentation I only see reference to /dev/rfkill, which isn't a
> usefull access method because for the applet to work for every user
> (based on the permissions of hal) we need hal/dbus access.

You could just go ahead and work on fixing HAL.

> Is this intended behaviour? Is there any other documentation but the
> very short rfkill.txt in the kernel's Documentation?

Changing RFKILL soft-block via the state file got fixed, but it is still
a total broken interface. If you rely on it (directly or via HAL) your
application is useless. And if you are polling the state of the RFKILL
switches via HAL, then your application is even worse. You need to
wake-up too often to actually see RFKILL state changes.

The /dev/rfkill interface is the only way to get a proper interface with
all RFKILL switches in your system. And this includes enumeration, async
notification and changing states on a per technology basis.

Regards

Marcel



  reply	other threads:[~2009-07-11 18:54 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-07-11  9:14 rfkill rework in 2.6.31-rc, hal/dbus access changes? Norbert Preining
2009-07-11 18:54 ` Marcel Holtmann [this message]
2009-07-11 19:59   ` Norbert Preining
2009-07-11 21:12     ` Marcel Holtmann
2009-08-10 10:43       ` Norbert Preining
2009-08-10 12:22         ` Johannes Berg
2009-08-10 12:28           ` Norbert Preining
2009-08-10 12:40             ` Johannes Berg

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=1247338473.9709.107.camel@localhost.localdomain \
    --to=marcel@holtmann.org \
    --cc=johannes@sipsolutions.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=preining@logic.at \
    /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