Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp424296pxj; Fri, 11 Jun 2021 02:35:06 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyscWO8kMiZgjYLOskUWjJhPJ5SUG2gI7/rckXLvm4rfdwiZmTxiuQk2utk48wvTVbJYCmI X-Received: by 2002:a17:907:75ee:: with SMTP id jz14mr2838752ejc.524.1623404106767; Fri, 11 Jun 2021 02:35:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623404106; cv=none; d=google.com; s=arc-20160816; b=YdXfJIv+RJUg62JPwikBRVZio20h9nv+hUQqnpbcfsRhGyPynjCQ7zFwl/cdzEJ0+L uUJywvVDn42+ZnouXLwWCi7Uy3huirjscgw2Mz0e2Pv7GGEPs046yloiKQ6Y0tJzOguL 0dYf4tyS978x3PNS60x6gR2++Mfnbxq+9lGaVIvrvI9o861bIDxhgDAvTDhbnrzDCZ6p xzLs96DPeKRmLbpSh7yOm4uHgIaKpmaLq1KmSzeI9TBYl6pQTu6wYWknZiB83TIqfafC FaGZ9YH/D0rwXsFOzsU+gCVoshO2LOnNt8gXwOZ9UrKqdai98NEKgD6YdaZ4xc0oRiOl bHGg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=Il9aD8Xn2A6MBl+617W68xF8gD09hzxRwfn55tf4XbQ=; b=R9uvWxKBEwPqLkCRLdXUZEipJ0GHvv+PUXWEZGcYgk8ToRNDT2BsbN2LO7rSAzEwEZ IrcpqN3hP7DRFwQ4FbaUOtgLsxQ7Z6WAswHeMS6G1zmdm80rk+nNvorknI1ENSOKebFa fdfhaOzFhYrGEi5DwYCMHrN2prpMrAUbTeP7LOIa3s4VFI8098O0ScvdvJ5sm2Ko5bPK wd3JX7xYmti8Oxur7L4XGvPT89R33SqBbvPsFSSxzJ5amicHvjcA0BYINJGTWIm67b9y 6NsJ0FlaXbv4PUv1h4TFnwa7ZbjWvpqvrGyM6eoaAh+54pC08RMtITdq0ivdwpkWDn6Y UYsw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t26si4331300edf.425.2021.06.11.02.34.43; Fri, 11 Jun 2021 02:35:06 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231210AbhFKJew (ORCPT + 99 others); Fri, 11 Jun 2021 05:34:52 -0400 Received: from szxga02-in.huawei.com ([45.249.212.188]:5504 "EHLO szxga02-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231319AbhFKJea (ORCPT ); Fri, 11 Jun 2021 05:34:30 -0400 Received: from dggemv703-chm.china.huawei.com (unknown [172.30.72.53]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4G1bCS5l7XzZdll; Fri, 11 Jun 2021 17:29:40 +0800 (CST) Received: from dggpeml500017.china.huawei.com (7.185.36.243) by dggemv703-chm.china.huawei.com (10.3.19.46) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Fri, 11 Jun 2021 17:32:32 +0800 Received: from huawei.com (10.175.103.91) by dggpeml500017.china.huawei.com (7.185.36.243) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Fri, 11 Jun 2021 17:32:31 +0800 From: Yang Yingliang To: , , CC: , Subject: [PATCH -next 6/9] ASoC: fsl_sai: Use devm_platform_get_and_ioremap_resource() Date: Fri, 11 Jun 2021 17:36:23 +0800 Message-ID: <20210611093626.579176-7-yangyingliang@huawei.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210611093626.579176-1-yangyingliang@huawei.com> References: <20210611093626.579176-1-yangyingliang@huawei.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.175.103.91] X-ClientProxiedBy: dggems704-chm.china.huawei.com (10.3.19.181) To dggpeml500017.china.huawei.com (7.185.36.243) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Use devm_platform_get_and_ioremap_resource() to simplify code. Signed-off-by: Yang Yingliang --- sound/soc/fsl/fsl_sai.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sound/soc/fsl/fsl_sai.c b/sound/soc/fsl/fsl_sai.c index 407a45e48eee..223fcd15bfcc 100644 --- a/sound/soc/fsl/fsl_sai.c +++ b/sound/soc/fsl/fsl_sai.c @@ -1017,8 +1017,7 @@ static int fsl_sai_probe(struct platform_device *pdev) sai->is_lsb_first = of_property_read_bool(np, "lsb-first"); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - base = devm_ioremap_resource(&pdev->dev, res); + base = devm_platform_get_and_ioremap_resource(pdev, 0, &res); if (IS_ERR(base)) return PTR_ERR(base); -- 2.25.1