Received: by 10.192.165.148 with SMTP id m20csp472508imm; Wed, 25 Apr 2018 02:37:41 -0700 (PDT) X-Google-Smtp-Source: AIpwx49wip15yijQryPlZslAVcfhkM3XFHS1y0Ex96nm9U33AnIDCUDu3qfr8bpHfddHh+iJYCi1 X-Received: by 10.101.100.132 with SMTP id e4mr18044893pgv.102.1524649061183; Wed, 25 Apr 2018 02:37:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524649061; cv=none; d=google.com; s=arc-20160816; b=uh4Ty2Vk6B9rnZlKFl2JGO7dtX/T2Pj04+7nV7aFdhw6kGqNA8b4N+Fd8O7/lhL1zU K1m30Vuhun2DDDo9XPrk66UymDDgxm7JHqQnq6K+QS1RIHDsVKIahEPShJkz1Gi/OLjP aC69kP9glWJaddI/ppWQ70h9nv0sp/eDyvjZENOLgRz9EmtH02WwSMxkrlXSkaTtbSCB 0Aq4l4HBF/vX+tGme+HB424U/m1caSbA5N6/X4Zvf11o5pIMQqE74SX7Kh8JhnqKnTmT FQSCUh77pFn5+6s0CiJJurNxPo/ExJKpb5rkTWEO2boeAsc65Uyyx2KuOHhKvutU4iO5 uW8g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:arc-authentication-results; bh=PdN0ABfoQ6MokbjBGG8BCpzodq47NHTGNcLv03eF5cc=; b=QEKM5bXXvVSI2XkoSLXRq+jIbZi8vAnCG31jwv92v8KmdbYtIma4Sh9brvywFg2UCp SmhIrv1gVaR3Id7EXGIfzrbrpWVKaK7punZ7lAEh0U4dJoQJbs7MQ5PlJqCNuXvfj6zo e4aQCIbeK1CVNAknVylvMaHVNryzDV+OyCNZLxk3TT9XMbwKCVPLhZj8NN5R+evxG5Ba 0jBd25mB0FnYFBvF76iYQbkJ13Spol/y0ZRQRPhITti3vkq3N8Y00mwe6+s9XCbQK11u zzvkuYqS87LZs6ozLLeSoUoimCWGj8SJyhR91d/wg6C+u5tNxAXNLZtsrfLNFTnjXfqO gpaA== 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 m12si12734149pgq.192.2018.04.25.02.37.26; Wed, 25 Apr 2018 02:37:41 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751466AbeDYJc6 (ORCPT + 99 others); Wed, 25 Apr 2018 05:32:58 -0400 Received: from mailgw02.mediatek.com ([210.61.82.184]:56217 "EHLO mailgw02.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1750986AbeDYJcx (ORCPT ); Wed, 25 Apr 2018 05:32:53 -0400 X-UUID: b7c3b6dbdc574302a85503d85586a40c-20180425 Received: from mtkcas07.mediatek.inc [(172.21.101.84)] by mailgw02.mediatek.com (envelope-from ) (mhqrelay.mediatek.com ESMTP with TLS) with ESMTP id 498124385; Wed, 25 Apr 2018 17:32:50 +0800 Received: from mtkcas08.mediatek.inc (172.21.101.126) by mtkmbs08n2.mediatek.inc (172.21.101.56) with Microsoft SMTP Server (TLS) id 15.0.1210.3; Wed, 25 Apr 2018 17:32:48 +0800 Received: from mtkswgap22.mediatek.inc (172.21.77.33) by mtkcas08.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1210.3 via Frontend Transport; Wed, 25 Apr 2018 17:32:49 +0800 From: To: , , , , , , , CC: , , , , , , Sean Wang Subject: [PATCH v2 07/17] mfd: mt6397: reuse DEFINE_RES_* helpers Date: Wed, 25 Apr 2018 17:32:33 +0800 Message-ID: X-Mailer: git-send-email 1.7.9.5 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain X-MTK: N Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Sean Wang Reuse DEFINE_RES_* helpers instead of an open-coded handling. Signed-off-by: Sean Wang --- drivers/mfd/mt6397-core.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/drivers/mfd/mt6397-core.c b/drivers/mfd/mt6397-core.c index c4ad5c3..e0012e2 100644 --- a/drivers/mfd/mt6397-core.c +++ b/drivers/mfd/mt6397-core.c @@ -43,16 +43,8 @@ static const struct resource mt6323_rtc_resources[] = { }; static const struct resource mt6397_rtc_resources[] = { - { - .start = MT6397_RTC_BASE, - .end = MT6397_RTC_BASE + MT6397_RTC_SIZE, - .flags = IORESOURCE_MEM, - }, - { - .start = MT6397_IRQ_RTC, - .end = MT6397_IRQ_RTC, - .flags = IORESOURCE_IRQ, - }, + DEFINE_RES_MEM(MT6397_RTC_BASE, MT6397_RTC_SIZE), + DEFINE_RES_IRQ(MT6397_IRQ_RTC), }; static const struct resource mt6323_keys_resources[] = { -- 2.7.4