From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id B56B4EB64DA for ; Fri, 30 Jun 2023 20:18:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231508AbjF3USU (ORCPT ); Fri, 30 Jun 2023 16:18:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44384 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230100AbjF3USH (ORCPT ); Fri, 30 Jun 2023 16:18:07 -0400 Received: from unicorn.mansr.com (unicorn.mansr.com [81.2.72.234]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5358430C5 for ; Fri, 30 Jun 2023 13:18:05 -0700 (PDT) Received: from raven.mansr.com (raven.mansr.com [IPv6:2001:8b0:ca0d:1::3]) by unicorn.mansr.com (Postfix) with ESMTPS id 55F7C15360; Fri, 30 Jun 2023 21:18:03 +0100 (BST) Received: by raven.mansr.com (Postfix, from userid 51770) id 47FED219FD1; Fri, 30 Jun 2023 21:18:03 +0100 (BST) From: Mans Rullgard To: Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Maxime Ripard Cc: Daniel Lezcano , Thomas Gleixner , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev Subject: [PATCH 0/3] clocksource: sun5i: clean up and convert to platform driver Date: Fri, 30 Jun 2023 21:01:25 +0100 Message-ID: <20230630201800.16501-1-mans@mansr.com> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The first two of these patches remove a bunch of duplicated code/data in the sun5i hstimer driver. To keep the diff clearer, the first patch introduces an otherwise pointless struct which is then removed in the second. The third patch converts the driver to a platform_device driver. This is to make it work again on A20 and A31 (I think) where it broke when the ccu driver was changed to a platform driver. I have only tested this on an A20 where the hstimer is registered as expected and can be selected through sysfs. I hope it doesn't break something else. Some additional discussion here: https://lore.kernel.org/linux-clk/20211119033338.25486-4-samuel@sholland.org/ Mans Rullgard (3): clocksource: sun5i: remove duplication of code and data clocksource: sun5i: remove pointless struct clocksource: sun5i: convert to platform device driver drivers/clocksource/timer-sun5i.c | 288 +++++++++++++----------------- 1 file changed, 123 insertions(+), 165 deletions(-) -- 2.41.0