From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932739AbdKDLYV (ORCPT ); Sat, 4 Nov 2017 07:24:21 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:39158 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756626AbdKDLYT (ORCPT ); Sat, 4 Nov 2017 07:24:19 -0400 Date: Sat, 4 Nov 2017 12:24:31 +0100 From: Greg Kroah-Hartman To: Andrey Smirnov Cc: linux-kernel@vger.kernel.org, linux-serial@vger.kernel.org, Rob Herring , cphealy@gmail.com, Guenter Roeck , Lucas Stach , Nikita Yushchenko , Lee Jones , Pavel Machek , Andy Shevchenko , Johan Hovold , Sebastian Reichel Subject: Re: [PATCH v10 1/5] serdev: Make .remove in struct serdev_device_driver optional Message-ID: <20171104112431.GA24583@kroah.com> References: <20171031163656.24552-1-andrew.smirnov@gmail.com> <20171031163656.24552-2-andrew.smirnov@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20171031163656.24552-2-andrew.smirnov@gmail.com> User-Agent: Mutt/1.9.1 (2017-09-22) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Oct 31, 2017 at 09:36:52AM -0700, Andrey Smirnov wrote: > Using devres infrastructure it is possible to write a serdev driver > that doesn't have any code that needs to be called as a part of > .remove. Add code to make .remove optional. What about manual unbind from userspace through sysfs? You need to have a remove function. All drivers need that, to not have it is pretty lazy :) thanks, greg k-h