From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wr1-f65.google.com (mail-wr1-f65.google.com [209.85.221.65]) by mx.groups.io with SMTP id smtpd.web11.9680.1607361085823334303 for ; Mon, 07 Dec 2020 09:11:26 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@nuviainc-com.20150623.gappssmtp.com header.s=20150623 header.b=AV9UjsSV; spf=pass (domain: nuviainc.com, ip: 209.85.221.65, mailfrom: leif@nuviainc.com) Received: by mail-wr1-f65.google.com with SMTP id i2so13513839wrs.4 for ; Mon, 07 Dec 2020 09:11:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nuviainc-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=DazdXgGnd/O7fqNgyTprosjVeps4trUiJi5E5G84Djk=; b=AV9UjsSV+VN7pa/TFm/a6M8KRPKUkDOfOFHjNB1bAZuFetqE8iz1trRlBPo2DQYsSw D/qLAOQLS1Xrfj8x6s2UOgvy1AsizCoLAQR7jWFw5ZxwYz8fgx9yQCEBeBEaLKCwuGIb HQqK8SCNirhGmGoAbSG5mzWQHM67BhdvHYu53rGDzm9ODLWHJrafYGWZKIwFZhxSfFqF e143PDgCnlP/+masRUG+fNUHt+oguDeYge1V3BOGdAUUDxWJbKsWiM123huW+leq1pWN Xe0vLzPzfQP7n0hm0xnWqXAdw80rQh902ej5rz3G1bn8aY202S/5RV7RlxI5nfNqZfvt xXQA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=DazdXgGnd/O7fqNgyTprosjVeps4trUiJi5E5G84Djk=; b=Lb/Hm87UhqB1ulzuhexWbQfdlfShXDrPg/e9EH/Cp8X9G2/AdZJKGhgmN4FaF0WzhF 2TjClEJh0lh8mWliuNYg8isEEyNIa9pthbNWvAfAxhmnKHIQXslHJv3gT0rt5eKoe+Ic DWIqwsfer2GEKnqmHo6CeEMYgy7Af3cT6TQm3gtP1Ps3+Mj23woRjephCC2CDV75uytv 8yxBoe3enbuIY/WDyAO2EiwVP+Rl5L7kEpYZP3rCmoOzTfE+X6lNkSZNzLW+1rVxvzh/ SIikG8yfubnXjywSC1YINds7NGi1nPq0LqS5cOpfyvKC4f22ZOMVYPUknkHwm6S6PvgV WUEQ== X-Gm-Message-State: AOAM531zxC8S6A//5MH+7yT7Md/2VYywaEm8PBOEi5jhfn4Q22tsggfY Spypcf4GPhoQQQ6LAjqAUCi8hA== X-Google-Smtp-Source: ABdhPJy3wZQXvYarjzKwLrU/K3EtDtX/oWzUc9SD5NhYMya8/R84rzG5UucHtkoc8xamHFwNg//O2g== X-Received: by 2002:adf:b193:: with SMTP id q19mr20374237wra.426.1607361084428; Mon, 07 Dec 2020 09:11:24 -0800 (PST) Return-Path: Received: from vanye (cpc1-cmbg19-2-0-cust915.5-4.cable.virginm.net. [82.27.183.148]) by smtp.gmail.com with ESMTPSA id h5sm5758183wrp.56.2020.12.07.09.11.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 07 Dec 2020 09:11:23 -0800 (PST) Date: Mon, 7 Dec 2020 17:11:21 +0000 From: "Leif Lindholm" To: Rebecca Cran Cc: devel@edk2.groups.io, Ard Biesheuvel , Michael D Kinney , Liming Gao , Zhiguang Liu Subject: Re: [PATCH v3 3/3] ArmPkg: add Universal/Smbios as a generic SMBIOS library Message-ID: <20201207171121.GE1664@vanye> References: <20201111001748.20217-1-rebecca@nuviainc.com> <20201111001748.20217-4-rebecca@nuviainc.com> <20201119125827.GL1664@vanye> MIME-Version: 1.0 In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Sun, Dec 06, 2020 at 21:59:48 -0700, Rebecca Cran wrote: > On 11/19/20 5:58 AM, Leif Lindholm wrote: > > > > +#define MAX_HANDLE_COUNT 0x10 > > Why? > > Does this belong in a generic header? > > It's an arbitrary value, since the SMBIOS protocol doesn't have a way of > letting you know how many records of a certain type are available without > iterating through them. It might be better to just iterate twice. Sadly, yes. Avoiding hard-coding of sizes is worth some extra code. / Leif