From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932690AbdGSQFz (ORCPT ); Wed, 19 Jul 2017 12:05:55 -0400 Received: from scorn.kernelslacker.org ([45.56.101.199]:44908 "EHLO scorn.kernelslacker.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933158AbdGSQFh (ORCPT ); Wed, 19 Jul 2017 12:05:37 -0400 Date: Wed, 19 Jul 2017 12:05:32 -0400 From: Dave Jones To: Chris Metcalf Cc: Andrew Morton , Andrey Ryabinin , Linus Torvalds , Alexander Potapenko , Dmitry Vyukov , kasan-dev@googlegroups.com, Linux Kernel Mailing List , Chris Metcalf Subject: Re: [PATCH] lib/strscpy: avoid KASAN false positive Message-ID: <20170719160532.st4tr3jxeerwmq4h@codemonkey.org.uk> Mail-Followup-To: Dave Jones , Chris Metcalf , Andrew Morton , Andrey Ryabinin , Linus Torvalds , Alexander Potapenko , Dmitry Vyukov , kasan-dev@googlegroups.com, Linux Kernel Mailing List , Chris Metcalf References: <20170718171523.32208-1-aryabinin@virtuozzo.com> <96a21da7-1258-0ada-298f-e0388849402a@virtuozzo.com> <20170718150441.fe789a065bd97d7dd67e8b36@linux-foundation.org> <8cf46473-062e-1b7c-1756-aea57daa8e65@mellanox.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <8cf46473-062e-1b7c-1756-aea57daa8e65@mellanox.com> User-Agent: NeoMutt/20170609 (1.8.3) X-Spam-Note: SpamAssassin invocation failed Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jul 19, 2017 at 11:39:32AM -0400, Chris Metcalf wrote: > > We could just remove all that word-at-a-time logic. Do we have any > > evidence that this would harm anything? > > The word-at-a-time logic was part of the initial commit since I wanted > to ensure that strscpy could be used to replace strlcpy or strncpy without > serious concerns about performance. I'm curious what the typical length of the strings we're concerned about in this case are if this makes a difference. Dave