Received: by 2002:a05:6358:16cc:b0:ea:6187:17c9 with SMTP id r12csp7703460rwl; Tue, 10 Jan 2023 04:27:58 -0800 (PST) X-Google-Smtp-Source: AMrXdXsbI87LGugniiC5Fnoi+VOGBUylTYuQzEy435Be3olSeMkhSXD0pBbi34Gsz3GMKywtdjYs X-Received: by 2002:a05:6a21:2d05:b0:a7:92f2:9b65 with SMTP id tw5-20020a056a212d0500b000a792f29b65mr86026750pzb.59.1673353678026; Tue, 10 Jan 2023 04:27:58 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673353678; cv=none; d=google.com; s=arc-20160816; b=g224eckqkAyImfWRxhZDuXmnqPXkLnOGWw/dV/wN2fsxTUu+Mm/VkmiPOl6Lrppogc tnFkaPFB87CxOSWdnuOEBm91dKTYsopM1A7rW/eCcyAeJT2Xl9QmD9DBhDebM/pY/2M/ lEdL3eGuxlJj2hPhPQby074s3OBy96113H7sEZvhXseOKERxdG7OGyvZINldvstVTdUN Q8r+s0TWwy1FBNrEjF6WoqikrOkXYl0XjsuBZHHmCc5G0C8XoZsyTrZbvugSAliLc4Pk WCvXNzBya19hNWuk1dXlH3y1A/BJtzFJLKeCMBl/OQhblIqBZJI9ze4ALntSSaYgJqOp sKyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=szV5uSi2lewecbhIhUNYInP6JwNl6YUB0TxKUWgBMj8=; b=nvXP9R+o9og9LTfMO2cXUOCmYB+SXLBAlz448hinrt5M4br5Y7r7hMHQSLZjzITp0h cIlvhTAgfgwgQ6XyTXQE2Sodiz4yr0+YAfbthMKa0aXDDpZVIEkTRQO63UAe7W13zkyS vMhBQjYvO/j44KXJdZ7gc/sS9IbqlD8JugyIoi0C0CSPkOJyKawdXMUG1nzULm6T0PvJ TRgTh0Dm52Ly7SkKs7e3xxGwXrBbHqKe3DyRX8tBim5o4LURzH08Tt5pneoo6xJ2Ixkk opqQMi+SK91V3VcT0bV2MEGZH+CBSk5IzPukjN47UKn4uIkVIjHFO/8n7OebXSJfiHt1 at/Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=COlt0u4o; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h62-20020a638341000000b004b3a4b58637si5174594pge.738.2023.01.10.04.27.51; Tue, 10 Jan 2023 04:27:58 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=COlt0u4o; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238025AbjAJL4W (ORCPT + 53 others); Tue, 10 Jan 2023 06:56:22 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46490 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233271AbjAJL4T (ORCPT ); Tue, 10 Jan 2023 06:56:19 -0500 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3F69A15F1C; Tue, 10 Jan 2023 03:56:18 -0800 (PST) Received: from pps.filterd (m0279864.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 30A9stBk016840; Tue, 10 Jan 2023 11:56:14 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h=message-id : date : mime-version : subject : to : cc : references : from : in-reply-to : content-type : content-transfer-encoding; s=qcppdkim1; bh=szV5uSi2lewecbhIhUNYInP6JwNl6YUB0TxKUWgBMj8=; b=COlt0u4omcrTXpav+cWJ8qbFQw4Fsk/b1pVIf0i7L3/x/LzrJ6wPeiz0x98SWjVb+axa 83gSpdG3ImWUMwowfF7ONXtVPnUEpufh6efQtWuvkPkJsdkuvPLNV0jYHLONHMRX7Yum nbSC3aaCL8oKTk12HQEwKZy2LrZ7dh2QgIjbajiyK+j6l9ddqNqv5osPrqqtyGV0mXc3 NRvY0YOF7z3rgW3jbkVCxz/mQ6LkiRY5Stg79XgwrTaX0xryrEnzmZuW2dXpmDSczb7b MbrFUU5Z6xG3nnLlDzAHsLR5RZ7q6lkb3iUu9aD6f4Ep77aksfrCyrhpjtdVyBAiCWVP mA== Received: from nalasppmta01.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3n13cngk7v-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 10 Jan 2023 11:56:14 +0000 Received: from nalasex01a.na.qualcomm.com (nalasex01a.na.qualcomm.com [10.47.209.196]) by NALASPPMTA01.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 30ABuDqL028238 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 10 Jan 2023 11:56:13 GMT Received: from [10.50.61.82] (10.80.80.8) by nalasex01a.na.qualcomm.com (10.47.209.196) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.36; Tue, 10 Jan 2023 03:56:10 -0800 Message-ID: Date: Tue, 10 Jan 2023 17:26:07 +0530 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.9.0 Subject: Re: [PATCH V0 1/1] bootconfig: Increase max size of bootconfig from 32 KB to 256 KB for DCC support Content-Language: en-US To: "Masami Hiramatsu (Google)" CC: , Bjorn Andersson , , , "Sai Prakash Ranjan" , Sibi Sankar , Rajendra Nayak References: <654357bcbfd3974072a558c494a51edafaa73e1a.1673261071.git.quic_schowdhu@quicinc.com> <20230110001820.5ca81344286f614ed4ccec77@kernel.org> From: Souradeep Chowdhury In-Reply-To: <20230110001820.5ca81344286f614ed4ccec77@kernel.org> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: nasanex01a.na.qualcomm.com (10.52.223.231) To nalasex01a.na.qualcomm.com (10.47.209.196) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-ORIG-GUID: -35SDsFvE0ty9eDrUPpPm93SYwHNP34g X-Proofpoint-GUID: -35SDsFvE0ty9eDrUPpPm93SYwHNP34g X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.923,Hydra:6.0.545,FMLib:17.11.122.1 definitions=2023-01-10_03,2023-01-10_03,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 phishscore=0 priorityscore=1501 spamscore=0 suspectscore=0 bulkscore=0 impostorscore=0 lowpriorityscore=0 mlxscore=0 mlxlogscore=986 adultscore=0 malwarescore=0 clxscore=1015 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2212070000 definitions=main-2301100072 X-Spam-Status: No, score=0.5 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_LOW, 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 lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 1/9/2023 8:48 PM, Masami Hiramatsu (Google) wrote: > On Mon, 9 Jan 2023 20:01:05 +0530 > Souradeep Chowdhury wrote: > >> Increasing the memory size of bootconfig to be able to handle a max number of >> 8192 nodes to be fitted in memory size of 256KB. > > Sorry, but you missed the 'xbc_node::data' stores the index of the data and > that is uint16_t. So the XBC_DATA_MAX is fixed limitation. > > The number of nodes (XBC_NODE_MAX) can be expanded because I just decided it > to keep the pre-compiled array size ~8KB. Maybe expanding it to 64KB just > increase the size of kernel on init memory (and freed after boot). > > Could you tell me why you need such a big data for your DCC? > > Thank you, DCC is a debugging tool used in qcom which is needed to debug crashes that can happen at boot-time. For debugging purposes a large number of registers need to be configured in DCC driver which is to be fed via the bootconfig file. For that we need to expand the nodes as well as memory for using bootconfig. Can you let us know the changes that you suggest for doing the same? Is it fine to just increase the XBC_NODE_MAX, do we also need to change the uint16_t to u32 for proper storing of index values? > >> >> Signed-off-by: Souradeep Chowdhury >> --- >> include/linux/bootconfig.h | 6 +++--- >> 1 file changed, 3 insertions(+), 3 deletions(-) >> >> diff --git a/include/linux/bootconfig.h b/include/linux/bootconfig.h >> index 1611f9d..64d233b 100644 >> --- a/include/linux/bootconfig.h >> +++ b/include/linux/bootconfig.h >> @@ -55,11 +55,11 @@ struct xbc_node { >> } __attribute__ ((__packed__)); >> >> #define XBC_KEY 0 >> -#define XBC_VALUE (1 << 15) >> -/* Maximum size of boot config is 32KB - 1 */ >> +#define XBC_VALUE (1 << 18) >> +/* Maximum size of boot config is 256KB - 1 */ >> #define XBC_DATA_MAX (XBC_VALUE - 1) >> >> -#define XBC_NODE_MAX 1024 >> +#define XBC_NODE_MAX 8192 >> #define XBC_KEYLEN_MAX 256 >> #define XBC_DEPTH_MAX 16 >> >> -- >> 2.7.4 >> > >