From patchwork Mon Jun 25 17:01:27 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Leif Lindholm X-Patchwork-Id: 139870 Delivered-To: patch@linaro.org Received: by 2002:a2e:970d:0:0:0:0:0 with SMTP id r13-v6csp4236638lji; Mon, 25 Jun 2018 10:14:51 -0700 (PDT) X-Google-Smtp-Source: ADUXVKJnlVB9lmhIfhrqVr/TlpVS06ro3tIcRflyQWKGhFBkgzAGcDRyA9qZhzKAGGFfGBWsdSRS X-Received: by 2002:ac8:610a:: with SMTP id a10-v6mr12041769qtm.139.1529946891848; Mon, 25 Jun 2018 10:14:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1529946891; cv=none; d=google.com; s=arc-20160816; b=r2IX1kQDF79sREBWToAYjjYfivMSlDY09jfQTWmQlbo73wIzyDIotJzmk4yir0kHCq YPy+ewBupiNuWf6ahT6vG1FHnF8+zuoPH2rdDvmUE4Cx9gv5QuvHlARTt41lY4fLXKbi JPO9P6kLPCxMFNr9kaEYnZbxdBrnKt3tG5CaRL3JU4OzzfWn3v5ESGtxQwD/HEKFYZrl lH3x1QpmUHsPeKCTHEZRwwdsf4WaBIwOqX7+sYXKiWxyaMHBxBQZxW8aqleDDGyhUdfu 8oKbV4gxUZTtBL7bKp+jMMOmAFZUzRGAltUuSI133IKW59ssKebCrwOhLuF0Qf4Eboxe /Sfg== 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=az8jTz7AslFhWj+YzYzi5T1iegVcacD4ZlvYJVTJS2U=; b=wlxKzt1S+v5hOrnhLE3Lucfd+Z2VhPIiBDe3yiCL8Q6390gJHgyPvZmrdaMdBubdMu Sfpyb/ihtgaWdcWmzE9U+JChiNxxz3XFr5ntqFX/4vuESgAcjPcjahoXOKT5chVgBK+P IwdKCh4CrpEFf1gGwbz0/d2jIHwY0db/tSMBqw7OWXM+za9JVKbkyA0fJqoVoHENm1n5 lqB/nl8k3Qb+6sA4+RQilFM1bKJ7hRVn9XxIQNxJONs5JqhDGh9hhGI8Wed4xeodPEGn x44lMdeM8L7UGmjbk1uIlIW/kS3Z4KJhzJ4yoeX4G2Zp8RH3a/p3/53JH+DzPwOk1T+E u7KQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=MDzUNCz8; 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 z202-v6si2858343qka.185.2018.06.25.10.14.51 for (version=TLS1 cipher=AES128-SHA bits=128/128); Mon, 25 Jun 2018 10:14:51 -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=MDzUNCz8; 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]:48425 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fXV4k-0003RJ-UL for patch@linaro.org; Mon, 25 Jun 2018 13:14:50 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:40055) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fXUrw-0002nK-RX for grub-devel@gnu.org; Mon, 25 Jun 2018 13:01:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fXUru-00009Z-9A for grub-devel@gnu.org; Mon, 25 Jun 2018 13:01:36 -0400 Received: from mail-wm0-x244.google.com ([2a00:1450:400c:c09::244]:33468) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fXUru-00008v-2Q for grub-devel@gnu.org; Mon, 25 Jun 2018 13:01:34 -0400 Received: by mail-wm0-x244.google.com with SMTP id z6-v6so13066244wma.0 for ; Mon, 25 Jun 2018 10:01:33 -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=fpLi/86O3XEP0Dk3cplLUn8XBp25mlxbauxIwHELcnk=; b=MDzUNCz8C1HzFF7+V+OO6JtmnYYq0iLd9Kswnii2HWTlm3674c8Azg/LrBMcLUq7MP FcNuEGQTodlvhhVQ9763MKbcirau83A3uZBg2gpJGZQde13RPugu2JpDC9h2+QGlH5P6 wFvJa47Z9XTU1NNWsHpwzSiru3ENv86CJX4xg= 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=fpLi/86O3XEP0Dk3cplLUn8XBp25mlxbauxIwHELcnk=; b=eaWmyPq72EESwGehvDa4szKcaVkr2pmqaqGy9tTdwIPy0F8k9WZb3Vix1RNQWqYW1G I0GJr+kWX7K5SgH6pNivWvkynOw4LX36E4HP1DcnyC4mjJ8tDMKNKB1+qjf1Wnyjk4mY jukMQp4zSWJUa43IJCKeI0YWu5ZWABiRnODQw8Ag/ybrMDc8G+L1g2zSb4brjVSWxC1I vCjwVI4b8sCB8TUQdwHqG9iGMljNmEJHToir5X9BQ3tSJsx4K1ntNU8pZSnS1HfN7BfF bJ57/WRH6/o4sWYkjcrAdJhwYHHyumDVsPzhCm4MykCadf6ST80RmS1opBFpou6s9Xhq LZ7A== X-Gm-Message-State: APt69E3JSwPgxgnHcPeeeqxQLg4HIZsr+noAQcxIyBPbchRvGiaVl7GX o0ADTsu1yRG9xAkEtF3R4RSqit5moaU= X-Received: by 2002:a1c:8893:: with SMTP id k141-v6mr1625034wmd.133.1529946091686; Mon, 25 Jun 2018 10:01:31 -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 m58-v6sm23881459wrf.61.2018.06.25.10.01.30 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 25 Jun 2018 10:01:30 -0700 (PDT) From: Leif Lindholm To: grub-devel@gnu.org Subject: [PATCH 0/2] use arm*/linux.h for file command Date: Mon, 25 Jun 2018 18:01:27 +0100 Message-Id: <20180625170129.23106-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:400c:c09::244 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" We now have pretty, architecture-safe, structs and macros for kernel image headers and magic values. Use this to get rid of some hardcoding in the "file" command. Leif Lindholm (2): commands/file: use definitions from arm/linux.h commands/file: use definitions from arm64/linux.h grub-core/commands/file.c | 27 +++++++++++++-------------- 1 file changed, 13 insertions(+), 14 deletions(-) -- 2.11.0 _______________________________________________ Grub-devel mailing list Grub-devel@gnu.org https://lists.gnu.org/mailman/listinfo/grub-devel Reviewed-by: Daniel Kiper