From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S965373AbdIYRq6 (ORCPT ); Mon, 25 Sep 2017 13:46:58 -0400 Received: from esa6.dell-outbound.iphmx.com ([68.232.149.229]:50485 "EHLO esa6.dell-outbound.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S965358AbdIYRq4 (ORCPT ); Mon, 25 Sep 2017 13:46:56 -0400 From: X-LoopCount0: from 10.166.132.195 X-IronPort-AV: E=Sophos;i="5.42,437,1500958800"; d="scan'208";a="554226506" X-DLP: DLP_GlobalPCIDSS To: , CC: , , , Subject: RE: [PATCH 11/12] platform/x86: dell-wmi-smbios: introduce character device for userspace Thread-Topic: [PATCH 11/12] platform/x86: dell-wmi-smbios: introduce character device for userspace Thread-Index: AQHTNhvQPYsUn06kcU6rwOi4n36OV6LGJoCA//+1hZA= Date: Mon, 25 Sep 2017 17:46:54 +0000 Message-ID: <23b3029bac144f17bd3a68a13cfe9cf4@ausx13mpc120.AMER.DELL.COM> References: <20170925163150.GM22190@pali> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-exchange-transport-fromentityheader: Hosted x-originating-ip: [10.143.18.86] Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by nfs id v8PHmHRG025919 > -----Original Message----- > From: Andy Shevchenko [mailto:andy.shevchenko@gmail.com] > Sent: Monday, September 25, 2017 12:58 PM > To: Pali Rohár > Cc: Limonciello, Mario ; dvhart@infradead.org; > LKML ; Platform Driver x86@vger.kernel.org>; quasisec@google.com > Subject: Re: [PATCH 11/12] platform/x86: dell-wmi-smbios: introduce character > device for userspace > > On Mon, Sep 25, 2017 at 7:31 PM, Pali Rohár wrote: > > On Thursday 21 September 2017 08:57:16 Mario Limonciello wrote: > >> This userspace character device will be used to perform SMBIOS calls > >> from any applications sending a properly formatted 4k calling interface > >> buffer. > >> > >> This character device is intended to deprecate the dcdbas kernel module > >> and the interface that it provides to userspace. > >> > >> It's important for the driver to provide a R/W ioctl to ensure that > >> two competing userspace processes don't race to provide or read each > >> others data. > > >> +What: /dev/wmi-dell-wmi-smbios > > > > What about just /dev/dell-smbios? IOCTL provided here is just SMBIOS > > related and I think userspace does not have to care if it is via WMI or > > direct SMM mode... Important is that it provides character device for > > SMBIOS API and not how it is implemented. > > > > Anyway, Darren, Andy, do we have some convention for naming platform > > character devices? > > For me, looking to this case, seems better to expose a folder like > /dev/smbios/ > with actual vendor device nodes inside like > /dev/smbios/dell I disagree with this. Dell exposes smbios calling in this kernel interface but other vendor drivers may also expose different methods for character devices that are not SMBIOS. I'm envisioning that this is just the first kernel module that will use a WMI character device to userspace. That's why I wanted to use a generic namespace. I would say it could be /dev/wmi-$GUID or /dev/wmi/$driver-$GUID if you want something more generic. As long as it's discovereable from uevent that's fine to me. > > Darren? > > P.S. Interestingly I wasn't in Cc list for this series at all. Sorry, my mistake in gitconfig. I'll add you in next version submission.