Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp7602494imu; Tue, 22 Jan 2019 08:31:53 -0800 (PST) X-Google-Smtp-Source: ALg8bN7j2fo2jgoZ0+5oxhYiHUnwixr+k4jLvS9q+RuurGovOQ6C1tHVawMrigr/XdFl2EiAj410 X-Received: by 2002:a63:960a:: with SMTP id c10mr32413869pge.106.1548174713452; Tue, 22 Jan 2019 08:31:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548174713; cv=none; d=google.com; s=arc-20160816; b=BZlLjO72TzEbrkQDUTj82KVlz4Xl/8ULTkKhUE+BMpx0v9UJZe/rIDcMgEt+nZxHWM vh2kVBptNTeerqOzKIJV0rJDjSs+7E//Mtbxr3rXSPVzobmGwNNMhMKe1qB1FGE4qBxA nlRW3aZPDWs1gMRbagEtfvWRlHxOSlwFTR8aa4+WwqvCsBwjSAdRHsbCibtoPGX16a/z eTY07omb3swpZj/zl9a6F+WC95YrK0stbPr2Aq5IUI49277KTKOJzF7nRZLMoB3M5mSm 5Qm20ZNiaTQE2Zk9LN/L7LKiWJxyT2XBR1nmUxuJZV6d/zoPUJgGHPdKfSgaHenxU+if mBiQ== 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; bh=t9n/5sXdoTPr3CpWzcc788OMKiVQhMebV1SwmFqOkDM=; b=A3lhSTc4hdDbD4bpG5y/yp14p2OH6aHBkLz/wtLrFxpLwcGRXBJ7IBr24J8WJ42L8E mMbggvt646amviwyW/0s9MLIUgkynOsmwauaUMFaZhnLzy7uodotVknly+Tu3YQiCu5U 1vvKcmegPH34cU4M/ANKF6CpGquKbhhyMPvV/z4gfctMdiH47qF8Jn2kpnHb4sc3qwkO CyD862Hy7ZOd6sJHyOdB2KIWMw2EoJcfhljbYCT+GRCsQIOgDVoEQ+bMkNSkicj3a18R cD/O2kkCmsq9W71H5m+89AuOvxqptWaWbX5hge8huY6YGCAEjxfEru+IMxBfPizw6dpS 4hKw== 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 m3si11846517pgc.232.2019.01.22.08.31.36; Tue, 22 Jan 2019 08:31:53 -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 S1729337AbfAVQ3k (ORCPT + 99 others); Tue, 22 Jan 2019 11:29:40 -0500 Received: from mail-lj1-f194.google.com ([209.85.208.194]:35375 "EHLO mail-lj1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728580AbfAVQ3k (ORCPT ); Tue, 22 Jan 2019 11:29:40 -0500 Received: by mail-lj1-f194.google.com with SMTP id x85-v6so21217997ljb.2; Tue, 22 Jan 2019 08:29:37 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=t9n/5sXdoTPr3CpWzcc788OMKiVQhMebV1SwmFqOkDM=; b=kc4ImfRHJ2aMVsf55zZP8lUCmmJ37QbdjsKPhci54UIIqIlRGs2wRGzNv8ZhlB3wI5 hM9ZIo0+HzErsWrrJ/YTQtSObY6+YEHYaC+renfJVgV2301Rw7y+coMkk+Xf504OVmDM FI1nlLzULKU/ipD3z3/oqzUMbifHQcX5IDin5WlVPEGtEvK56tsxtV8Gu2s8xIXUEUUQ IALpk/uGeHl/0XuTIMaURd02vRx+GIIQRcE3nF17RxvZNOq6LRXkuoTigclJD92bnJfd CtwnhSLEZ22YZJsUxilESOQ3XDL9daL4nBJSmDQ30+KUVx5jOyUhRTwIssclrwa9m+5w YdvA== X-Gm-Message-State: AJcUukeDof6kSjknN4fYDyk+y0kBgniHQ3V5AkbxjgWSt0SdHXXgf4xq rQ9vKRz6nTvmaGKZWG67ghg= X-Received: by 2002:a2e:914b:: with SMTP id q11-v6mr8884858ljg.164.1548174576827; Tue, 22 Jan 2019 08:29:36 -0800 (PST) Received: from localhost.localdomain (82-203-157-3.bb.dnainternet.fi. [82.203.157.3]) by smtp.gmail.com with ESMTPSA id h22-v6sm87861lji.45.2019.01.22.08.29.34 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 22 Jan 2019 08:29:36 -0800 (PST) Date: Tue, 22 Jan 2019 18:29:31 +0200 From: Matti Vaittinen To: Guenter Roeck Cc: mazziesaccount@gmail.com, lee.jones@linaro.org, robh+dt@kernel.org, mark.rutland@arm.com, lgirdwood@gmail.com, broonie@kernel.org, gregkh@linuxfoundation.org, rafael@kernel.org, mturquette@baylibre.com, sboyd@kernel.org, linus.walleij@linaro.org, bgolaszewski@baylibre.com, sre@kernel.org, a.zummo@towertech.it, alexandre.belloni@bootlin.com, wim@linux-watchdog.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org, linux-gpio@vger.kernel.org, linux-pm@vger.kernel.org, linux-rtc@vger.kernel.org, linux-watchdog@vger.kernel.org, mikko.mutanen@fi.rohmeurope.com, heikki.haikola@fi.rohmeurope.com Subject: Re: [RFC PATCH v1 11/13] rtc: bd70528: Initial support for ROHM bd70528 RTC Message-ID: <20190122162931.GB2559@localhost.localdomain> References: <390e9379-329b-02dc-13f6-763aeae703e1@roeck-us.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <390e9379-329b-02dc-13f6-763aeae703e1@roeck-us.net> User-Agent: Mutt/1.9.2 (2017-12-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jan 22, 2019 at 06:48:21AM -0800, Guenter Roeck wrote: > On 1/22/19 1:47 AM, Matti Vaittinen wrote: > > + > > +static int bd70528_set_rtc_based_timers(struct bd70528 *bd70528, int new_state, > > + int *old_state) > > Passed parameter is an int, not int *. I'd be quite surprised if this compiles > without warning. > > > +static int bd70528_re_enable_rtc_based_timers(struct bd70528 *bd70528, > > + int old_state) // snip > > + return bd70528_set_rtc_based_timers(bd70528, old_state, NULL); and > > +static int bd70528_disable_rtc_based_timers(struct bd70528 *bd70528, > > + int *old_state) // snip > > + return bd70528_set_rtc_based_timers(bd70528, 0, old_state); I'm not quite sure I understand what you mean by that. Second parameter is int, third one is is int *. > > +static int bd70528_re_enable_rtc_based_timers(struct bd70528 *bd70528, > > + int old_state) > > +{ > > + if (bd70528->rtc_timer_lock) > > + mutex_unlock(bd70528->rtc_timer_lock); > > + > Unlock before calling bd70528_set_rtc_based_timers is odd, especially since it > is called after locking below. > Yet another brainfart. Thanks for pointing this out! Will be fixed as well. Br, Matti Vaittinen -- Matti Vaittinen ROHM Semiconductors ~~~ "I don't think so," said Rene Descartes. Just then, he vanished ~~~