From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 28F7F335078 for ; Wed, 14 Jan 2026 18:20:41 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=216.40.44.17 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768414845; cv=none; b=TDVV207LtbtCCqmXWTqAsl7YwU85VLgNdDzEuk9X4CflYn8rSIk8r8IxzxC+FMkgRXSgdkt8zXpvq659FWbtWuElatmjgpPCeqMckhX8CnQHp472s49tS746Q5kW+GOr4BibTtso1ZHOx/Vy15WxXEMNAYMp8ozSnbyU0TMOiAM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768414845; c=relaxed/simple; bh=do2hokBdu17HZ8hN3Z55+TvhkGxJYgXunw/9mxO5Bx4=; h=Message-ID:Subject:From:To:Cc:Date:In-Reply-To:References: Content-Type:MIME-Version; b=imxBjAOjMCpnXs/EWv2ph8Baf7DmtBbRGGZ1OK5d6NRYVMla3M9lU0zke7mX+2jd+5b7WyHU9j+Y7oHm3092CpI+73TW6CkNNs5RB9mj6MevxmJwfRfItnnR22R/TRMcN28KaskVDXDjEJiTmdaLJpWUzq+BuvG2Cv2PAuu0egM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=perches.com; spf=pass smtp.mailfrom=perches.com; arc=none smtp.client-ip=216.40.44.17 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=perches.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=perches.com Received: from omf17.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id 629F016059B; Wed, 14 Jan 2026 18:20:38 +0000 (UTC) Received: from [HIDDEN] (Authenticated sender: joe@perches.com) by omf17.hostedemail.com (Postfix) with ESMTPA id B570E17; Wed, 14 Jan 2026 18:20:35 +0000 (UTC) Message-ID: Subject: Re: [PATCH v1] checkpatch: Warn about sign offs if there's an accidental patch separator From: Joe Perches To: Andrew Morton , Ian Rogers Cc: Kuan-Wei Chiu , Dwaipayan Ray , Lukas Bulwahn , Stephen Rothwell , Andy Whitcroft , linux-kernel@vger.kernel.org, Namhyung Kim Date: Wed, 14 Jan 2026 10:20:34 -0800 In-Reply-To: <20260113193319.701e5799059eb642bbfc9a04@linux-foundation.org> References: <20251205053457.8556-1-irogers@google.com> <195a2cba2b461a0ab99ae004bdf079b038db8b07.camel@perches.com> <45e299a4c4326d46360955758df7d3df58613255.camel@perches.com> <20260113193319.701e5799059eb642bbfc9a04@linux-foundation.org> Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.56.2 (3.56.2-2.fc42) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Stat-Signature: dmic9aykr48rkz166ozdbz5ayr151qo4 X-Rspamd-Server: rspamout03 X-Rspamd-Queue-Id: B570E17 X-Session-Marker: 6A6F6540706572636865732E636F6D X-Session-ID: U2FsdGVkX1//m/IxiYDkWeVYNxbwt9ZuzlyVdhtO3u4= X-HE-Tag: 1768414835-672448 X-HE-Meta: U2FsdGVkX1/aXPJLlbnTLqdq6U+qdK1SkvOcs6yrxU7IHGcsxaBkZsENCM0a5nbW0V2ttAnt/vbA8nkcenqaTiJyaZT0zQzHOc0KY677ZaxaYYsfd7KYYOGS5aMT4IW1LQhz+73eEtiLIGXY/L1MAxOLlelntzJsjkIifW0zPtZWEA5uS/JkTfYY4NYGLQqFSdm9O56f0emdKoMICGxMaJCnAc+u/ARNPjw4S3mpVzW1ogmIjp73Rl4C96tI82zjRgMyatWnwWV4qbvlHzs9nid9+6VEK+S0Y8YfacHpiQLuE8GxOOo16XMWyhX8FIEaXt3sdg39l2Meoc0fL9ZXF0ND1/9k16VLZ+TwOT0GDEaoFaqEpNOOJhQFHvzP7sWU On Tue, 2026-01-13 at 19:33 -0800, Andrew Morton wrote: > I was bitten by this recently. Someone's changelog had >=20 > ----------- stuff here >=20 > and git-quiltimport remove half the changelog and all the metadata. >=20 > git is wrong. I say so coz I invented the --- convention.=20 > submitting-patches.rst says >=20 > - A marker line containing simply ``---``. >=20 > The astonishingly old https://www.ozlabs.org/~akpm/stuff/tpp.txt says > "... scripts will treat a ^--- string as ...". I regret not > explicitly using "^---$". >=20 > I'd like checkpatch to emit a warning in this case. If a line starts > with --- then please let's warn the user that downstream tooling will > screw this up. Maybe something like this: --- scripts/checkpatch.pl | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index e0f1d6a6bc636..8dd58710302bc 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -3035,6 +3035,14 @@ sub process { } } =20 +# Check for invalid patch separator + if ($in_commit_log && + $line =3D~ /^---.+/) { + ERROR("BAD_PATCH_SEPARATOR", + "Invalid patch separator - some tools may have problems applying = this\n" . $herecurr) + } + =09 + # Check for patch separator if ($line =3D~ /^---$/) { $has_patch_separator =3D 1;