From patchwork Fri Jul 13 16:34:42 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Leif Lindholm X-Patchwork-Id: 141937 Delivered-To: patch@linaro.org Received: by 2002:a2e:9754:0:0:0:0:0 with SMTP id f20-v6csp1011000ljj; Fri, 13 Jul 2018 09:35:09 -0700 (PDT) X-Google-Smtp-Source: AAOMgpcCTTMJXvJtFXXS9c+GgzbfQxyEODXF0wfUUyO1+iKvJV+c17NNi/rj4347A0UoJcwwnbJK X-Received: by 2002:a0c:bc8a:: with SMTP id l10-v6mr7966312qvg.130.1531499709073; Fri, 13 Jul 2018 09:35:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1531499709; cv=none; d=google.com; s=arc-20160816; b=NydcPdfiyZ51E+6O9kfcbrDmYa0ZTdiOzftlwzLN4tZKi/ouWqTnrGWTFnq9Zq/jGm noOgMkNvO9RNWZkI04drYqmYrSW1Pj2Fi0ZH9mXVNy9ZPAQsP4PqhLvBQz7AmOIHoQmc hAAdvBlW1puJUkCHW1BG+V7UgCT80ZRC1Dx6J41bc17mAI2E+2kwoxoQcqDqR19fW1ng +oay2cn5TkgN4/TcRAdXGs/Yl8GJ6Hcv+ky4lU0/8IFZJQV2Xmxial8Fbi1ppZ6FNque MUSSgXHN+od2SJCufsCp4gXol9hX9Jc65oAoPnGshX32OxuSA2thHdeIfsP1I1iAvoDb 1/2w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version:cc:reply-to :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:message-id:date:subject:to:from:dkim-signature :arc-authentication-results; bh=CJevnBUS87cR6c27OMk1T9l3VZo5t1osjJetpWjTSuU=; b=m8auGJXtjSopDzOf1meRWbHS+C6z+dLeRvLA17aXMyOkETIwbGOhS8vnYhC/k/4e+D eU+/pKKV17e8V8Y9A6kVquT+8AbqROzxdaMWQvelpww1pPboGoLzfEW7CFaHeJCt2pM9 Pqgu6cj+k3Ak6WROu1MXRMTv7N0t9pEi8ostFmzHeZ5M0XQjuFOqM4HpUZAYEmaRtupb OeplO7CJsCFU3ujz8/TX07wUi9lZZF1GPFUGQlnyR71rwOSxLkuAxyWKQxxboQDuPMS5 1oKuKiipQpg5tMj7qiU7iKxz0VHsc1EDMi1S8zrwW8PecRHMZwZlN88fq8UoQAWq/EuJ 00DA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=CfmGTdow; spf=pass (google.com: domain of grub-devel-bounces+patch=linaro.org@gnu.org designates 2001:4830:134:3::11 as permitted sender) smtp.mailfrom="grub-devel-bounces+patch=linaro.org@gnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [2001:4830:134:3::11]) by mx.google.com with ESMTPS id m3-v6si2788618qkd.194.2018.07.13.09.35.08 for (version=TLS1 cipher=AES128-SHA bits=128/128); Fri, 13 Jul 2018 09:35:09 -0700 (PDT) Received-SPF: pass (google.com: domain of grub-devel-bounces+patch=linaro.org@gnu.org designates 2001:4830:134:3::11 as permitted sender) client-ip=2001:4830:134:3::11; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=CfmGTdow; spf=pass (google.com: domain of grub-devel-bounces+patch=linaro.org@gnu.org designates 2001:4830:134:3::11 as permitted sender) smtp.mailfrom="grub-devel-bounces+patch=linaro.org@gnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:38328 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fe12C-0005eu-Dm for patch@linaro.org; Fri, 13 Jul 2018 12:35:08 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:43164) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fe11y-0005eD-4r for grub-devel@gnu.org; Fri, 13 Jul 2018 12:34:55 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fe11u-0000NA-5s for grub-devel@gnu.org; Fri, 13 Jul 2018 12:34:54 -0400 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]:33987) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fe11t-0000LT-NW for grub-devel@gnu.org; Fri, 13 Jul 2018 12:34:50 -0400 Received: by mail-wr1-x442.google.com with SMTP id c13-v6so25672234wrt.1 for ; Fri, 13 Jul 2018 09:34:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=XudT/t65ijmNlFj2vb1DUd+UAKAhEem++JlHHsJfKII=; b=CfmGTdowg4Cm1A9nTL491BL9+2h8ZimxCN/tN5RnFxN3dkeYs6PfhtVMrU67CJSVJ9 DXJddFcmxH8trwK/xRhXmUNPqEb/a1a+i4ot71crIuaM5T+WcP4u1rzOk2kyzo3O1Fqe K4dG5O5/F/LB46pfqzK/TU540qyeErTxUP+G4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=XudT/t65ijmNlFj2vb1DUd+UAKAhEem++JlHHsJfKII=; b=lkXYK4kehCk1PZEJ5paND3Um4WaIQ5xFHh333jw9x6CvkoOEOMBWWT0saEvcGep6R9 Fd1gpOqy6pFgTJzjJ3BgsHZsNLTb8S19UQvvo0x1BJemItE4zlgllnOyuhuHwhyl4LSE kyXclzQjSO9lqrPCTZFciEvMmShGp0wYrFsKN4QiN+eypUUXXtxzjdeegIM1cIAifcoq MHH+zO+nhOrSndAuz/yScRU71yxGOp/aZP69mRfEc5k34gC2taMlV2ZE+BRRDfvMp3qJ nSGJe/uSOnJC9BiE1P4LNMQFTXIf5nsinJwJVDdAV7WWgTOt+wLp8y3i07AkYDfAkKrU akIg== X-Gm-Message-State: AOUpUlGjs/J6MmqmLepfbE7atkwPpiZMbQLokptT8PwkEVGMEQh/oBu4 CmIfW9/ToeORsEm7oMkyWCDO9WpTX1U= X-Received: by 2002:a5d:5088:: with SMTP id a8-v6mr5631452wrt.37.1531499687945; Fri, 13 Jul 2018 09:34:47 -0700 (PDT) Received: from vanye.hemma.eciton.net (cpc92302-cmbg19-2-0-cust304.5-4.cable.virginm.net. [82.1.209.49]) by smtp.gmail.com with ESMTPSA id h5-v6sm16245899wrr.19.2018.07.13.09.34.46 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 13 Jul 2018 09:34:46 -0700 (PDT) From: Leif Lindholm To: grub-devel@gnu.org Subject: [PATCH 0/3] use central copy of grub_efi_find_mmap_size Date: Fri, 13 Jul 2018 17:34:42 +0100 Message-Id: <20180713163445.29478-1-leif.lindholm@linaro.org> X-Mailer: git-send-email 2.11.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::442 X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: The development of GNU GRUB Cc: Daniel Kiper MIME-Version: 1.0 Errors-To: grub-devel-bounces+patch=linaro.org@gnu.org Sender: "Grub-devel" There were multiple local implementations of functions to determine the size of buffer required to hold a UEFI memory map. Drop these and switch to grub_efi_find_mmap_size() in kern/efi/mm.c. I'm not going to lie. I no longer have an ia64 cross-toolchain, so that one is not even compile tested. Leif Lindholm (3): loader/i386/linux: use central copy of grub_efi_find_mmap_size loader/ia64/linux: use central copy of grub_efi_find_mmap_size loader/multiboot_mbi2: use central copy of grub_efi_find_mmap_size grub-core/loader/i386/linux.c | 51 +-------------------------------------- grub-core/loader/ia64/efi/linux.c | 46 ++--------------------------------- grub-core/loader/multiboot_mbi2.c | 38 +---------------------------- 3 files changed, 4 insertions(+), 131 deletions(-) -- 2.11.0 _______________________________________________ Grub-devel mailing list Grub-devel@gnu.org https://lists.gnu.org/mailman/listinfo/grub-devel Reviewed-by: Daniel Kiper for whole patch series.