Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp3484951ybb; Mon, 6 Apr 2020 09:48:33 -0700 (PDT) X-Google-Smtp-Source: APiQypLq65QhbyZJ+rP6l7iKfO4g4MXvwIt7NPz+K6DJhI2GvlPrtursOiFw5x2D+qHA+QISuZ6t X-Received: by 2002:aca:df45:: with SMTP id w66mr68592oig.76.1586191713058; Mon, 06 Apr 2020 09:48:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1586191713; cv=none; d=google.com; s=arc-20160816; b=OuXWXO5rZAwIH+Q61mu3EDn3uuMO19reL95Lr/xbBwCKwwqNpYoXYgmFbm9L5YXpBc WZ5J0Vp2XVFUvoFolBuBwkMVAmrhGIv3I0hUKYoZ7gu70fT2Zgey4NIag7BPS1q0aGhQ YaL07baMZWHgF37l5kZ3PzEYelsFo7uLHySQ0NDsZACrHES6Pl8ViI7HjOX9i7tZLW/Z FVLdbXk7BGAA4LcHRYsLulATCpYPMAQokVQ9VeQ3PDVSK8BXVAvjvanDVyvgq1J871lX q+g755EtkLca2QEyru4p6QOcl+AUsfXzZPf5Zz4NmchXTkEITM0dIxhpe9k3FypS1PZa kMLQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=n6KLsIL5V6k4cItTzey0/EFVgvxOMTcpSkXR1SJgtjQ=; b=L9cdCzvrJkkG5zpvw0zptTTt5Q56d4XjgV7mjPUkUq03vy2BWugPMp1rp+9H+eTyy1 8HnFgpAkRqkR+AC8+mv/8ux6ByS9enHpKc1c+FKBiE+A19zU6CY+Fnpi0wpk643Rh3Sx 6e8/mbCC22JcvJBPqFaC89H5jvNhbXQGHqyiND5iMTOQwLCjBowlZ3aabCbmZL9ArqjJ uJscZ6c2sbx9tkTTCeulvbndEYQGabqj7ThWip5b03ydqoiIkwrN94APMPZA3j3d++yh d0E1Jxjxm78/ImEBabpbLpmKp/X4eTF6YB929lyVFDpwTAm0PuQnj3O7uIzQmGvZLpb2 a8Nw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=M1pb1wWD; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t11si7562535oig.108.2020.04.06.09.48.20; Mon, 06 Apr 2020 09:48:33 -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=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=M1pb1wWD; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729505AbgDFQqn (ORCPT + 99 others); Mon, 6 Apr 2020 12:46:43 -0400 Received: from bombadil.infradead.org ([198.137.202.133]:42964 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728735AbgDFQqn (ORCPT ); Mon, 6 Apr 2020 12:46:43 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=n6KLsIL5V6k4cItTzey0/EFVgvxOMTcpSkXR1SJgtjQ=; b=M1pb1wWDO+F6JveWkE4TuyTu2l GM52up/Ub+9M/NBHzbc+N/vpI5faViAewjHfL7qtJUTtMF0vFo7S/joX28WPkZmb1MuLHvjvBNksI k+rtfcvPwYavL0WZ6P6dFcT9Z8xcJGstFeBCml5Og9cG7DB20An7kg16oWyVVw8GVXYr/y+E27Siq hBpJyJR1QuuJTh2xScMKWG7ryaoT/64HPVjtsdRvq2b7brJgl4+OWDKIiR28rI41v2KOAavLFu99g mgAal+yLlDYw+LDkMZp3ekPIHvr4p1hZlL/bl4u/oaOuoCykWDy+qEQGAP2JY7QvdJdILOVzgrvQd gcsQPHIg==; Received: from willy by bombadil.infradead.org with local (Exim 4.92.3 #3 (Red Hat Linux)) id 1jLUtV-0002ZP-NF; Mon, 06 Apr 2020 16:46:41 +0000 Date: Mon, 6 Apr 2020 09:46:41 -0700 From: Matthew Wilcox To: Dominique Martinet Cc: Linus Torvalds , Linux Kernel Mailing List , linux-fsdevel , v9fs-developer@lists.sourceforge.net, Sergey Alirzaev Subject: Re: [GIT PULL] 9p update for 5.7 Message-ID: <20200406164641.GF21484@bombadil.infradead.org> References: <20200406110702.GA13469@nautica> <20200406164057.GA18312@nautica> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200406164057.GA18312@nautica> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Apr 06, 2020 at 06:40:57PM +0200, Dominique Martinet wrote: > Anyway, I agree looking at O_NONBLOCK for that isn't obvious. > I agree with the usecase here and posix allows short reads regardless of > the flag so the behaviour is legal either way ; the filesystem is > allowed to return whenever it wants on a whim - let's just add some docs > as you suggest unless Sergey has something to add. Ahahahahhahahahahaha. POSIX may well "allow" short reads, but userspace programmers basically never check the return value from read(). Short reads aren't actually allowed. That's why signals are only allowed to interrupt syscalls if they're fatal (and the application will never see the returned value because it's already dead).