Received: by 2002:a05:7412:d8a:b0:e2:908c:2ebd with SMTP id b10csp266388rdg; Tue, 10 Oct 2023 09:37:09 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFsXD2ENAT0y1+UWnGmxI0cnCaObQ4coQnGV9byFMcNK6qVKD0h367S23iel8VxTvrq7ehG X-Received: by 2002:a05:6a00:1516:b0:691:da6:47b with SMTP id q22-20020a056a00151600b006910da6047bmr18990610pfu.10.1696955828926; Tue, 10 Oct 2023 09:37:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696955828; cv=none; d=google.com; s=arc-20160816; b=bpJ4jfGTseEg25DtXMvdvjmA9KB80mwbxfbmR9Btzt4Tj4XsWvjj4ycMOj//Dmc5PU qRxi4ToEdiCTuUo11WIr9hT64a2fBX55/XMw+Aap4GRpGiVD7JiK5x1+3TJ4qrRx2ucK 1WLYxPXWf0shNHZY4VaJ0oCyXqllrBNSpUvja/C3uiqXHwCqpTUM9lpDU71kJxNXMVVw qrR/8ERJyGtzVu/REhA2tf5ZbW/WNnWHew4fZfos9hHtDa8w0ES6PJQ4n3MPDg4EpfeO iHw0f6o0Taj/o9TWsqrefmbFaw1n6NKpcMAvk7gFtwVL/ewdPdzDG+6uGtwqB0DYOhII 8tVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:user-agent:references:in-reply-to :subject:cc:to:from:message-id:date:dkim-signature; bh=OIleFKF6twFuG5Dc0SGIgrFuQGcumsYBYyAZKUCcZc0=; fh=Gh84rXhjqfrD0dSirEoiLhjWUJmzRkj0Oi6McJNaZWU=; b=s3mZJp2To/rfxErUhPiKUWoMcF/dADAZR7vvxqsh8V9iuVT9+WCUiczLiGgobqixl6 xea46gw3vGQiF3JdGZezRXo0H7IQBA4GvnTYJ9tREaJQkX0mypXmpGCr3Ker56e08WMI qhLrtXG4jQgjdhKFFsEqSLTZX8lK5PTQLzq3mPWJoVoJ3JXXi4wIFDGrhfQrny2ykqor tYvP9kaENTKDNXbNYlW9C8FHdlKfovtnTd6gugKPXXVxYHhz63JPOfAPqMi638V571EU XtklVpFxv74Lazk8oUu2v7Qwp/44y3kvBs539wcGLwGvFCLdyBQg3gOqnIDDiE2bTaTJ tAsQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=D9B6K+j5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [2620:137:e000::3:3]) by mx.google.com with ESMTPS id bk13-20020a056a02028d00b00578e5228c76si12095027pgb.505.2023.10.10.09.37.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 10 Oct 2023 09:37:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) client-ip=2620:137:e000::3:3; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=D9B6K+j5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 93EE181BF32B; Tue, 10 Oct 2023 09:37:06 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233440AbjJJQhA (ORCPT + 99 others); Tue, 10 Oct 2023 12:37:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51026 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231449AbjJJQg7 (ORCPT ); Tue, 10 Oct 2023 12:36:59 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 863A593 for ; Tue, 10 Oct 2023 09:36:58 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2513DC433C7; Tue, 10 Oct 2023 16:36:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1696955818; bh=W2xIKe9L/LI5ekQDMfwHG7XAOQIQ9z/WMjX7Z1TYmxQ=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=D9B6K+j5Di39Lds6hkOZ3g552VZGLNdd2uYMqqy3T4H2GzrODYEn++a2HFFR6SawY zNfMNqw8HbxH6OK4V7ZDDamXqMKAjx4kBRhOveJBjYNc0OxTwNg/QIAji8kyfxxEPU 6w9RnP72uLoNZ7CUWF0lTHIPn5dMU4Ru7mR/8UaMtmSC0TUykWcBKZbZG2HKAeOYN8 SMw4YuHHdYcBWP4cVKi4LeMvxR1yTo58Mw910astCLG4hVtXiiD8wXtw3Y5RgRIfPL rTgVXP8705qYkFzoNQley5S9SZYkqmQ4J4dKwadbEKJqx4Qczysn4h6wpPOdwLC6gm DVK91u5VfEbAg== Received: from [104.132.1.97] (helo=wait-a-minute.misterjones.org) by disco-boy.misterjones.org with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.95) (envelope-from ) id 1qqFj4-002rfh-Tw; Tue, 10 Oct 2023 17:36:55 +0100 Date: Tue, 10 Oct 2023 17:36:50 +0100 Message-ID: <874jiymo2l.wl-maz@kernel.org> From: Marc Zyngier To: Yicong Yang Cc: , , , , , , , , , , , Subject: Re: [RFC PATCH 0/3] Add HiSilicon system timer driver In-Reply-To: <20231010123033.23258-1-yangyicong@huawei.com> References: <20231010123033.23258-1-yangyicong@huawei.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM-LB/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL-LB/10.8 EasyPG/1.0.0 Emacs/28.2 (x86_64-pc-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII X-SA-Exim-Connect-IP: 104.132.1.97 X-SA-Exim-Rcpt-To: yangyicong@huawei.com, mark.rutland@arm.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, daniel.lezcano@linaro.org, tglx@linutronix.de, jonathan.cameron@huawei.com, prime.zeng@huawei.com, wanghuiqiang@huawei.com, wangwudi@hisilicon.com, guohanjun@huawei.com, yangyicong@hisilicon.com, linuxarm@huawei.com X-SA-Exim-Mail-From: maz@kernel.org X-SA-Exim-Scanned: No (on disco-boy.misterjones.org); SAEximRunCond expanded to false X-Spam-Status: No, score=2.4 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, RCVD_IN_SBL_CSS,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Tue, 10 Oct 2023 09:37:06 -0700 (PDT) X-Spam-Level: ** On Tue, 10 Oct 2023 13:30:30 +0100, Yicong Yang wrote: > > From: Yicong Yang > > HiSilicon system timer is a memory mapped platform timer compatible with > the arm's generic timer specification. The timer supports both SPI and > LPI interrupt and can be enumerated through ACPI DSDT table. Since the > timer is fully compatible with the spec, it can reuse most codes of the > arm_arch_timer driver. However since the arm_arch_timer driver only > supports GTDT and SPI interrupt, this series support the HiSilicon system > timer by: > > - refactor some of the arm_arch_timer codes and export the function to > register a arch memory timer by other drivers > - retrieve the IO memory and interrupt resource through DSDT in a separate > driver, then setup and register the clockevent device reuse the arm_arch_timer > function > > Using LPI for the timer is mentioned in BSA Spec section 3.8.1 (DEN0094C 1.0C). This strikes me as pretty odd. LPIs are, by definition, *edge* triggered. The timer interrupt must be *level* triggered. So there must be some bridge in the middle that is going to regenerate edges on EOI, and that cannot be architectural. What am I missing? Thanks, M. -- Without deviation from the norm, progress is not possible.