Received: by 10.213.65.68 with SMTP id h4csp1956914imn; Sun, 8 Apr 2018 15:47:03 -0700 (PDT) X-Google-Smtp-Source: AIpwx4+D7rn7Q0OiDU8jzMof7xww8XBdUL9SIKQKOWcPBJzKcz+F96fB3tRpyBl5ThTkzbWNcPen X-Received: by 2002:a17:902:3181:: with SMTP id x1-v6mr2291887plb.2.1523227623903; Sun, 08 Apr 2018 15:47:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1523227623; cv=none; d=google.com; s=arc-20160816; b=KKMDePdtCkhbPP59vE9VNAl/DK1MDoYDtAZjzBlLnhgp+gpXI4sr1iDaq5VD3r3mn9 2QgjAIPrn6h/QavdOTOmCdGEHqcbEXrLeXJiY5kF8RCZGMkmh5t5HxQP5uN2T/2wA/jh bgy5rmkeCYTp1Rz9UhbvGsW9WnmUJADTWf/uxD1jMoamMMJl6h8XzZkYEovnrLSMyLzL 5e5nmft4NUDM77hyxnuJvd7k3L3Lg5k6YMQ1blKhGemmO6Ii+aKerLZPjq7IbJw5k2My vLtKjENzueLYupdqGI7Op4qXFdptmMpropXjl3t/Qwi31iDs6HhN/R160ko4gqVSBtMf Be0A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=PrK7FhpT4rzuiAe6sZu8ZDGdoYut3Z5VpXt289UJ/J4=; b=Se44NeAtVeUVHjxl6vUv6sLFTLQUddncsFWdi12MVxTzYwiwkxsA4hwUBHGZMUHQqP Qt31B23C+ElXkYW0d8k54ZtH9TJi4BKpKXNASrEYjdH7orgPTVTkENPioOTsjP4HOaoz 23+p2JDni9m+H3073vo+8MAR7qRfRgXkHxBrkPMG9D6pgYAlyAXydqlAWdB7n4ylfS0f nFe96fXVpAveUDC80ibDmNP6APGfwpf6+UR9r8fSIsnL4iJRnRO4CJyaeZYLkfqKEJiQ 27ZnfQtrKVROjkMBIRgbUkVDZs8M9dQDftGBy3bm/uYsFMFU6AQT4huUmRZDn1/GNXUB W5hA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q10si10026947pgs.133.2018.04.08.15.46.27; Sun, 08 Apr 2018 15:47:03 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752610AbeDHV53 (ORCPT + 99 others); Sun, 8 Apr 2018 17:57:29 -0400 Received: from rnd-relay.smtp.broadcom.com ([192.19.229.170]:48510 "EHLO rnd-relay.smtp.broadcom.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752501AbeDHV52 (ORCPT ); Sun, 8 Apr 2018 17:57:28 -0400 Received: from mail-irv-17.broadcom.com (mail-irv-17.lvn.broadcom.net [10.75.224.233]) by rnd-relay.smtp.broadcom.com (Postfix) with ESMTP id 717AE30C02A; Sun, 8 Apr 2018 14:57:27 -0700 (PDT) Received: from bld-bun-01.bun.broadcom.com (bld-bun-01.bun.broadcom.com [10.176.128.83]) by mail-irv-17.broadcom.com (Postfix) with ESMTP id A5BF281EBD; Sun, 8 Apr 2018 14:57:27 -0700 (PDT) Received: by bld-bun-01.bun.broadcom.com (Postfix, from userid 25152) id 25416B0392A; Sun, 8 Apr 2018 23:57:24 +0200 (CEST) From: Arend van Spriel To: Greg Kroah-Hartman Cc: LKML , Brian Norris , Arend van Spriel Subject: [RESEND PATCH] drivers: change struct device_driver::coredump() return type to void Date: Sun, 8 Apr 2018 23:57:07 +0200 Message-Id: <1523224627-24136-1-git-send-email-aspriel@gmail.com> X-Mailer: git-send-email 1.9.1 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Upon submitting a patch for mwifiex [1] it was discussed whether this callback function could fail. To keep things simple there is no need for the error code so the driver can do the task synchronous or not without worries. Currently the device driver core already ignores the return value so changing it to void. [1] https://patchwork.kernel.org/patch/10231933/ Signed-off-by: Arend van Spriel --- Hi Greg, Here is a resend of my patch that got lost. See if it makes it this time ;-) Regards, Arend --- include/linux/device.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/include/linux/device.h b/include/linux/device.h index 0059b99..4779569 100644 --- a/include/linux/device.h +++ b/include/linux/device.h @@ -256,7 +256,9 @@ enum probe_type { * automatically. * @pm: Power management operations of the device which matched * this driver. - * @coredump: Called through sysfs to initiate a device coredump. + * @coredump: Called when sysfs entry is written to. The device driver + * is expected to call the dev_coredump API resulting in a + * uevent. * @p: Driver core's private data, no one other than the driver * core can touch this. * @@ -288,7 +290,7 @@ struct device_driver { const struct attribute_group **groups; const struct dev_pm_ops *pm; - int (*coredump) (struct device *dev); + void (*coredump) (struct device *dev); struct driver_private *p; }; -- 2.7.4