Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp4131218pxj; Tue, 15 Jun 2021 16:21:48 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzvZCaefRaMkvI8+yYCJvrVgwki8QTVk6zGzmOSSnCYD5yL44v5cMl/1Bbf/8UkZ6GjMQon X-Received: by 2002:a5d:934d:: with SMTP id i13mr1311468ioo.164.1623799308708; Tue, 15 Jun 2021 16:21:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623799308; cv=none; d=google.com; s=arc-20160816; b=zIezoIPHyKYhnz4hxbo+N27mIdrIwpSYlIJ/Q3N9MqJrFqISAYp15A+Cqq6h6HXEgg Y7gCrpyajZ1G++2CTLVdISGSKVa/11UMHbeBqfWjI2fZk8DRrgGPUBc6fyab1O+ijogR xsbUAKr2xOj8hfbue31EIqj7a/ACMFU/4Ng+SvXEaf84AC3Mbig1NL0KNgI5s2gRGfw3 7pDNck7z5BbfQU2na7wL//yOX3L4gF36BFkjSXu2MUJuCJs+7BqfYJlOZoS40lER5o1T SiZyi3Jhf2sdzmjgU2iZaFTPM1fqsW89tQ7BpitVmndk2CpbmwRPrkSa9FU2z0qEvqPS Lyxg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:in-reply-to:content-disposition :references:message-id:subject:cc:to:from:date:dkim-signature; bh=qkDrRL+kFAdywKSAgJ0+Gvc/rzwjrV+zPz4PbZ+zNSQ=; b=i/13PpkL+95WZlHtqGvQiMnz9i5kDfS8DCCpEegH1cl5uqfd3RdYQKo9XNdi76gYFX hSZyTjaa7H7vAzvTno8OXbWhPcizCSKGYZ07B7CAW4MkwyXqJVQX5WmA4wa7E22iEsxi isi+EM71wZsvjOoGX4f7U2R4x1DKSIGx0WsYkr1BXLhy/mTnc5zxzso9J5oYHgBA5ZmS 0mgM1159dMOyQver/8uO2XIZMc8A6pO2wSsXKax+TiV+o6dISEvY3C5GSoRsnBFL/uwO eeFQY+gyQJKqR2X+xY5asLJ8xTypLglGCUavE5e8oa7stT1dG30sGmaI3iydea3H1mof Ms9g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ibm.com header.s=pp1 header.b=JvZF6dUU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h23si561172jar.116.2021.06.15.16.21.33; Tue, 15 Jun 2021 16:21:48 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@ibm.com header.s=pp1 header.b=JvZF6dUU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231403AbhFOXWL (ORCPT + 99 others); Tue, 15 Jun 2021 19:22:11 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:50452 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229811AbhFOXWK (ORCPT ); Tue, 15 Jun 2021 19:22:10 -0400 Received: from pps.filterd (m0098399.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.43/8.16.0.43) with SMTP id 15FNESC7130849; Tue, 15 Jun 2021 19:20:04 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=date : from : to : cc : subject : message-id : references : content-type : in-reply-to : mime-version; s=pp1; bh=qkDrRL+kFAdywKSAgJ0+Gvc/rzwjrV+zPz4PbZ+zNSQ=; b=JvZF6dUU8BuX394b4Y5NUK3zhFrOunn07TAua2mlsun5i8FF/h77zq4AQvHWRw3dYMVT Ji+jH7i5odeVLfhtxMgd0mjlAB9DW3x6ltIr4UmvzK2atA8aas53pP8Wc/B/NR5Iupzx xE0x9W5+rP5U0B/5VLNYblYqqYvMrFAhZk8eFbYlFsHvBO84Sy6U3mDo36tlNxpo2UTI rJPysUwjYfnnp0IP5lYg2QtUC1Dr/hF9SYdF6XQ71oMGYuZPR78w8U4OHuuvwbrxhoYr VnKejuY/sJVz7u38QaBLN05CYbfa3BSPaianmGyiZho7YDG5gGNtOkm5SBljUqvX8jRB UA== Received: from ppma05fra.de.ibm.com (6c.4a.5195.ip4.static.sl-reverse.com [149.81.74.108]) by mx0a-001b2d01.pphosted.com with ESMTP id 3975py843y-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 15 Jun 2021 19:20:03 -0400 Received: from pps.filterd (ppma05fra.de.ibm.com [127.0.0.1]) by ppma05fra.de.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 15FNCN8O029818; Tue, 15 Jun 2021 23:20:01 GMT Received: from b06avi18626390.portsmouth.uk.ibm.com (b06avi18626390.portsmouth.uk.ibm.com [9.149.26.192]) by ppma05fra.de.ibm.com with ESMTP id 394mj8gyg7-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 15 Jun 2021 23:20:01 +0000 Received: from d06av21.portsmouth.uk.ibm.com (d06av21.portsmouth.uk.ibm.com [9.149.105.232]) by b06avi18626390.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 15FNIt0V36176222 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 15 Jun 2021 23:18:55 GMT Received: from d06av21.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id C5DE552050; Tue, 15 Jun 2021 23:19:57 +0000 (GMT) Received: from localhost (unknown [9.171.72.121]) by d06av21.portsmouth.uk.ibm.com (Postfix) with ESMTPS id 7BD0C5204F; Tue, 15 Jun 2021 23:19:57 +0000 (GMT) Date: Wed, 16 Jun 2021 01:19:56 +0200 From: Vasily Gorbik To: Dimitri John Ledkov Cc: linux-kernel@vger.kernel.org, Heiko Carstens , Christian Borntraeger , linux-s390@vger.kernel.org Subject: Re: [PATCH] s390/boot: add zstd support Message-ID: References: <20210615114150.325080-1-dimitri.ledkov@canonical.com> Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20210615114150.325080-1-dimitri.ledkov@canonical.com> X-TM-AS-GCONF: 00 X-Proofpoint-GUID: vOivXIbsRptxIZXNrURxeVztOAwS0VpU X-Proofpoint-ORIG-GUID: vOivXIbsRptxIZXNrURxeVztOAwS0VpU X-Proofpoint-UnRewURL: 0 URL was un-rewritten MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.391,18.0.761 definitions=2021-06-15_07:2021-06-15,2021-06-15 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1011 impostorscore=0 malwarescore=0 adultscore=0 mlxlogscore=999 spamscore=0 suspectscore=0 phishscore=0 priorityscore=1501 bulkscore=0 lowpriorityscore=0 mlxscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2104190000 definitions=main-2106150142 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jun 15, 2021 at 12:41:50PM +0100, Dimitri John Ledkov wrote: > Enable ztsd support in s390/boot, to enable booting with zstd > compressed kernel when configured with CONFIG_KERNEL_ZSTD=y. > > BugLink: https://bugs.launchpad.net/bugs/1931725 > Signed-off-by: Dimitri John Ledkov > cc: Heiko Carstens > cc: Vasily Gorbik > cc: Christian Borntraeger > cc: linux-s390@vger.kernel.org > --- > arch/s390/Kconfig | 1 + > arch/s390/boot/compressed/Makefile | 4 ++++ > arch/s390/boot/compressed/decompressor.c | 4 ++++ > 3 files changed, 9 insertions(+) Reviewing your patch I noticed that we use wrong condition to define BOOT_HEAP_SIZE. So I made a tiny fix: diff --git a/arch/s390/boot/compressed/decompressor.c b/arch/s390/boot/compressed/decompressor.c index 3061b11c4d27..cf2571050c68 100644 --- a/arch/s390/boot/compressed/decompressor.c +++ b/arch/s390/boot/compressed/decompressor.c @@ -29,5 +29,5 @@ extern unsigned char _compressed_start[]; extern unsigned char _compressed_end[]; -#ifdef CONFIG_HAVE_KERNEL_BZIP2 +#ifdef CONFIG_KERNEL_BZIP2 #define BOOT_HEAP_SIZE 0x400000 #else And applied your patch with the following changes: Added to the commit message: """ BOOT_HEAP_SIZE is defined to 0x30000 in this case. Actual decompressor memory usage with allyesconfig is currently 0x26150. """ diff --git a/arch/s390/boot/compressed/decompressor.c b/arch/s390/boot/compressed/decompressor.c index cf2571050c68..37a4a8d33c6c 100644 --- a/arch/s390/boot/compressed/decompressor.c +++ b/arch/s390/boot/compressed/decompressor.c @@ -31,4 +31,6 @@ extern unsigned char _compressed_end[]; #ifdef CONFIG_KERNEL_BZIP2 #define BOOT_HEAP_SIZE 0x400000 +#elif CONFIG_KERNEL_ZSTD +#define BOOT_HEAP_SIZE 0x30000 #else #define BOOT_HEAP_SIZE 0x10000 I hope you are ok with that, thanks!