Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp5616297yba; Thu, 11 Apr 2019 01:54:21 -0700 (PDT) X-Google-Smtp-Source: APXvYqyoTsi6qOcmSCrNFzTeYU3z8G+oIJEkboiBeJBawN4Cvgu6SV1f9RUgpURCHACMV1ieNoW4 X-Received: by 2002:a62:b602:: with SMTP id j2mr49243495pff.68.1554972861685; Thu, 11 Apr 2019 01:54:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554972861; cv=none; d=google.com; s=arc-20160816; b=whR1qRmMaxyFNJ7TKF7kvbx4kR+m8PIbNceTFPp4bH42Wu4FhwlEI4bFdbB/w9QNGo 4AM7gdsJtDi9P1DKTmWI2v6Uz2iL6jBgudusbU8b2cBiq4sxjj51YBJVY0qrBsPdCE6h K4vEYq0zpagjy3t5oYg1yU+E4NUgg5sKtwf6/llPN+XrYj1vXO1b3KJ/SmYQMgvJNAsM Lx22/LrJds7ynexgCp2GGWEPbinsZjrthNaSE4JAhJtSYbfkuMB8DP2sIBVn/jel6lDm f+yL9OkNoiQQpSqSGH9COsF9W0t0n/3qNdu7tl55D53hrlzaWKAHk9QIX22StKAPPEtq xLOQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=VNSz6oufGMspJjJa9j2vZ0JsJxl+X7s5i0no9JtMpCQ=; b=HW7e6S3RCe50GJTQVkqZ+3Kl45i0LXeyytfWy/1h0qCzhqJem3qs2M74AIJOZGHCOH r/vQ6ID9rVzapBqF54NG6jdseFXvMLkbU18XTNzsuvafVRXk/o0naCm3gIQd1aen97Dl 4XnPtzQXXEWpEEGUepqCEB6R+3o32jlXMQ15V6ODYTBIaRW9rvkaHTKz9Mj1tT+G5/Rv eNmKD2FBOGADYI2RAeroR+fOQ/RE84CNHqTxi7VkgEWdvaQT+LJRmODtbka0Xk3/aAFW qZwXyoJN2mhdHABpELVy8hru+ri/QJMsrZ1nc8gN7Kv8aXnuiFJL2+KHUfaFMpVXEogN VkbA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=dvZz7i7W; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c12si21736199pgj.461.2019.04.11.01.54.05; Thu, 11 Apr 2019 01:54:21 -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; dkim=pass header.i=@kernel.org header.s=default header.b=dvZz7i7W; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726731AbfDKIxc (ORCPT + 99 others); Thu, 11 Apr 2019 04:53:32 -0400 Received: from mail.kernel.org ([198.145.29.99]:58904 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725793AbfDKIxc (ORCPT ); Thu, 11 Apr 2019 04:53:32 -0400 Received: from dragon (98.142.130.235.16clouds.com [98.142.130.235]) (using TLSv1.2 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 45D032184B; Thu, 11 Apr 2019 08:53:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1554972811; bh=TjmBak9eIUg4Gs4XABfTfdyrm/SsN3+af+vk1upbfAo=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=dvZz7i7WCm2Q8jFAHqcgXfH4IvBiglc+Wl+OnMq4BtnP/PV2yh11vDgYhOFHl8QBF PvyhtJP1pe+uwAo+v9fOAiaM1bc5xOtho9L3yMx62vnhplUoJlKQXOFoFQn+Kb97tL T+1gQpoc+/SaLw/ZxZTPEAyoZ+lnth/bpJ4HRkDo= Date: Thu, 11 Apr 2019 16:53:17 +0800 From: Shawn Guo To: Guenter Roeck Cc: Wim Van Sebroeck , linux-watchdog@vger.kernel.org, linux-kernel@vger.kernel.org, Jun Nie Subject: Re: [PATCH 12/22] watchdog: zx2967_wdt: Convert to use device managed functions and other improvements Message-ID: <20190411085316.GG3050@dragon> References: <1554913683-25454-1-git-send-email-linux@roeck-us.net> <1554913683-25454-13-git-send-email-linux@roeck-us.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1554913683-25454-13-git-send-email-linux@roeck-us.net> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Apr 10, 2019 at 09:27:53AM -0700, Guenter Roeck wrote: > Use device managed functions to simplify error handling, reduce > source code size, improve readability, and reduce the likelyhood of bugs. > Other improvements as listed below. > > The conversion was done automatically with coccinelle using the > following semantic patches. The semantic patches and the scripts > used to generate this commit log are available at > https://github.com/groeck/coccinelle-patches > > - Drop assignments to otherwise unused variables > - Drop empty remove function > - Use devm_add_action_or_reset() for calls to clk_disable_unprepare > - Use local variable 'struct device *dev' consistently > - Use devm_watchdog_register_driver() to register watchdog device > > Cc: Jun Nie > Cc: Shawn Guo > Signed-off-by: Guenter Roeck Acked-by: Shawn Guo