Received: by 2002:a25:f815:0:0:0:0:0 with SMTP id u21csp3400196ybd; Tue, 25 Jun 2019 01:48:50 -0700 (PDT) X-Google-Smtp-Source: APXvYqwhSVvjJo3niQ08qVvEeqhgSV142uOSpUaK/phVgOLBDfIO5UrKsaN2qPoTsCoX9tplc30W X-Received: by 2002:a63:fd0d:: with SMTP id d13mr38819155pgh.423.1561452530214; Tue, 25 Jun 2019 01:48:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1561452530; cv=none; d=google.com; s=arc-20160816; b=jMcQLKVPQL1XOI7JelGIj7Ocn2sujy5EeWwraVmo3zXCmVKXFzrtyGKz5Ot2wysFt5 ff2JIZlIXqFp0tEDycCxQYrL7e0hdYyTGP3ITB3bTGN1p9qEAHyY+KS1oT2snWSr/Ol6 FpH/WHVnvJq8V78/0Lto7GDvV7Kdd0W1KYPi83C1XW4T5xOIZRCDzXwQsmNIujrEd418 Co6RPxWwRcOnl319NqgQZpJRBaxgx534AvZRgO2JRV6cSYMk5ODME2/EHiEP15ZVEhHj +ChRy7oOE9FEv+Fa6LUBEMFKTApM7qgzLI1/0qls4i65lpePq4ica05dyGyIEe1pEvgF /Rew== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-disposition :content-transfer-encoding:mime-version:robot-unsubscribe:robot-id :git-commit-id:subject:to:references:in-reply-to:reply-to:cc :message-id:from:date:dkim-signature:dkim-filter; bh=r6tnFvU39VmjCmnbfgkD0LslLgpQaPrkkhyNC3Y3hjs=; b=hubi+QtS0ofV8129RGeir0OjnAmSYknie1VDK72O0/u6wMgZCu1KChuKYQacnfrKKz E9EyDBcX6P709OT+anf5RAB8smBldwat75xxiBaOeIKXE3AcOXxlco0cmmao9Nqgh02t rVgTFdTPZGterjf80wadpyzA4HNWMPowUwmJId81WaPuGol2UytyjPX+uS5Q0shO+McY pu9HUqMNij1TPOMVCBFsKJjha1HFAJEtrHZqbgrgxX7wk5p7FJQ3Zo4SWmfb7I34gvhB eRLqwFSVoHK+JvxlSUrqyVpPoszipAFsKpLwuQcsGMBSJI3bumIunG+A88dgBkEddIE8 1/SQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@zytor.com header.s=2019061801 header.b=mCjjhY47; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=zytor.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u20si12572859plq.421.2019.06.25.01.48.34; Tue, 25 Jun 2019 01:48:50 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@zytor.com header.s=2019061801 header.b=mCjjhY47; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=zytor.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730796AbfFYIrI (ORCPT + 99 others); Tue, 25 Jun 2019 04:47:08 -0400 Received: from terminus.zytor.com ([198.137.202.136]:34457 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727916AbfFYIrI (ORCPT ); Tue, 25 Jun 2019 04:47:08 -0400 Received: from terminus.zytor.com (localhost [127.0.0.1]) by terminus.zytor.com (8.15.2/8.15.2) with ESMTPS id x5P8kpbf3535966 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO); Tue, 25 Jun 2019 01:46:51 -0700 DKIM-Filter: OpenDKIM Filter v2.11.0 terminus.zytor.com x5P8kpbf3535966 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=zytor.com; s=2019061801; t=1561452412; bh=r6tnFvU39VmjCmnbfgkD0LslLgpQaPrkkhyNC3Y3hjs=; h=Date:From:Cc:Reply-To:In-Reply-To:References:To:Subject:From; b=mCjjhY47eiUszmbb/d7Jzohnfenrjyf93AZGYlUXTZOqnjxRM7j920CVKDepGzI4o uClSgoyYkVPq8aKCBQMQdwlPmdATYvDuBNmSAOrk3XUROjzvNwa6m39Ky4J38td7Nz qEwlAz0uRk2ws0h2DmBeeowEG6+HdJC8Mh8slf6Ite1J5bV+17ucaQK1JIM3gMYnPj 06gXQhsMoC6ZvqEc+Nqbp80mU3PfjLH5BbYzqHgEfyB0rE/XtkDo4boZWey+9i9kT6 kaV1p3H2TQqicedltuxYTShnwV4Hwew7sycq/wgPFPP6kmph35CHh4XaOLhQ/41XNs srRqOutnt8d/g== Received: (from tipbot@localhost) by terminus.zytor.com (8.15.2/8.15.2/Submit) id x5P8kpN63535963; Tue, 25 Jun 2019 01:46:51 -0700 Date: Tue, 25 Jun 2019 01:46:51 -0700 X-Authentication-Warning: terminus.zytor.com: tipbot set sender to tipbot@zytor.com using -f From: tip-bot for Michael Forney Message-ID: Cc: mingo@kernel.org, peterz@infradead.org, linux-kernel@vger.kernel.org, mforney@mforney.org, hpa@zytor.com, will.deacon@arm.com, boqun.feng@gmail.com, torvalds@linux-foundation.org, tglx@linutronix.de Reply-To: torvalds@linux-foundation.org, tglx@linutronix.de, boqun.feng@gmail.com, hpa@zytor.com, will.deacon@arm.com, linux-kernel@vger.kernel.org, mforney@mforney.org, mingo@kernel.org, peterz@infradead.org In-Reply-To: <20190618053306.730-1-mforney@mforney.org> References: <20190618053306.730-1-mforney@mforney.org> To: linux-tip-commits@vger.kernel.org Subject: [tip:locking/core] locking/atomics: Use sed(1) instead of non-standard head(1) option Git-Commit-ID: ebf8d82bbb32720878a3867b28e655950ccee992 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, FREEMAIL_FORGED_REPLYTO autolearn=no autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on terminus.zytor.com Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: ebf8d82bbb32720878a3867b28e655950ccee992 Gitweb: https://git.kernel.org/tip/ebf8d82bbb32720878a3867b28e655950ccee992 Author: Michael Forney AuthorDate: Mon, 17 Jun 2019 22:33:06 -0700 Committer: Ingo Molnar CommitDate: Tue, 25 Jun 2019 10:17:07 +0200 locking/atomics: Use sed(1) instead of non-standard head(1) option POSIX says the -n option must be a positive decimal integer. Not all implementations of head(1) support negative numbers meaning offset from the end of the file. Instead, the sed expression '$d' has the same effect of removing the last line of the file. Signed-off-by: Michael Forney Signed-off-by: Peter Zijlstra (Intel) Acked-by: Will Deacon Cc: Boqun Feng Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Link: https://lkml.kernel.org/r/20190618053306.730-1-mforney@mforney.org Signed-off-by: Ingo Molnar --- scripts/atomic/check-atomics.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/atomic/check-atomics.sh b/scripts/atomic/check-atomics.sh index cfa0c2f71c84..8378c63a1e09 100755 --- a/scripts/atomic/check-atomics.sh +++ b/scripts/atomic/check-atomics.sh @@ -22,7 +22,7 @@ while read header; do OLDSUM="$(tail -n 1 ${LINUXDIR}/include/${header})" OLDSUM="${OLDSUM#// }" - NEWSUM="$(head -n -1 ${LINUXDIR}/include/${header} | sha1sum)" + NEWSUM="$(sed '$d' ${LINUXDIR}/include/${header} | sha1sum)" NEWSUM="${NEWSUM%% *}" if [ "${OLDSUM}" != "${NEWSUM}" ]; then