Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp2590641imu; Sun, 23 Dec 2018 03:20:34 -0800 (PST) X-Google-Smtp-Source: ALg8bN4XJmh7QbYnvrMhL8tWAgnAeblNQ8y7UVLLqnFZpYHNs0kAxKhAtBCO2snJ5bhzjaxxM6Iq X-Received: by 2002:a63:101:: with SMTP id 1mr8897944pgb.152.1545564034506; Sun, 23 Dec 2018 03:20:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1545564034; cv=none; d=google.com; s=arc-20160816; b=ZVyJnshBe8j0pFUUWMOHbl5TVlLHYd5ZXWhQD9ko6y6brRhXCbZ30G/pSugTLC+8er 2YME918pJC+8wZxnxgrOEanqgRnbv9qCo9RM/GhH3uY4uIO+VaifnzJSRsq1Dcu/If/b 6AcmiwY/VsRiCuGm4hzmeq8mQfQ6vnu8Vg8ItLCTXSxlXmNSJK21z5bogB7ZYQq+31Oq RHddemb2U+dydYkZUjAj8QNRBFsIe2LTGV15D8Yo8M7ran3yLaGZI1tgPEGfVjRFYiru eJwVkxO4ofXyv5EdUtrUSnPbzmwunWXxxTyxWqI3VJUGwXjmViiwLpfuh7wSgKrFypwP IUYA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=8iEjNoTJXDO0rTFZkxKW8Avwjnii7GuykR1eFRH7jmo=; b=C18n21pTCJMhb0uZMDFwmgDlpCMUqhwqHMZsS8yKnZx0JL5fy8ECAoD50ADldWwzUP Hc60Lv3x7FHZMi3A7GO7lIpCVZcpN0+ognKsf95KrJQcjzne9c6bMlv7GOkhdZrDbKS2 bU0PycpW9wtFx08XooyZirq+2fMaJLb7hJecM3wRi5/OJp+NqrbJ3gKodCorqmt1SqEL gMHHkrv9f4M5yn6a9jB0X7Bx7TbTUmpmT4/XuFKsnGE08GMvb2pmRa7sx0dUMKBUwRMU CxkfvQOegScGqrelepXucCuzfZe0RZRzubAI5k0t38dALvdTqk8v68dEUfjXysoDMfUo Ry1Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=uVqFn2H7; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a17si12666216pfn.213.2018.12.23.03.20.18; Sun, 23 Dec 2018 03:20:34 -0800 (PST) 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=@gmail.com header.s=20161025 header.b=uVqFn2H7; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387772AbeLVREo (ORCPT + 99 others); Sat, 22 Dec 2018 12:04:44 -0500 Received: from mail-wm1-f66.google.com ([209.85.128.66]:33251 "EHLO mail-wm1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729637AbeLVREo (ORCPT ); Sat, 22 Dec 2018 12:04:44 -0500 Received: by mail-wm1-f66.google.com with SMTP id r24so16363731wmh.0 for ; Sat, 22 Dec 2018 09:04:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=8iEjNoTJXDO0rTFZkxKW8Avwjnii7GuykR1eFRH7jmo=; b=uVqFn2H7UoT8MO8rl8BP6L1evcETAoaOyBSrB8mRrwusc1YIC67we/U+P/xKh3CyM1 RchPebYgppDDNlpt1S15PYLw/laoAt4oOxeePK252Fu1uud3EMwbuoZIH4NFvXeotgmz w2GrgnTJScvFF/OffKXkrE8V9LsL0U02IlI8NWBNKALZ8Cpl7Sg0ddDVwcBxfkEzwOkt xNx6V6slluKnTmGBgU/IUN/yvyahhLjEGSaxkj5csQJqAOi54h2jVDeszthwUhx1DUaa n0OlExLk5PRo3eZUcPFxxccecx1ad1NgsPfby2GB1DLkPnKUSYmNmp8lTwwhACmRJZT7 NUgQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=8iEjNoTJXDO0rTFZkxKW8Avwjnii7GuykR1eFRH7jmo=; b=OhrnHdrMnU+dcrR5qCXvASCVsLcpUk4Z2fhtniu/sWVWtiz8tfcPjlEEpyWfIBclZm upeFdPzpJSGzywlbwVapr4X0dtWMxCB6cU5ImRbabfkS4M5ePhzoXu54/iQ2Gwnrb5Bh ugYK4T4Ls8oqcHjcRELZLW7Z+4FNq3auweqm9yZz4TdWPZJWsDWd+yTkuRqOaICqAiLx uP2SApjwYuEwcmCVYMGZto4Ms5XGvOePjC4EMC4RGRxJa8uRwz+GPbrh8wr888Yc2qZ1 zKQf04b9PmLBxIegINc6xHCPacUqfMIhafwudCZffwPR4138KlH/TYtAtdtw14mvS9/0 OFoA== X-Gm-Message-State: AA+aEWbBsRWRk9Rlnar95vD7+9wLwOzXYhzLAT3Zaql6dz54iyA0TU4K FotRsWSnunIn7WWzL87NoK8BgDyk X-Received: by 2002:a1c:8acf:: with SMTP id m198mr6352209wmd.143.1545474004851; Sat, 22 Dec 2018 02:20:04 -0800 (PST) Received: from [192.168.43.227] (94.197.120.105.threembb.co.uk. [94.197.120.105]) by smtp.gmail.com with ESMTPSA id t76sm18924350wme.33.2018.12.22.02.20.03 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 22 Dec 2018 02:20:04 -0800 (PST) Subject: Re: [for-next][PATCH 23/24] string.h: Add strncmp_prefix() helper macro To: Linus Torvalds , Steven Rostedt Cc: Linux List Kernel Mailing , Ingo Molnar , Andrew Morton , Namhyung Kim , Masami Hiramatsu , Joe Perches , Tom Zanussi , Greg Kroah-Hartman References: <20181221175618.968519903@goodmis.org> <20181221175659.208858193@goodmis.org> From: Malcolm Priestley Message-ID: Date: Sat, 22 Dec 2018 10:20:02 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.2.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 21/12/2018 18:51, Linus Torvalds wrote: > On Fri, Dec 21, 2018 at 9:57 AM Steven Rostedt wrote: >> >> I figured the best thing to do is to create a helper macro and place it >> into include/linux/string.h. And go around and fix all the open coded >> versions of it later. >> >> I plan on only applying this patch and updating the tracing hooks for >> this merge window. And perhaps use it to fix some of the bugs that were >> found. > > I like the helper function concept, but as they say about CS: "There > is only one hard problem in computer science: naming and off-by-one > errors". > > And this one has that problem. The name makes absolutely no sense. > > Calling it "strncmp_prefix()" when there is no "n" there makes no sense. > > So drop the "n" from the name. > Being British the 'n' implies 'and' and still being interpreted Boolean. strncmp = string and compare Like other of our words Fish'n'Chips, Salt'n'Shake. I don't think these abbreviations exist in American English.