From patchwork Tue Jul 16 20:47:46 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Troy Kisky X-Patchwork-Id: 259508 X-Patchwork-Delegate: marek.vasut@gmail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 7CD232C0169 for ; Wed, 17 Jul 2013 06:54:21 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 05F724A053; Tue, 16 Jul 2013 22:53:38 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id vhBQjCjEkKkF; Tue, 16 Jul 2013 22:53:37 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id E42BE4A049; Tue, 16 Jul 2013 22:53:30 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 741014A023 for ; Tue, 16 Jul 2013 22:53:12 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id bAetXnHwkVl0 for ; Tue, 16 Jul 2013 22:53:06 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 BL_NJABL=SKIP(-1.5) (only DNSBL check requested) Received: from mail-pb0-f50.google.com (mail-pb0-f50.google.com [209.85.160.50]) by theia.denx.de (Postfix) with ESMTPS id 3C2244A028 for ; Tue, 16 Jul 2013 22:53:04 +0200 (CEST) Received: by mail-pb0-f50.google.com with SMTP id wz7so1095489pbc.23 for ; Tue, 16 Jul 2013 13:53:02 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references :x-gm-message-state; bh=aBxp0TTlP/ZJgKrZALrAKzlsuWEI9DTo6J1A1hvxbCc=; b=d7c+dNi9CZkuXVgLVpA0+NbKgsVfyQHrBOF+lqDWsMcss50axKW+0kleHLDiWu9U/i RkkYKjyd6n4fw0dXWAU65Sntpm99EWW4Gm7/kboJMvmg0KUBArJe/Es+0e04QJYVU1iG 9i8C4tgK5cas3M71k3vaChILGN6cdCTbtTbKAK/ursG4aOwJ5oqqn1A5hVWM/ldnlQb9 sdSh3T0BBoMurnqjnEw8DY/qwYm7GONINeJxSf1EDyCCfFV3Ik6EMBIwQ+fkBrJD4nEA j+gG5ErZIloZYB45iiPCoRP/9ndHbs+JJwzileHIuYh5ok5KiYgnBWs2WAj9Xcj7pSJF /nPQ== X-Received: by 10.68.216.227 with SMTP id ot3mr3367470pbc.80.1374007982925; Tue, 16 Jul 2013 13:53:02 -0700 (PDT) Received: from officeserver-2 ([70.96.116.236]) by mx.google.com with ESMTPSA id pv5sm6136128pac.14.2013.07.16.13.53.01 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Tue, 16 Jul 2013 13:53:02 -0700 (PDT) Received: from tkisky by officeserver-2 with local (Exim 4.80) (envelope-from ) id 1UzCA3-0000kY-Sw; Tue, 16 Jul 2013 13:47:51 -0700 From: Troy Kisky To: marek.vasut@gmail.com Date: Tue, 16 Jul 2013 13:47:46 -0700 Message-Id: <1374007666-2749-19-git-send-email-troy.kisky@boundarydevices.com> X-Mailer: git-send-email 1.8.1.2 In-Reply-To: <1374007666-2749-1-git-send-email-troy.kisky@boundarydevices.com> References: <1374007666-2749-1-git-send-email-troy.kisky@boundarydevices.com> X-Gm-Message-State: ALoCoQmh+QLzPrM8y06X7L/wtyQ3kWfpRGKaRuuwSeI/xM6WeWEVlggY7nGv9MywDqVWwZdGmZYA Cc: u-boot@lists.denx.de Subject: [U-Boot] [PATCH RFC V1 18/18] usb: gadget: mv_udc: clear desc upon ep_disable X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de desc is set at ep_enable, so for symmetry, clear it at ep_disable. Signed-off-by: Troy Kisky --- drivers/usb/gadget/mv_udc.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/usb/gadget/mv_udc.c b/drivers/usb/gadget/mv_udc.c index 324a8d1..5d3cd74 100644 --- a/drivers/usb/gadget/mv_udc.c +++ b/drivers/usb/gadget/mv_udc.c @@ -176,6 +176,9 @@ static int mv_ep_enable(struct usb_ep *ep, static int mv_ep_disable(struct usb_ep *ep) { + struct mv_ep *mv_ep = container_of(ep, struct mv_ep, ep); + + mv_ep->desc = NULL; return 0; }