From patchwork Thu Jan 4 12:50:18 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Lezcano X-Patchwork-Id: 123410 Delivered-To: patch@linaro.org Received: by 10.140.22.227 with SMTP id 90csp11389482qgn; Thu, 4 Jan 2018 04:51:17 -0800 (PST) X-Google-Smtp-Source: ACJfBotraOGw0Pi9bs6le7QKjo9vUuqYkzrCgBl8h1c/6ce+Xw3CW3NlD/zAX5TiV2ejCaEey4Kb X-Received: by 10.84.131.65 with SMTP id 59mr4505198pld.156.1515070277677; Thu, 04 Jan 2018 04:51:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1515070277; cv=none; d=google.com; s=arc-20160816; b=q22wed3sFnC41bVSBhKuLoNYYMZU9lrk2ewfZ8Rfn2UUp6u7fhScG7w+1nhCxfMTWY UPS5m9JSSePDuTeGccMH0Ke3wZ0IBMHJj7Ut6tez+i9Lo3Hlzsbbj9zEd5DWn41Q71EJ BZeO4eTdz0QCUgBlofZbEINNNWJW/NSHKUKgtxaiIrpDy5XjgTl5faTmLeYmv2cqu84f CcW/e4ec8JjSJa5xGbBq0yLg29tC7Gjev7s4FiBIlA7RIncWY/jR/UUat+QbZeUAkzKY cs+3AS53EcdGCoKc89PuYK9ia2BD25H5muPQNMY5pbFl8Th1aexJv8Lc9Z8nW8ZawKg6 U1tQ== 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:arc-authentication-results; bh=DTJ6y5+9Ch8yOfmLDv0vXLpCj+GzPWWs1Aacq3oRjMM=; b=Tz2JeDojPY+8pbvUzSXawWAkci1IveHCw0zlmjpGRDtaHxQiIUQlHqf2YE5UYoOPUp /PnAxcYc9k5dPKbOgEcPvIFDW7ekF/7OavfbsXvKjUpbe1YlPhSuRZyQ//ly7hUt/7bu I1LmYUIO0V7628KJH2EzrrcorF325Zxzi+X8UAAL3QtNwznJ/nbWY77TTUtOD6sC94Q/ UUqBQwftzpCplTnoJOkPr75EVQCNxhqTGPAHJG1QDM7TWJZr6SQ/ygkDMtqnyqMHdA7O N54t8gWShzEellW9641VD0ahQ+F/ElLR2wdFPrUtcunyIp5UmPc41QvZANX+EEnJOn4B 0DEQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=AyPydhN8; 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=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c80si2283237pfb.307.2018.01.04.04.51.17; Thu, 04 Jan 2018 04:51:17 -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=@linaro.org header.s=google header.b=AyPydhN8; 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=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752657AbeADMvN (ORCPT + 27 others); Thu, 4 Jan 2018 07:51:13 -0500 Received: from mail-wm0-f67.google.com ([74.125.82.67]:43819 "EHLO mail-wm0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752587AbeADMvL (ORCPT ); Thu, 4 Jan 2018 07:51:11 -0500 Received: by mail-wm0-f67.google.com with SMTP id n138so3289572wmg.2 for ; Thu, 04 Jan 2018 04:51:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=DTJ6y5+9Ch8yOfmLDv0vXLpCj+GzPWWs1Aacq3oRjMM=; b=AyPydhN8wtE/YPA/EdllQx0lHREgYGHjnDALKv8kgcw7Wn5ZQ5L+J/9zNPS86vTNdy omdmN8Sg2OV/cJtwrRTL6Di/zudP7e4yxN6OGC+1Ma+Rw8JH/rnR9/b9M0xRpEnuj0nz j3BF+gwEQmaxGJ4YmiaxmiVz8im0z1UTNWtiw= 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=DTJ6y5+9Ch8yOfmLDv0vXLpCj+GzPWWs1Aacq3oRjMM=; b=V/ryKUlbiO69fZlR+hUJ2HSgVnSNVW+GOvhUA3+3pu0jKrnoYQ5+vauAQLGOLhHVHM FoQnmGcilLLsG11T2Vuf+4lntEBThk3FcmXCrgscjCafuHSiG+Pz6D5ATzqzQnu69iuH 3Hli0GTyawZpM2GTTs3qbgNPN5IYWL+Byu2QAaOj1YOe7fMaIM8UKvQftZ5G7LIpoGOj sxnOqMVWAgOURQUapu5HLEnMPemw/hLT15AqtL/TqssrHZeCtmhhzkr+CRYiQOe5cxf3 Il2mdSB51H7AVjUihi0Y9WP263gqqbMEBXdWJXaa0lyaSYQNbL5+7GM73bY2i/1wh/vM tYmw== X-Gm-Message-State: AKGB3mI7INSyPDtoFXT+AQnl2H3mCxc9t8Be71OKlwVK2fnR3hbRhWVw ONwYcQzwTXmH7jflfUVdBEmjuBBi/UA= X-Received: by 10.28.71.76 with SMTP id u73mr3743948wma.77.1515070269970; Thu, 04 Jan 2018 04:51:09 -0800 (PST) Received: from mai.lan ([2001:41d0:fe90:b800:c10d:405d:d60:60bb]) by smtp.gmail.com with ESMTPSA id d71sm3668348wma.7.2018.01.04.04.51.08 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 04 Jan 2018 04:51:09 -0800 (PST) From: Daniel Lezcano To: daniel.lezcano@linaro.org, tglx@linutronix.de Cc: linux-kernel@vger.kernel.org, benjamin.gaignard@linaro.org Subject: [PATCH 02/12] clocksource/drivers/timer-of: Don't request the resource by name Date: Thu, 4 Jan 2018 13:50:18 +0100 Message-Id: <1515070228-10481-3-git-send-email-daniel.lezcano@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1515070228-10481-1-git-send-email-daniel.lezcano@linaro.org> References: <1515070228-10481-1-git-send-email-daniel.lezcano@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org When the driver does not specify a name for the resource, don't use of_io_request_and_map but of_iomap. That prevents resource name allocation conflict on some platforms which have the same name than the node. Signed-off-by: Daniel Lezcano --- drivers/clocksource/timer-of.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) -- 2.7.4 diff --git a/drivers/clocksource/timer-of.c b/drivers/clocksource/timer-of.c index 2ae348b..5aa7dcd 100644 --- a/drivers/clocksource/timer-of.c +++ b/drivers/clocksource/timer-of.c @@ -162,11 +162,11 @@ static __init void timer_of_base_exit(struct of_timer_base *of_base) static __init int timer_of_base_init(struct device_node *np, struct of_timer_base *of_base) { - const char *name = of_base->name ? of_base->name : np->full_name; - - of_base->base = of_io_request_and_map(np, of_base->index, name); + of_base->base = of_base->name ? + of_io_request_and_map(np, of_base->index, of_base->name) : + of_iomap(np, of_base->index); if (IS_ERR(of_base->base)) { - pr_err("Failed to iomap (%s)\n", name); + pr_err("Failed to iomap (%s)\n", of_base->name); return PTR_ERR(of_base->base); }