From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757853AbcHWLGj (ORCPT ); Tue, 23 Aug 2016 07:06:39 -0400 Received: from mga07.intel.com ([134.134.136.100]:48231 "EHLO mga07.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753741AbcHWLGi (ORCPT ); Tue, 23 Aug 2016 07:06:38 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.28,565,1464678000"; d="asc'?scan'208";a="1040109375" From: Felipe Balbi To: Felipe Ferreri Tonello , John Youn , "linux-usb\@vger.kernel.org" Cc: "linux-kernel\@vger.kernel.org" , Michal Nazarewicz Subject: Re: [PATCH v4 10/10] usb: gadget: f_hid: use alloc_ep_req() In-Reply-To: <35182515-2a5b-1efa-564c-0ba38016520d@felipetonello.com> References: <20160808203013.19283-1-eu@felipetonello.com> <20160808203013.19283-11-eu@felipetonello.com> <6a4fcb3c-7c75-257d-24d5-3c7b8e0f056f@synopsys.com> <87r39hi6vm.fsf@linux.intel.com> <35182515-2a5b-1efa-564c-0ba38016520d@felipetonello.com> User-Agent: Notmuch/0.22.1+63~g994277e (https://notmuchmail.org) Emacs/25.1.1 (x86_64-pc-linux-gnu) Date: Tue, 23 Aug 2016 14:03:23 +0300 Message-ID: <87y43nhhms.fsf@linux.intel.com> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hi, Felipe Ferreri Tonello writes: >> John Youn writes: >>> On 8/8/2016 1:30 PM, Felipe F. Tonello wrote: >>>> Use gadget's framework allocation function instead of directly calling >>>> usb_ep_alloc_request(). >>>> >>>> Signed-off-by: Felipe F. Tonello >>>> --- >>>> drivers/usb/gadget/function/f_hid.c | 6 +----- >>>> 1 file changed, 1 insertion(+), 5 deletions(-) >>>> >>>> diff --git a/drivers/usb/gadget/function/f_hid.c b/drivers/usb/gadget/= function/f_hid.c >>>> index a010496e4e05..89d2e9a5a04f 100644 >>>> --- a/drivers/usb/gadget/function/f_hid.c >>>> +++ b/drivers/usb/gadget/function/f_hid.c >>>> @@ -611,14 +611,10 @@ static int hidg_bind(struct usb_configuration *c= , struct usb_function *f) >>>>=20=20 >>>> /* preallocate request and buffer */ >>>> status =3D -ENOMEM; >>>> - hidg->req =3D usb_ep_alloc_request(hidg->in_ep, GFP_KERNEL); >>>> + hidg->req =3D alloc_ep_req(hidg->in_ep, hidg->report_length); >>>> if (!hidg->req) >>>> goto fail; >>>>=20=20 >>>> - hidg->req->buf =3D kmalloc(hidg->report_length, GFP_KERNEL); >>>> - if (!hidg->req->buf) >>>> - goto fail; >>>> - >>>> /* set descriptor dynamic values */ >>>> hidg_interface_desc.bInterfaceSubClass =3D hidg->bInterfaceSubClass; >>>> hidg_interface_desc.bInterfaceProtocol =3D hidg->bInterfaceProtocol; >>>> >>> >>> Hi Felipe, >>> >>> This commit on your testing/next breaks compilation. >>> >>> ../drivers/usb/gadget/function/f_hid.c: In function =E2=80=98hidg_bind= =E2=80=99: >>> ../drivers/usb/gadget/function/f_hid.c:620:14: error: too few arguments= to function =E2=80=98alloc_ep_req=E2=80=99 >>> hidg->req =3D alloc_ep_req(hidg->in_ep, hidg->report_length); >>> ^ >>> In file included from ../drivers/usb/gadget/function/f_hid.c:24:0: >>> ../drivers/usb/gadget/u_f.h:63:21: note: declared here >>> struct usb_request *alloc_ep_req(struct usb_ep *ep, size_t len, int de= fault_len); >>=20 >> true that :-) Dropping from my queue. >>=20 > > Are you applying the previous patches? Specially that this is the last > patch in the series, how can it break with you if it doesn't break here? > What should I do then? Can you rebase your series on top of my testing/next? My HEAD is at commit 95bbb3474f1e87c9ec7ebe2acf25006e5e94a824. =2D-=20 balbi --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIcBAEBCAAGBQJXvC17AAoJEIaOsuA1yqREZCgP/iERj0L2numCHMX/KEFMeZhJ cblpVPAKdwp1xQZbBQEX6f5TJyvVGv8b1RCTu98EysGPfDlrSqwYNJrLKfQDnOn9 h6fY0KUXQhzGH2wFxsrShF6+pwoly2u83ROeZyq6p1MnAYUeoUNCx/4Psszj9fe5 YAmV22SdfYhTKIoG6ogLpJU2+VXKinaJcAmZ9JOhBxLXhh5y2h7ZCHCHmPHXjufv TrveD37LK5n7tXkRyDpg43BgOYdmwv56Y9jE08Rfj1Djl/ISJIOmDfX2DcgPV6AS 5VpADhmnjPyBFeBZ3A3cwPEzClG/4SxzEVANxJKVY25xrJA22i7bSsghY3XdgOgT zgmU2Koq26Goaw4hGeYhieHJuhj6edpoaKcuZQxQw6vyliQobkmxP6af4RELZmNU LAllyaFq5bJ6efEs9UPyqh46IrvNTWC5FoIL/CTJw4ph/zd1Tldg4qVZjuTb1OOS /Y6EwFlbeu58YzqkY5DfxxapS/QvCGh63g6cTTWyLbNefj5q0wMaYitvypWUKuyV ca/gSQa5x2vkZ+GO8YJRQuIOJxKO5z2d+MnHxyr7+StT4n5c8YB+wdFSFis9yzc3 88scvsUxNfr1aWQ9ONo2gBKlb6NdWkzILnO1As4ts0OC6cth5cs1cifP9RZrhNDx PmaSfwtw8fgVbzc3hMpH =l31i -----END PGP SIGNATURE----- --=-=-=--