Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp12375628ybl; Sat, 28 Dec 2019 10:56:01 -0800 (PST) X-Google-Smtp-Source: APXvYqylbqFthT9MF5XlPaIbexjrUFQy+CFxQfRvaGq6csh4pIQ5QkndrLwIF+//JXTOanGOOnNb X-Received: by 2002:a9d:dc1:: with SMTP id 59mr64591578ots.250.1577559361523; Sat, 28 Dec 2019 10:56:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1577559361; cv=none; d=google.com; s=arc-20160816; b=Kz7A4z/aBiHTkXG3JJMB8CY1gLDEfxEt+4OZvx10DzafUxFSh8muHoIB0YuizejEXj C5TA79Z2vLBC/lbTFjVoOXRu+TcEyVIpR+iZRWKUgkqhh/ytD6REQC+/lZhynrsUTk2M sXQ67QEUNDJjaQjkj34evHOjsiEKPjCVV2niGs9QNAVdCZ0L/l8QrNhFyckFk5X0b0OT E4XuZnwYaBRnTpQyrxJt/VrpVC/mA5NYpctnAI4v2bY7UVpEm5ZYO1BLcY31xoVoIZhh bdkat0QYjErh3u3xUc/3kMHpYFdU7gfSA3t/tluQ9phdaJjNaWn9fzM44pCvgNJK9IJf hcaw== 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:dkim-signature; bh=UMpegDdh42rzwNWi4a8X/3LZzmdLDgDCJkziq2QANl8=; b=uDDXx93i8FHnsiIiSeeb7/5glHzXd4LKWpmT2Q69cBIuWqfMblRgksr12XJ2b6JYg6 2AboSNBocs5EVaPKC/XOBi7dlZTQkngDP1/R/+lyxuDYMkuiXFLAGYy3llsqG6f+opUQ 3RtiLaP8fyY6EfcQmwVZApzsZGnKcBWtcqVRoeVkWg5u+gvVXd/UJO20oId2K4spkTYy XrXw2bjcn5b5TbGg6VmPbcaqzpqKuKCQCsrSb6dW/4qhxl89d3XxIiVF2BxgBzElMZKw FsECrO4DnZpsmEjRO067bQzhh1ezb2o6mM1mTily3Gj3V7zYpvuu/QW6LlqPoJDQBsAe HFOQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=e9q6Ugps; 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=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 t1si20500094otq.322.2019.12.28.10.55.50; Sat, 28 Dec 2019 10:56:01 -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; dkim=pass header.i=@gmail.com header.s=20161025 header.b=e9q6Ugps; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726460AbfL1SyO (ORCPT + 99 others); Sat, 28 Dec 2019 13:54:14 -0500 Received: from mail-pf1-f194.google.com ([209.85.210.194]:45982 "EHLO mail-pf1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726310AbfL1SyO (ORCPT ); Sat, 28 Dec 2019 13:54:14 -0500 Received: by mail-pf1-f194.google.com with SMTP id 2so16325282pfg.12 for ; Sat, 28 Dec 2019 10:54:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=UMpegDdh42rzwNWi4a8X/3LZzmdLDgDCJkziq2QANl8=; b=e9q6UgpsjC8HSol+91vUSHFa8daBZdwfDH9ZaAV2Jp6qXzLG2sx+VRx0s6GWj8/ADO HYGMGVEEMgKjXVJ0AdrCNTV7kiDHSMV8/qNfTrMf+f1GmzI/bebbACkVVz14k/dS82Tj IhYUG14vGzbmhUd73o0R7t2I3cX7SSb6YUHbqZWXHxOq+czkfmzq1I5oyVDPuOMeZAGH BNf12FdFdPkDC9ndIR7pTNCQhi/8qLU3QlbOmDWLsSv8SgtoSdjB1PW1QYu1oheOMUW4 Uvi7Rf8iwO7R6LazQsZ6crHj2+WJF4Yxvx/3/uO8zfCmTXvCuMYb4YKWtZlRSvv/i1vm coTg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=UMpegDdh42rzwNWi4a8X/3LZzmdLDgDCJkziq2QANl8=; b=i1m80PrbI5NqGjZQslEWiWs/RhLBGigMAEDsSjTsc2WwwC+eIgvuPuQs+8FsK9a7i3 ZmvQZsekHxPr1afFArZl0sTmG9UcopIVHXO8cROI0Anu5cUgdkrXzztaYpfsTuay1ZKx A5TfIKHxJeom7lZpvapKNuZ0i2m1fgM9ImtyhN3IIIpfkMxMLAUfSjzEwSF3QhY2aAZL HuiRBmIb7fFu1Cg/hx99b4TcPbSbzy2zFexIE1PgO02sxyE1KYCOeFLvvhaydM3aM9J8 Veg4hNx5pHTezPd4asM5LXfLmNFIk9ADx1bhbRc53j9yYAGhz+trWL9aji9UKfAht8AS l8rQ== X-Gm-Message-State: APjAAAVgl6Q6LZ5GMxRrwjERVS7dLClil9d3byYPvBJng7Y03v6tskbu T9mJBqB92N6DPe5HyJojpDg= X-Received: by 2002:a63:fe0a:: with SMTP id p10mr59963512pgh.96.1577559253330; Sat, 28 Dec 2019 10:54:13 -0800 (PST) Received: from localhost ([2001:19f0:6001:12c8:5400:2ff:fe72:6403]) by smtp.gmail.com with ESMTPSA id 80sm37407784pfw.123.2019.12.28.10.54.12 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sat, 28 Dec 2019 10:54:12 -0800 (PST) From: Yangtao Li To: vitor.soares@synopsys.com, bbrezillon@kernel.org, pgaj@cadence.com Cc: linux-i3c@lists.infradead.org, linux-kernel@vger.kernel.org, Yangtao Li Subject: [PATCH 2/2] i3c: master: cdns: convert to devm_platform_ioremap_resource Date: Sat, 28 Dec 2019 18:54:06 +0000 Message-Id: <20191228185406.26551-2-tiny.windzz@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20191228185406.26551-1-tiny.windzz@gmail.com> References: <20191228185406.26551-1-tiny.windzz@gmail.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li --- drivers/i3c/master/i3c-master-cdns.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/i3c/master/i3c-master-cdns.c b/drivers/i3c/master/i3c-master-cdns.c index 10db0bf0655a..2fb7ed34f995 100644 --- a/drivers/i3c/master/i3c-master-cdns.c +++ b/drivers/i3c/master/i3c-master-cdns.c @@ -1524,7 +1524,6 @@ static void cdns_i3c_master_hj(struct work_struct *work) static int cdns_i3c_master_probe(struct platform_device *pdev) { struct cdns_i3c_master *master; - struct resource *res; int ret, irq; u32 val; @@ -1532,8 +1531,7 @@ static int cdns_i3c_master_probe(struct platform_device *pdev) if (!master) return -ENOMEM; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - master->regs = devm_ioremap_resource(&pdev->dev, res); + master->regs = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(master->regs)) return PTR_ERR(master->regs); -- 2.17.1