From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751671AbcHGJoK (ORCPT ); Sun, 7 Aug 2016 05:44:10 -0400 Received: from mga01.intel.com ([192.55.52.88]:7180 "EHLO mga01.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751527AbcHGJoH convert rfc822-to-8bit (ORCPT ); Sun, 7 Aug 2016 05:44:07 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.28,483,1464678000"; d="scan'208";a="1009883772" From: "Winkler, Tomas" To: Pavel Machek CC: Greg Kroah-Hartman , Ulf Hansson , "Hunter, Adrian" , "James Bottomley" , "Martin K. Petersen" , Vinayak Holikatti , Andy Lutomirski , Arve Hj?nnev?g , "Michael Ryleev" , Joao Pinto , "Christoph Hellwig" , Yaniv Gardi , "linux-kernel@vger.kernel.org" , "linux-mmc@vger.kernel.org" , "linux-scsi@vger.kernel.org" Subject: RE: [PATCH v5 4/8] char: rpmb: provide a user space interface Thread-Topic: [PATCH v5 4/8] char: rpmb: provide a user space interface Thread-Index: AQHR71UzA6wBb7OMAk2Dd+NUuhN0zKA9P4sA Date: Sun, 7 Aug 2016 09:44:03 +0000 Message-ID: <5B8DA87D05A7694D9FA63FD143655C1B542B8AC9@hasmsx108.ger.corp.intel.com> References: <1468873673-21776-1-git-send-email-tomas.winkler@intel.com> <1468873673-21776-5-git-send-email-tomas.winkler@intel.com> <20160805200823.GB7999@amd> In-Reply-To: <20160805200823.GB7999@amd> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ctpclassification: CTP_IC x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiOTY3NzBkMGItYzZkMi00M2M2LWFiNjItNmIzMzVjN2VjNzQxIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX0lDIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE1LjkuNi42IiwiVHJ1c3RlZExhYmVsSGFzaCI6InRUVGlXUk1Ed1Vzd2hhN1U1cFJMaFp3MWtyRktCRXRTcDRQSUpBZXphaUU9In0= x-originating-ip: [10.184.70.11] Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7BIT MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > > On Mon 2016-07-18 23:27:49, Tomas Winkler wrote: > > The user space API is achieved via two synchronous IOCTL. > > IOCTLs? Will fix > > Simplified one, RPMB_IOC_REQ_CMD, were read result cycles is > performed > > by the framework on behalf the user and second, RPMB_IOC_SEQ_CMD > where > > the whole RPMB sequence including RESULT_READ is supplied by the caller. > > The latter is intended for easier adjusting of the applications > > that use MMC_IOC_MULTI_CMD ioctl. > > Why " "? Not sure I there is enough clue in your question. > > > > > Signed-off-by: Tomas Winkler > > > + > > +static long rpmb_ioctl(struct file *fp, unsigned int cmd, unsigned > > +long arg) { > > + return __rpmb_ioctl(fp, cmd, (void __user *)arg); } > > + > > +#ifdef CONFIG_COMPAT > > +static long rpmb_compat_ioctl(struct file *fp, unsigned int cmd, > > + unsigned long arg) > > +{ > > + return __rpmb_ioctl(fp, cmd, compat_ptr(arg)); > > +} > > +#endif /* CONFIG_COMPAT */ > > Description of the ioctl is missing, Will add. and it should certainly be designed in a way > that it does not need compat support. The compat_ioctl handler just casts the compat_ptr, I believe this should be done unless the ioctl is globaly registered in fs/compat_ioctl.c, but I might be wrong. Tomas