Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756947Ab2FGUmK (ORCPT ); Thu, 7 Jun 2012 16:42:10 -0400 Received: from iolanthe.rowland.org ([192.131.102.54]:54948 "HELO iolanthe.rowland.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1753703Ab2FGUmI (ORCPT ); Thu, 7 Jun 2012 16:42:08 -0400 Date: Thu, 7 Jun 2012 16:42:07 -0400 (EDT) From: Alan Stern X-X-Sender: stern@iolanthe.rowland.org To: Stefani Seibold cc: Greg KH , , , , Subject: Re: [PATCH 04/11] remove usb_interface pointer In-Reply-To: <1339098621.13885.13.camel@wall-e> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 688 Lines: 17 On Thu, 7 Jun 2012, Stefani Seibold wrote: > That what i am looking for. If we do an usb_get_intf() in the > skel_probe() function and an usb_put_intf() in skel_delete() function at > the end, then it should be save to access the usb_device pointer by > interface_to_usbdev() in the skel_delete() function. Right? Safe, yes, but unnecessary. Just get rid of the usb_put_dev() in skel_delete and the usb_get_dev in skel_probe. Alan Stern -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/