From patchwork Fri Oct 17 17:17:02 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Felipe Balbi X-Patchwork-Id: 38955 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-lb0-f197.google.com (mail-lb0-f197.google.com [209.85.217.197]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 80C13202DB for ; Fri, 17 Oct 2014 17:19:10 +0000 (UTC) Received: by mail-lb0-f197.google.com with SMTP id p9sf724267lbv.4 for ; Fri, 17 Oct 2014 10:19:09 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe:content-type; bh=WnfMgqy+N+MuxDgRGlSiGZ7zL67bszKxcPYaKvi/t1o=; b=iyGk7TZwCgskp8NFLmUAWfpzboLRGLizXbQe1jsSrkD+Y7/lC+PlbM8LYVDyXU+9Tg 1G7zF4EmQ81Xs0QcReelCbeSsuBR5uOblDlB7HS5/yfirr7iiobXM3SGaOdy+Cc9u/dP U1v4hUDXLtS3eQOJR/P1jRTxaaLqi9GT7zHXpvbM2FW8kRdAwj3Lji4PBNyqa7+gf8hC qpHWKCSye7FfrvbX1OXrfSLReMvNZQZd11B0o6rbZSd81gJu/agoawhxpkl5jKa39E1O i9Fj1rl4crSQAX99Kgj78iSSs0f5pUgcgsF6wrJvPWadhOsy34du683YXzXcN0jlTRDb VhVg== X-Gm-Message-State: ALoCoQmnE3761GyC3xHUXd7esU0a/Vc4fZFrF4zAtlRu4CrXutrP+yaprMpzSh6VNZXEgbCHYyK3 X-Received: by 10.194.242.36 with SMTP id wn4mr629194wjc.4.1413566349303; Fri, 17 Oct 2014 10:19:09 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.20.42 with SMTP id k10ls265881lae.66.gmail; Fri, 17 Oct 2014 10:19:09 -0700 (PDT) X-Received: by 10.112.198.73 with SMTP id ja9mr10088850lbc.19.1413566349146; Fri, 17 Oct 2014 10:19:09 -0700 (PDT) Received: from mail-la0-f50.google.com (mail-la0-f50.google.com. [209.85.215.50]) by mx.google.com with ESMTPS id yn9si3050118lbb.10.2014.10.17.10.19.09 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 17 Oct 2014 10:19:09 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.50 as permitted sender) client-ip=209.85.215.50; Received: by mail-la0-f50.google.com with SMTP id s18so1059869lam.23 for ; Fri, 17 Oct 2014 10:19:09 -0700 (PDT) X-Received: by 10.112.12.35 with SMTP id v3mr10243542lbb.80.1413566349055; Fri, 17 Oct 2014 10:19:09 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.84.229 with SMTP id c5csp268233lbz; Fri, 17 Oct 2014 10:19:08 -0700 (PDT) X-Received: by 10.68.65.78 with SMTP id v14mr9742293pbs.95.1413566335146; Fri, 17 Oct 2014 10:18:55 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id gd2si1590896pbb.180.2014.10.17.10.18.54 for ; Fri, 17 Oct 2014 10:18:55 -0700 (PDT) Received-SPF: none (google.com: linux-usb-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753734AbaJQRSc (ORCPT + 3 others); Fri, 17 Oct 2014 13:18:32 -0400 Received: from arroyo.ext.ti.com ([192.94.94.40]:56042 "EHLO arroyo.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753716AbaJQRSb (ORCPT ); Fri, 17 Oct 2014 13:18:31 -0400 Received: from dflxv15.itg.ti.com ([128.247.5.124]) by arroyo.ext.ti.com (8.13.7/8.13.7) with ESMTP id s9HHIMSG029560; Fri, 17 Oct 2014 12:18:22 -0500 Received: from DFLE72.ent.ti.com (dfle72.ent.ti.com [128.247.5.109]) by dflxv15.itg.ti.com (8.14.3/8.13.8) with ESMTP id s9HHIMdf029884; Fri, 17 Oct 2014 12:18:22 -0500 Received: from dflp32.itg.ti.com (10.64.6.15) by DFLE72.ent.ti.com (128.247.5.109) with Microsoft SMTP Server id 14.3.174.1; Fri, 17 Oct 2014 12:18:22 -0500 Received: from localhost (ileax41-snat.itg.ti.com [10.172.224.153]) by dflp32.itg.ti.com (8.14.3/8.13.8) with ESMTP id s9HHILOT031290; Fri, 17 Oct 2014 12:18:22 -0500 From: Felipe Balbi To: Linux USB Mailing List CC: Greg KH , , Paul Zimmerman , , , , , , , Felipe Balbi Subject: [PATCH 55/67] usb: musb: gadget: do not rely on 'driver' argument Date: Fri, 17 Oct 2014 12:17:02 -0500 Message-ID: <1413566234-13537-56-git-send-email-balbi@ti.com> X-Mailer: git-send-email 2.1.0.GIT In-Reply-To: <1413566234-13537-1-git-send-email-balbi@ti.com> References: <1413566234-13537-1-git-send-email-balbi@ti.com> MIME-Version: 1.0 Sender: linux-usb-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-usb@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: balbi@ti.com X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.50 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , future patches will remove the extra 'driver' argument to ->udc_stop(), in order to do that, we must make sure that our UDC does not rely on it first. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_gadget.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/musb/musb_gadget.c b/drivers/usb/musb/musb_gadget.c index 24c8c02..fdb8b31 100644 --- a/drivers/usb/musb/musb_gadget.c +++ b/drivers/usb/musb/musb_gadget.c @@ -1946,11 +1946,11 @@ static int musb_gadget_stop(struct usb_gadget *g, (void) musb_gadget_vbus_draw(&musb->g, 0); musb->xceiv->state = OTG_STATE_UNDEFINED; - stop_activity(musb, driver); + stop_activity(musb, NULL); otg_set_peripheral(musb->xceiv->otg, NULL); dev_dbg(musb->controller, "unregistering driver %s\n", - driver ? driver->function : "(removed)"); + musb->gadget_driver->function); musb->is_active = 0; musb->gadget_driver = NULL;