From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754221AbcBHQUd (ORCPT ); Mon, 8 Feb 2016 11:20:33 -0500 Received: from [82.165.8.211] ([82.165.8.211]:51911 "EHLO mail.holtmann.org" rhost-flags-FAIL-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1750781AbcBHQUb convert rfc822-to-8bit (ORCPT ); Mon, 8 Feb 2016 11:20:31 -0500 Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 9.2 \(3112\)) Subject: Re: [PATCH 8/9] rfkill: Userspace control for airplane mode From: Marcel Holtmann In-Reply-To: <1454946096-9752-9-git-send-email-jprvita@endlessm.com> Date: Mon, 8 Feb 2016 11:20:24 -0500 Cc: Johannes Berg , "David S. Miller" , Darren Hart , linux-wireless , Network Development , platform-driver-x86@vger.kernel.org, linux-api@vger.kernel.org, linux-doc@vger.kernel.org, Linux Kernel Mailing List , linux@endlessm.com, =?utf-8?Q?Jo=C3=A3o_Paulo_Rechi_Vita?= Content-Transfer-Encoding: 8BIT Message-Id: References: <1454946096-9752-1-git-send-email-jprvita@endlessm.com> <1454946096-9752-9-git-send-email-jprvita@endlessm.com> To: =?utf-8?Q?Jo=C3=A3o_Paulo_Rechi_Vita?= X-Mailer: Apple Mail (2.3112) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Joa Paulo, > Provide an interface for the airplane-mode indicator be controlled from > userspace. User has to first acquire the control through > RFKILL_OP_AIRPLANE_MODE_ACQUIRE and keep the fd open for the whole time > it wants to be in control of the indicator. Closing the fd or using > RFKILL_OP_AIRPLANE_MODE_RELEASE restores the default policy. > > To change state of the indicator, the RFKILL_OP_AIRPLANE_MODE_CHANGE > operation is used, passing the value on "struct rfkill_event.soft". If > the caller has not acquired the airplane-mode control beforehand, the > operation fails. as explained in an earlier response, the concept Airplane Mode seems to be imposing policy into the kernel. Do we really want have this as a kernel exposed API. Regards Marcel