Received: by 2002:ab2:1347:0:b0:1f4:ac9d:b246 with SMTP id g7csp78382lqg; Wed, 10 Apr 2024 16:23:02 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUZGeqDKD5krb1VjqVmUoIzAatj5iR9E1nEW9MS7XQ+6XPf9zqINdMB1jHtTmhKORSLPTg4FlrPh2lAVG+zrgNKGCwYYwkgSv2/EIIHuA== X-Google-Smtp-Source: AGHT+IHJ/9WSKjaveZyzkqeydqIFX3hf56qyrxTCqX2/bbjw/6Zt4Bv/+Xog9SzcnYYIeCQ3SuxN X-Received: by 2002:a05:622a:1308:b0:435:9920:9cfa with SMTP id v8-20020a05622a130800b0043599209cfamr3578144qtk.45.1712791382033; Wed, 10 Apr 2024 16:23:02 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712791382; cv=pass; d=google.com; s=arc-20160816; b=uIK359BCdrTPXxdUehuLdt1OKEdBwiqS2sUr1n/X3bZwaKLLFSqEqerTmNm0Rg6aAJ DxC9GD32cLiN6J1FiRvq0eqZFqdRTv0xaTbwt9MUz4mzytnMm3GNyk3FboVrQiFnXRJV pG5DjYWbNwb3z0lxtGlqoxYhJaXiqIsyC58MJWTuoe9E7AY6u1aWY7JyTXTEocNsKPAt EYgwCnkFaX0eERGSRbGKhX/oQ3E2+5QJqLXwW6M189yohKJZYwLiH4yVyVz2xR2p+XQW Ec3jcPkL0228CMOUJK7QD69mdsyVlBFe9NpgcLBW5fXG+XgdmfVwJu3zxgwAynP+DzX7 d/Rw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=m6GWeq3XOyCgOhhTvpF1S7omIve7JbnP/NpPy+2G4KQ=; fh=Gt6E73U6FxwD4WIEQH3lxlSoR1cUEFg1cL4NkFwjy/A=; b=GxVp2+3lIFhD2LrHHfSLuNbHX3I4aLXaxCQkJi3RawBCiDyWCz5ZBHsQ5Lk6r8Fi7e +WxVhh7DXdAmjtYn8qwjFmJhwemrgpDoJZE8WwTPpmIfVt4uhgFIoyM6X9S1ENxYkUtM 5oDDYIQ0HkJmfuP4o8HkOu6PuG1sNdqJa6KVJptUdKbCQlLNV1f6VyTyqzFbLubYpw5+ I2JbrRgTe2qjpDJvzl0luCiF+eUo8yBDm4QzvlzgAyaj9rg5ER6xbhZAy1Uv20TAiMQt r8aE4L729crL4Gc6kbzf67Xb8sCuX60L4EAQZGAMdmidqOhzV+Hqq7kTtrZYVSbatdBx 8fjA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@sifive.com header.s=google header.b=mfONAZt0; arc=pass (i=1 spf=pass spfdomain=sifive.com dkim=pass dkdomain=sifive.com dmarc=pass fromdomain=sifive.com); spf=pass (google.com: domain of linux-kernel+bounces-139524-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-139524-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=sifive.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id b11-20020ac87fcb000000b00436513278b4si249870qtk.664.2024.04.10.16.23.01 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 Apr 2024 16:23:02 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-139524-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@sifive.com header.s=google header.b=mfONAZt0; arc=pass (i=1 spf=pass spfdomain=sifive.com dkim=pass dkdomain=sifive.com dmarc=pass fromdomain=sifive.com); spf=pass (google.com: domain of linux-kernel+bounces-139524-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-139524-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=sifive.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 9B0D01C22CC9 for ; Wed, 10 Apr 2024 23:22:42 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 441303F9CC; Wed, 10 Apr 2024 23:22:18 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=sifive.com header.i=@sifive.com header.b="mfONAZt0" Received: from mail-pj1-f47.google.com (mail-pj1-f47.google.com [209.85.216.47]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0320A2E417 for ; Wed, 10 Apr 2024 23:22:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.216.47 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712791337; cv=none; b=HFksBafACCtFd6/0ux+L/L6akz24dd1HEPko2/nIb6djHMjjFmAMfJP6Vnn9JLB2vNcgKLb6MustQlfCv2zmA8q1TJle2kBXhDhVjOkicMT3LFgKmsRTtU+g0p6auQHtNAxCEnGoHt7gbSSTtKrGgEf3JiYmEi7UE+0zQA408SI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712791337; c=relaxed/simple; bh=8JbUy6lckbhTM3ZPTAPlE4Ad+zV4OmjpIzHolEPOxGk=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=opEXazTwTMUi4sUeuo2dqrqfxm+Tw5DRlrZkmPaoOxxPS2AI2lcdBXzZupdcfJ3XABzKyEZKlNkc8ZgiLfWpprUPkyZDoujxk5iMdQHTVRhoW/Cs9OtY4LCnlCKwE7mYZvzezS4KNiKVoTTjtQGs6uUcpFM37Q+swKlJJyBV5ws= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=sifive.com; spf=pass smtp.mailfrom=sifive.com; dkim=pass (2048-bit key) header.d=sifive.com header.i=@sifive.com header.b=mfONAZt0; arc=none smtp.client-ip=209.85.216.47 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=sifive.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=sifive.com Received: by mail-pj1-f47.google.com with SMTP id 98e67ed59e1d1-2a526803fccso2436596a91.1 for ; Wed, 10 Apr 2024 16:22:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sifive.com; s=google; t=1712791335; x=1713396135; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=m6GWeq3XOyCgOhhTvpF1S7omIve7JbnP/NpPy+2G4KQ=; b=mfONAZt0YSpHYKNsRD2Xg47zyReC5XB4RpG61pDb3rJh19+EMmou7krSE7lyLJgu03 QsEaZd1gdLJKfNQySEMVksFyD1+Ogrk6qCux6qC7b8uLqSDZzYvBrjYgKHLVMXV3GS6V El0AihUG8DzIYlZ0RQD6r9/uPh6s0b/6wbxMG2g+NAJqwS23xf4jxdI4iG3yuWpEzZbS jJb1l5ooDa1xhLQMaH//fBGIKXDlSh7v7F7VRNeKPz6b59KLCPO+WpI5Y2GOv5hP0T08 RGxY+9f0mcT4DUp0Jfj1Ku2Vo+gDaUuRXzIiXVk0akoWBuGJSiytrkB2lV/MwuKEjPic J2yQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712791335; x=1713396135; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=m6GWeq3XOyCgOhhTvpF1S7omIve7JbnP/NpPy+2G4KQ=; b=isiprH2BCHpO7sop9LnXrcgHpuI9p+J5EaGRM2LT5VrTi/ms0ZPn/vGsSLcMp7xuU+ MLoSeyxry/8L67QoV9wjmShoLdVfrb0yZTCMR6MBDV1uX5pDDRvYx771qDQxXSoLXbEC nhbQOwj20G/Q9XKgtk67XJQcH4AbrcCqxvG0YMJ2ycftpLLYc1ARusoTMPG/DuYeKTP5 JqZ6fOoNdJWU6OhA5p0tcHPGdQFJdaLO11p724PAf7IioDoVs2oVzJvIB/xJaJ3uEBvN wR4HVEupbx/8MlaLn3GE1uyEalTGTzNYhpb+4bGpok5N9cUAk22UykxtTmEzSQHnHSi4 NH/A== X-Forwarded-Encrypted: i=1; AJvYcCVPE9Byr32rGmhtD7w1BW4zIpPzXCyimv384tqsxI0iW1ZbEmC777MU6sU2Pi35AvTOV4+qITAXUj3WCGkHGQ4Cv0XJUvJQL6aox4hL X-Gm-Message-State: AOJu0YzrhzDeVExDCW3UhFxbaId3MlfIE8maY6NZMVL0INTCyTsv3GuK OUZfbqtwSYrkDdWDzt33jmqiE2zVfHduuc9J7DtoCK7birkNGKTwVFiKZUjdj30= X-Received: by 2002:a17:90a:7c43:b0:2a2:97ce:24f5 with SMTP id e3-20020a17090a7c4300b002a297ce24f5mr4347230pjl.35.1712791335281; Wed, 10 Apr 2024 16:22:15 -0700 (PDT) Received: from sw06.internal.sifive.com ([4.53.31.132]) by smtp.gmail.com with ESMTPSA id o19-20020a17090aac1300b002a269828bb8sm161865pjq.40.2024.04.10.16.22.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 Apr 2024 16:22:14 -0700 (PDT) From: Samuel Holland To: Conor Dooley , linux-riscv@lists.infradead.org Cc: Samuel Holland , Paul Walmsley , linux-kernel@vger.kernel.org Subject: [PATCH 2/4] cache: sifive_ccache: Use of_iomap() helper Date: Wed, 10 Apr 2024 16:22:04 -0700 Message-ID: <20240410232211.438277-3-samuel.holland@sifive.com> X-Mailer: git-send-email 2.44.0 In-Reply-To: <20240410232211.438277-1-samuel.holland@sifive.com> References: <20240410232211.438277-1-samuel.holland@sifive.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit This simplifies the code with no functional change. Signed-off-by: Samuel Holland --- drivers/cache/sifive_ccache.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/drivers/cache/sifive_ccache.c b/drivers/cache/sifive_ccache.c index 6874b72ec59d..9833e9f6f36c 100644 --- a/drivers/cache/sifive_ccache.c +++ b/drivers/cache/sifive_ccache.c @@ -288,7 +288,6 @@ static struct platform_driver sifive_ccache_driver = { static int __init sifive_ccache_init(void) { struct device_node *np; - struct resource res; const struct of_device_id *match; unsigned long quirks __maybe_unused; int rc; @@ -299,12 +298,7 @@ static int __init sifive_ccache_init(void) quirks = (uintptr_t)match->data; - if (of_address_to_resource(np, 0, &res)) { - rc = -ENODEV; - goto err_node_put; - } - - ccache_base = ioremap(res.start, resource_size(&res)); + ccache_base = of_iomap(np, 0); if (!ccache_base) { rc = -ENOMEM; goto err_node_put; -- 2.44.0