From patchwork Tue Dec 19 05:07:12 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christophe JAILLET X-Patchwork-Id: 180756 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:24d3:b0:fb:cd0c:d3e with SMTP id r19csp1721919dyi; Mon, 18 Dec 2023 21:07:34 -0800 (PST) X-Google-Smtp-Source: AGHT+IFaoxTRBepDdKRw2FRiYOjx9HE/B8LW2GYgq8MfbCGHWiB67ObPIe9gC4/ZTUSGOerGSAyR X-Received: by 2002:a50:f68a:0:b0:553:9faa:d907 with SMTP id d10-20020a50f68a000000b005539faad907mr73901edn.67.1702962453897; Mon, 18 Dec 2023 21:07:33 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702962453; cv=none; d=google.com; s=arc-20160816; b=Jz67AZSt58AwyeP0IJF7KefWDn39uprd8Y+1a3Doscn2ygfIm9WlhoU2IbdgpTd9aT 0xpZao5FHf5YWLvbY+aqLyvUseX3mQYnU1hOW3DMjGN1RgY7TpuRXEdG4TF2Km4obnJp iIIX0muzIixH2dilOd14t2OaLIbYVoR8PIT7xxCP+pk55Jaev75twpGNk9eugXzt+rOp 7Ybs0HtinjJgD58k6owqJGousySd+HJA91Sy1P3Wiel4DrEcqiiUWEogHYtecRtO8qx0 v4aWoAOjxobcEdY3leT2TwKJaKj0mQKD6Z1tuIK9w/3yLjg0U5dRLfhbDzddov3o4xgK 5pyA== ARC-Message-Signature: i=1; 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:message-id:date:subject:cc:to :from:dkim-signature; bh=hNYuJtLt44j1feoxZtTgwq9FQXGAYBO23/GymZ86/oM=; fh=z4uC/5yXZY/u8C11T1KGT+w7Tu1GXVpi7SoZSnxKEhE=; b=MDlEtxP7RMn9HhvhyGbQyyT/kuCNKfOnbt7AkEhN32/yip0hPOTrl9jO23VqGLZwYK S+6eKpNAyq7SzC5QPOZA+7EA/cZwCogW6PJbrSkIg71KDksXqUo0obG4Kvo2bHiKYTkm F7eJfvLzCG04JR1OFLFgA1WHPTlLmv/9s9QzN9h9oXBBqa4bDqtbPPrWCR7oqkrO3UFf HzZNGoMoWpXA2h9jUPmSmsJJT6CKdgTFKuczjJSTh1HAo4iN2YLQQ/A7sgzNJBCI46gc HloI9W+bblvhHTH/ZJeOXxCKvWPvzEHx3zxVuVL48wJkzthUcr9ZCY2F0/2ctyfzGaNK 0Rng== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@wanadoo.fr header.s=t20230301 header.b=jikoi80u; spf=pass (google.com: domain of linux-kernel+bounces-4703-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-4703-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=wanadoo.fr Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id v26-20020a50955a000000b005537fc22bffsi609220eda.590.2023.12.18.21.07.33 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 18 Dec 2023 21:07:33 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-4703-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@wanadoo.fr header.s=t20230301 header.b=jikoi80u; spf=pass (google.com: domain of linux-kernel+bounces-4703-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-4703-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=wanadoo.fr 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 am.mirrors.kernel.org (Postfix) with ESMTPS id 842811F24BC3 for ; Tue, 19 Dec 2023 05:07:33 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 9057F746A; Tue, 19 Dec 2023 05:07:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=wanadoo.fr header.i=@wanadoo.fr header.b="jikoi80u" X-Original-To: linux-kernel@vger.kernel.org Received: from smtp.smtpout.orange.fr (smtp-15.smtpout.orange.fr [80.12.242.15]) (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 591CB611F for ; Tue, 19 Dec 2023 05:07:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=wanadoo.fr Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=wanadoo.fr Received: from pop-os.home ([92.140.202.140]) by smtp.orange.fr with ESMTPA id FSK1r7LYOlOIfFSK1rNq1F; Tue, 19 Dec 2023 06:07:14 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=wanadoo.fr; s=t20230301; t=1702962434; bh=hNYuJtLt44j1feoxZtTgwq9FQXGAYBO23/GymZ86/oM=; h=From:To:Cc:Subject:Date; b=jikoi80uOG58pqVrEA9fTFMioN76sSv7LCJL4SuH6vCakXTBBmWmYfkAOQWtYoHyu pEc6A7aHjbvWlA7dkVbNPKz4uqfFiNM2NzScWprWYzm+kTMVWkRKVjXsvoA1ucYThx tsqgHNq8Dwg5liFAPkI9BhslqfgEkNQMQbfeItSN+OlEqm7Y8bnFQkVPVUGKoZ6fLW M1KMltITCaUvAJp7hjqExWDcmRT4CC8xOKmRB6+/gn8PhavLF7M3ia69Pe6zPA5MBq kc5XCbKvWtdTv5C4xx+dMppMM42ECriwWhMvMnHBZ+Ljn8DWwJSKqBX0OzI9B7Slm7 XrjzckzfpVRng== X-ME-Helo: pop-os.home X-ME-Auth: Y2hyaXN0b3BoZS5qYWlsbGV0QHdhbmFkb28uZnI= X-ME-Date: Tue, 19 Dec 2023 06:07:14 +0100 X-ME-IP: 92.140.202.140 From: Christophe JAILLET To: Alessandro Zummo , Alexandre Belloni Cc: linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org, Christophe JAILLET , linux-rtc@vger.kernel.org Subject: [PATCH] rtc: class: Remove usage of the deprecated ida_simple_xx() API Date: Tue, 19 Dec 2023 06:07:12 +0100 Message-Id: <4f2c049cb09d46fed336e22445c71988b4f340d6.1702962419.git.christophe.jaillet@wanadoo.fr> X-Mailer: git-send-email 2.34.1 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1785685558173920929 X-GMAIL-MSGID: 1785685558173920929 ida_alloc() and ida_free() should be preferred to the deprecated ida_simple_get() and ida_simple_remove(). This is less verbose. Signed-off-by: Christophe JAILLET --- Commit 592ff0c8d064 ("rtc: Directly use ida_alloc()/free()") missed this call --- drivers/rtc/class.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/rtc/class.c b/drivers/rtc/class.c index edfd942f8c54..921ee1827974 100644 --- a/drivers/rtc/class.c +++ b/drivers/rtc/class.c @@ -256,7 +256,7 @@ static int rtc_device_get_id(struct device *dev) of_id = of_alias_get_id(dev->parent->of_node, "rtc"); if (of_id >= 0) { - id = ida_simple_get(&rtc_ida, of_id, of_id + 1, GFP_KERNEL); + id = ida_alloc_range(&rtc_ida, of_id, of_id, GFP_KERNEL); if (id < 0) dev_warn(dev, "/aliases ID %d not available\n", of_id); }