From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr1-f68.google.com ([209.85.221.68]:41682 "EHLO mail-wr1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731648AbeLUKHR (ORCPT ); Fri, 21 Dec 2018 05:07:17 -0500 Received: by mail-wr1-f68.google.com with SMTP id x10so4597763wrs.8 for ; Fri, 21 Dec 2018 02:07:16 -0800 (PST) Date: Fri, 21 Dec 2018 13:07:12 +0300 From: Alexey Dobriyan To: Andrew Morton Cc: =?utf-8?B?TWljaGHFgiBNaXJvc8WCYXc=?= , linux-fsdevel@vger.kernel.org, David Rientjes Subject: Re: [PATCH 1/2] procfs: signal /proc/PID/comm write truncation Message-ID: <20181221100712.GA2106@avx2> References: <80bec689c8ce0d46ef64f0dbbee349b54dd4038c.1545261970.git.mirq-linux@rere.qmqm.pl> <20181220123833.c7305ae124845b36bc05cff6@linux-foundation.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20181220123833.c7305ae124845b36bc05cff6@linux-foundation.org> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Thu, Dec 20, 2018 at 12:38:33PM -0800, Andrew Morton wrote: > On Thu, 20 Dec 2018 00:28:04 +0100 Michał Mirosław wrote: > > > Keeps truncation working, but also signals to writing process > > when that happens. > > Please fully describe what is presently wrong with truncation. ie: > describe the end-user-visible effects of a bug when fixing it. Well, patch returns number of bytes actually copied instead of what write(2) is given if truncation occurs. But TASK_COMM_LEN was fixed since forever, none of this is needed. Same for the second patch, lseek(SEEK_END) is unnecessary is the size of the file is fixed.