From owner-freebsd-current@freebsd.org Wed May 22 17:59:08 2019 Return-Path: Delivered-To: freebsd-current@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DE2BB15B38BC for ; Wed, 22 May 2019 17:59:08 +0000 (UTC) (envelope-from johalun@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 81EAE9166C; Wed, 22 May 2019 17:59:08 +0000 (UTC) (envelope-from johalun@FreeBSD.org) Received: from [10.46.14.95] (wsip-72-212-151-146.ph.ph.cox.net [72.212.151.146]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) (Authenticated sender: johalun) by smtp.freebsd.org (Postfix) with ESMTPSA id 18D3813746; Wed, 22 May 2019 17:59:08 +0000 (UTC) (envelope-from johalun@FreeBSD.org) Subject: Re: Weirdness when writing to pseudofs file To: Konstantin Belousov Cc: FreeBSD Current References: <6ec62e4d-9f93-ffe1-646c-3846c9308334@FreeBSD.org> <20190522175133.GC2748@kib.kiev.ua> From: Johannes Lundberg X-Tagtoolbar-Keys: D20190522105906698 Message-ID: <84e3001b-646d-b1d9-f206-577d63f79bf1@FreeBSD.org> Date: Wed, 22 May 2019 10:59:06 -0700 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: <20190522175133.GC2748@kib.kiev.ua> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Content-Language: en-US X-Rspamd-Queue-Id: 81EAE9166C X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-6.96 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; REPLY(-4.00)[]; NEURAL_HAM_SHORT(-0.96)[-0.965,0] X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 22 May 2019 17:59:09 -0000 On 5/22/19 10:51 AM, Konstantin Belousov wrote: > On Wed, May 22, 2019 at 10:36:34AM -0700, Johannes Lundberg wrote: >> Hi >> >> I'm fiddling with lindebugfs, which is based on pseudofs. When writing >> to a file, >> >> this works: # echo  1 >> /path/to/file >> >> but this does not: # echo 1 > /path/to/file >> >> "Operation not supported." is returned before the pseudofs code is even >> entered. >> >> Is this expected behavior? (if so, why?) > Does the file exist ? > > Pseudofs does not implement VOP_CREATE(), which is reasonable. Yes, it exists and my custom write function is receiving the call for ">>". (which is for example used by drm driver debugfs to do certain things on demand by accepting write to a debugfs file)