From patchwork Wed Sep 27 17:00:11 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sunil V L X-Patchwork-Id: 14601 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:cae8:0:b0:403:3b70:6f57 with SMTP id r8csp2776667vqu; Wed, 27 Sep 2023 10:14:36 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEygJDijojOoeDdvDRnWHudnDRmHHFi30yBUTFKYbxR8Q6mBuQ1ZEfc5b12h8WEZyVqE9gy X-Received: by 2002:a05:6a20:8f09:b0:140:f6c4:aa71 with SMTP id b9-20020a056a208f0900b00140f6c4aa71mr3050968pzk.8.1695834876457; Wed, 27 Sep 2023 10:14:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695834876; cv=none; d=google.com; s=arc-20160816; b=G4olyHx6aFLv5DBCSrNjzzSkHqwy+U7CthbU1HjQ7K97gdk6cqUbSJZv4IEONLCWhg a1pdfokELVtNbDATbJSKnP6lyigecFJwwXtl7kMGS4v42uPqUJM5bHl3DpmlyG7UtfXI MSCgp8keF+ooGNJfvJXOx7OF4druxr+4bAEtjTo7jLzDauduUaZBTfZMmV+SWtOBWagQ CLGzcy6sSZb8LXE6+VOC/Red6rA3pyUanxCD/b+VKVYr/BOx/EPo1kkjfsROHbulUPo6 OaeOcUxDIzPnElxZXm3C3yD58L9gMVJeMC+s0biBqw+Nb/6LdPOO7+nNXUoMsVrEQfTt DGWA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=lR0BPLKkgj2fJ5IyWi7flO/+WIQlLqax41QD5MIUKy0=; fh=sfgdT0UZ8CYMELEEedGcAjPKookfa29m+O/tEazxSkQ=; b=mDNMW6kpOB6/vfY1h7ec2NNYjXRa8jf3D5L4xA3FXxlbT+sbo6zv4xeQCjRGuIex6R sI5ywgDQpy4l7zDCa4Yf02N5ub5qDm5YPCnrQ36ahlFYfg5Y1UeboE2ekdRb+6UxRx0e fT0J9dd1MyIvC3q2XZmcN4DM6wIPzrcRK05LL8OI4war6yqsf1SVFp0eYLrEPhoWjJA1 /5kDHYchNdPCUyOsoDqWbotnvR4t0A4J0L7bGuDNLFugvJnrSgT48mrUtTFesb5ImFFt L/01RSN7iPjQh+FTXlRXHcUYAsZL0g+ug6oRs9fEiRgMxkIFuI+rDywYDSRtutakzAs7 brMw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ventanamicro.com header.s=google header.b=iih6pNLI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from groat.vger.email (groat.vger.email. [23.128.96.35]) by mx.google.com with ESMTPS id c15-20020a170902d48f00b001b81fe65fa3si17511268plg.569.2023.09.27.10.14.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 27 Sep 2023 10:14:36 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) client-ip=23.128.96.35; Authentication-Results: mx.google.com; dkim=pass header.i=@ventanamicro.com header.s=google header.b=iih6pNLI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id 52E0C832B164; Wed, 27 Sep 2023 10:00:41 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229530AbjI0RA2 (ORCPT + 19 others); Wed, 27 Sep 2023 13:00:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52318 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229533AbjI0RA0 (ORCPT ); Wed, 27 Sep 2023 13:00:26 -0400 Received: from mail-vs1-xe34.google.com (mail-vs1-xe34.google.com [IPv6:2607:f8b0:4864:20::e34]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 88AFCDE for ; Wed, 27 Sep 2023 10:00:24 -0700 (PDT) Received: by mail-vs1-xe34.google.com with SMTP id ada2fe7eead31-45270220069so4864788137.3 for ; Wed, 27 Sep 2023 10:00:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ventanamicro.com; s=google; t=1695834023; x=1696438823; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=lR0BPLKkgj2fJ5IyWi7flO/+WIQlLqax41QD5MIUKy0=; b=iih6pNLIRQUZMRqe3zrtvGPXNMlkAk7Rc6fRsmfK0AhRT5gg3kJcnaIx2g1Gvtw/+f 0xG6mfTE+OhsDeHBFgXdEGijpgIei4p6gT11ktSATIElzKS0RdAv+QPMPv8XzspXkhn/ pQoaVmrQtWZ11WRZvnNL8ZfxIQGRSZehYIkuh4CV6hjnIqPBFKdoncbzK4NvP3LZXZG6 3vWasTAoj0c2oEh0DBXsJRKrJu0YKH0r1lkvCDtrFufuZ02Bz4V5AeVbJY9vHeOe52e8 M0zD3cAOVVBIndccPmlbT3KLCGHR01ehPGj2HkYLUDh+YJPLoHh/H4MP6nhtwO+uYzV6 oxpw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695834023; x=1696438823; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=lR0BPLKkgj2fJ5IyWi7flO/+WIQlLqax41QD5MIUKy0=; b=b3yFBJqwcUR8uLMehWMeqnf56MCm30MLTIe/P3AOWSRY+v4tEZcb0JfpoT13IOLiha f2uoN8gUhE3Dpm2X4aAPdO9azULj8UsxT16fjWyMuALM55KW7BYvSYmzm+pZ94IBdKxk zKQeWOKOuUE/dQd7NcIlqOQdGKTe+sspnFUVBcKnnYmNQTwDpMLaHctOKYiE5lmfubhc 616Tf1JXQ01oetxrSzIB3maYwzAQZ0WATlNZxCZbHtmjb+y53m/1YV1xM1qX3LPoUuQK QGSmssQs2NSTZ8Gz8caTPY/FqgRgQiULGisw8y6X2lB1e/WWytuqJ7+ZSgecU5ro+or+ APfA== X-Gm-Message-State: AOJu0YwSV8mzokvMU5DKEn440gfYJU43UT1bosfj/G/Z2o6hlVRYKCgb 6eZzvo4H/aATl8LMlRPELUmDwA== X-Received: by 2002:a05:6102:f81:b0:452:de00:7ab4 with SMTP id e1-20020a0561020f8100b00452de007ab4mr1063401vsv.5.1695834023233; Wed, 27 Sep 2023 10:00:23 -0700 (PDT) Received: from sunil-pc.Dlink ([106.51.190.42]) by smtp.gmail.com with ESMTPSA id u7-20020a637907000000b00584b293d157sm3279396pgc.80.2023.09.27.10.00.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 27 Sep 2023 10:00:22 -0700 (PDT) From: Sunil V L To: linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, linux-acpi@vger.kernel.org Cc: Paul Walmsley , Palmer Dabbelt , Albert Ou , "Rafael J . Wysocki" , Len Brown , Daniel Lezcano , Thomas Gleixner , Andrew Jones , Conor Dooley , Anup Patel , Ard Biesheuvel , Alexandre Ghiti , Andy Shevchenko , Atish Kumar Patra , Sunil V L Subject: [PATCH v2 -next 0/4] RISC-V: ACPI improvements Date: Wed, 27 Sep 2023 22:30:11 +0530 Message-Id: <20230927170015.295232-1-sunilvl@ventanamicro.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.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 (groat.vger.email [0.0.0.0]); Wed, 27 Sep 2023 10:00:42 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1778211751837006648 X-GMAIL-MSGID: 1778211751837006648 This series is a set of patches which were originally part of RFC v1 series [1] to add ACPI support in RISC-V interrupt controllers. Since these patches are independent of the interrupt controllers, creating this new series which helps to merge instead of waiting for big series. This set of patches primarily adds support below ECR [2] which is approved by the ASWG and adds below features. - Get CBO block sizes from RHCT on ACPI based systems. - Set timer_can_not_wakeup in timer driver based on the flag in RHCT. Additionally, the series contains a patch to improve acpi_os_ioremap(). [1] - https://lore.kernel.org/lkml/20230803175202.3173957-1-sunilvl@ventanamicro.com/ [2] - https://drive.google.com/file/d/1sKbOa8m1UZw1JkquZYe3F1zQBN1xXsaf/view?usp=sharing Changes since RFC v1: 1) Separated the patches from interrupt controller support series. 2) Addressed feedback from Andy and Drew. 3) Rebased to Palmer's for-next tree. 4) Added RB tags received on RFC v1. Sunil V L (4): RISC-V: ACPI: Enhance acpi_os_ioremap with MMIO remapping RISC-V: ACPI: RHCT: Add function to get CBO block sizes RISC-V: cacheflush: Initialize CBO variables on ACPI systems clocksource/timer-riscv: ACPI: Add timer_cannot_wakeup_cpu arch/riscv/Kconfig | 1 + arch/riscv/include/asm/acpi.h | 9 ++++ arch/riscv/kernel/acpi.c | 87 ++++++++++++++++++++++++++++++- arch/riscv/mm/cacheflush.c | 37 ++++++++++--- drivers/acpi/riscv/rhct.c | 72 ++++++++++++++++++++++++- drivers/clocksource/timer-riscv.c | 4 ++ 6 files changed, 201 insertions(+), 9 deletions(-)