Received: by 2002:a05:7412:d8a:b0:e2:908c:2ebd with SMTP id b10csp3765448rdg; Wed, 18 Oct 2023 05:41:28 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFRebegpKD3aw3yk0MPpr4qeSFPqHHPuqg1JNGwG2jUWLKgU1ToJ0PBTzSF4SXvuOVaN9zg X-Received: by 2002:a17:903:487:b0:1c9:ff46:162d with SMTP id jj7-20020a170903048700b001c9ff46162dmr4565387plb.22.1697632887831; Wed, 18 Oct 2023 05:41:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697632887; cv=none; d=google.com; s=arc-20160816; b=z94F+evBIZqgPed6tZQuCnPEtVehKczvfeFe5O1cXaPaCzOrg1LuKY6u5KocbmWX+2 ebdwJU3GfZuKl/BvAEXtrUQdcm5H0P1uEpnBKmwd7YYOmuVXBAQlug/cFuMVfaLgkh4Q i248ETnPdpGBBsRONVGsgbDbya0NlQiv5s+hv6V5y/fZWQGok/ZOi6/rqq4CSba+FiA6 DZ15Si717iUO71QO0QhKw6yvKAgSfR9EpUpI3Os4NTosrbHeNGOIdVm0e6IJKKC2XFDI xD++FYRR5WnyKbKLRq7IAlXTFY8JyU0DYyr3Smexpbq/kDHHhMq4r5j9gFyiQSelPGE1 EvmQ== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=TgXGiaZbK4m4HiMVh4BDyfHZ4ZNWdeAQabBtO14MLJk=; fh=GA8jgg99n1wbdtGTXlvdoBzs7t1k8r/1aGEnK0qMx54=; b=FCkQUPCAPh0IXnoIdpr2HjZeIToWTlX2OFs3c1eeYXX18IERqV217w6AAt5+HGXoso HmeVyDaeLee5Igl60qnikswA40uzc5KHKml6bdoCPDMBpOboSXr9J2o+x/SDLi95jLxy Q2Am76sTOx3e8+t3tOQq9PddZ94uQ0JIrzr8dwQ1rxaeo0HB/flHc0wKmpQMbatBdiUY oJ8TM4i6/LYHUlFqjTA5ASnoxkbR5o16Fqihuw/pfqASC8ffs0eKVddCzXJaFx5odVmg /BuQIYtnPSPyUbvlHfGFvq2hMXyNTUGjyfaxGVshkUtzJMQJX7ytsHEbSILl9RzSrBAv cZhQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ventanamicro.com header.s=google header.b=TVGXfpil; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from snail.vger.email (snail.vger.email. [23.128.96.37]) by mx.google.com with ESMTPS id z18-20020a170903019200b001c6183af4d3si4296094plg.332.2023.10.18.05.41.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 Oct 2023 05:41:27 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) client-ip=23.128.96.37; Authentication-Results: mx.google.com; dkim=pass header.i=@ventanamicro.com header.s=google header.b=TVGXfpil; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 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 snail.vger.email (Postfix) with ESMTP id 332698075912; Wed, 18 Oct 2023 05:40:37 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230384AbjJRMk0 (ORCPT + 99 others); Wed, 18 Oct 2023 08:40:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37038 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230355AbjJRMkX (ORCPT ); Wed, 18 Oct 2023 08:40:23 -0400 Received: from mail-pf1-x435.google.com (mail-pf1-x435.google.com [IPv6:2607:f8b0:4864:20::435]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 387B6116 for ; Wed, 18 Oct 2023 05:40:22 -0700 (PDT) Received: by mail-pf1-x435.google.com with SMTP id d2e1a72fcca58-6b20a48522fso4385971b3a.1 for ; Wed, 18 Oct 2023 05:40:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ventanamicro.com; s=google; t=1697632821; x=1698237621; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=TgXGiaZbK4m4HiMVh4BDyfHZ4ZNWdeAQabBtO14MLJk=; b=TVGXfpilDcoTQyjcyxM4vGOMfK6awfsLvj+WpPGp0FQp/Z+prg8AehGJc8slm2Lz3o gWXch3bUg2KcUuFeX1kSPtODJcrWVAhrOk6G6JG+C8rZIFd1is8O4zsFMOMYV7MlKf1O HNT4d6U/PqZIcM9kV3KEuxFF2xRXJJ9cRB5FvWpKC3194UjbUCO7XC++Oll8622+tNWO BkQh3bIR7KwR/G9M0a/UztF/zVzBQx6f/bFcLl8YhXreyl4t6LHBLzwhBId4m+0VGZuD hYA2VXs1h9oxJe5YZscAJlZ5skygD3yGeKN4SzJKhe9GqE3VJftNmPbk/SuEaH/Tjy2k hwcg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697632821; x=1698237621; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=TgXGiaZbK4m4HiMVh4BDyfHZ4ZNWdeAQabBtO14MLJk=; b=su7tf71Q+B+3AigrHBB7vNZj0UR/jlhUH3HV/qi1KeXUQ7hg/2VVr55cdUPQxTPtLx JZiyPojHZe5tpLvPKUdk11nH41w2XMk4Pch3TZ/Ssj5KQ03bv+QAQdTcHYWrz1KortPf YI94I5g/WpDjt2QuHae8ikRqqEkAYrukx6Lkoq2SPmhH+8EYfwYsmArAy2OhTdbCiht8 5z/BsOXNvm57EDVQLFxy2iYdZJyfJ+cTGINWsBksyeFZ90sQfooBloMZ/Mq0gKHCfklD tpe3TItc+LpOWsTr8gPoa+EPMxN9gyWwU82i1KYUTvLChmmMTGsRD/Wl0WJSlCQY5NYx 9a4g== X-Gm-Message-State: AOJu0Yx0rsJMIE0tsOCXcxRbkRIosTBYV/LYsCjiX1kIv3DvygL4YF8N asc0ve329p76uWcx+WuLKemWVw== X-Received: by 2002:a05:6a00:24d4:b0:692:b6e8:ce88 with SMTP id d20-20020a056a0024d400b00692b6e8ce88mr5494314pfv.17.1697632821422; Wed, 18 Oct 2023 05:40:21 -0700 (PDT) Received: from sunil-pc.Dlink ([106.51.188.78]) by smtp.gmail.com with ESMTPSA id w190-20020a6382c7000000b005891f3af36asm1599267pgd.87.2023.10.18.05.40.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 Oct 2023 05:40:21 -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 , Andrew Jones , Conor Dooley , Anup Patel , Sunil V L Subject: [PATCH v4 -next 2/4] RISC-V: ACPI: Update the return value of acpi_get_rhct() Date: Wed, 18 Oct 2023 18:10:05 +0530 Message-Id: <20231018124007.1306159-3-sunilvl@ventanamicro.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231018124007.1306159-1-sunilvl@ventanamicro.com> References: <20231018124007.1306159-1-sunilvl@ventanamicro.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=1.2 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_SBL_CSS,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Level: * X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net 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 (snail.vger.email [0.0.0.0]); Wed, 18 Oct 2023 05:40:37 -0700 (PDT) acpi_get_rhct() currently returns pointer to acpi_table_header structure. But since this is specific to RHCT, return pointer to acpi_table_rhct structure itself. Suggested-by: Andrew Jones Signed-off-by: Sunil V L --- drivers/acpi/riscv/rhct.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/acpi/riscv/rhct.c b/drivers/acpi/riscv/rhct.c index b280b3e9c7d9..489b0e93b1e5 100644 --- a/drivers/acpi/riscv/rhct.c +++ b/drivers/acpi/riscv/rhct.c @@ -9,7 +9,7 @@ #include -static struct acpi_table_header *acpi_get_rhct(void) +static struct acpi_table_rhct *acpi_get_rhct(void) { static struct acpi_table_header *rhct; acpi_status status; @@ -26,7 +26,7 @@ static struct acpi_table_header *acpi_get_rhct(void) } } - return rhct; + return (struct acpi_table_rhct *)rhct; } /* @@ -48,7 +48,7 @@ int acpi_get_riscv_isa(struct acpi_table_header *table, unsigned int cpu, const BUG_ON(acpi_disabled); if (!table) { - rhct = (struct acpi_table_rhct *)acpi_get_rhct(); + rhct = acpi_get_rhct(); if (!rhct) return -ENOENT; } else { -- 2.39.2