Received: by 10.223.185.116 with SMTP id b49csp1786236wrg; Sun, 11 Feb 2018 21:25:51 -0800 (PST) X-Google-Smtp-Source: AH8x224moVkx4L91FZl0hdnkv6QZKLX0EKN2DeCiWNEQKhhWcEZ699z/OuT/jdh6+oI5CZ2zCvK3 X-Received: by 10.101.86.137 with SMTP id v9mr8419064pgs.353.1518413151512; Sun, 11 Feb 2018 21:25:51 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518413151; cv=none; d=google.com; s=arc-20160816; b=0LgF52l9AX0AHbRQh4B92r9ZHd1gCkvFTLKJZZVdyUUIGVum9QYSvGvHcufHnKV4Gk PUTFvAa6mKjOvzzMFWR5dBZgleSsbSPM9hLWIlGbkJLc+nNuuMfCJSFl8/hNGne1h99O 6YIqweXUYqvJTW3bZlgkUMswsZc0fb1iYjyCcCbYj0MxX0BGgD1WdyWKyzt+hT37RrQH 2aHwj/mpQ0sSVGr4sfTnVkXC0ziifxTn/oxID9RL3KuXj+SWbgSZtwPssCTtkhq3zSkV Vz44uUkgXOID2oT8tgXFofuU1SiMuTICq31ISMoGY48XQj1nOQsN8/G5F+WJbJ3U/Q4c 2YYA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:arc-authentication-results; bh=oHJnglPGmzbRVH8U8Cx3CxbnfW2PZLO2FSMM9SDZxh4=; b=krTQljDErQoHVQYzVFPhKBuzPoF0EMDn0JVK6hVM/hTT3izgDD4va6s6QFYW2p97eJ XGnSsFZUsjGYy5YTs02Pez5JLZlfGEQpstpMtj0xxX/K/a2rbaaQeHlQj9vMrpMTe2sZ xgRVNonLKMYcagkFSEQj5WyyuqQ7fkpPE4RsqiQA1iOadr8LsUdNf1g6PPbXcukp71ki t2/RLKL/hHnhRWXV0aNDWv5cd5Gpr0wXRX/aATthSKyqh4BaeKj5PgfZGjguMLhob5ka brWkuPf+nMihT77/7uI327ilLJI2kJZc2vQgg1mY8tEYtBmxgLHjKT87SCqCEn8NL0KN O/qg== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n8-v6si336515pls.231.2018.02.11.21.25.37; Sun, 11 Feb 2018 21:25:51 -0800 (PST) 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932846AbeBLFYX (ORCPT + 99 others); Mon, 12 Feb 2018 00:24:23 -0500 Received: from g9t1613g.houston.hpe.com ([15.241.32.99]:30145 "EHLO g9t1613g.houston.hpe.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751233AbeBLFWZ (ORCPT ); Mon, 12 Feb 2018 00:22:25 -0500 Received: from g4t3427.houston.hpe.com (g4t3427.houston.hpe.com [15.241.140.73]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by g9t1613g.houston.hpe.com (Postfix) with ESMTPS id D5EBF6016C; Mon, 12 Feb 2018 05:22:24 +0000 (UTC) Received: from g9t2301.houston.hpecorp.net (g9t2301.houston.hpecorp.net [16.220.97.129]) by g4t3427.houston.hpe.com (Postfix) with ESMTP id EB71D57; Mon, 12 Feb 2018 05:22:23 +0000 (UTC) Received: from anatevka.ftc.rdlabs.hpecorp.net (anatevka.americas.hpqcorp.net [10.34.81.6]) by g9t2301.houston.hpecorp.net (Postfix) with ESMTP id 8745D4C; Mon, 12 Feb 2018 05:22:23 +0000 (UTC) From: Jerry Hoemann To: wim@linux-watchdog.org, linux@roeck-us.net Cc: linux-watchdog@vger.kernel.org, linux-kernel@vger.kernel.org, rwright@hpe.com, maurice.a.saldivar@hpe.com, Jerry Hoemann Subject: [PATCH v2 04/11] watchdog/hpwdt: white space changes Date: Sun, 11 Feb 2018 22:21:04 -0700 Message-Id: <20180212052111.12010-5-jerry.hoemann@hpe.com> X-Mailer: git-send-email 2.13.6 In-Reply-To: <20180212052111.12010-1-jerry.hoemann@hpe.com> References: <20180212052111.12010-1-jerry.hoemann@hpe.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Minor white space changes and some name clean up. Signed-off-by: Jerry Hoemann --- drivers/watchdog/hpwdt.c | 49 +++++++++++++++++++++++------------------------- 1 file changed, 23 insertions(+), 26 deletions(-) diff --git a/drivers/watchdog/hpwdt.c b/drivers/watchdog/hpwdt.c index 6f7949ef9a23..ee9a92220ece 100644 --- a/drivers/watchdog/hpwdt.c +++ b/drivers/watchdog/hpwdt.c @@ -1,11 +1,9 @@ /* * HPE WatchDog Driver - * based on * - * SoftDog 0.05: A Software Watchdog Device - * - * (c) Copyright 2015 Hewlett Packard Enterprise Development LP + * (c) Copyright 2018 Hewlett Packard Enterprise Development LP * Thomas Mingarelli + * Jerry Hoemann * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License @@ -53,7 +51,7 @@ static unsigned long __iomem *hpwdt_timer_con; static const struct pci_device_id hpwdt_devices[] = { { PCI_DEVICE(PCI_VENDOR_ID_COMPAQ, 0xB203) }, /* iLO2 */ { PCI_DEVICE(PCI_VENDOR_ID_HP, 0x3306) }, /* iLO3 */ - {0}, /* terminate list */ + {0}, /* terminate list */ }; MODULE_DEVICE_TABLE(pci, hpwdt_devices); @@ -102,7 +100,7 @@ static int hpwdt_time_left(void) return TICKS_TO_SECS(ioread16(hpwdt_timer_reg)); } -#ifdef CONFIG_HPWDT_NMI_DECODING +#ifdef CONFIG_HPWDT_NMI_DECODING /* { */ static int hpwdt_my_nmi(void) { return ioread8(hpwdt_nmistat) & 0x6; @@ -140,7 +138,7 @@ static int hpwdt_pretimeout(unsigned int ulReason, struct pt_regs *regs) return NMI_HANDLED; } -#endif /* CONFIG_HPWDT_NMI_DECODING */ +#endif /* } */ /* * /dev/watchdog handling @@ -205,11 +203,11 @@ static ssize_t hpwdt_write(struct file *file, const char __user *data, return len; } -static const struct watchdog_info ident = { - .options = WDIOF_SETTIMEOUT | - WDIOF_KEEPALIVEPING | - WDIOF_MAGICCLOSE, - .identity = "HPE iLO2+ HW Watchdog Timer", +static const struct watchdog_info hpwdt_info = { + .options = WDIOF_SETTIMEOUT | + WDIOF_KEEPALIVEPING | + WDIOF_MAGICCLOSE, + .identity = "HPE iLO2+ HW Watchdog Timer", }; static long hpwdt_ioctl(struct file *file, unsigned int cmd, @@ -223,7 +221,7 @@ static long hpwdt_ioctl(struct file *file, unsigned int cmd, switch (cmd) { case WDIOC_GETSUPPORT: ret = 0; - if (copy_to_user(argp, &ident, sizeof(ident))) + if (copy_to_user(argp, &hpwdt_info, sizeof(hpwdt_info))) ret = -EFAULT; break; @@ -320,7 +318,7 @@ static int hpwdt_init_nmi_decoding(struct pci_dev *dev) return 0; error2: - unregister_nmi_handler(NMI_SERR, "hpwdt"); + unregister_nmi_handler(NMI_SERR, "hpwdt"); error1: unregister_nmi_handler(NMI_UNKNOWN, "hpwdt"); error: @@ -334,15 +332,14 @@ static int hpwdt_init_nmi_decoding(struct pci_dev *dev) static void hpwdt_exit_nmi_decoding(void) { -#ifdef CONFIG_HPWDT_NMI_DECODING - unregister_nmi_handler(NMI_UNKNOWN, "hpwdt"); - unregister_nmi_handler(NMI_SERR, "hpwdt"); +#ifdef CONFIG_HPWDT_NMI_DECODING /* { */ + unregister_nmi_handler(NMI_UNKNOWN, "hpwdt"); + unregister_nmi_handler(NMI_SERR, "hpwdt"); unregister_nmi_handler(NMI_IO_CHECK, "hpwdt"); -#endif +#endif /* } */ } -static int hpwdt_init_one(struct pci_dev *dev, - const struct pci_device_id *ent) +static int hpwdt_probe(struct pci_dev *dev, const struct pci_device_id *ent) { int retval; @@ -429,10 +426,10 @@ static void hpwdt_exit(struct pci_dev *dev) } static struct pci_driver hpwdt_driver = { - .name = "hpwdt", - .id_table = hpwdt_devices, - .probe = hpwdt_init_one, - .remove = hpwdt_exit, + .name = "hpwdt", + .id_table = hpwdt_devices, + .probe = hpwdt_probe, + .remove = hpwdt_exit, }; MODULE_AUTHOR("Tom Mingarelli"); @@ -447,9 +444,9 @@ module_param(nowayout, bool, 0); MODULE_PARM_DESC(nowayout, "Watchdog cannot be stopped once started (default=" __MODULE_STRING(WATCHDOG_NOWAYOUT) ")"); -#ifdef CONFIG_HPWDT_NMI_DECODING +#ifdef CONFIG_HPWDT_NMI_DECODING /* { */ module_param(allow_kdump, int, 0); MODULE_PARM_DESC(allow_kdump, "Start a kernel dump after NMI occurs"); -#endif /* !CONFIG_HPWDT_NMI_DECODING */ +#endif /* } */ module_pci_driver(hpwdt_driver); -- 2.13.6