Received: from list by lists.gnu.org with archive (Exim 4.90_1) id 1puCtB-0000jW-KW for mharc-grub-devel@gnu.org; Wed, 03 May 2023 09:51:25 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1puCt6-0000fv-CG for grub-devel@gnu.org; Wed, 03 May 2023 09:51:22 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1puCt3-0007eO-Rp for grub-devel@gnu.org; Wed, 03 May 2023 09:51:19 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1683121877; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=G6PizaT0TxUnYS1H79emtFv5WFRCJkhr8/7yR40pqUg=; b=I6ABLm0n6w+/pT/vNPbf7gMH7TTkCPm152eMYwL9ikFDV4HOOL8GfTkdxzUKp/1Wdqpvc/ HGQ5kbC2+Cg73p6KpwMO6riSCsO7eYC8XVDEBhnNpQchZdqaeWE+EKy8Xy12C0GZwRXf0N zNkmadq8ivgKqTVwlFD4okjnTlQK/Q8= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-530-lzzzvekqPeGwz-1snsmdeQ-1; Wed, 03 May 2023 09:51:14 -0400 X-MC-Unique: lzzzvekqPeGwz-1snsmdeQ-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id CC2AA84AECA; Wed, 3 May 2023 13:51:13 +0000 (UTC) Received: from osteffen-laptop.redhat.com (unknown [10.39.193.168]) by smtp.corp.redhat.com (Postfix) with ESMTP id EA9342166B26; Wed, 3 May 2023 13:51:11 +0000 (UTC) From: Oliver Steffen To: grub-devel@gnu.org Cc: Daniel Kiper , Gerd Hoffmann , Oliver Steffen , Daniel Kiper Subject: [PATCH v7 05/10] types.h: Add GRUB_SSIZE_MAX Date: Wed, 3 May 2023 15:50:14 +0200 Message-Id: <20230503135019.101181-6-osteffen@redhat.com> In-Reply-To: <20230503135019.101181-1-osteffen@redhat.com> References: <20230503135019.101181-1-osteffen@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.6 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII"; x-default=true Received-SPF: pass client-ip=170.10.133.124; envelope-from=osteffen@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -22 X-Spam_score: -2.3 X-Spam_bar: -- X-Spam_report: (-2.3 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.161, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 03 May 2023 13:51:22 -0000 In the same way as GRUB_SIZE_MAX, add GRUB_SSIZE_MAX. Signed-off-by: Oliver Steffen Reviewed-by: Daniel Kiper --- include/grub/types.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/grub/types.h b/include/grub/types.h index c56ce9820..9f43a5580 100644 --- a/include/grub/types.h +++ b/include/grub/types.h @@ -122,6 +122,7 @@ typedef grub_uint64_t grub_size_t; typedef grub_int64_t grub_ssize_t; # define GRUB_SIZE_MAX 18446744073709551615UL +# define GRUB_SSIZE_MAX 9223372036854775807L # if GRUB_CPU_SIZEOF_LONG == 8 # define PRIxGRUB_SIZE "lx" @@ -140,6 +141,7 @@ typedef grub_uint32_t grub_size_t; typedef grub_int32_t grub_ssize_t; # define GRUB_SIZE_MAX 4294967295UL +# define GRUB_SSIZE_MAX 2147483647L # define PRIxGRUB_SIZE "x" # define PRIxGRUB_ADDR "x" -- 2.40.1