From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751742AbdI3T5B (ORCPT ); Sat, 30 Sep 2017 15:57:01 -0400 Received: from esa1.dell-outbound.iphmx.com ([68.232.153.90]:16364 "EHLO esa1.dell-outbound.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751099AbdI3T46 (ORCPT ); Sat, 30 Sep 2017 15:56:58 -0400 From: X-LoopCount0: from 10.166.132.152 X-IronPort-AV: E=Sophos;i="5.42,459,1500958800"; d="scan'208";a="154594196" X-DLP: DLP_GlobalPCIDSS To: , CC: , , , , Subject: RE: [PATCH v3 2/8] platform/x86: dell-smbios: Introduce a WMI-ACPI interface Thread-Topic: [PATCH v3 2/8] platform/x86: dell-smbios: Introduce a WMI-ACPI interface Thread-Index: AQHTOYY/8DciPaHu7EGBHAtkFBbhBaLNWJwAgACA2IA= Date: Sat, 30 Sep 2017 19:56:56 +0000 Message-ID: <83fbdf94817c449ba858c6e57e7d5a41@ausx13mpc120.AMER.DELL.COM> References: <7b632baafbfdc6c55c4d56225c54fd441b747286.1506571188.git.mario.limonciello@dell.com> <20170930005127.GA13307@fury> <201709300915.40983@pali> In-Reply-To: <201709300915.40983@pali> 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 v8UJv7hZ012881 > -----Original Message----- > From: Pali Rohár [mailto:pali.rohar@gmail.com] > Sent: Saturday, September 30, 2017 2:16 AM > To: Darren Hart > Cc: Limonciello, Mario ; Andy Shevchenko > ; LKML ; > platform-driver-x86@vger.kernel.org; Andy Lutomirski ; > quasisec@google.com > Subject: Re: [PATCH v3 2/8] platform/x86: dell-smbios: Introduce a WMI-ACPI > interface > > On Saturday 30 September 2017 02:51:27 Darren Hart wrote: > > > +DELL SMBIOS DRIVER > > > +M: Pali Rohár > > > +M: Mario Limonciello > > > +S: Maintained > > > +F: drivers/platform/x86/dell-smbios.* > > > > Pali, do you agree with this? > > Yes, no problem. > > > > -static int __init dell_smbios_init(void) > > > +static int dell_smbios_wmi_probe(struct wmi_device *wdev) > > > +{ > > > + /* no longer need the SMI page */ > > > + free_page((unsigned long)buffer); > > > + > > > + /* WMI buffer should be 32k */ > > > + buffer = (void *)__get_free_pages(GFP_KERNEL, 3); > > > > Assuming PAGE_SIZE here (I know, this driver, this architecture, > > etc...). But, please use get_order() to determine number of pages > > from a linear size: > > > > __get_free_pages(GFP_KERNEL, get_order(32768)); > > I agree that specifying size (instead of count) explicitly lead to more > readable code. > Alright will adjust.