From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=5.135.140.105 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796423037; b=f7R0B11IFsk4MLz07Fge+JlIq/H9o2Tn5aWi17RPHMd+fAGGc5E7tpgzrx9DQ8rRt6Pk Fm6NKFddWmDz7ZLTYncqcNWce3UWEV0RxCWiZ9yp3KNC5P6c83hNK0fIk3ETF2yRey+uz 3+fryjyS49FU//Z5HbeQre+FBNFc49EDENS+JyE3YPGYnfv5GSwZ7GXtqhG32GcGsdhTu HJ864fZNeyLiW7EI7vEBxlpOpvm4ec9mxk2BWLLJbCzKgAq7sTqtES31DJlpkqRb5wKVR wlLMTO0P9aLgF2jUUcJPZNQ4yaKnEmTX5U94rkbgV4ZElryhtcNqVggdHVHNYpLMD+A== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796423037; h=DMARC-Filter:Received:DKIM-Signature:From:To:Cc:Subject:Date: Message-Id:MIME-Version:Content-Transfer-Encoding: X-Last-TLS-Session-Version; bh=0wlETg9Ygr0BHO6mAAtazgczSizzAbbOHis2UEwFCmE=; b=otC6FQ8foZiGJ5HGn6Av4FsCOWdWmTM7jTQkm4gaOnLCAmNS8I8ao5WYwOiOX60oe84c KFcjTSL6nT60xl8F0ZSzsUVDc+69oZ4MzqY0rq/dpcjMaI/4MmFdwZyKlui9fSyBGL7/i UCeAbU/uqvdON/a4LOOEmX7/j21tVHY5zfCS2O3kr5J85S4nO/XtXMOhKmkEUnSvzdbJM gsI1FVGn9lsjpwEZlBbjFqbdtMfLuZh8eb4JdovZ+orE0PvVno5wExZxh7hC/PhdpRRrZ tPkaq8+Pxw19sg3l17a5F0xLCNoPt6YGDNTDBFBZYT63ck5qcFvaEX8tUHBXj9oWxTg== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=cjdns.fr; spf=pass smtp.mailfrom=cjdns.fr; dkim=pass header.d=cjdns.fr header.i=@cjdns.fr header.a=rsa-sha256 header.s=dkim header.b=iZeE9gto; arc=none smtp.remote-ip=5.135.140.105 Received: from mail.cjdns.fr (mail.cjdns.fr [5.135.140.105]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2A238606A335; Fri, 4 Dec 2026 22:23:55 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 2A238606A335 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=cjdns.fr Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=cjdns.fr Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=cjdns.fr header.i=@cjdns.fr header.a=rsa-sha256 header.s=dkim header.b=iZeE9gto Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id 59F4B6ED55F; Fri, 4 Dec 2026 23:23:42 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cjdns.fr; s=dkim; t=1796423025; h=from:subject:date:message-id:to:cc:mime-version: content-transfer-encoding; bh=0wlETg9Ygr0BHO6mAAtazgczSizzAbbOHis2UEwFCmE=; b=iZeE9gton5t0DK2oBrG1/Ppb0b3qjUx0Z8sLgv7BkKLz0TME4+UTqya2gMuNEKOH//Aw8Z N9w0/MoPT5VTvYF1K8AKsRmks7bkW6nknbt3zwvGm6RR/yzyQ282/JBkIOsH0Y+6Dx5ORU ib1//7qSJ/au4NtH1XyECcQyJ53O1L/0jiHGuLOOAAkaPj8yXtcOn6nSvFl4bRMdjDoBAV XT55CyeYTZ7x7qT29muGWVm5YJ4TNxpI3tvtpOhexpzdyfHj5IT4PkbM6Z1yoTVMwX+VBM BuNbdFgZI7DzQoMSkN9mCUhwKLEjXMZsjU4HXfR2MoUF8W9a9amz7ic1diuuyw== From: Caleb James DeLisle To: linux-mips@vger.kernel.org Cc: conor+dt@kernel.org, daniel.lezcano@kernel.org, devicetree@vger.kernel.org, krzk+dt@kernel.org, linux-kernel@vger.kernel.org, naseefkm@gmail.com, robh@kernel.org, tglx@kernel.org, grandmaster@al2klimov.de, Caleb James DeLisle Subject: [PATCH RESEND v12 0/5] clocksource/timer-econet-en751221: Support irq number per timer Date: Fri, 4 Dec 2026 22:23:29 +0000 Message-Id: <20261204222334.1085123-1-cjd@cjdns.fr> X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Last-TLS-Session-Version: TLSv1.3 Hello all, I haven't seen any activity on this patchset from NOV 17: Link: https://lore.kernel.org/linux-mips/20261117095117.173316-1-cjd@cjdns.fr/ It seems that it still applies cleanly so I'm re-sending now. Any attention would be most appreciated. Thanks, Caleb This timer appears on both the EcoNet EN751221 (34Kc) and on the EN751627 / EN7528 (1004Kc) SoCs. On the 34Kc the interrupt controller uses a percpu interrupt while on the others it uses an individual IRQ number for each CPU timer. Add support for EN751627 and EN7528. Add support for IRQ number for each CPU timer under the econet,en751627-timer compatible. Changes since v11: * Update to tip/timers/core Nov 1, see base-commit. Changes since v10: * Unconditionally setup clock_event_device for all possible CPUs so that error log will not access uninitialized data. Identified by: Link: https://sashiko.dev/#/patchset/20261015145331.453837-1-cjd@cjdns.fr?part=4 Changes since v9: * Use dynamic size irq and iomem block arrays based on DT * Update commit message explicating that CPU hotplug is intentionally not supported Changes since v8: * Actually git commit changes from v7. Guys, I sincerely apologize for the spam. Changes since v7: * Use %zd for logging with ARRAY_SIZE to avoid compiler errors if test-compiling on 64 bit. Changes since v6: * Rebase to tip/timers/core (base-commit below) Changes since v5: * Integrate patch fix refcount leak from: Link: https://lore.kernel.org/linux-mips/20260526184105.18962-3-grandmaster@al2klimov.de/ * NULL econet_timer.membase after unmapping * NULL check dev->event_handler in case clockevents_config_and_register failed to fully register. * v5: https://lore.kernel.org/linux-mips/20260516233943.49502-1-cjd@cjdns.fr/ Changes from v4: * Fixed incorrect compatible in DT schema * Bracing in out_irq_free if statement * I did not move cpuhp_setup_state past the point of no return * v4: https://lore.kernel.org/linux-mips/20260516215720.4160831-1-cjd@cjdns.fr Changes from v3: * off-by-one in out_irq_free * Gracefully fail if too many address resources are provided in the DT * Allow fewer actual timers than num_possible_cpus, as long as they never start * v3: https://lore.kernel.org/linux-mips/20260516182648.3987792-1-cjd@cjdns.fr v3 note: I decided to take this patchset in a slightly different direction from v2. There is a certain amount of initialization that once it has run, it cannot be reverted in case of error. The original driver init was a mixture of revertible and non-revertible code which made it too easy for code which is designed with best practices in mind to in fact introduce a bug. Therefore I start by making the init process more legible but without any business logic changes, then fix a race condition by keeping IRQ disabled until after cevt is setup, then finally add non-percpu IRQ support. * v2: https://lore.kernel.org/linux-mips/20260514000601.3430262-1-cjd@cjdns.fr Changes from v1: * Split changes over 3 refactoring patches + main patch * Remove driver discussion from dt commit message * v1: https://lore.kernel.org/linux-mips/20260416175101.958073-1-cjd@cjdns.fr/ Caleb James DeLisle (5): dt-bindings: timer: econet: Update EN751627 for multi-IRQ clocksource/timer-econet-en751221: Init teardown on error if possible clocksource/timer-econet-en751221: Disable IRQ until cevt registered clocksource/timer-econet-en751221: Support EN751627 without percpu IRQ clocksource/timer-econet-en751221: Do not use NR_CPUS for resource array size .../bindings/timer/econet,en751221-timer.yaml | 31 ++- drivers/clocksource/timer-econet-en751221.c | 206 ++++++++++++++---- 2 files changed, 181 insertions(+), 56 deletions(-) base-commit: 0359ecff58853a491dd0f09792fea8e87235ae06 -- 2.39.5