Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp1673749pxu; Tue, 24 Nov 2020 06:22:15 -0800 (PST) X-Google-Smtp-Source: ABdhPJw/UodmX0VTfI4PpK66hoz4yKg8Cc4T6cSH87nGqAEQ5sM4GCcYAvvd0NY1fCRdu0+DDYYF X-Received: by 2002:a17:906:d96e:: with SMTP id rp14mr4463920ejb.214.1606227735251; Tue, 24 Nov 2020 06:22:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606227735; cv=none; d=google.com; s=arc-20160816; b=j19OHGEwn7PSUm4sSmbWpsGrYsGklAR6lq2YpZdfI1QVhx1Z0sN4ZCnG/qjfK/YGNk pdC0Kko817IvOY6MqUUe42ZwRnBVLD0P2QVSYBMVgno111eoB7xKoqPMHthmQb+EijLW BFzxW4LaKX92QdC5pVky3Ok43ataBlbVCBi1Or4YychdwNccheWpmG/x3jgvRdwdAs6P T36Q0ojdn4WevTYt7lM+aF6pB0rhlWpeuxD95w2SmxE85KJuI921o4cPaiLBFEKWXwNQ Q6I/NKUil9jtz1obN6pVgPRjsxgFbC2u6g5uY6fe+nbgtcDBMNjzZP1Lm4Vv9AO5Y3I6 FQGA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=MuEr+TN8EO6wywj7sQUs18k5/f5+dJKPqa0SaZnMOQo=; b=CPozFQv/6wf0gFclztM5BwAxVJLnMZpjthYlGz7as9DEucCRXoeOHiRax0NLnFnQ9s zudn7Vf75UKYK9UYJLzATJw4i5teF+k5hnZibP+F9gCa17MliNHp3/5v2ydjJ/XCjZXm D/r5PVzr2GSw7NO2RlkyhRXEtA8sF7FXVzLI5aMtMIMeBc3p+SwTxzxrjO7sa4zzFSaD Qyp8M4MxuojXOJ38TuYjpQBaEWN9taNPERv1YIFs+FXVvRrKAiNr8Bdy9ua4DRfRGNnx uQjvZ+wIJC0iCAIGP2otzHLQaV4dzQhSNwkbrT0q6FCNsRoJMrlprtwd3MR+/EKKWxwu jHcQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id bz2si8595440ejc.558.2020.11.24.06.21.50; Tue, 24 Nov 2020 06:22:15 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388774AbgKXOSm (ORCPT + 99 others); Tue, 24 Nov 2020 09:18:42 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41428 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388682AbgKXOSl (ORCPT ); Tue, 24 Nov 2020 09:18:41 -0500 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 09F6AC0613D6 for ; Tue, 24 Nov 2020 06:18:41 -0800 (PST) Received: from pty.hi.pengutronix.de ([2001:67c:670:100:1d::c5]) by metis.ext.pengutronix.de with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1khZ9T-00080P-1y; Tue, 24 Nov 2020 15:18:39 +0100 Received: from ukl by pty.hi.pengutronix.de with local (Exim 4.89) (envelope-from ) id 1khZ9S-0001pm-ON; Tue, 24 Nov 2020 15:18:38 +0100 From: =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= To: Thorsten Scherer , Greg Kroah-Hartman Cc: linux-kernel@vger.kernel.org, Pengutronix Kernel Team Subject: [PATCH v2 2/2] siox: Make remove callback return void Date: Tue, 24 Nov 2020 15:18:34 +0100 Message-Id: <20201124141834.3096325-3-u.kleine-koenig@pengutronix.de> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201124141834.3096325-1-u.kleine-koenig@pengutronix.de> References: <20201124141834.3096325-1-u.kleine-koenig@pengutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::c5 X-SA-Exim-Mail-From: ukl@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The driver core ignores the return value of the remove callback, so don't give siox drivers the chance to provide a value. All siox drivers only allocate devm-managed resources in .probe, so there is no .remove callback to fix. Signed-off-by: Uwe Kleine-König --- drivers/siox/siox-core.c | 5 ++--- include/linux/siox.h | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/siox/siox-core.c b/drivers/siox/siox-core.c index b56cdcb52967..1794ff0106bc 100644 --- a/drivers/siox/siox-core.c +++ b/drivers/siox/siox-core.c @@ -525,12 +525,11 @@ static int siox_remove(struct device *dev) struct siox_driver *sdriver = container_of(dev->driver, struct siox_driver, driver); struct siox_device *sdevice = to_siox_device(dev); - int ret = 0; if (sdriver->remove) - ret = sdriver->remove(sdevice); + sdriver->remove(sdevice); - return ret; + return 0; } static void siox_shutdown(struct device *dev) diff --git a/include/linux/siox.h b/include/linux/siox.h index da7225bf1877..6bfbda3f634c 100644 --- a/include/linux/siox.h +++ b/include/linux/siox.h @@ -36,7 +36,7 @@ bool siox_device_connected(struct siox_device *sdevice); struct siox_driver { int (*probe)(struct siox_device *sdevice); - int (*remove)(struct siox_device *sdevice); + void (*remove)(struct siox_device *sdevice); void (*shutdown)(struct siox_device *sdevice); /* -- 2.29.2